From 3772841a142ef2f273f71c9cc6e0535ec6eacce7 Mon Sep 17 00:00:00 2001 From: Gauthier Roebroeck Date: Mon, 13 Oct 2025 16:20:59 +0800 Subject: [PATCH] remove fragments and use only components --- next-ui/README.md | 7 +- next-ui/src/App.vue | 6 +- next-ui/src/components.d.ts | 66 +++++++++---------- .../fragment => components}/BuildCommit.mdx | 2 +- .../BuildCommit.stories.ts | 0 .../fragment => components}/BuildCommit.vue | 0 .../fragment => components}/BuildVersion.mdx | 2 +- .../BuildVersion.stories.ts | 0 .../fragment => components}/BuildVersion.vue | 0 .../LocaleSelector.mdx | 2 +- .../LocaleSelector.stories.ts | 0 .../LocaleSelector.vue | 0 .../RemoteFileList.mdx | 2 +- .../RemoteFileList.stories.ts | 0 .../RemoteFileList.vue | 0 .../fragment => components}/SnackQueue.mdx | 2 +- .../SnackQueue.stories.ts | 0 .../fragment => components}/SnackQueue.vue | 0 .../fragment => components}/ThemeSelector.mdx | 2 +- .../ThemeSelector.stories.ts | 0 .../fragment => components}/ThemeSelector.vue | 0 .../apikey/GenerateDialog.mdx | 0 .../apikey/GenerateDialog.stories.ts | 0 .../apikey/GenerateDialog.vue | 0 .../fragment => components}/apikey/Table.mdx | 2 +- .../apikey/Table.stories.ts | 0 .../fragment => components}/apikey/Table.vue | 0 .../dialog/ConfirmEditInstance.vue} | 0 .../dialog/ConfirmInstance.vue} | 0 .../dialog/SeriesPicker.mdx | 2 +- .../dialog/SeriesPicker.stories.ts | 0 .../dialog/SeriesPicker.vue | 0 .../fragment => components}/history/Table.mdx | 2 +- .../history/Table.stories.ts | 0 .../fragment => components}/history/Table.vue | 20 +++--- .../history/expand/BookConverted.stories.ts | 0 .../history/expand/BookConverted.vue | 2 +- .../history/expand/BookFileDeleted.stories.ts | 0 .../history/expand/BookFileDeleted.vue | 2 +- .../history/expand/BookImported.stories.ts | 0 .../history/expand/BookImported.vue | 2 +- .../expand/DuplicatePageDeleted.stories.ts | 0 .../history/expand/DuplicatePageDeleted.vue | 0 .../expand/SeriesDirectoryDeleted.stories.ts | 0 .../history/expand/SeriesDirectoryDeleted.vue | 2 +- .../history/expand/Table.vue | 0 .../books/DirectorySelection.stories.ts | 4 +- .../import/books/DirectorySelection.vue | 4 +- .../import/books/TransientBooksTable.mdx | 2 +- .../books/TransientBooksTable.stories.ts | 2 +- .../import/books/TransientBooksTable.vue | 2 +- .../import/readlist/Table.stories.ts | 2 +- .../import/readlist/Table.vue | 2 +- .../layout/app/Bar.vue | 4 +- .../layout/app/drawer/Drawer.vue | 0 .../layout/app/drawer/Footer.vue | 4 +- .../layout/app/drawer/menu/Account.vue | 0 .../layout/app/drawer/menu/History.vue | 0 .../layout/app/drawer/menu/Import.vue | 0 .../layout/app/drawer/menu/Logout.vue | 0 .../layout/app/drawer/menu/Media.vue | 0 .../layout/app/drawer/menu/Menu.vue | 0 .../layout/app/drawer/menu/Server.vue | 0 .../user/AuthenticationActivityTable.mdx | 2 +- .../AuthenticationActivityTable.stories.ts | 0 .../user/AuthenticationActivityTable.vue | 0 .../fragment => components}/user/Table.mdx | 2 +- .../user/Table.stories.ts | 0 .../fragment => components}/user/Table.vue | 0 .../user/form/CreateEdit.mdx | 2 +- .../user/form/CreateEdit.stories.ts | 0 .../user/form/CreateEdit.vue | 0 next-ui/src/fragments/README.md | 35 ---------- next-ui/src/pages/account/activity.vue | 2 +- next-ui/src/pages/account/api-keys.stories.ts | 4 +- next-ui/src/pages/account/api-keys.vue | 4 +- next-ui/src/pages/account/details.stories.ts | 4 +- next-ui/src/pages/claim.vue | 4 +- next-ui/src/pages/history.vue | 2 +- next-ui/src/pages/import/books.stories.ts | 4 +- next-ui/src/pages/import/books.vue | 2 +- next-ui/src/pages/login.vue | 4 +- next-ui/src/pages/server/activity.vue | 2 +- next-ui/src/pages/server/settings.stories.ts | 2 +- next-ui/src/pages/server/users.stories.ts | 10 ++- next-ui/src/pages/server/users.vue | 4 +- next-ui/vite.config.mts | 2 +- 87 files changed, 105 insertions(+), 137 deletions(-) rename next-ui/src/{fragments/fragment => components}/BuildCommit.mdx (93%) rename next-ui/src/{fragments/fragment => components}/BuildCommit.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/BuildCommit.vue (100%) rename next-ui/src/{fragments/fragment => components}/BuildVersion.mdx (92%) rename next-ui/src/{fragments/fragment => components}/BuildVersion.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/BuildVersion.vue (100%) rename next-ui/src/{fragments/fragment => components}/LocaleSelector.mdx (91%) rename next-ui/src/{fragments/fragment => components}/LocaleSelector.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/LocaleSelector.vue (100%) rename next-ui/src/{fragments/fragment => components}/RemoteFileList.mdx (90%) rename next-ui/src/{fragments/fragment => components}/RemoteFileList.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/RemoteFileList.vue (100%) rename next-ui/src/{fragments/fragment => components}/SnackQueue.mdx (87%) rename next-ui/src/{fragments/fragment => components}/SnackQueue.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/SnackQueue.vue (100%) rename next-ui/src/{fragments/fragment => components}/ThemeSelector.mdx (89%) rename next-ui/src/{fragments/fragment => components}/ThemeSelector.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/ThemeSelector.vue (100%) rename next-ui/src/{fragments/fragment => components}/apikey/GenerateDialog.mdx (100%) rename next-ui/src/{fragments/fragment => components}/apikey/GenerateDialog.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/apikey/GenerateDialog.vue (100%) rename next-ui/src/{fragments/fragment => components}/apikey/Table.mdx (92%) rename next-ui/src/{fragments/fragment => components}/apikey/Table.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/apikey/Table.vue (100%) rename next-ui/src/{fragments/fragment/dialog/ConfirmEdit.vue => components/dialog/ConfirmEditInstance.vue} (100%) rename next-ui/src/{fragments/fragment/dialog/Confirm.vue => components/dialog/ConfirmInstance.vue} (100%) rename next-ui/src/{fragments/fragment => components}/dialog/SeriesPicker.mdx (84%) rename next-ui/src/{fragments/fragment => components}/dialog/SeriesPicker.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/dialog/SeriesPicker.vue (100%) rename next-ui/src/{fragments/fragment => components}/history/Table.mdx (94%) rename next-ui/src/{fragments/fragment => components}/history/Table.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/history/Table.vue (87%) rename next-ui/src/{fragments/fragment => components}/history/expand/BookConverted.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/history/expand/BookConverted.vue (88%) rename next-ui/src/{fragments/fragment => components}/history/expand/BookFileDeleted.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/history/expand/BookFileDeleted.vue (88%) rename next-ui/src/{fragments/fragment => components}/history/expand/BookImported.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/history/expand/BookImported.vue (90%) rename next-ui/src/{fragments/fragment => components}/history/expand/DuplicatePageDeleted.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/history/expand/DuplicatePageDeleted.vue (100%) rename next-ui/src/{fragments/fragment => components}/history/expand/SeriesDirectoryDeleted.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/history/expand/SeriesDirectoryDeleted.vue (88%) rename next-ui/src/{fragments/fragment => components}/history/expand/Table.vue (100%) rename next-ui/src/{fragments/fragment => components}/import/books/TransientBooksTable.mdx (92%) rename next-ui/src/{fragments/fragment => components}/import/books/TransientBooksTable.stories.ts (95%) rename next-ui/src/{fragments/fragment => components}/import/books/TransientBooksTable.vue (99%) rename next-ui/src/{fragments/fragment => components}/import/readlist/Table.stories.ts (97%) rename next-ui/src/{fragments/fragment => components}/import/readlist/Table.vue (99%) rename next-ui/src/{fragments => components}/layout/app/Bar.vue (93%) rename next-ui/src/{fragments => components}/layout/app/drawer/Drawer.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/Footer.vue (92%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/Account.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/History.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/Import.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/Logout.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/Media.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/Menu.vue (100%) rename next-ui/src/{fragments => components}/layout/app/drawer/menu/Server.vue (100%) rename next-ui/src/{fragments/fragment => components}/user/AuthenticationActivityTable.mdx (95%) rename next-ui/src/{fragments/fragment => components}/user/AuthenticationActivityTable.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/user/AuthenticationActivityTable.vue (100%) rename next-ui/src/{fragments/fragment => components}/user/Table.mdx (95%) rename next-ui/src/{fragments/fragment => components}/user/Table.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/user/Table.vue (100%) rename next-ui/src/{fragments/fragment => components}/user/form/CreateEdit.mdx (90%) rename next-ui/src/{fragments/fragment => components}/user/form/CreateEdit.stories.ts (100%) rename next-ui/src/{fragments/fragment => components}/user/form/CreateEdit.vue (100%) delete mode 100644 next-ui/src/fragments/README.md diff --git a/next-ui/README.md b/next-ui/README.md index cc0d142d6..987612421 100644 --- a/next-ui/README.md +++ b/next-ui/README.md @@ -51,12 +51,11 @@ The Vite plugin [dir2json](https://github.com/buddywang/vite-plugin-dir2json) is Vue template files are segregated in different categories depending on usage: -- `./src/components`: Pure UI components, driven by model/props. Those are reusable components. -- `./src/fragments`: Fragments interact with other layers of the application, like API or Pinia stores. They are split into separate files for easier organization, but are not necessarily reused. -- `./src/pages`: Pages make use of components/fragments as well as API / Pinia stores. Each Component in that folder is converted to a navigable route using [unplugin-vue-router](https://github.com/posva/unplugin-vue-router). Pages contain a special `` to define the layout to use as well as other router meta attributes. +- `./src/components`: UI components. +- `./src/pages`: Pages make use of components as well as API / Pinia stores. Each Component in that folder is converted to a navigable route using [unplugin-vue-router](https://github.com/posva/unplugin-vue-router). Pages contain a special `` to define the layout to use as well as other router meta attributes. - `./src/layouts`: Wrapper component around Pages. -Components and Fragments are automatically imported using [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components). +Components are automatically imported using [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components). ## Icons diff --git a/next-ui/src/App.vue b/next-ui/src/App.vue index 27228cf93..98e5f2b1c 100644 --- a/next-ui/src/App.vue +++ b/next-ui/src/App.vue @@ -2,9 +2,9 @@ - - - + + + diff --git a/next-ui/src/components.d.ts b/next-ui/src/components.d.ts index 7a9593166..1fc7618ce 100644 --- a/next-ui/src/components.d.ts +++ b/next-ui/src/components.d.ts @@ -11,54 +11,54 @@ declare module 'vue' { AnnouncementCard: typeof import('./components/announcement/Card.vue')['default'] ApikeyDeletionWarning: typeof import('./components/apikey/DeletionWarning.vue')['default'] ApikeyForceSyncWarning: typeof import('./components/apikey/ForceSyncWarning.vue')['default'] + ApikeyGenerateDialog: typeof import('./components/apikey/GenerateDialog.vue')['default'] + ApikeyTable: typeof import('./components/apikey/Table.vue')['default'] AppFooter: typeof import('./components/AppFooter.vue')['default'] + BuildCommit: typeof import('./components/BuildCommit.vue')['default'] + BuildVersion: typeof import('./components/BuildVersion.vue')['default'] DialogBookPicker: typeof import('./components/dialog/BookPicker.vue')['default'] DialogConfirm: typeof import('./components/dialog/Confirm.vue')['default'] DialogConfirmEdit: typeof import('./components/dialog/ConfirmEdit.vue')['default'] + DialogConfirmEditInstance: typeof import('./components/dialog/ConfirmEditInstance.vue')['default'] + DialogConfirmInstance: typeof import('./components/dialog/ConfirmInstance.vue')['default'] DialogFileNamePicker: typeof import('./components/dialog/FileNamePicker.vue')['default'] + DialogSeriesPicker: typeof import('./components/dialog/SeriesPicker.vue')['default'] EmptyStateNetworkError: typeof import('./components/EmptyStateNetworkError.vue')['default'] FormattedMessage: typeof import('./components/FormattedMessage.ts')['default'] - FragmentApikeyGenerateDialog: typeof import('./fragments/fragment/apikey/GenerateDialog.vue')['default'] - FragmentApikeyTable: typeof import('./fragments/fragment/apikey/Table.vue')['default'] - FragmentBuildCommit: typeof import('./fragments/fragment/BuildCommit.vue')['default'] - FragmentBuildVersion: typeof import('./fragments/fragment/BuildVersion.vue')['default'] - FragmentDialogConfirm: typeof import('./fragments/fragment/dialog/Confirm.vue')['default'] - FragmentDialogConfirmEdit: typeof import('./fragments/fragment/dialog/ConfirmEdit.vue')['default'] - FragmentDialogSeriesPicker: typeof import('./fragments/fragment/dialog/SeriesPicker.vue')['default'] - FragmentHistoryExpandBookConverted: typeof import('./fragments/fragment/history/expand/BookConverted.vue')['default'] - FragmentHistoryExpandBookFileDeleted: typeof import('./fragments/fragment/history/expand/BookFileDeleted.vue')['default'] - FragmentHistoryExpandBookImported: typeof import('./fragments/fragment/history/expand/BookImported.vue')['default'] - FragmentHistoryExpandDuplicatePageDeleted: typeof import('./fragments/fragment/history/expand/DuplicatePageDeleted.vue')['default'] - FragmentHistoryExpandSeriesDirectoryDeleted: typeof import('./fragments/fragment/history/expand/SeriesDirectoryDeleted.vue')['default'] - FragmentHistoryExpandTable: typeof import('./fragments/fragment/history/expand/Table.vue')['default'] - FragmentHistoryTable: typeof import('./fragments/fragment/history/Table.vue')['default'] - FragmentImportBooksTransientBooksTable: typeof import('./fragments/fragment/import/books/TransientBooksTable.vue')['default'] - FragmentImportReadlistTable: typeof import('./fragments/fragment/import/readlist/Table.vue')['default'] - FragmentLocaleSelector: typeof import('./fragments/fragment/LocaleSelector.vue')['default'] - FragmentRemoteFileList: typeof import('./fragments/fragment/RemoteFileList.vue')['default'] - FragmentSnackQueue: typeof import('./fragments/fragment/SnackQueue.vue')['default'] - FragmentThemeSelector: typeof import('./fragments/fragment/ThemeSelector.vue')['default'] - FragmentUserAuthenticationActivityTable: typeof import('./fragments/fragment/user/AuthenticationActivityTable.vue')['default'] - FragmentUserFormCreateEdit: typeof import('./fragments/fragment/user/form/CreateEdit.vue')['default'] - FragmentUserTable: typeof import('./fragments/fragment/user/Table.vue')['default'] HelloWorld: typeof import('./components/HelloWorld.vue')['default'] + HistoryExpandBookConverted: typeof import('./components/history/expand/BookConverted.vue')['default'] + HistoryExpandBookFileDeleted: typeof import('./components/history/expand/BookFileDeleted.vue')['default'] + HistoryExpandBookImported: typeof import('./components/history/expand/BookImported.vue')['default'] + HistoryExpandDuplicatePageDeleted: typeof import('./components/history/expand/DuplicatePageDeleted.vue')['default'] + HistoryExpandSeriesDirectoryDeleted: typeof import('./components/history/expand/SeriesDirectoryDeleted.vue')['default'] + HistoryExpandTable: typeof import('./components/history/expand/Table.vue')['default'] + HistoryTable: typeof import('./components/history/Table.vue')['default'] ImportBooksDirectorySelection: typeof import('./components/import/books/DirectorySelection.vue')['default'] - LayoutAppBar: typeof import('./fragments/layout/app/Bar.vue')['default'] - LayoutAppDrawer: typeof import('./fragments/layout/app/drawer/Drawer.vue')['default'] - LayoutAppDrawerFooter: typeof import('./fragments/layout/app/drawer/Footer.vue')['default'] - LayoutAppDrawerMenu: typeof import('./fragments/layout/app/drawer/menu/Menu.vue')['default'] - LayoutAppDrawerMenuAccount: typeof import('./fragments/layout/app/drawer/menu/Account.vue')['default'] - LayoutAppDrawerMenuHistory: typeof import('./fragments/layout/app/drawer/menu/History.vue')['default'] - LayoutAppDrawerMenuImport: typeof import('./fragments/layout/app/drawer/menu/Import.vue')['default'] - LayoutAppDrawerMenuLogout: typeof import('./fragments/layout/app/drawer/menu/Logout.vue')['default'] - LayoutAppDrawerMenuMedia: typeof import('./fragments/layout/app/drawer/menu/Media.vue')['default'] - LayoutAppDrawerMenuServer: typeof import('./fragments/layout/app/drawer/menu/Server.vue')['default'] + ImportBooksTransientBooksTable: typeof import('./components/import/books/TransientBooksTable.vue')['default'] + ImportReadlistTable: typeof import('./components/import/readlist/Table.vue')['default'] + LayoutAppBar: typeof import('./components/layout/app/Bar.vue')['default'] + LayoutAppDrawer: typeof import('./components/layout/app/drawer/Drawer.vue')['default'] + LayoutAppDrawerFooter: typeof import('./components/layout/app/drawer/Footer.vue')['default'] + LayoutAppDrawerMenu: typeof import('./components/layout/app/drawer/menu/Menu.vue')['default'] + LayoutAppDrawerMenuAccount: typeof import('./components/layout/app/drawer/menu/Account.vue')['default'] + LayoutAppDrawerMenuHistory: typeof import('./components/layout/app/drawer/menu/History.vue')['default'] + LayoutAppDrawerMenuImport: typeof import('./components/layout/app/drawer/menu/Import.vue')['default'] + LayoutAppDrawerMenuLogout: typeof import('./components/layout/app/drawer/menu/Logout.vue')['default'] + LayoutAppDrawerMenuMedia: typeof import('./components/layout/app/drawer/menu/Media.vue')['default'] + LayoutAppDrawerMenuServer: typeof import('./components/layout/app/drawer/menu/Server.vue')['default'] + LocaleSelector: typeof import('./components/LocaleSelector.vue')['default'] ReleaseCard: typeof import('./components/release/Card.vue')['default'] + RemoteFileList: typeof import('./components/RemoteFileList.vue')['default'] RouterLink: typeof import('vue-router')['RouterLink'] RouterView: typeof import('vue-router')['RouterView'] ServerSettings: typeof import('./components/server/Settings.vue')['default'] + SnackQueue: typeof import('./components/SnackQueue.vue')['default'] + ThemeSelector: typeof import('./components/ThemeSelector.vue')['default'] + UserAuthenticationActivityTable: typeof import('./components/user/AuthenticationActivityTable.vue')['default'] UserDeletionWarning: typeof import('./components/user/DeletionWarning.vue')['default'] UserDetails: typeof import('./components/user/Details.vue')['default'] UserFormChangePassword: typeof import('./components/user/form/ChangePassword.vue')['default'] + UserFormCreateEdit: typeof import('./components/user/form/CreateEdit.vue')['default'] + UserTable: typeof import('./components/user/Table.vue')['default'] } } diff --git a/next-ui/src/fragments/fragment/BuildCommit.mdx b/next-ui/src/components/BuildCommit.mdx similarity index 93% rename from next-ui/src/fragments/fragment/BuildCommit.mdx rename to next-ui/src/components/BuildCommit.mdx index 2a83aacc8..a4f04af6a 100644 --- a/next-ui/src/fragments/fragment/BuildCommit.mdx +++ b/next-ui/src/components/BuildCommit.mdx @@ -4,7 +4,7 @@ import * as Stories from './BuildCommit.stories'; -# FragmentBuildCommit +# BuildCommit A button showing the current Github commit sha, retrieved from the Komga server. Clicking on the button will redirect to the particular commit at Github. diff --git a/next-ui/src/fragments/fragment/BuildCommit.stories.ts b/next-ui/src/components/BuildCommit.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/BuildCommit.stories.ts rename to next-ui/src/components/BuildCommit.stories.ts diff --git a/next-ui/src/fragments/fragment/BuildCommit.vue b/next-ui/src/components/BuildCommit.vue similarity index 100% rename from next-ui/src/fragments/fragment/BuildCommit.vue rename to next-ui/src/components/BuildCommit.vue diff --git a/next-ui/src/fragments/fragment/BuildVersion.mdx b/next-ui/src/components/BuildVersion.mdx similarity index 92% rename from next-ui/src/fragments/fragment/BuildVersion.mdx rename to next-ui/src/components/BuildVersion.mdx index aade792d2..468c422fb 100644 --- a/next-ui/src/fragments/fragment/BuildVersion.mdx +++ b/next-ui/src/components/BuildVersion.mdx @@ -4,7 +4,7 @@ import * as Stories from './BuildVersion.stories'; -# FragmentBuildVersion +# BuildVersion A button showing the current version of the Komga server. Will show a dot badge if a new update is available. diff --git a/next-ui/src/fragments/fragment/BuildVersion.stories.ts b/next-ui/src/components/BuildVersion.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/BuildVersion.stories.ts rename to next-ui/src/components/BuildVersion.stories.ts diff --git a/next-ui/src/fragments/fragment/BuildVersion.vue b/next-ui/src/components/BuildVersion.vue similarity index 100% rename from next-ui/src/fragments/fragment/BuildVersion.vue rename to next-ui/src/components/BuildVersion.vue diff --git a/next-ui/src/fragments/fragment/LocaleSelector.mdx b/next-ui/src/components/LocaleSelector.mdx similarity index 91% rename from next-ui/src/fragments/fragment/LocaleSelector.mdx rename to next-ui/src/components/LocaleSelector.mdx index 156ec9563..8cc94b886 100644 --- a/next-ui/src/fragments/fragment/LocaleSelector.mdx +++ b/next-ui/src/components/LocaleSelector.mdx @@ -4,7 +4,7 @@ import * as Stories from './LocaleSelector.stories'; -# FragmentLocaleSelector +# LocaleSelector A button that will display a menu when clicked, with a choice of available locales. diff --git a/next-ui/src/fragments/fragment/LocaleSelector.stories.ts b/next-ui/src/components/LocaleSelector.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/LocaleSelector.stories.ts rename to next-ui/src/components/LocaleSelector.stories.ts diff --git a/next-ui/src/fragments/fragment/LocaleSelector.vue b/next-ui/src/components/LocaleSelector.vue similarity index 100% rename from next-ui/src/fragments/fragment/LocaleSelector.vue rename to next-ui/src/components/LocaleSelector.vue diff --git a/next-ui/src/fragments/fragment/RemoteFileList.mdx b/next-ui/src/components/RemoteFileList.mdx similarity index 90% rename from next-ui/src/fragments/fragment/RemoteFileList.mdx rename to next-ui/src/components/RemoteFileList.mdx index 23c1421cc..838f48bda 100644 --- a/next-ui/src/fragments/fragment/RemoteFileList.mdx +++ b/next-ui/src/components/RemoteFileList.mdx @@ -4,7 +4,7 @@ import * as Stories from './RemoteFileList.stories'; -# FragmentRemoteFileList +# RemoteFileList A remote directory browser, to browse directories on a remote server. diff --git a/next-ui/src/fragments/fragment/RemoteFileList.stories.ts b/next-ui/src/components/RemoteFileList.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/RemoteFileList.stories.ts rename to next-ui/src/components/RemoteFileList.stories.ts diff --git a/next-ui/src/fragments/fragment/RemoteFileList.vue b/next-ui/src/components/RemoteFileList.vue similarity index 100% rename from next-ui/src/fragments/fragment/RemoteFileList.vue rename to next-ui/src/components/RemoteFileList.vue diff --git a/next-ui/src/fragments/fragment/SnackQueue.mdx b/next-ui/src/components/SnackQueue.mdx similarity index 87% rename from next-ui/src/fragments/fragment/SnackQueue.mdx rename to next-ui/src/components/SnackQueue.mdx index 19f06ed87..62d7dbe19 100644 --- a/next-ui/src/fragments/fragment/SnackQueue.mdx +++ b/next-ui/src/components/SnackQueue.mdx @@ -1,3 +1,3 @@ -# FragmentSnackQueue +# SnackQueue A Vuetify [Snackbar Queue](https://vuetifyjs.com/en/components/snackbar-queue/#usage) that is hooked up to the Pinia `messagesStore.messages`. diff --git a/next-ui/src/fragments/fragment/SnackQueue.stories.ts b/next-ui/src/components/SnackQueue.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/SnackQueue.stories.ts rename to next-ui/src/components/SnackQueue.stories.ts diff --git a/next-ui/src/fragments/fragment/SnackQueue.vue b/next-ui/src/components/SnackQueue.vue similarity index 100% rename from next-ui/src/fragments/fragment/SnackQueue.vue rename to next-ui/src/components/SnackQueue.vue diff --git a/next-ui/src/fragments/fragment/ThemeSelector.mdx b/next-ui/src/components/ThemeSelector.mdx similarity index 89% rename from next-ui/src/fragments/fragment/ThemeSelector.mdx rename to next-ui/src/components/ThemeSelector.mdx index d63c6efad..4afe48ae1 100644 --- a/next-ui/src/fragments/fragment/ThemeSelector.mdx +++ b/next-ui/src/components/ThemeSelector.mdx @@ -4,7 +4,7 @@ import * as Stories from './ThemeSelector.stories'; -# FragmentThemeSelector +# ThemeSelector A cycling button to change the theme. diff --git a/next-ui/src/fragments/fragment/ThemeSelector.stories.ts b/next-ui/src/components/ThemeSelector.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/ThemeSelector.stories.ts rename to next-ui/src/components/ThemeSelector.stories.ts diff --git a/next-ui/src/fragments/fragment/ThemeSelector.vue b/next-ui/src/components/ThemeSelector.vue similarity index 100% rename from next-ui/src/fragments/fragment/ThemeSelector.vue rename to next-ui/src/components/ThemeSelector.vue diff --git a/next-ui/src/fragments/fragment/apikey/GenerateDialog.mdx b/next-ui/src/components/apikey/GenerateDialog.mdx similarity index 100% rename from next-ui/src/fragments/fragment/apikey/GenerateDialog.mdx rename to next-ui/src/components/apikey/GenerateDialog.mdx diff --git a/next-ui/src/fragments/fragment/apikey/GenerateDialog.stories.ts b/next-ui/src/components/apikey/GenerateDialog.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/apikey/GenerateDialog.stories.ts rename to next-ui/src/components/apikey/GenerateDialog.stories.ts diff --git a/next-ui/src/fragments/fragment/apikey/GenerateDialog.vue b/next-ui/src/components/apikey/GenerateDialog.vue similarity index 100% rename from next-ui/src/fragments/fragment/apikey/GenerateDialog.vue rename to next-ui/src/components/apikey/GenerateDialog.vue diff --git a/next-ui/src/fragments/fragment/apikey/Table.mdx b/next-ui/src/components/apikey/Table.mdx similarity index 92% rename from next-ui/src/fragments/fragment/apikey/Table.mdx rename to next-ui/src/components/apikey/Table.mdx index f83a1847f..8f5a5dcc9 100644 --- a/next-ui/src/fragments/fragment/apikey/Table.mdx +++ b/next-ui/src/components/apikey/Table.mdx @@ -4,7 +4,7 @@ import * as Stories from './Table.stories'; -# FragmentApikeyTable +# ApikeyTable [Server DataTable](https://vuetifyjs.com/en/components/data-tables/server-side-tables/) showing API keys. diff --git a/next-ui/src/fragments/fragment/apikey/Table.stories.ts b/next-ui/src/components/apikey/Table.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/apikey/Table.stories.ts rename to next-ui/src/components/apikey/Table.stories.ts diff --git a/next-ui/src/fragments/fragment/apikey/Table.vue b/next-ui/src/components/apikey/Table.vue similarity index 100% rename from next-ui/src/fragments/fragment/apikey/Table.vue rename to next-ui/src/components/apikey/Table.vue diff --git a/next-ui/src/fragments/fragment/dialog/ConfirmEdit.vue b/next-ui/src/components/dialog/ConfirmEditInstance.vue similarity index 100% rename from next-ui/src/fragments/fragment/dialog/ConfirmEdit.vue rename to next-ui/src/components/dialog/ConfirmEditInstance.vue diff --git a/next-ui/src/fragments/fragment/dialog/Confirm.vue b/next-ui/src/components/dialog/ConfirmInstance.vue similarity index 100% rename from next-ui/src/fragments/fragment/dialog/Confirm.vue rename to next-ui/src/components/dialog/ConfirmInstance.vue diff --git a/next-ui/src/fragments/fragment/dialog/SeriesPicker.mdx b/next-ui/src/components/dialog/SeriesPicker.mdx similarity index 84% rename from next-ui/src/fragments/fragment/dialog/SeriesPicker.mdx rename to next-ui/src/components/dialog/SeriesPicker.mdx index 76f4ae249..978ccd26b 100644 --- a/next-ui/src/fragments/fragment/dialog/SeriesPicker.mdx +++ b/next-ui/src/components/dialog/SeriesPicker.mdx @@ -4,6 +4,6 @@ import * as Stories from './SeriesPicker.stories'; -# FragmentDialogSeriesPicker +# DialogSeriesPicker Search and pick series. diff --git a/next-ui/src/fragments/fragment/dialog/SeriesPicker.stories.ts b/next-ui/src/components/dialog/SeriesPicker.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/dialog/SeriesPicker.stories.ts rename to next-ui/src/components/dialog/SeriesPicker.stories.ts diff --git a/next-ui/src/fragments/fragment/dialog/SeriesPicker.vue b/next-ui/src/components/dialog/SeriesPicker.vue similarity index 100% rename from next-ui/src/fragments/fragment/dialog/SeriesPicker.vue rename to next-ui/src/components/dialog/SeriesPicker.vue diff --git a/next-ui/src/fragments/fragment/history/Table.mdx b/next-ui/src/components/history/Table.mdx similarity index 94% rename from next-ui/src/fragments/fragment/history/Table.mdx rename to next-ui/src/components/history/Table.mdx index 7f693e82a..9d7a507b2 100644 --- a/next-ui/src/fragments/fragment/history/Table.mdx +++ b/next-ui/src/components/history/Table.mdx @@ -4,7 +4,7 @@ import * as Stories from './Table.stories'; -# FragmentHistoryTable +# HistoryTable [Server DataTable](https://vuetifyjs.com/en/components/data-tables/server-side-tables/) showing historical events: - rows can be expanded to display event details diff --git a/next-ui/src/fragments/fragment/history/Table.stories.ts b/next-ui/src/components/history/Table.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/history/Table.stories.ts rename to next-ui/src/components/history/Table.stories.ts diff --git a/next-ui/src/fragments/fragment/history/Table.vue b/next-ui/src/components/history/Table.vue similarity index 87% rename from next-ui/src/fragments/fragment/history/Table.vue rename to next-ui/src/components/history/Table.vue index 68be7dceb..a0be2b620 100644 --- a/next-ui/src/fragments/fragment/history/Table.vue +++ b/next-ui/src/components/history/Table.vue @@ -92,11 +92,11 @@ import { useIntl } from 'vue-intl' import { PageRequest, type SortItem } from '@/types/PageRequest' import { useQuery } from '@pinia/colada' import { historyQuery } from '@/colada/history' -import FragmentHistoryExpandBookFileDeleted from '@/fragments/fragment/history/expand/BookFileDeleted.vue' -import FragmentHistoryExpandBookImported from '@/fragments/fragment/history/expand/BookImported.vue' -import FragmentHistoryExpandBookConverted from '@/fragments/fragment/history/expand/BookConverted.vue' -import FragmentHistoryExpandDuplicatePageDeleted from '@/fragments/fragment/history/expand/DuplicatePageDeleted.vue' -import FragmentHistoryExpandSeriesDirectoryDeleted from '@/fragments/fragment/history/expand/SeriesDirectoryDeleted.vue' +import HistoryExpandBookFileDeleted from '@/components/history/expand/BookFileDeleted.vue' +import HistoryExpandBookImported from '@/components/history/expand/BookImported.vue' +import HistoryExpandBookConverted from '@/components/history/expand/BookConverted.vue' +import HistoryExpandDuplicatePageDeleted from '@/components/history/expand/DuplicatePageDeleted.vue' +import HistoryExpandSeriesDirectoryDeleted from '@/components/history/expand/SeriesDirectoryDeleted.vue' import { historicalEventMessages } from '@/utils/i18n/enum/historical-event' import type { MessageDescriptor } from '@formatjs/intl/src/types' import { seriesDetailQuery } from '@/colada/series' @@ -186,15 +186,15 @@ function getEventMessage(eventType: string): MessageDescriptor { function getExpandedComponent(eventType: string): Component | null { switch (eventType) { case 'BookFileDeleted': - return markRaw(FragmentHistoryExpandBookFileDeleted) + return markRaw(HistoryExpandBookFileDeleted) case 'SeriesFolderDeleted': - return markRaw(FragmentHistoryExpandSeriesDirectoryDeleted) + return markRaw(HistoryExpandSeriesDirectoryDeleted) case 'DuplicatePageDeleted': - return markRaw(FragmentHistoryExpandDuplicatePageDeleted) + return markRaw(HistoryExpandDuplicatePageDeleted) case 'BookConverted': - return markRaw(FragmentHistoryExpandBookConverted) + return markRaw(HistoryExpandBookConverted) case 'BookImported': - return markRaw(FragmentHistoryExpandBookImported) + return markRaw(HistoryExpandBookImported) default: return null } diff --git a/next-ui/src/fragments/fragment/history/expand/BookConverted.stories.ts b/next-ui/src/components/history/expand/BookConverted.stories.ts similarity index 100% rename from next-ui/src/fragments/fragment/history/expand/BookConverted.stories.ts rename to next-ui/src/components/history/expand/BookConverted.stories.ts diff --git a/next-ui/src/fragments/fragment/history/expand/BookConverted.vue b/next-ui/src/components/history/expand/BookConverted.vue similarity index 88% rename from next-ui/src/fragments/fragment/history/expand/BookConverted.vue rename to next-ui/src/components/history/expand/BookConverted.vue index 55a5412aa..5ddbfe56b 100644 --- a/next-ui/src/fragments/fragment/history/expand/BookConverted.vue +++ b/next-ui/src/components/history/expand/BookConverted.vue @@ -1,5 +1,5 @@ -``` - -When your template is rendered, the component's import will automatically be inlined, which renders to this: - -```vue - - - -``` diff --git a/next-ui/src/pages/account/activity.vue b/next-ui/src/pages/account/activity.vue index 990f44ab8..d0e637728 100644 --- a/next-ui/src/pages/account/activity.vue +++ b/next-ui/src/pages/account/activity.vue @@ -3,7 +3,7 @@ fluid class="pa-0 pa-sm-4 h-100 h-sm-auto" > - + diff --git a/next-ui/src/pages/account/api-keys.stories.ts b/next-ui/src/pages/account/api-keys.stories.ts index 2addb8a6f..74ce85e0b 100644 --- a/next-ui/src/pages/account/api-keys.stories.ts +++ b/next-ui/src/pages/account/api-keys.stories.ts @@ -1,12 +1,12 @@ import type { Meta, StoryObj } from '@storybook/vue3-vite' import ApiKeys from './api-keys.vue' -import DialogConfirm from '@/fragments/fragment/dialog/Confirm.vue' +import DialogConfirmInstance from '@/components/dialog/ConfirmInstance.vue' const meta = { component: ApiKeys, render: (args: object) => ({ - components: { ApiKeys, DialogConfirm }, + components: { ApiKeys, DialogConfirm: DialogConfirmInstance }, setup() { return { args } }, diff --git a/next-ui/src/pages/account/api-keys.vue b/next-ui/src/pages/account/api-keys.vue index 62e64df9a..9edef8109 100644 --- a/next-ui/src/pages/account/api-keys.vue +++ b/next-ui/src/pages/account/api-keys.vue @@ -6,7 +6,7 @@ - diff --git a/next-ui/src/pages/account/details.stories.ts b/next-ui/src/pages/account/details.stories.ts index 422c3a033..249ccdd84 100644 --- a/next-ui/src/pages/account/details.stories.ts +++ b/next-ui/src/pages/account/details.stories.ts @@ -1,12 +1,12 @@ import type { Meta, StoryObj } from '@storybook/vue3-vite' import AccountDetails from './details.vue' -import DialogConfirmEdit from '@/fragments/fragment/dialog/ConfirmEdit.vue' +import DialogConfirmEditInstance from '@/components/dialog/ConfirmEditInstance.vue' const meta = { component: AccountDetails, render: (args: object) => ({ - components: { AccountDetails, DialogConfirmEdit }, + components: { AccountDetails, DialogConfirmEdit: DialogConfirmEditInstance }, setup() { return { args } }, diff --git a/next-ui/src/pages/claim.vue b/next-ui/src/pages/claim.vue index ecd3e39fa..cad941fbb 100644 --- a/next-ui/src/pages/claim.vue +++ b/next-ui/src/pages/claim.vue @@ -121,8 +121,8 @@
- - + +
diff --git a/next-ui/src/pages/history.vue b/next-ui/src/pages/history.vue index ee54824ed..ef18e9f09 100644 --- a/next-ui/src/pages/history.vue +++ b/next-ui/src/pages/history.vue @@ -3,7 +3,7 @@ fluid class="pa-0 pa-sm-4 h-100 h-sm-auto" > - + diff --git a/next-ui/src/pages/import/books.stories.ts b/next-ui/src/pages/import/books.stories.ts index 23c6ccc4c..598a1b9aa 100644 --- a/next-ui/src/pages/import/books.stories.ts +++ b/next-ui/src/pages/import/books.stories.ts @@ -1,13 +1,13 @@ import type { Meta, StoryObj } from '@storybook/vue3-vite' import ImportBooks from './books.vue' -import DialogConfirmEdit from '@/fragments/fragment/dialog/ConfirmEdit.vue' +import DialogConfirmEditInstance from '@/components/dialog/ConfirmEditInstance.vue' import { delay, http } from 'msw' const meta = { component: ImportBooks, render: (args: object) => ({ - components: { ImportBooks, DialogConfirmEdit }, + components: { ImportBooks, DialogConfirmEdit: DialogConfirmEditInstance }, setup() { return { args } }, diff --git a/next-ui/src/pages/import/books.vue b/next-ui/src/pages/import/books.vue index fcdfb8a6e..e0c647634 100644 --- a/next-ui/src/pages/import/books.vue +++ b/next-ui/src/pages/import/books.vue @@ -3,7 +3,7 @@ :loading="isLoading" @scan="(directory) => doScan(directory)" /> -
- - + +
diff --git a/next-ui/src/pages/server/activity.vue b/next-ui/src/pages/server/activity.vue index 04a2f3125..0c9a8b5d9 100644 --- a/next-ui/src/pages/server/activity.vue +++ b/next-ui/src/pages/server/activity.vue @@ -3,7 +3,7 @@ fluid class="pa-0 pa-sm-4 h-100 h-sm-auto" > - + diff --git a/next-ui/src/pages/server/settings.stories.ts b/next-ui/src/pages/server/settings.stories.ts index 3a2116030..84d71be74 100644 --- a/next-ui/src/pages/server/settings.stories.ts +++ b/next-ui/src/pages/server/settings.stories.ts @@ -1,7 +1,7 @@ import type { Meta, StoryObj } from '@storybook/vue3-vite' import settings from './settings.vue' -import SnackQueue from '@/fragments/fragment/SnackQueue.vue' +import SnackQueue from '@/components/SnackQueue.vue' import { http, delay } from 'msw' import { response401Unauthorized } from '@/mocks/api/handlers' diff --git a/next-ui/src/pages/server/users.stories.ts b/next-ui/src/pages/server/users.stories.ts index 57b345f19..9f93de364 100644 --- a/next-ui/src/pages/server/users.stories.ts +++ b/next-ui/src/pages/server/users.stories.ts @@ -2,14 +2,18 @@ import type { Meta, StoryObj } from '@storybook/vue3-vite' import users from './users.vue' import { http, delay } from 'msw' -import DialogConfirm from '@/fragments/fragment/dialog/Confirm.vue' -import DialogConfirmEdit from '@/fragments/fragment/dialog/ConfirmEdit.vue' +import DialogConfirmInstance from '@/components/dialog/ConfirmInstance.vue' +import DialogConfirmEditInstance from '@/components/dialog/ConfirmEditInstance.vue' import { response401Unauthorized } from '@/mocks/api/handlers' const meta = { component: users, render: (args: object) => ({ - components: { users, DialogConfirm, DialogConfirmEdit }, + components: { + users, + DialogConfirm: DialogConfirmInstance, + DialogConfirmEdit: DialogConfirmEditInstance, + }, setup() { return { args } }, diff --git a/next-ui/src/pages/server/users.vue b/next-ui/src/pages/server/users.vue index d58d5a709..4a5817c2f 100644 --- a/next-ui/src/pages/server/users.vue +++ b/next-ui/src/pages/server/users.vue @@ -6,7 +6,7 @@