import 'package:flutter/material.dart'; import 'package:vbvs_app/common/util/FitTool.dart'; import 'package:vbvs_app/component/tool/ClickableContainer.dart'; class SleepdateWidget extends StatelessWidget { final DateTime date; final bool isSelected; final VoidCallback onTap; const SleepdateWidget({ super.key, required this.date, required this.isSelected, required this.onTap, }); @override Widget build(BuildContext context) { return ClickableContainer( onTap: onTap, backgroundColor: Colors.transparent, highlightColor: Colors.transparent, padding: EdgeInsets.all(4.rpx), child: Container( width: 90.rpx, height: 90.rpx, decoration: BoxDecoration( borderRadius: BorderRadius.circular(30.rpx), color: isSelected ? Colors.black : Colors.transparent, ), child: Padding( padding: EdgeInsetsDirectional.fromSTEB(10.rpx, 10.rpx, 10.rpx, 10.rpx), child: Container( decoration: BoxDecoration( color: Color(0xFFDC1C1C), shape: BoxShape.circle, ), child: Align( alignment: AlignmentDirectional(0, 0), child: Text( '${date.day}', style: TextStyle( color: Colors.white, fontSize: 26.rpx, letterSpacing: 0.0, ), ), ), ), ), ), ); } }