finished notes page

This commit is contained in:
Kima
2023-12-30 18:10:19 +01:00
parent f238b86dc7
commit 5476397af6
12 changed files with 561 additions and 16 deletions

View File

@@ -4,13 +4,20 @@ import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
class Panel extends StatelessWidget {
const Panel(
{super.key, this.child, this.title, this.padding, this.hasShadow = true});
const Panel({
super.key,
this.child,
this.title,
this.padding,
this.hasShadow = true,
this.isTransparent = false,
});
final Widget? child;
final Widget? title;
final EdgeInsetsGeometry? padding;
final bool hasShadow;
final bool isTransparent;
@override
Widget build(BuildContext context) {
@@ -26,9 +33,11 @@ class Panel extends StatelessWidget {
width: double.infinity,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(16.0),
color: Theme.of(context).colorScheme.background,
color: isTransparent
? Colors.transparent
: Theme.of(context).colorScheme.background,
boxShadow: [
if (hasShadow &&
if ((hasShadow && !isTransparent) &&
Provider.of<SettingsProvider>(context, listen: false)
.shadowEffect)
BoxShadow(