fix: remove useless comments
This commit is contained in:
+5
-37
@@ -1,9 +1,5 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Shared design tokens
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
|
|
||||||
class AppRadii {
|
class AppRadii {
|
||||||
static const double sm = 10;
|
static const double sm = 10;
|
||||||
static const double md = 14;
|
static const double md = 14;
|
||||||
@@ -19,10 +15,6 @@ class AppSpacing {
|
|||||||
static const double xl = 24;
|
static const double xl = 24;
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Dark theme — refined violet palette
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
|
|
||||||
const _violet = Color(0xFF8B5CF6);
|
const _violet = Color(0xFF8B5CF6);
|
||||||
const _violetSoft = Color(0xFFB39DFF);
|
const _violetSoft = Color(0xFFB39DFF);
|
||||||
const _bg = Color(0xFF111014);
|
const _bg = Color(0xFF111014);
|
||||||
@@ -261,10 +253,6 @@ final ThemeData darkTheme = ThemeData(
|
|||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Neo-brutalist dark theme — punchy, high-contrast alternative
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
|
|
||||||
const _nbBg = Color(0xFF0C0C0E);
|
const _nbBg = Color(0xFF0C0C0E);
|
||||||
const _nbSurface = Color(0xFF1C1C20);
|
const _nbSurface = Color(0xFF1C1C20);
|
||||||
const _nbYellow = Color(0xFFFFD60A);
|
const _nbYellow = Color(0xFFFFD60A);
|
||||||
@@ -494,14 +482,8 @@ final ThemeData lightTheme = ThemeData(
|
|||||||
letterSpacing: -0.3,
|
letterSpacing: -0.3,
|
||||||
color: Color(0xFF1A1A1A),
|
color: Color(0xFF1A1A1A),
|
||||||
),
|
),
|
||||||
iconTheme: const IconThemeData(
|
iconTheme: const IconThemeData(color: Color(0xFF5C5C5C), size: 22),
|
||||||
color: Color(0xFF5C5C5C),
|
actionsIconTheme: const IconThemeData(color: Color(0xFF5C5C5C), size: 22),
|
||||||
size: 22,
|
|
||||||
),
|
|
||||||
actionsIconTheme: const IconThemeData(
|
|
||||||
color: Color(0xFF5C5C5C),
|
|
||||||
size: 22,
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
|
|
||||||
iconButtonTheme: IconButtonThemeData(
|
iconButtonTheme: IconButtonThemeData(
|
||||||
@@ -629,10 +611,7 @@ final ThemeData lightTheme = ThemeData(
|
|||||||
fontSize: 19,
|
fontSize: 19,
|
||||||
fontWeight: FontWeight.w800,
|
fontWeight: FontWeight.w800,
|
||||||
),
|
),
|
||||||
contentTextStyle: const TextStyle(
|
contentTextStyle: const TextStyle(color: Color(0xFF5C5C5C), height: 1.4),
|
||||||
color: Color(0xFF5C5C5C),
|
|
||||||
height: 1.4,
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
|
|
||||||
floatingActionButtonTheme: const FloatingActionButtonThemeData(
|
floatingActionButtonTheme: const FloatingActionButtonThemeData(
|
||||||
@@ -711,16 +690,9 @@ final ThemeData lightTheme = ThemeData(
|
|||||||
color: Color(0xFF1A1A1A),
|
color: Color(0xFF1A1A1A),
|
||||||
fontWeight: FontWeight.w700,
|
fontWeight: FontWeight.w700,
|
||||||
),
|
),
|
||||||
bodyLarge: TextStyle(
|
bodyLarge: TextStyle(color: Color(0xFF5C5C5C), fontSize: 16, height: 1.5),
|
||||||
color: Color(0xFF5C5C5C),
|
|
||||||
fontSize: 16,
|
|
||||||
height: 1.5,
|
|
||||||
),
|
|
||||||
bodyMedium: TextStyle(color: Color(0xFF757575), height: 1.4),
|
bodyMedium: TextStyle(color: Color(0xFF757575), height: 1.4),
|
||||||
bodySmall: TextStyle(
|
bodySmall: TextStyle(color: Color(0xFF9E9E9E), height: 1.3),
|
||||||
color: Color(0xFF9E9E9E),
|
|
||||||
height: 1.3,
|
|
||||||
),
|
|
||||||
labelLarge: TextStyle(
|
labelLarge: TextStyle(
|
||||||
color: Color(0xFF1A1A1A),
|
color: Color(0xFF1A1A1A),
|
||||||
fontWeight: FontWeight.w700,
|
fontWeight: FontWeight.w700,
|
||||||
@@ -728,10 +700,6 @@ final ThemeData lightTheme = ThemeData(
|
|||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Ugly theme — intentionally repulsive
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
|
|
||||||
const _uglyFg = Color(0xFFFFF700);
|
const _uglyFg = Color(0xFFFFF700);
|
||||||
const _uglyBg = Color(0xFF00FFFF);
|
const _uglyBg = Color(0xFF00FFFF);
|
||||||
const _uglySurface = Color(0xFFFF00FF);
|
const _uglySurface = Color(0xFFFF00FF);
|
||||||
|
|||||||
@@ -199,9 +199,6 @@ class _BarScreenViewState extends State<BarScreenView> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Product grid
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
class _ProductGrid extends StatelessWidget {
|
class _ProductGrid extends StatelessWidget {
|
||||||
final List<Product> products;
|
final List<Product> products;
|
||||||
final int rows;
|
final int rows;
|
||||||
@@ -353,10 +350,6 @@ class _ProductGrid extends StatelessWidget {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
// Tab panel
|
|
||||||
// ---------------------------------------------------------------------------
|
|
||||||
|
|
||||||
class _TabPanel extends StatefulWidget {
|
class _TabPanel extends StatefulWidget {
|
||||||
final List<BarTab> tabs;
|
final List<BarTab> tabs;
|
||||||
final BarTab? selectedTab;
|
final BarTab? selectedTab;
|
||||||
@@ -408,9 +401,6 @@ class _TabPanelState extends State<_TabPanel> {
|
|||||||
}).toList();
|
}).toList();
|
||||||
|
|
||||||
return DecoratedBox(
|
return DecoratedBox(
|
||||||
// A step darker/lighter than the main surface, whichever direction
|
|
||||||
// the active theme goes — matches how it read against the dark
|
|
||||||
// surface color originally.
|
|
||||||
decoration: BoxDecoration(color: scheme.surfaceContainerLow),
|
decoration: BoxDecoration(color: scheme.surfaceContainerLow),
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.all(16),
|
padding: const EdgeInsets.all(16),
|
||||||
@@ -457,37 +447,6 @@ class _TabPanelState extends State<_TabPanel> {
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|
||||||
//
|
|
||||||
// const SizedBox(height: 18),
|
|
||||||
//
|
|
||||||
// Row(
|
|
||||||
// children: [
|
|
||||||
// Text(
|
|
||||||
// l10n.openTabs.toUpperCase(),
|
|
||||||
// style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
|
||||||
// fontWeight: FontWeight.w700,
|
|
||||||
// letterSpacing: 0.8,
|
|
||||||
// ),
|
|
||||||
// ),
|
|
||||||
// const SizedBox(width: 8),
|
|
||||||
// Container(
|
|
||||||
// padding: const EdgeInsets.symmetric(
|
|
||||||
// horizontal: 8,
|
|
||||||
// vertical: 2,
|
|
||||||
// ),
|
|
||||||
// decoration: BoxDecoration(
|
|
||||||
// color: scheme.onSurface.withValues(alpha: 0.06),
|
|
||||||
// borderRadius: BorderRadius.circular(999),
|
|
||||||
// ),
|
|
||||||
// child: Text(
|
|
||||||
// '${filteredTabs.length}',
|
|
||||||
// style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
|
||||||
// fontWeight: FontWeight.w700,
|
|
||||||
// ),
|
|
||||||
// ),
|
|
||||||
// ),
|
|
||||||
// ],
|
|
||||||
// ),
|
|
||||||
const SizedBox(height: 8),
|
const SizedBox(height: 8),
|
||||||
|
|
||||||
SizedBox(
|
SizedBox(
|
||||||
|
|||||||
@@ -89,7 +89,6 @@ class _PinEntryViewState extends State<PinEntryView> {
|
|||||||
final l10n = AppLocalizations.of(context);
|
final l10n = AppLocalizations.of(context);
|
||||||
|
|
||||||
if (_isCreateFlow && !_isConfirmStep) {
|
if (_isCreateFlow && !_isConfirmStep) {
|
||||||
// First entry of a new PIN — stash it, then ask for confirmation.
|
|
||||||
final entered = _digits;
|
final entered = _digits;
|
||||||
|
|
||||||
setState(() {
|
setState(() {
|
||||||
@@ -127,7 +126,6 @@ class _PinEntryViewState extends State<PinEntryView> {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Unlock flow.
|
|
||||||
setState(() => _isSubmitting = true);
|
setState(() => _isSubmitting = true);
|
||||||
final ok = await _verify(_digits);
|
final ok = await _verify(_digits);
|
||||||
if (!mounted) return;
|
if (!mounted) return;
|
||||||
|
|||||||
@@ -87,14 +87,12 @@ class ProductTile extends StatelessWidget {
|
|||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
// Stock badge
|
|
||||||
Positioned(
|
Positioned(
|
||||||
top: 10,
|
top: 10,
|
||||||
right: 10,
|
right: 10,
|
||||||
child: _StockBadge(product: product),
|
child: _StockBadge(product: product),
|
||||||
),
|
),
|
||||||
|
|
||||||
// Out of stock overlay
|
|
||||||
if (outOfStock)
|
if (outOfStock)
|
||||||
Center(
|
Center(
|
||||||
child: Container(
|
child: Container(
|
||||||
|
|||||||
@@ -1,11 +0,0 @@
|
|||||||
// This is a basic Flutter widget test.
|
|
||||||
//
|
|
||||||
// To perform an interaction with a widget in your test, use the WidgetTester
|
|
||||||
// utility in the flutter_test package. For example, you can send tap and scroll
|
|
||||||
// gestures. You can also use WidgetTester to find child widgets in the widget
|
|
||||||
// tree, read text, and verify that the values of widget properties are correct.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void main() {
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user