diff --git a/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookControls.vue b/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookControls.vue index e62b17f544daa4b5be796a2ecd0aaeb30b595dbb..2119667bd011cc1df3ab7d97b871eddd0d909fe6 100644 --- a/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookControls.vue +++ b/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookControls.vue @@ -1,5 +1,5 @@ <script setup> -import SecondaryActionButton from "aleksis.core/components/generic/buttons/SecondaryActionButton.vue"; +import CoursebookPrintDialog from "./CoursebookPrintDialog.vue"; </script> <template> @@ -69,11 +69,8 @@ import SecondaryActionButton from "aleksis.core/components/generic/buttons/Secon > {{ pageTypeButtonText }} </v-btn> - <secondary-action-button + <coursebook-print-dialog v-if="pageType === 'documentations'" - i18n-key="alsijil.coursebook.print" - icon-text="$print" - :click="showPrintMenu" /> </div> </div> diff --git a/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue b/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue new file mode 100644 index 0000000000000000000000000000000000000000..2d111617a9adbc6000ca16401b2273c550550002 --- /dev/null +++ b/aleksis/apps/alsijil/frontend/components/coursebook/CoursebookPrintDialog.vue @@ -0,0 +1,33 @@ +<script setup> +import MobileFullscreenDialog from "aleksis.core/components/generic/dialogs/MobileFullscreenDialog.vue"; +import SecondaryActionButton from "aleksis.core/components/generic/buttons/SecondaryActionButton.vue"; +</script> + +<template> + <mobile-fullscreen-dialog + v-model="dialog" + > + <template #activator> + <secondary-action-button + i18n-key="alsijil.coursebook.print" + icon-text="$print" + @click="dialog=true" + :disabled="dialog" + /> + </template> + </mobile-fullscreen-dialog> +</template> + +<script> +/** + * This component provides a dialog for configuring the coursebook-printout + */ +export default { + name: "CoursebookPrintDialog", + data() { + return { + dialog: false, + }; + }, +}; +</script>