diff --git a/src/frontend/src/components/buttons/CopyButton.tsx b/src/frontend/src/components/buttons/CopyButton.tsx index 363487be5c..a43b4b3099 100644 --- a/src/frontend/src/components/buttons/CopyButton.tsx +++ b/src/frontend/src/components/buttons/CopyButton.tsx @@ -38,6 +38,11 @@ export function CopyButton({ }>) { const ButtonComponent = label ? Button : ActionIcon; + // Disable the copy button if we are not in a secure context, as the Clipboard API is not available + if (!window.isSecureContext) { + return null; + } + return ( {({ copied, copy }) => ( diff --git a/src/frontend/src/forms/CompanyForms.tsx b/src/frontend/src/forms/CompanyForms.tsx index de136355a4..e94bfedded 100644 --- a/src/frontend/src/forms/CompanyForms.tsx +++ b/src/frontend/src/forms/CompanyForms.tsx @@ -39,6 +39,7 @@ export function useSupplierPartFields({ }, manufacturer_part: { value: manufacturerPartId, + autoFill: true, filters: { manufacturer: manufacturerId, part_detail: true, diff --git a/src/frontend/src/tables/CopyableCell.tsx b/src/frontend/src/tables/CopyableCell.tsx index e07dec3b96..e90d122296 100644 --- a/src/frontend/src/tables/CopyableCell.tsx +++ b/src/frontend/src/tables/CopyableCell.tsx @@ -29,7 +29,7 @@ export function CopyableCell({ align='center' > {children} - {isHovered && value != null && ( + {window.isSecureContext && isHovered && value != null && ( e.stopPropagation()} diff --git a/src/frontend/src/tables/InvenTreeTable.tsx b/src/frontend/src/tables/InvenTreeTable.tsx index 250683db76..65cff57c19 100644 --- a/src/frontend/src/tables/InvenTreeTable.tsx +++ b/src/frontend/src/tables/InvenTreeTable.tsx @@ -285,8 +285,10 @@ export function InvenTreeTable>({ } const copyValue = rawCopyValue == null ? '' : String(rawCopyValue); - if (!!copyValue) { + if (window.isSecureContext && !!copyValue) { return {content}; + } else { + return content; } }; }