2
0
mirror of https://github.com/inventree/inventree-app.git synced 2025-06-14 11:15:26 +00:00

Barcode scanner updates (#562)

* Add BUILDING.md

* Replace scaning library

- Out with qr_code_scanner
- In with flutter_zxing

* Update specs for jdk / kotlin / gradle

- NFI what this all means?

* Refactor barcode scanning widget

* Refactor barcode overlay

* Add handlers

* Update release notes

* Fix AppBar color

* Enhance attachment widget

* remove unused import

* Improved icon

* Select theme from main drawer
This commit is contained in:
Oliver
2024-12-06 00:08:04 +11:00
committed by GitHub
parent 4151aeb8e1
commit d4cff1a5b9
18 changed files with 339 additions and 228 deletions

View File

@ -208,11 +208,8 @@ class _AttachmentWidgetState extends RefreshableState<AttachmentWidget> {
if (tiles.isEmpty) {
tiles.add(ListTile(
leading: Icon(TablerIcons.file_x, color: COLOR_WARNING),
title: Text(L10().attachmentNone),
subtitle: Text(
L10().attachmentNoneDetail,
style: TextStyle(fontStyle: FontStyle.italic),
),
));
}

View File

@ -1,3 +1,4 @@
import "package:adaptive_theme/adaptive_theme.dart";
import "package:flutter/material.dart";
import "package:flutter_tabler_icons/flutter_tabler_icons.dart";
@ -185,6 +186,28 @@ class InvenTreeDrawer extends StatelessWidget {
)
);
tiles.add(Divider());
bool darkMode = AdaptiveTheme.of(context).mode.isDark;
tiles.add(
ListTile(
onTap: () {
AdaptiveTheme.of(context).toggleThemeMode();
_closeDrawer();
},
title: Text(L10().colorScheme),
subtitle: Text(L10().colorSchemeDetail),
leading: Icon(
TablerIcons.sun_moon,
color: COLOR_ACTION
),
trailing: Icon(
darkMode ? TablerIcons.moon : TablerIcons.sun,
)
)
);
tiles.add(
ListTile(
title: Text(L10().settings),

View File

@ -101,7 +101,7 @@ mixin BaseWidgetProperties {
},
),
IconButton(
icon: Icon(Icons.barcode_reader, color: COLOR_ACTION),
icon: Icon(TablerIcons.barcode, color: COLOR_ACTION),
iconSize: iconSize,
onPressed: () {
if (InvenTreeAPI().checkConnection()) {