@@ -104,35 +104,35 @@ const Color _kDialogColor = CupertinoDynamicColor.withBrightness(
104104// Translucent light gray that is painted on top of the blurred backdrop as the
105105// background color of a pressed button.
106106// Eyeballed from iOS 13 beta simulator.
107- const Color _kDialogPressedColor = CupertinoDynamicColor .withBrightness (
107+ const Color _kPressedColor = CupertinoDynamicColor .withBrightness (
108108 color: Color (0xFFE1E1E1 ),
109109 darkColor: Color (0xFF2E2E2E ),
110110);
111111
112- // Translucent light gray that is painted on top of the blurred backdrop as the
113- // background color of a pressed button.
114- // Eyeballed from iOS 17 simulator.
115- const Color _kActionSheetPressedColor = Color (0xCAE0E0E0 );
116-
117- const Color _kActionSheetCancelColor = Color (0xFFFFFFFF );
118- const Color _kActionSheetCancelPressedColor = Color (0xFFECECEC );
112+ const Color _kActionSheetCancelPressedColor = CupertinoDynamicColor .withBrightness (
113+ color: Color (0xFFECECEC ),
114+ darkColor: Color (0xFF49494B ),
115+ );
119116
120117// Translucent, very light gray that is painted on top of the blurred backdrop
121118// as the action sheet's background color.
122119// TODO(LongCatIsLooong): https://github.com/flutter/flutter/issues/39272. Use
123120// System Materials once we have them.
124- // Eyeballed from iOS 17 simulator.
125- const Color _kActionSheetBackgroundColor = Color (0xC8FCFCFC );
121+ // Extracted from https://developer.apple.com/design/resources/.
122+ const Color _kActionSheetBackgroundColor = CupertinoDynamicColor .withBrightness (
123+ color: Color (0xC7F9F9F9 ),
124+ darkColor: Color (0xC7252525 ),
125+ );
126126
127127// The gray color used for text that appears in the title area.
128- // Eyeballed from iOS 17 simulator .
129- const Color _kActionSheetContentTextColor = Color (0x851D1D1D );
128+ // Extracted from https://developer.apple.com/design/resources/ .
129+ const Color _kActionSheetContentTextColor = Color (0xFF8F8F8F );
130130
131131// Translucent gray that is painted on top of the blurred backdrop in the gap
132132// areas between the content section and actions section, as well as between
133133// buttons.
134- // Eyeballed from iOS 17 simulator.
135- const Color _kActionSheetButtonDividerColor = Color ( 0xD4C9C9C9 ) ;
134+ // Eye-balled from iOS 13 beta simulator.
135+ const Color _kActionSheetButtonDividerColor = _kActionSheetContentTextColor ;
136136
137137// The alert dialog layout policy changes depending on whether the user is using
138138// a "regular" font size vs a "large" font size. This is a spectrum. There are
@@ -1115,19 +1115,19 @@ class _ActionSheetButtonBackgroundState extends State<_ActionSheetButtonBackgrou
11151115 BorderRadius ? borderRadius;
11161116 if (! widget.isCancel) {
11171117 backgroundColor = isBeingPressed
1118- ? _kActionSheetPressedColor
1119- : _kActionSheetBackgroundColor;
1118+ ? _kPressedColor
1119+ : CupertinoDynamicColor . resolve ( _kActionSheetBackgroundColor, context) ;
11201120 } else {
11211121 backgroundColor = isBeingPressed
1122- ? _kActionSheetCancelPressedColor
1123- : _kActionSheetCancelColor ;
1122+ ? _kActionSheetCancelPressedColor
1123+ : CupertinoColors .secondarySystemGroupedBackground ;
11241124 borderRadius = const BorderRadius .all (Radius .circular (_kCornerRadius));
11251125 }
11261126 return MetaData (
11271127 metaData: this ,
11281128 child: Container (
11291129 decoration: BoxDecoration (
1130- color: CupertinoDynamicColor . resolve ( backgroundColor, context) ,
1130+ color: backgroundColor,
11311131 borderRadius: borderRadius,
11321132 ),
11331133 child: widget.child,
@@ -2269,7 +2269,7 @@ class _CupertinoDialogActionsRenderWidget extends MultiChildRenderObjectWidget {
22692269 : _kCupertinoDialogWidth,
22702270 dividerThickness: _dividerThickness,
22712271 dialogColor: CupertinoDynamicColor .resolve (_kDialogColor, context),
2272- dialogPressedColor: CupertinoDynamicColor .resolve (_kDialogPressedColor , context),
2272+ dialogPressedColor: CupertinoDynamicColor .resolve (_kPressedColor , context),
22732273 dividerColor: CupertinoDynamicColor .resolve (CupertinoColors .separator, context),
22742274 hasCancelButton: _hasCancelButton,
22752275 );
@@ -2283,7 +2283,7 @@ class _CupertinoDialogActionsRenderWidget extends MultiChildRenderObjectWidget {
22832283 : _kCupertinoDialogWidth
22842284 ..dividerThickness = _dividerThickness
22852285 ..dialogColor = CupertinoDynamicColor .resolve (_kDialogColor, context)
2286- ..dialogPressedColor = CupertinoDynamicColor .resolve (_kDialogPressedColor , context)
2286+ ..dialogPressedColor = CupertinoDynamicColor .resolve (_kPressedColor , context)
22872287 ..dividerColor = CupertinoDynamicColor .resolve (CupertinoColors .separator, context)
22882288 ..hasCancelButton = _hasCancelButton;
22892289 }
0 commit comments