Skip to content

Instantly share code, notes, and snippets.

@rena2019
rena2019 / main.dart
Created October 7, 2025 13:50
different text styles in 1 Text
//different text styles in 1 Text
import 'package:flutter/material.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@rena2019
rena2019 / main.dart
Created September 30, 2025 14:16
Figma button with shadow
import 'package:flutter/material.dart';
//figma button with shadow
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
MyApp({super.key});
@rena2019
rena2019 / main.dart
Last active September 30, 2025 12:57
flutter image placeholder
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
MyApp({super.key});
@override
@rena2019
rena2019 / main.dart
Created September 24, 2025 14:20
Progress Popup Widget with Stream
import 'dart:async';
import 'package:flutter/material.dart';
//Progress Popup Widget with Stream
/// Beispiel-Datenmodell, das vom Stream gesendet wird.
class MyStreamData {
final double progress; // 0.0 .. 1.0
final String? message;
final bool done;
@rena2019
rena2019 / main.dart
Created September 24, 2025 14:18
Overlay Popup with Stream
import 'dart:async';
import 'package:flutter/material.dart';
//Overlay Popup with Stream
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) => MaterialApp(home: HomePage());
}
@rena2019
rena2019 / main.dart
Created September 15, 2025 05:43
Flutter showDialog
// showDialog
/*
onPressed: () {
showDialog(
context: context,
builder: (context) {
return Dialog(
child: Text('DIALOG'),
);
},
@rena2019
rena2019 / main.dart
Created September 10, 2025 11:56
Flutter Shadow with CustomPainter
import 'package:flutter/material.dart';
//Flutter Shadow with CustomPainter
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@rena2019
rena2019 / main.dart
Last active September 10, 2025 07:40
Button with BoxDecoration
//Button with BoxDecoration
//Button with BoxDecoration
import 'package:flutter/material.dart';
void main() => runApp(const MyApp());
class MyApp extends StatelessWidget {
const MyApp({super.key});
@rena2019
rena2019 / main.dart
Last active September 5, 2025 17:59
Flutter Animation/Tween (replace Widget) 2
// Flutter Animation/Tween (replace Widget) 2
import 'package:flutter/material.dart';
void main() => runApp(TimeSlideApp());
class TimeSlideApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
@rena2019
rena2019 / main.dart
Created September 5, 2025 17:33
Flutter Animation/Tween (replace Widget)
// Flutter Animation/Tween (replace Widget)
import 'package:flutter/material.dart';
import 'package:intl/intl.dart'; // add intl in pubspec.yaml oder entfernen und eigene Formatierung nutzen
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {