diff --git a/lib/src/components/inputs/form/y_form_field.dart b/lib/src/components/inputs/form/y_form_field.dart index ba218f9..0c363cd 100644 --- a/lib/src/components/inputs/form/y_form_field.dart +++ b/lib/src/components/inputs/form/y_form_field.dart @@ -163,19 +163,19 @@ class _CustomActions { builder: (BuildContext context, Widget? child) => Theme( data: ThemeData( colorScheme: _colorScheme(Brightness.light), - dialogBackgroundColor: theme.colors.backgroundLightColor, buttonTheme: const ButtonThemeData(textTheme: ButtonTextTheme.primary), textTheme: - TextTheme(subtitle1: theme.texts.body1.copyWith(color: theme.colors.foregroundColor, height: 1.5)), + TextTheme(titleMedium: theme.texts.body1.copyWith(color: theme.colors.foregroundColor, height: 1.5)), inputDecorationTheme: InputDecorationTheme( filled: true, fillColor: theme.colors.backgroundColor, contentPadding: YPadding.p(YScale.s3), border: UnderlineInputBorder(borderSide: BorderSide.none, borderRadius: YBorderRadius.lg), labelStyle: theme.texts.body1, - )), + ), dialogTheme: DialogThemeData(backgroundColor: theme.colors.backgroundLightColor)), child: child!)); if (date != null) return DateFormat("dd/MM/yyyy").format(date); + return null; } static Future pickDateRange( @@ -192,15 +192,15 @@ class _CustomActions { builder: (BuildContext context, Widget? child) => Theme( data: ThemeData( colorScheme: _colorScheme(theme.isDark ? Brightness.dark : Brightness.light), - dialogBackgroundColor: theme.colors.backgroundLightColor, buttonTheme: const ButtonThemeData(textTheme: ButtonTextTheme.primary), textTheme: - TextTheme(subtitle1: theme.texts.body1.copyWith(color: theme.colors.foregroundColor, height: 1.5)), + TextTheme(titleMedium: theme.texts.body1.copyWith(color: theme.colors.foregroundColor, height: 1.5)), dialogTheme: DialogThemeData(backgroundColor: theme.colors.backgroundLightColor), ), child: child!)); if (date != null) { - return DateFormat("dd/MM/yyyy").format(date.start) + " - " + DateFormat("dd/MM/yyyy").format(date.end); + return "${DateFormat("dd/MM/yyyy").format(date.start)} - ${DateFormat("dd/MM/yyyy").format(date.end)}"; } + return null; } static Future pickOption(BuildContext context, @@ -214,6 +214,7 @@ class _CustomActions { ), ); if (res != null) return "$res. ${options[res].label}"; + return null; } static Future pickTime(BuildContext context, {required TimeOfDay initialTime}) async { @@ -227,16 +228,15 @@ class _CustomActions { ), child: child!)); if (time != null) return "${time.hour.toString().padLeft(2, '0')}:${time.minute.toString().padLeft(2, '0')}"; + return null; } static ColorScheme _colorScheme(Brightness brightness) => ColorScheme( - background: theme.colors.backgroundLightColor, // Useless - onBackground: theme.colors.foregroundColor, // Useless primary: theme.colors.primary.backgroundColor, - primaryVariant: theme.colors.primary.lightColor, + primaryContainer: theme.colors.primary.lightColor, onPrimary: theme.colors.primary.foregroundColor, secondary: theme.colors.backgroundLightColor, // Useless - secondaryVariant: theme.colors.backgroundColor, // Useless + secondaryContainer: theme.colors.backgroundColor, // Useless onSecondary: theme.colors.foregroundColor, // Useless surface: theme.colors.backgroundLightColor, onSurface: theme.colors.foregroundColor, diff --git a/lib/src/components/y_scrollbar.dart b/lib/src/components/y_scrollbar.dart index 136c7bd..0eb811c 100644 --- a/lib/src/components/y_scrollbar.dart +++ b/lib/src/components/y_scrollbar.dart @@ -9,7 +9,7 @@ class YScrollbar extends StatelessWidget { @override Widget build(BuildContext context) { return RawScrollbar( - isAlwaysShown: isAlwaysShown, + thumbVisibility: true, thumbColor: theme.colors.foregroundLightColor, radius: Radius.circular(YScale.s2), thickness: YScale.s2, diff --git a/lib/src/theme/theme.dart b/lib/src/theme/theme.dart index c6790ec..88ccd69 100644 --- a/lib/src/theme/theme.dart +++ b/lib/src/theme/theme.dart @@ -45,15 +45,13 @@ class YTheme { ThemeData get themeData => ThemeData( colorScheme: ColorScheme( primary: colors.backgroundLightColor, - primaryVariant: colors.backgroundColor, + primaryContainer: colors.backgroundColor, onPrimary: colors.foregroundColor, secondary: colors.primary.backgroundColor, - secondaryVariant: colors.primary.lightColor, + secondaryContainer: colors.primary.lightColor, onSecondary: colors.primary.foregroundColor, error: colors.danger.backgroundColor, onError: colors.danger.foregroundColor, - background: colors.backgroundColor, - onBackground: colors.foregroundColor, surface: colors.backgroundLightColor, onSurface: colors.foregroundLightColor, brightness: theme.isDark ? Brightness.dark : Brightness.light, diff --git a/pubspec.lock b/pubspec.lock index 9aebd6c..1c5a16d 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -5,74 +5,74 @@ packages: dependency: "direct main" description: name: another_flushbar - sha256: "7fc3a5e61f88dcf096d6637945c705fdd73cac011bda50103c649cd825621736" + sha256: "2b99671c010a7d5770acf5cb24c9f508b919c3a7948b6af9646e773e7da7b757" url: "https://pub.dev" source: hosted - version: "1.10.29" + version: "1.12.32" async: dependency: transitive description: name: async - sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" + sha256: "758e6d74e971c3e5aceb4110bfd6698efc7f501675bcfe0c775459a8140750eb" url: "https://pub.dev" source: hosted - version: "2.11.0" + version: "2.13.0" boolean_selector: dependency: transitive description: name: boolean_selector - sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" + sha256: "8aab1771e1243a5063b8b0ff68042d67334e3feab9e95b9490f9a6ebf73b42ea" url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" characters: dependency: transitive description: name: characters - sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" + sha256: f71061c654a3380576a52b451dd5532377954cf9dbd272a78fc8479606670803 url: "https://pub.dev" source: hosted - version: "1.3.0" + version: "1.4.0" clock: dependency: transitive description: name: clock - sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf + sha256: fddb70d9b5277016c77a80201021d40a2247104d9f4aa7bab7157b7e3f05b84b url: "https://pub.dev" source: hosted - version: "1.1.1" + version: "1.1.2" collection: dependency: transitive description: name: collection - sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c" + sha256: "2f5709ae4d3d59dd8f7cd309b4e023046b57d8a6c82130785d2b0e5868084e76" url: "https://pub.dev" source: hosted - version: "1.17.1" + version: "1.19.1" crypto: dependency: transitive description: name: crypto - sha256: cf75650c66c0316274e21d7c43d3dea246273af5955bd94e8184837cd577575c + sha256: c8ea0233063ba03258fbcf2ca4d6dadfefe14f02fab57702265467a19f27fadf url: "https://pub.dev" source: hosted - version: "3.0.1" + version: "3.0.7" equatable: dependency: "direct main" description: name: equatable - sha256: c6094fd1efad3046334a9c40bee022147e55c25401ccd89b94e373e3edadd375 + sha256: "3e0141505477fd8ad55d6eb4e7776d3fe8430be8e497ccb1521370c3f21a3e2b" url: "https://pub.dev" source: hosted - version: "2.0.3" + version: "2.0.8" fake_async: dependency: transitive description: name: fake_async - sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78" + sha256: "5368f224a74523e8d2e7399ea1638b37aecfca824a3cc4dfdf77bf1fa905ac44" url: "https://pub.dev" source: hosted - version: "1.3.1" + version: "1.3.3" flutter: dependency: "direct main" description: flutter @@ -82,10 +82,10 @@ packages: dependency: "direct dev" description: name: flutter_lints - sha256: "2118df84ef0c3ca93f96123a616ae8540879991b8b57af2f81b76a7ada49b2a4" + sha256: a25a15ebbdfc33ab1cd26c63a6ee519df92338a9c10f122adda92938253bef04 url: "https://pub.dev" source: hosted - version: "2.0.2" + version: "2.0.3" flutter_responsive_breakpoints: dependency: "direct main" description: @@ -115,14 +115,30 @@ packages: url: "https://pub.dev" source: hosted version: "0.18.1" - js: + leak_tracker: + dependency: transitive + description: + name: leak_tracker + sha256: "33e2e26bdd85a0112ec15400c8cbffea70d0f9c3407491f672a2fad47915e2de" + url: "https://pub.dev" + source: hosted + version: "11.0.2" + leak_tracker_flutter_testing: + dependency: transitive + description: + name: leak_tracker_flutter_testing + sha256: "1dbc140bb5a23c75ea9c4811222756104fbcd1a27173f0c34ca01e16bea473c1" + url: "https://pub.dev" + source: hosted + version: "3.0.10" + leak_tracker_testing: dependency: transitive description: - name: js - sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3 + name: leak_tracker_testing + sha256: "8d5a2d49f4a66b49744b23b018848400d23e54caf9463f4eb20df3eb8acb2eb1" url: "https://pub.dev" source: hosted - version: "0.6.7" + version: "3.0.2" lints: dependency: transitive description: @@ -135,26 +151,26 @@ packages: dependency: transitive description: name: matcher - sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb" + sha256: dc58c723c3c24bf8d3e2d3ad3f2f9d7bd9cf43ec6feaa64181775e60190153f2 url: "https://pub.dev" source: hosted - version: "0.12.15" + version: "0.12.17" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 + sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec url: "https://pub.dev" source: hosted - version: "0.2.0" + version: "0.11.1" meta: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + sha256: "23f08335362185a5ea2ad3a4e597f1375e78bce8a040df5c600c8d3552ef2394" url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.17.0" nested: dependency: transitive description: @@ -167,95 +183,103 @@ packages: dependency: transitive description: name: path - sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" + sha256: "75cca69d1490965be98c73ceaea117e8a04dd21217b37b292c9ddbec0d955bc5" url: "https://pub.dev" source: hosted - version: "1.8.3" + version: "1.9.1" provider: dependency: "direct main" description: name: provider - sha256: "7896193cf752c40ba7f7732a95264319a787871e5d628225357f5c909182bc06" + sha256: "4e82183fa20e5ca25703ead7e05de9e4cceed1fbd1eadc1ac3cb6f565a09f272" url: "https://pub.dev" source: hosted - version: "6.0.2" + version: "6.1.5+1" sky_engine: dependency: transitive description: flutter source: sdk - version: "0.0.99" + version: "0.0.0" source_span: dependency: transitive description: name: source_span - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 + sha256: "56a02f1f4cd1a2d96303c0144c93bd6d909eea6bee6bf5a0e0b685edbd4c47ab" url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.2" stack_trace: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 + sha256: "8b27215b45d22309b5cddda1aa2b19bdfec9df0e765f2de506401c071d38d1b1" url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.12.1" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" + sha256: "969e04c80b8bcdf826f8f16579c7b14d780458bd97f56d107d3950fdbeef059d" url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.4" string_scanner: dependency: transitive description: name: string_scanner - sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" + sha256: "921cd31725b72fe181906c6a94d987c78e3b98c2e205b397ea399d4054872b43" url: "https://pub.dev" source: hosted - version: "1.2.0" + version: "1.4.1" term_glyph: dependency: transitive description: name: term_glyph - sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 + sha256: "7f554798625ea768a7518313e58f83891c7f5024f88e46e7182a4558850a4b8e" url: "https://pub.dev" source: hosted - version: "1.2.1" + version: "1.2.2" test_api: dependency: transitive description: name: test_api - sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb + sha256: ab2726c1a94d3176a45960b6234466ec367179b87dd74f1611adb1f3b5fb9d55 url: "https://pub.dev" source: hosted - version: "0.5.1" + version: "0.7.7" typed_data: dependency: transitive description: name: typed_data - sha256: "53bdf7e979cfbf3e28987552fd72f637e63f3c8724c9e56d9246942dc2fa36ee" + sha256: f9049c039ebfeb4cf7a7104a675823cd72dba8297f264b6637062516699fa006 url: "https://pub.dev" source: hosted - version: "1.3.0" + version: "1.4.0" uuid: dependency: "direct main" description: name: uuid - sha256: "00ba1241ff12e77d8059eeb1f102b35235df01661a6110afd165ab52a0fc7714" + sha256: "648e103079f7c64a36dc7d39369cabb358d377078a051d6ae2ad3aa539519313" url: "https://pub.dev" source: hosted - version: "3.0.5" + version: "3.0.7" vector_math: dependency: transitive description: name: vector_math - sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" + sha256: d530bd74fea330e6e364cda7a85019c434070188383e1cd8d9777ee586914c5b url: "https://pub.dev" source: hosted - version: "2.1.4" + version: "2.2.0" + vm_service: + dependency: transitive + description: + name: vm_service + sha256: "45caa6c5917fa127b5dbcfbd1fa60b14e583afdc08bfc96dda38886ca252eb60" + url: "https://pub.dev" + source: hosted + version: "15.0.2" sdks: - dart: ">=3.0.0 <4.0.0" - flutter: ">=1.17.0" + dart: ">=3.8.0-0 <4.0.0" + flutter: ">=3.18.0-18.0.pre.54"