From 327884ca2691887b4c034deb921eaee3abd28b97 Mon Sep 17 00:00:00 2001 From: Oliver Date: Fri, 29 Nov 2024 17:32:15 +1100 Subject: [PATCH] [PUI] Barcode title (#8591) * Increase query limit * PUI: Barcode UI tweaks - Small visual tweaks to barcode dialogs --- .../src/components/items/ActionDropdown.tsx | 2 +- src/frontend/src/components/items/QRCode.tsx | 39 ++++++++++++------- 2 files changed, 27 insertions(+), 14 deletions(-) diff --git a/src/frontend/src/components/items/ActionDropdown.tsx b/src/frontend/src/components/items/ActionDropdown.tsx index ad098e91f02c..958db8e61fc1 100644 --- a/src/frontend/src/components/items/ActionDropdown.tsx +++ b/src/frontend/src/components/items/ActionDropdown.tsx @@ -163,7 +163,7 @@ export function BarcodeActionDropdown({ actions={[ GeneralBarcodeAction({ mdl_prop: prop, - title: t`View`, + title: t`View Barcode`, icon: , tooltip: t`View barcode`, ChildItem: InvenTreeQRCode diff --git a/src/frontend/src/components/items/QRCode.tsx b/src/frontend/src/components/items/QRCode.tsx index 9681d09c902b..fab66b195acb 100644 --- a/src/frontend/src/components/items/QRCode.tsx +++ b/src/frontend/src/components/items/QRCode.tsx @@ -4,6 +4,7 @@ import { Box, Button, Code, + Divider, Group, Image, Select, @@ -96,6 +97,8 @@ export const InvenTreeQRCode = ({ return ( + + {mdl_prop.hash ? ( @@ -107,6 +110,8 @@ export const InvenTreeQRCode = ({ + + {data && settings.getSetting('BARCODE_SHOW_TEXT', 'false') && ( { }; return ( - setBarcode(event.currentTarget.value)} - onScan={actionSubmit} - onAction={handleLinkBarcode} - actionText={t`Link`} - /> + + + setBarcode(event.currentTarget.value)} + onScan={actionSubmit} + onAction={handleLinkBarcode} + actionText={t`Link`} + /> + ); }; @@ -186,12 +194,17 @@ export const QRCodeUnlink = ({ mdl_prop }: { mdl_prop: QrCodeType }) => { } return ( - - This will remove the link to the associated barcode - - + + + + This will remove the link to the associated barcode + + + + + ); };