Skip to content

Instantly share code, notes, and snippets.

View aloisdeniel's full-sized avatar
🤘
Flutter / Figma / Firebase rock!

Aloïs Deniel aloisdeniel

🤘
Flutter / Figma / Firebase rock!
View GitHub Profile
@aloisdeniel
aloisdeniel / slide.dart
Last active December 19, 2023 10:13
FittedBox
import 'package:flutter/material.dart';
const Color darkBlue = Color.fromARGB(255, 18, 32, 47);
const availableSizes = <Size?>[
null,
Size(1920, 1080),
Size(720, 480),
];
@aloisdeniel
aloisdeniel / flutter_custom_layout.dart
Last active October 2, 2023 22:00
Flutter custom layout
import 'dart:math' as math;
import 'package:flutter/material.dart';
const darkBlue = Color.fromARGB(255, 18, 32, 47);
const barBackground = Color(0xFFE9EAF6);
const barForeground = Color(0xFF0B0B10);
void main() {
runApp(MyApp());
@aloisdeniel
aloisdeniel / text_style.dart
Created May 17, 2023 12:42
Flutter Text Style
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return const MaterialApp(
@aloisdeniel
aloisdeniel / vector_heart.dart
Created August 9, 2022 08:09
Flutter vector graphics - Custom painter example
import 'package:flutter/material.dart';
const Color darkBlue = Color.fromARGB(255, 18, 32, 47);
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
@aloisdeniel
aloisdeniel / bastiui_challenge.dart
Created April 23, 2022 14:57
BastiUI - Challenge
import 'dart:math';
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
abstract class Colors {
static const bg1 = Color(0xFF00232B);
static const content1 = Color(0xFFFFFFFF);
static const content2 = Color(0xAAFFFFFF);
static const shadow3d1 = Color(0xFF000000);
@aloisdeniel
aloisdeniel / main.dart
Created February 9, 2022 16:29
Flutter - Separation of concern - #4
import 'dart:convert';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
import 'package:http/http.dart';
// main.dart
void main() {
runApp(const MyApp());
@aloisdeniel
aloisdeniel / main.dart
Last active February 9, 2022 16:26
Flutter - Separation of concern - #3
import 'dart:convert';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
import 'package:http/http.dart';
// main.dart
void main() {
runApp(const MyApp());
@aloisdeniel
aloisdeniel / main.dart
Created February 9, 2022 10:52
Flutter - Separation of concern - #1
import 'dart:convert';
import 'package:flutter/material.dart';
import 'package:http/http.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
@aloisdeniel
aloisdeniel / Solution.dart
Last active August 30, 2021 12:15
Expand padding while scroll
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(

Test

Create file

pubspec.yaml

Open file

pubspec.yaml