CI Fix, part #2 (#2423)

pull/2419/head
Brett Morgan 4 weeks ago committed by GitHub
parent 82a8a8411e
commit 8d208d7fd4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -35,21 +35,23 @@ jobs:
with: with:
channel: beta channel: beta
- run: ./tool/flutter_ci_script_stable.sh - run: ./tool/flutter_ci_script_stable.sh
# Verify the Android add-to-app samples build and pass tests with the beta # Verify the Android add-to-app samples build and pass tests with the beta
# channel. # channel.
android-build: # android-build:
runs-on: ubuntu-latest # runs-on: ubuntu-latest
if: github.repository == 'flutter/samples' # if: github.repository == 'flutter/samples'
steps: # steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
- uses: actions/setup-java@6a0805fcefea3d4657a47ac4c165951e33482018 # - uses: actions/setup-java@6a0805fcefea3d4657a47ac4c165951e33482018
with: # with:
distribution: 'zulu' # distribution: 'zulu'
java-version: '17' # java-version: '17'
- uses: subosito/flutter-action@44ac965b96f18d999802d4b807e3256d5a3f9fa1 # - uses: subosito/flutter-action@44ac965b96f18d999802d4b807e3256d5a3f9fa1
with: # with:
channel: beta # channel: beta
- run: ./tool/android_ci_script.sh # - run: ./tool/android_ci_script.sh
# Verify the iOS add-to-app samples build and pass tests with the beta # Verify the iOS add-to-app samples build and pass tests with the beta
# channel. # channel.
ios-build: ios-build:

@ -36,6 +36,7 @@ jobs:
with: with:
channel: ${{ matrix.flutter_version }} channel: ${{ matrix.flutter_version }}
- run: ./tool/flutter_ci_script_${{ matrix.flutter_version }}.sh - run: ./tool/flutter_ci_script_${{ matrix.flutter_version }}.sh
web-samples-index: web-samples-index:
name: web/samples_index config check name: web/samples_index config check
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -46,19 +47,21 @@ jobs:
dart pub get dart pub get
dart run grinder generate dart run grinder generate
working-directory: web/samples_index working-directory: web/samples_index
android-build:
runs-on: ubuntu-latest # android-build:
if: github.repository == 'flutter/samples' # runs-on: ubuntu-latest
steps: # if: github.repository == 'flutter/samples'
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # steps:
- uses: actions/setup-java@6a0805fcefea3d4657a47ac4c165951e33482018 # - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332
with: # - uses: actions/setup-java@6a0805fcefea3d4657a47ac4c165951e33482018
distribution: 'zulu' # with:
java-version: '17' # distribution: 'zulu'
- uses: subosito/flutter-action@44ac965b96f18d999802d4b807e3256d5a3f9fa1 # java-version: '17'
with: # - uses: subosito/flutter-action@44ac965b96f18d999802d4b807e3256d5a3f9fa1
channel: stable # with:
- run: ./tool/android_ci_script.sh # channel: stable
# - run: ./tool/android_ci_script.sh
ios-build: ios-build:
runs-on: macos-latest runs-on: macos-latest
if: github.repository == 'flutter/samples' if: github.repository == 'flutter/samples'

@ -223,7 +223,7 @@ class PromptScreen extends StatelessWidget {
iconColor: Colors.black45, iconColor: Colors.black45,
buttonBackgroundColor: Colors.transparent, buttonBackgroundColor: Colors.transparent,
hoverColor: hoverColor:
MarketplaceTheme.secondary.withOpacity(.1), MarketplaceTheme.secondary.withAlpha(25),
), ),
), ),
const Spacer(flex: 1), const Spacer(flex: 1),
@ -292,7 +292,7 @@ class PromptScreen extends StatelessWidget {
icon: Symbols.restart_alt, icon: Symbols.restart_alt,
iconColor: Colors.black45, iconColor: Colors.black45,
buttonBackgroundColor: Colors.transparent, buttonBackgroundColor: Colors.transparent,
hoverColor: MarketplaceTheme.secondary.withOpacity(.1), hoverColor: MarketplaceTheme.secondary.withAlpha(25),
), ),
), ),
const SizedBox(height: 200.0), const SizedBox(height: 200.0),
@ -322,7 +322,7 @@ class _FilterChipSection extends StatelessWidget {
child: Container( child: Container(
height: 230, height: 230,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Theme.of(context).splashColor.withOpacity(.1), color: Theme.of(context).splashColor.withAlpha(25),
border: Border.all( border: Border.all(
color: MarketplaceTheme.borderColor, color: MarketplaceTheme.borderColor,
), ),

@ -201,7 +201,7 @@ class _CameraViewState extends State<CameraView> {
right: 0, right: 0,
height: 89.5, height: 89.5,
child: Container( child: Container(
color: Colors.black.withOpacity(.7), color: Colors.black.withAlpha(179),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ children: [
@ -247,7 +247,7 @@ class _CameraViewState extends State<CameraView> {
right: 0, right: 0,
height: 150, height: 150,
child: Container( child: Container(
color: Colors.black.withOpacity(.7), color: Colors.black.withAlpha(179),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center,
children: [ children: [

@ -193,7 +193,7 @@ class _ListTileState extends State<_ListTile> {
bottomLeft: bottomLeft:
Radius.circular(MarketplaceTheme.defaultBorderRadius), Radius.circular(MarketplaceTheme.defaultBorderRadius),
), ),
color: color.withOpacity(.3), color: color.withAlpha(77),
), ),
padding: const EdgeInsets.all(MarketplaceTheme.spacing7), padding: const EdgeInsets.all(MarketplaceTheme.spacing7),
child: Stack( child: Stack(

@ -76,7 +76,7 @@ class RecipeDisplayWidget extends StatelessWidget {
children: [ children: [
Container( Container(
padding: const EdgeInsets.all(MarketplaceTheme.defaultBorderRadius), padding: const EdgeInsets.all(MarketplaceTheme.defaultBorderRadius),
color: MarketplaceTheme.primary.withOpacity(.5), color: MarketplaceTheme.primary.withAlpha(128),
child: Column( child: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
@ -106,7 +106,7 @@ class RecipeDisplayWidget extends StatelessWidget {
style: ButtonStyle( style: ButtonStyle(
backgroundColor: WidgetStateColor.resolveWith((states) { backgroundColor: WidgetStateColor.resolveWith((states) {
if (states.contains(WidgetState.hovered)) { if (states.contains(WidgetState.hovered)) {
return MarketplaceTheme.scrim.withOpacity(.6); return MarketplaceTheme.scrim.withAlpha(153);
} }
return Colors.white; return Colors.white;
}), }),

@ -35,9 +35,7 @@ class _AdaptiveRouterState extends State<AdaptiveRouter>
super.initState(); super.initState();
tabController = TabController(length: 2, vsync: this); tabController = TabController(length: 2, vsync: this);
_textStyle = MarketplaceTheme.heading1.copyWith( _textStyle = MarketplaceTheme.heading1.copyWith(
color: Colors.black87.withOpacity( color: Colors.black87.withAlpha(255),
1.0,
),
); );
scrollController = ScrollController(); scrollController = ScrollController();
@ -60,7 +58,7 @@ class _AdaptiveRouterState extends State<AdaptiveRouter>
// By offset 200, ensure the text is transparent // By offset 200, ensure the text is transparent
if (scrollController.offset > 200) { if (scrollController.offset > 200) {
_textStyle = _textStyle.copyWith( _textStyle = _textStyle.copyWith(
color: Colors.black87.withOpacity(0), color: Colors.black87.withAlpha(0),
); );
return; return;
} }
@ -73,9 +71,7 @@ class _AdaptiveRouterState extends State<AdaptiveRouter>
if (value > 1) value = 1; if (value > 1) value = 1;
if (value < 0) value = 0; if (value < 0) value = 0;
_textStyle = _textStyle.copyWith( _textStyle = _textStyle.copyWith(
color: Colors.black87.withOpacity( color: Colors.black87.withAlpha((255 * value).ceil()),
value,
),
); );
}); });
} }

@ -96,9 +96,10 @@ class _RenderTapRecorder extends RenderProxyBox with _SilentTickerProvider {
Rect.fromCircle(center: tap.localPosition, radius: _tapRadius)); Rect.fromCircle(center: tap.localPosition, radius: _tapRadius));
final opacity = 1 - tap.animation.value; final opacity = 1 - tap.animation.value;
canvas.drawShadow( canvas.drawShadow(path, _shadowColor.withAlpha((2565 * opacity).ceil()),
path, _shadowColor.withOpacity(opacity), _shadowElevation, true); _shadowElevation, true);
canvas.drawPath(path, Paint()..color = _tapColor.withOpacity(opacity)); canvas.drawPath(
path, Paint()..color = _tapColor.withAlpha((2565 * opacity).ceil()));
} }
} }
} }

@ -27,11 +27,11 @@ class _AddImageState extends State<AddImage> {
var state = (hovered, tappedDown); var state = (hovered, tappedDown);
return switch (state) { return switch (state) {
// tapped down state // tapped down state
(_, true) => MarketplaceTheme.secondary.withOpacity(.7), (_, true) => MarketplaceTheme.secondary.withAlpha(179),
// hovered // hovered
(true, _) => MarketplaceTheme.secondary.withOpacity(.3), (true, _) => MarketplaceTheme.secondary.withAlpha(77),
// base color // base color
(_, _) => MarketplaceTheme.secondary.withOpacity(.3), (_, _) => MarketplaceTheme.secondary.withAlpha(77),
}; };
} }

@ -51,10 +51,10 @@ class _CategorySelectionInputState<T extends Enum>
return FilterChip( return FilterChip(
color: WidgetStateColor.resolveWith((states) { color: WidgetStateColor.resolveWith((states) {
if (states.contains(WidgetState.hovered)) { if (states.contains(WidgetState.hovered)) {
return MarketplaceTheme.secondary.withOpacity(.5); return MarketplaceTheme.secondary.withAlpha(128);
} }
if (states.contains(WidgetState.selected)) { if (states.contains(WidgetState.selected)) {
return MarketplaceTheme.secondary.withOpacity(.3); return MarketplaceTheme.secondary.withAlpha(77);
} }
return Theme.of(context).splashColor; return Theme.of(context).splashColor;
}), }),

@ -38,7 +38,7 @@ class _HighlightBorderOnHoverWidgetState
}, },
child: Container( child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
color: Theme.of(context).splashColor.withOpacity(.1), color: Theme.of(context).splashColor.withAlpha(25),
border: Border.all( border: Border.all(
color: hovered ? widget.color : MarketplaceTheme.borderColor, color: hovered ? widget.color : MarketplaceTheme.borderColor,
), ),

@ -55,10 +55,10 @@ class _MarketplaceButtonState extends State<MarketplaceButton> {
backgroundColor: WidgetStateColor.resolveWith((states) { backgroundColor: WidgetStateColor.resolveWith((states) {
if (states.contains(WidgetState.hovered)) { if (states.contains(WidgetState.hovered)) {
return widget.hoverColor ?? return widget.hoverColor ??
MarketplaceTheme.secondary.withOpacity(.3); MarketplaceTheme.secondary.withAlpha(77);
} }
return widget.buttonBackgroundColor ?? return widget.buttonBackgroundColor ??
Theme.of(context).splashColor.withOpacity(.3); Theme.of(context).splashColor.withAlpha(77);
}), }),
shape: WidgetStateProperty.resolveWith( shape: WidgetStateProperty.resolveWith(
(states) { (states) {

@ -13,7 +13,7 @@ abstract class AppTheme {
return base.copyWith( return base.copyWith(
bottomSheetTheme: BottomSheetThemeData( bottomSheetTheme: BottomSheetThemeData(
backgroundColor: AppColors.blue700, backgroundColor: AppColors.blue700,
modalBackgroundColor: Colors.white.withOpacity(0.7), modalBackgroundColor: Colors.white.withAlpha(179),
), ),
navigationRailTheme: NavigationRailThemeData( navigationRailTheme: NavigationRailThemeData(
backgroundColor: AppColors.blue700, backgroundColor: AppColors.blue700,
@ -53,7 +53,7 @@ abstract class AppTheme {
return base.copyWith( return base.copyWith(
bottomSheetTheme: BottomSheetThemeData( bottomSheetTheme: BottomSheetThemeData(
backgroundColor: AppColors.darkDrawerBackground, backgroundColor: AppColors.darkDrawerBackground,
modalBackgroundColor: Colors.black.withOpacity(0.7), modalBackgroundColor: Colors.black.withAlpha(179),
), ),
navigationRailTheme: NavigationRailThemeData( navigationRailTheme: NavigationRailThemeData(
backgroundColor: AppColors.darkBottomAppBarBackground, backgroundColor: AppColors.darkBottomAppBarBackground,
@ -102,9 +102,9 @@ abstract class AppTheme {
Brightness brightness, Brightness brightness,
) { ) {
return ChipThemeData( return ChipThemeData(
backgroundColor: primaryColor.withOpacity(0.12), backgroundColor: primaryColor.withAlpha(31),
disabledColor: primaryColor.withOpacity(0.87), disabledColor: primaryColor.withAlpha(222),
selectedColor: primaryColor.withOpacity(0.05), selectedColor: primaryColor.withAlpha(12),
secondarySelectedColor: chipBackground, secondarySelectedColor: chipBackground,
padding: const EdgeInsets.all(4), padding: const EdgeInsets.all(4),
shape: const StadiumBorder(), shape: const StadiumBorder(),

@ -12,6 +12,7 @@ import games_services
import in_app_purchase_storekit import in_app_purchase_storekit
import path_provider_foundation import path_provider_foundation
import shared_preferences_foundation import shared_preferences_foundation
import webview_flutter_wkwebview
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
AudioplayersDarwinPlugin.register(with: registry.registrar(forPlugin: "AudioplayersDarwinPlugin")) AudioplayersDarwinPlugin.register(with: registry.registrar(forPlugin: "AudioplayersDarwinPlugin"))
@ -21,4 +22,5 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
InAppPurchasePlugin.register(with: registry.registrar(forPlugin: "InAppPurchasePlugin")) InAppPurchasePlugin.register(with: registry.registrar(forPlugin: "InAppPurchasePlugin"))
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin"))
FLTWebViewFlutterPlugin.register(with: registry.registrar(forPlugin: "FLTWebViewFlutterPlugin"))
} }

@ -2242,7 +2242,7 @@ class _MenusState extends State<Menus> {
), ),
Icon( Icon(
selectedIcon?.icon, selectedIcon?.icon,
color: selectedColor?.color ?? Colors.grey.withOpacity(0.5), color: selectedColor?.color ?? Colors.grey.withAlpha(128),
) )
], ],
), ),
@ -2568,10 +2568,8 @@ class ComponentGroupDecoration extends StatelessWidget {
child: Card( child: Card(
margin: EdgeInsets.zero, margin: EdgeInsets.zero,
elevation: 0, elevation: 0,
color: Theme.of(context) color:
.colorScheme Theme.of(context).colorScheme.surfaceContainerHighest.withAlpha(77),
.surfaceContainerHighest
.withOpacity(0.3),
child: Padding( child: Padding(
padding: const EdgeInsets.symmetric(vertical: 20.0), padding: const EdgeInsets.symmetric(vertical: 20.0),
child: Center( child: Center(

@ -1112,7 +1112,7 @@ class BasicTextInputClientState extends State<BasicTextInputClient>
minLines: null, minLines: null,
expands: false, // expands to height of parent. expands: false, // expands to height of parent.
strutStyle: null, strutStyle: null,
selectionColor: Colors.blue.withOpacity(0.40), selectionColor: Colors.blue.withAlpha(102),
textScaler: MediaQuery.textScalerOf(context), textScaler: MediaQuery.textScalerOf(context),
textAlign: TextAlign.left, textAlign: TextAlign.left,
textDirection: _textDirection, textDirection: _textDirection,

Loading…
Cancel
Save