-
Notifications
You must be signed in to change notification settings - Fork 29.8k
Closed
flutter/engine
#12081Labels
c: performanceRelates to speed or footprint issues (see "perf:" labels)Relates to speed or footprint issues (see "perf:" labels)platform-webWeb applications specificallyWeb applications specifically
Description
Pretty sure Radial Gradient doesn't work in flutter for web.
Code
import 'package:flutter_web/material.dart';
import 'dart:async';
import 'dart:math' as math;
import 'package:flutter_web/rendering.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: MyHomePage()
);
}
}
class MyHomePage extends StatelessWidget {
MyHomePage({Key key, this.title}) : super(key: key);
final String title;
@override
Widget build(BuildContext context) {
return Scaffold(
body: CustomScrollView(
slivers: <Widget>[
SliverAppBar(
expandedHeight: 400,
centerTitle: true,
pinned: true,
title: Text("lasagna"),
flexibleSpace: FlexibleSpaceBar(
background: Container(
decoration: BoxDecoration(
gradient: RadialGradient(
colors: [const Color (0xFF8E78FF) , const Color (0xFFBA7AC9)],
center:const Alignment(0,0),
radius: 0.2,
)
),
)
)
),
],
)
);
}
}
I don't get error's page renders like this.
Metadata
Metadata
Assignees
Labels
c: performanceRelates to speed or footprint issues (see "perf:" labels)Relates to speed or footprint issues (see "perf:" labels)platform-webWeb applications specificallyWeb applications specifically