Initial commit

This commit is contained in:
2026-03-21 01:34:22 +01:00
parent 8ec17d5ed4
commit 6805f4a3f4
144 changed files with 7312 additions and 13 deletions

View File

@@ -0,0 +1,46 @@
import 'package:flutter/material.dart';
class BrightnessSlider extends StatelessWidget {
final double value;
final ValueChanged<double> onChanged;
final ValueChanged<double>? onChangeEnd;
const BrightnessSlider({
super.key,
required this.value,
required this.onChanged,
this.onChangeEnd,
});
@override
Widget build(BuildContext context) {
return Row(
children: [
const Icon(Icons.brightness_low, color: Colors.grey, size: 20),
Expanded(
child: SliderTheme(
data: SliderTheme.of(context).copyWith(
activeTrackColor: Colors.amber,
thumbColor: Colors.amber,
inactiveTrackColor: Colors.grey.shade800,
),
child: Slider(
value: value,
min: 0.0,
max: 1.0,
divisions: 20,
onChanged: onChanged,
onChangeEnd: onChangeEnd,
),
),
),
const Icon(Icons.brightness_high, color: Colors.amber, size: 20),
const SizedBox(width: 8),
Text(
'${(value * 100).round()}%',
style: TextStyle(color: Colors.grey.shade400, fontSize: 13),
),
],
);
}
}