fix: Check browser has print ability before showing Print option

This commit is contained in:
Tom Moor
2023-01-22 10:32:31 -05:00
parent f83b0ab5e3
commit aa88bb2a7b

View File

@@ -439,7 +439,7 @@ export const printDocument = createAction({
isContextMenu ? t("Print") : t("Print document"),
section: DocumentSection,
icon: <PrintIcon />,
visible: ({ activeDocumentId }) => !!activeDocumentId,
visible: ({ activeDocumentId }) => !!(activeDocumentId && window.print),
perform: async () => {
window.print();
},