Skip to content

Instantly share code, notes, and snippets.

@CarloTerracciano
Created September 2, 2024 10:04
Show Gist options
  • Save CarloTerracciano/0dbaa56ffe66748f83434e896a0c7c67 to your computer and use it in GitHub Desktop.
Save CarloTerracciano/0dbaa56ffe66748f83434e896a0c7c67 to your computer and use it in GitHub Desktop.
Generated code from pixels2flutter.dev
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
debugShowCheckedModeBanner: false,
home: Scaffold(
body: Center(
child: Stack(
alignment: Alignment.topRight,
children: [
Container(
width: 100,
height: 100,
decoration: BoxDecoration(
color: Colors.blue,
borderRadius: BorderRadius.circular(20),
),
),
Positioned(
top: -10,
right: -10,
child: Container(
width: 50,
height: 50,
decoration: BoxDecoration(
color: Colors.yellow,
borderRadius: BorderRadius.circular(15),
),
child: Center(
child: Icon(
Icons.close,
color: Colors.white,
size: 30,
),
),
),
),
],
),
),
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment