fontastic 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.editorconfig +16 -0
- package/.eslintrc.json +54 -0
- package/.github/FUNDING.yml +12 -0
- package/.github/ISSUE_TEMPLATE/bug_report.md +29 -0
- package/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
- package/.github/dependabot.yml +6 -0
- package/.github/pull_request_template.md +21 -0
- package/.github/stale.yml +17 -0
- package/.github/workflows/macos.yml +58 -0
- package/.github/workflows/ubuntu.yml +70 -0
- package/.github/workflows/windows.yml +64 -0
- package/.node-version +1 -0
- package/.vscode/launch.json +46 -0
- package/.vscode/tasks.json +49 -0
- package/CODE_OF_CONDUCT.md +45 -0
- package/CONTRIBUTING.md +72 -0
- package/LICENSE +21 -0
- package/README.md +111 -0
- package/_config.yml +1 -0
- package/angular.json +194 -0
- package/angular.webpack.js +32 -0
- package/app/Application.js +40 -0
- package/app/Application.ts +38 -0
- package/app/config/alert.ts +32 -0
- package/app/config/database.js +203 -0
- package/app/config/database.ts +202 -0
- package/app/config/index.js +20 -0
- package/app/config/index.ts +3 -0
- package/app/config/mimes.js +49 -0
- package/app/config/mimes.ts +54 -0
- package/app/config/system.js +497 -0
- package/app/config/system.ts +498 -0
- package/app/config/themes.ts +38 -0
- package/app/core/AppLogger.js +31 -0
- package/app/core/AppLogger.ts +38 -0
- package/app/core/ConfigManager.js +114 -0
- package/app/core/ConfigManager.ts +137 -0
- package/app/core/ConnectionManager.js +83 -0
- package/app/core/ConnectionManager.ts +95 -0
- package/app/core/FontCatalog.js +51 -0
- package/app/core/FontCatalog.ts +42 -0
- package/app/core/FontFinder.js +86 -0
- package/app/core/FontFinder.ts +96 -0
- package/app/core/FontInstaller.js +67 -0
- package/app/core/FontInstaller.ts +63 -0
- package/app/core/FontManager.js +165 -0
- package/app/core/FontManager.ts +172 -0
- package/app/core/FontObject.js +54 -0
- package/app/core/FontObject.ts +62 -0
- package/app/core/MessageHandler.js +272 -0
- package/app/core/MessageHandler.ts +337 -0
- package/app/core/SystemManager.js +140 -0
- package/app/core/SystemManager.ts +171 -0
- package/app/core/menu/Example.ts +280 -0
- package/app/core/menu/MenuBuilder.js +45 -0
- package/app/core/menu/MenuBuilder.ts +53 -0
- package/app/core/menu/templates/DarwinTemplate.js +127 -0
- package/app/core/menu/templates/DarwinTemplate.ts +142 -0
- package/app/core/menu/templates/SystemTemplate.js +124 -0
- package/app/core/menu/templates/SystemTemplate.ts +139 -0
- package/app/database/entity/Collection.schema.js +99 -0
- package/app/database/entity/Collection.schema.ts +68 -0
- package/app/database/entity/Logger.schema.js +50 -0
- package/app/database/entity/Logger.schema.ts +26 -0
- package/app/database/entity/Store.schema.js +165 -0
- package/app/database/entity/Store.schema.ts +116 -0
- package/app/database/entity/index.js +20 -0
- package/app/database/entity/index.ts +3 -0
- package/app/database/repository/Collection.repository.js +181 -0
- package/app/database/repository/Collection.repository.ts +190 -0
- package/app/database/repository/Logger.repository.js +25 -0
- package/app/database/repository/Logger.repository.ts +11 -0
- package/app/database/repository/Store.repository.js +328 -0
- package/app/database/repository/Store.repository.ts +358 -0
- package/app/database/repository/User.repository.js +12 -0
- package/app/database/repository/User.repository.ts +8 -0
- package/app/database/repository/index.js +20 -0
- package/app/database/repository/index.ts +3 -0
- package/app/enums/ChannelType.js +62 -0
- package/app/enums/ChannelType.ts +65 -0
- package/app/enums/StorageType.js +19 -0
- package/app/enums/index.js +19 -0
- package/app/enums/index.ts +2 -0
- package/app/enums/storageType.ts +14 -0
- package/app/helpers/command.js +28 -0
- package/app/helpers/command.ts +20 -0
- package/app/helpers/random.js +16 -0
- package/app/helpers/random.ts +12 -0
- package/app/main.js +82 -0
- package/app/main.ts +94 -0
- package/app/package-lock.json +2649 -0
- package/app/package.json +35 -0
- package/app/types/AppAlert.js +3 -0
- package/app/types/AppAlert.ts +8 -0
- package/app/types/AuthUser.js +7 -0
- package/app/types/AuthUser.ts +5 -0
- package/app/types/Breadcrumb.js +3 -0
- package/app/types/Breadcrumb.ts +5 -0
- package/app/types/ImportOptions.js +7 -0
- package/app/types/ImportOptions.ts +3 -0
- package/app/types/QueryOptions.js +3 -0
- package/app/types/QueryOptions.ts +12 -0
- package/app/types/SystemConfig.js +3 -0
- package/app/types/SystemConfig.ts +132 -0
- package/app/types/SystemStats.js +3 -0
- package/app/types/SystemStats.ts +7 -0
- package/app/types/SystemTheme.js +3 -0
- package/app/types/SystemTheme.ts +5 -0
- package/app/types/index.js +25 -0
- package/app/types/index.ts +8 -0
- package/docs/logo.png +0 -0
- package/docs/screenshots/readme.md +7 -0
- package/docs/screenshots/screen-grab1.png +0 -0
- package/docs/screenshots/screen-grab2.png +0 -0
- package/docs/screenshots/screen-grab3.png +0 -0
- package/e2e/main.spec.ts +59 -0
- package/e2e/playwright.config.ts +19 -0
- package/e2e/tsconfig.e2e.json +13 -0
- package/electron-builder.json +71 -0
- package/package.json +121 -0
- package/src/app/app-routing.module.ts +15 -0
- package/src/app/app.component.html +1 -0
- package/src/app/app.component.scss +0 -0
- package/src/app/app.component.spec.ts.dist +33 -0
- package/src/app/app.component.ts +37 -0
- package/src/app/app.module.ts +63 -0
- package/src/app/core/core.module.ts +11 -0
- package/src/app/core/model/AuthUserModel.ts +7 -0
- package/src/app/core/model/CustomThemeModel.ts +7 -0
- package/src/app/core/model/DbConnectionModel.ts +16 -0
- package/src/app/core/model/ImportOptionsModel.ts +5 -0
- package/src/app/core/model/LatestNewsModel.ts +7 -0
- package/src/app/core/model/SearchFormModel.ts +10 -0
- package/src/app/core/model/index.ts +6 -0
- package/src/app/core/services/alert/alert.service.spec.ts +22 -0
- package/src/app/core/services/alert/alert.service.ts +71 -0
- package/src/app/core/services/auth/auth.service.ts +30 -0
- package/src/app/core/services/boot/boot.service.ts +33 -0
- package/src/app/core/services/breadcrumb/breadcrumb.service.spec.ts +22 -0
- package/src/app/core/services/breadcrumb/breadcrumb.service.ts +30 -0
- package/src/app/core/services/config/config.service.ts +63 -0
- package/src/app/core/services/database/database.service.ts +286 -0
- package/src/app/core/services/electron/electron.service.spec.ts +12 -0
- package/src/app/core/services/electron/electron.service.ts +62 -0
- package/src/app/core/services/font/font.service.ts +79 -0
- package/src/app/core/services/gravatar/gravatar.service.spec.ts +16 -0
- package/src/app/core/services/gravatar/gravatar.service.ts +18 -0
- package/src/app/core/services/index.ts +14 -0
- package/src/app/core/services/message/message.service.ts +289 -0
- package/src/app/core/services/modal/modal.service.spec.ts +16 -0
- package/src/app/core/services/modal/modal.service.ts +34 -0
- package/src/app/core/services/news/news.service.ts +94 -0
- package/src/app/core/services/presentation/presentation.service.ts +341 -0
- package/src/app/core/services/utils/utils.service.spec.ts +12 -0
- package/src/app/core/services/utils/utils.service.ts +144 -0
- package/src/app/layout/aside/aside.component.html +9 -0
- package/src/app/layout/aside/aside.component.scss +1 -0
- package/src/app/layout/aside/aside.component.ts +26 -0
- package/src/app/layout/footer/footer.component.html +11 -0
- package/src/app/layout/footer/footer.component.scss +27 -0
- package/src/app/layout/footer/footer.component.ts +32 -0
- package/src/app/layout/header/header.component.html +35 -0
- package/src/app/layout/header/header.component.scss +60 -0
- package/src/app/layout/header/header.component.ts +229 -0
- package/src/app/layout/layout.component.html +14 -0
- package/src/app/layout/layout.component.scss +119 -0
- package/src/app/layout/layout.component.ts +23 -0
- package/src/app/layout/layout.module.ts +32 -0
- package/src/app/layout/layout.service.ts +13 -0
- package/src/app/layout/navigation/navigation.component.html +142 -0
- package/src/app/layout/navigation/navigation.component.scss +0 -0
- package/src/app/layout/navigation/navigation.component.ts +302 -0
- package/src/app/pages/main/grid/grid.component.html +160 -0
- package/src/app/pages/main/grid/grid.component.scss +3 -0
- package/src/app/pages/main/grid/grid.component.ts +98 -0
- package/src/app/pages/main/inspect/inspect.component.html +7 -0
- package/src/app/pages/main/inspect/inspect.component.scss +3 -0
- package/src/app/pages/main/inspect/inspect.component.ts +66 -0
- package/src/app/pages/main/main-routing.module.ts +30 -0
- package/src/app/pages/main/main.component.html +6 -0
- package/src/app/pages/main/main.component.scss +191 -0
- package/src/app/pages/main/main.component.ts +35 -0
- package/src/app/pages/main/main.module.ts +28 -0
- package/src/app/pages/main/preview/preview.component.html +46 -0
- package/src/app/pages/main/preview/preview.component.scss +0 -0
- package/src/app/pages/main/preview/preview.component.ts +239 -0
- package/src/app/pages/main/toolbar/toolbar.component.html +78 -0
- package/src/app/pages/main/toolbar/toolbar.component.scss +3 -0
- package/src/app/pages/main/toolbar/toolbar.component.ts +132 -0
- package/src/app/shared/components/alert/alert.component.html +9 -0
- package/src/app/shared/components/alert/alert.component.scss +0 -0
- package/src/app/shared/components/alert/alert.component.ts +37 -0
- package/src/app/shared/components/breadcrumbs/breadcrumbs.component.html +14 -0
- package/src/app/shared/components/breadcrumbs/breadcrumbs.component.scss +0 -0
- package/src/app/shared/components/breadcrumbs/breadcrumbs.component.ts +36 -0
- package/src/app/shared/components/button/button.component.html +3 -0
- package/src/app/shared/components/button/button.component.scss +2 -0
- package/src/app/shared/components/button/button.component.ts +22 -0
- package/src/app/shared/components/collection/create-collection/create-collection.component.html +41 -0
- package/src/app/shared/components/collection/create-collection/create-collection.component.scss +0 -0
- package/src/app/shared/components/collection/create-collection/create-collection.component.ts +68 -0
- package/src/app/shared/components/collection/form-collection/form-collection.component.html +1 -0
- package/src/app/shared/components/collection/form-collection/form-collection.component.scss +0 -0
- package/src/app/shared/components/collection/form-collection/form-collection.component.ts +15 -0
- package/src/app/shared/components/collection/update-collection/update-collection.component.html +40 -0
- package/src/app/shared/components/collection/update-collection/update-collection.component.scss +0 -0
- package/src/app/shared/components/collection/update-collection/update-collection.component.ts +71 -0
- package/src/app/shared/components/glyph-list/glyph-list.component.html +40 -0
- package/src/app/shared/components/glyph-list/glyph-list.component.scss +1 -0
- package/src/app/shared/components/glyph-list/glyph-list.component.ts +165 -0
- package/src/app/shared/components/glyph-view/glyph-view.component.html +23 -0
- package/src/app/shared/components/glyph-view/glyph-view.component.scss +0 -0
- package/src/app/shared/components/glyph-view/glyph-view.component.ts +228 -0
- package/src/app/shared/components/index.ts +16 -0
- package/src/app/shared/components/loading/loading.component.html +1 -0
- package/src/app/shared/components/loading/loading.component.scss +0 -0
- package/src/app/shared/components/loading/loading.component.ts +26 -0
- package/src/app/shared/components/modal/modal.component.html +31 -0
- package/src/app/shared/components/modal/modal.component.scss +0 -0
- package/src/app/shared/components/modal/modal.component.ts +51 -0
- package/src/app/shared/components/page-not-found/page-not-found.component.html +3 -0
- package/src/app/shared/components/page-not-found/page-not-found.component.scss +0 -0
- package/src/app/shared/components/page-not-found/page-not-found.component.ts +12 -0
- package/src/app/shared/components/paginator/paginator.component.html +21 -0
- package/src/app/shared/components/paginator/paginator.component.scss +3 -0
- package/src/app/shared/components/paginator/paginator.component.ts +133 -0
- package/src/app/shared/components/pairing/pairing.component.html +20 -0
- package/src/app/shared/components/pairing/pairing.component.scss +0 -0
- package/src/app/shared/components/pairing/pairing.component.ts +33 -0
- package/src/app/shared/components/search/search.component.html +54 -0
- package/src/app/shared/components/search/search.component.scss +10 -0
- package/src/app/shared/components/search/search.component.ts +77 -0
- package/src/app/shared/components/settings/database/database.component.html +151 -0
- package/src/app/shared/components/settings/database/database.component.scss +0 -0
- package/src/app/shared/components/settings/database/database.component.ts +145 -0
- package/src/app/shared/components/settings/general/general.component.html +170 -0
- package/src/app/shared/components/settings/general/general.component.scss +0 -0
- package/src/app/shared/components/settings/general/general.component.ts +150 -0
- package/src/app/shared/components/settings/logs/logs.component.html +44 -0
- package/src/app/shared/components/settings/logs/logs.component.scss +0 -0
- package/src/app/shared/components/settings/logs/logs.component.ts +37 -0
- package/src/app/shared/components/settings/news/news.component.html +41 -0
- package/src/app/shared/components/settings/news/news.component.scss +0 -0
- package/src/app/shared/components/settings/news/news.component.ts +52 -0
- package/src/app/shared/components/settings/settings.component.html +46 -0
- package/src/app/shared/components/settings/settings.component.scss +0 -0
- package/src/app/shared/components/settings/settings.component.ts +23 -0
- package/src/app/shared/components/settings/system/system.component.html +30 -0
- package/src/app/shared/components/settings/system/system.component.scss +0 -0
- package/src/app/shared/components/settings/system/system.component.ts +43 -0
- package/src/app/shared/components/settings/theme/theme.component.html +22 -0
- package/src/app/shared/components/settings/theme/theme.component.scss +0 -0
- package/src/app/shared/components/settings/theme/theme.component.ts +50 -0
- package/src/app/shared/components/spinner/spinner.component.html +1 -0
- package/src/app/shared/components/spinner/spinner.component.scss +0 -0
- package/src/app/shared/components/spinner/spinner.component.ts +26 -0
- package/src/app/shared/components/store/store.component.html +22 -0
- package/src/app/shared/components/store/store.component.scss +10 -0
- package/src/app/shared/components/store/store.component.ts +58 -0
- package/src/app/shared/components/tables/tables.component.html +47 -0
- package/src/app/shared/components/tables/tables.component.scss +10 -0
- package/src/app/shared/components/tables/tables.component.ts +81 -0
- package/src/app/shared/components/typescale/typescale.component.html +53 -0
- package/src/app/shared/components/typescale/typescale.component.scss +0 -0
- package/src/app/shared/components/typescale/typescale.component.ts +168 -0
- package/src/app/shared/directives/gravatar/gravatar.directive.ts +29 -0
- package/src/app/shared/directives/index.ts +2 -0
- package/src/app/shared/directives/webview/webview.directive.ts +8 -0
- package/src/app/shared/pipes/installable.pipe.ts +10 -0
- package/src/app/shared/pipes/prettybytes.pipe.ts +10 -0
- package/src/app/shared/pipes/safehtml.pipe.ts +10 -0
- package/src/app/shared/shared.module.ts +92 -0
- package/src/assets/.gitkeep +0 -0
- package/src/assets/fonts/fa/fa-brands-400.eot +0 -0
- package/src/assets/fonts/fa/fa-brands-400.svg +3535 -0
- package/src/assets/fonts/fa/fa-brands-400.ttf +0 -0
- package/src/assets/fonts/fa/fa-brands-400.woff +0 -0
- package/src/assets/fonts/fa/fa-brands-400.woff2 +0 -0
- package/src/assets/fonts/fa/fa-regular-400.eot +0 -0
- package/src/assets/fonts/fa/fa-regular-400.svg +803 -0
- package/src/assets/fonts/fa/fa-regular-400.ttf +0 -0
- package/src/assets/fonts/fa/fa-regular-400.woff +0 -0
- package/src/assets/fonts/fa/fa-regular-400.woff2 +0 -0
- package/src/assets/fonts/fa/fa-solid-900.eot +0 -0
- package/src/assets/fonts/fa/fa-solid-900.svg +4700 -0
- package/src/assets/fonts/fa/fa-solid-900.ttf +0 -0
- package/src/assets/fonts/fa/fa-solid-900.woff +0 -0
- package/src/assets/fonts/fa/fa-solid-900.woff2 +0 -0
- package/src/assets/fonts/md/MaterialIcons-Regular.eot +0 -0
- package/src/assets/fonts/md/MaterialIcons-Regular.ijmap +1 -0
- package/src/assets/fonts/md/MaterialIcons-Regular.svg +2373 -0
- package/src/assets/fonts/md/MaterialIcons-Regular.ttf +0 -0
- package/src/assets/fonts/md/MaterialIcons-Regular.woff +0 -0
- package/src/assets/fonts/md/MaterialIcons-Regular.woff2 +0 -0
- package/src/assets/fonts/md/README.md +9 -0
- package/src/assets/fonts/md/codepoints +932 -0
- package/src/assets/fonts/md/material-icons.css +36 -0
- package/src/assets/fonts/octicon/octicon.eot +0 -0
- package/src/assets/fonts/octicon/octicon.svg +378 -0
- package/src/assets/fonts/octicon/octicon.ttf +0 -0
- package/src/assets/fonts/octicon/octicon.woff +0 -0
- package/src/assets/fonts/octicon/octicon.woff2 +0 -0
- package/src/assets/fonts/roboto/Roboto-Bold-webfont.eot +0 -0
- package/src/assets/fonts/roboto/Roboto-Bold-webfont.svg +607 -0
- package/src/assets/fonts/roboto/Roboto-Bold-webfont.ttf +0 -0
- package/src/assets/fonts/roboto/Roboto-Bold-webfont.woff +0 -0
- package/src/assets/fonts/roboto/Roboto-Medium-webfont.eot +0 -0
- package/src/assets/fonts/roboto/Roboto-Medium-webfont.svg +607 -0
- package/src/assets/fonts/roboto/Roboto-Medium-webfont.ttf +0 -0
- package/src/assets/fonts/roboto/Roboto-Medium-webfont.woff +0 -0
- package/src/assets/fonts/roboto/Roboto-Regular-webfont.eot +0 -0
- package/src/assets/fonts/roboto/Roboto-Regular-webfont.svg +635 -0
- package/src/assets/fonts/roboto/Roboto-Regular-webfont.ttf +0 -0
- package/src/assets/fonts/roboto/Roboto-Regular-webfont.woff +0 -0
- package/src/assets/i18n/en.json +12 -0
- package/src/assets/icons/android-chrome-192x192.png +0 -0
- package/src/assets/icons/android-chrome-512x512.png +0 -0
- package/src/assets/icons/apple-touch-icon.png +0 -0
- package/src/assets/icons/favicon-16x16.png +0 -0
- package/src/assets/icons/favicon-32x32.png +0 -0
- package/src/assets/icons/favicon.ico +0 -0
- package/src/assets/icons/site.webmanifest +1 -0
- package/src/assets/images/electron.bmp +0 -0
- package/src/bin/activator +0 -0
- package/src/bin/activator.exe +0 -0
- package/src/environments/environment.dev.ts +4 -0
- package/src/environments/environment.prod.ts +4 -0
- package/src/environments/environment.ts +4 -0
- package/src/environments/environment.web.prod.ts +4 -0
- package/src/environments/environment.web.ts +4 -0
- package/src/favicon.ico +0 -0
- package/src/index.html +55 -0
- package/src/karma.conf.js +50 -0
- package/src/main.ts +15 -0
- package/src/polyfills-test.ts +1 -0
- package/src/polyfills.ts +53 -0
- package/src/styles/base/loading.scss +87 -0
- package/src/styles/base/reset.scss +408 -0
- package/src/styles/components/alert.scss +54 -0
- package/src/styles/components/buttons.scss +93 -0
- package/src/styles/components/forms.scss +96 -0
- package/src/styles/components/inputs.scss +113 -0
- package/src/styles/components/modal.scss +52 -0
- package/src/styles/components/paginator.scss +108 -0
- package/src/styles/components/scrollbox.scss +71 -0
- package/src/styles/components/spinner.scss +11 -0
- package/src/styles/components/tables.scss +42 -0
- package/src/styles/components/tabs.scss +44 -0
- package/src/styles/components/toolbar.scss +130 -0
- package/src/styles/fonts/md.scss +54 -0
- package/src/styles/fonts/octicons.scss +1351 -0
- package/src/styles/fonts/roboto.scss +32 -0
- package/src/styles/themes/dashboard.scss +294 -0
- package/src/styles/themes/euphoria.scss +283 -0
- package/src/styles/themes/mellow.scss +280 -0
- package/src/styles/themes/midnight.scss +283 -0
- package/src/styles/themes/passion.scss +280 -0
- package/src/styles/themes/swiss.scss +283 -0
- package/src/styles/tools/_functions.scss +5 -0
- package/src/styles/tools/_mixins.scss +159 -0
- package/src/styles/tools/_placeholders.scss +17 -0
- package/src/styles/tools/_variables.scss +67 -0
- package/src/styles.scss +37 -0
- package/src/test.ts +22 -0
- package/src/tsconfig.app.json +20 -0
- package/src/tsconfig.spec.json +23 -0
- package/src/typings.d.ts +9 -0
- package/tailwind.config.js +67 -0
- package/tsconfig.json +42 -0
- package/tsconfig.serve.json +27 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
@import "../../../styles/tools/variables";
|
|
2
|
+
|
|
3
|
+
header {
|
|
4
|
+
display: grid;
|
|
5
|
+
grid-template-areas: "left middle right";
|
|
6
|
+
grid-template-columns: 240px 1fr 240px;
|
|
7
|
+
grid-template-rows: $appHeaderHeight;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
@media only screen and (min-width: 1440px) {
|
|
11
|
+
header {
|
|
12
|
+
grid-template-columns: 300px 1fr 300px;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.left {
|
|
17
|
+
grid-area: left;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.middle {
|
|
21
|
+
grid-area: middle;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.right {
|
|
25
|
+
grid-area: right;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.left,
|
|
29
|
+
.middle,
|
|
30
|
+
.right {
|
|
31
|
+
@apply relative;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.middle {
|
|
35
|
+
@apply m-0;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.header-block {
|
|
39
|
+
@apply p-0 h-full;
|
|
40
|
+
|
|
41
|
+
a {
|
|
42
|
+
@apply cursor-pointer text-[11px] text-center no-underline py-[5px] px-[10px] inline-block outline-none whitespace-nowrap opacity-0 invisible transition-all;
|
|
43
|
+
|
|
44
|
+
i {
|
|
45
|
+
@apply block text-[24px] leading-none p-0;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
a+a {
|
|
50
|
+
@apply pl-[5px];
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
a.gravatar {
|
|
54
|
+
@apply mt-[1px];
|
|
55
|
+
|
|
56
|
+
img {
|
|
57
|
+
@apply w-[38px] rounded-full;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
@@ -0,0 +1,229 @@
|
|
|
1
|
+
import { Component, OnInit } from '@angular/core';
|
|
2
|
+
import { Router } from '@angular/router';
|
|
3
|
+
import { AlertService, AuthService, ConfigService, DatabaseService, GravatarService, MessageService, ModalService, PresentationService, UtilsService } from '@app/core/services';
|
|
4
|
+
import { AuthUser } from '@main/types';
|
|
5
|
+
import { StorageType } from '@main/enums';
|
|
6
|
+
import { Collection } from '@main/database/entity';
|
|
7
|
+
|
|
8
|
+
@Component({
|
|
9
|
+
selector: 'app-header',
|
|
10
|
+
templateUrl: './header.component.html',
|
|
11
|
+
styleUrls: ['./header.component.scss']
|
|
12
|
+
})
|
|
13
|
+
export class HeaderComponent implements OnInit {
|
|
14
|
+
|
|
15
|
+
collectionId: number;
|
|
16
|
+
currentUser: AuthUser;
|
|
17
|
+
gravatarUrl: string;
|
|
18
|
+
|
|
19
|
+
gridEnabled = true;
|
|
20
|
+
toolbarEnabled = true;
|
|
21
|
+
previewEnabled = true;
|
|
22
|
+
inspectEnabled = true;
|
|
23
|
+
navigationEnabled = true;
|
|
24
|
+
asideEnabled = true;
|
|
25
|
+
|
|
26
|
+
constructor(
|
|
27
|
+
private router: Router,
|
|
28
|
+
private utils: UtilsService,
|
|
29
|
+
private alertService: AlertService,
|
|
30
|
+
private authService: AuthService,
|
|
31
|
+
private configService: ConfigService,
|
|
32
|
+
private messageService: MessageService,
|
|
33
|
+
private modalService: ModalService,
|
|
34
|
+
private databaseService: DatabaseService,
|
|
35
|
+
private presentationService: PresentationService,
|
|
36
|
+
private gravatar: GravatarService
|
|
37
|
+
) { }
|
|
38
|
+
|
|
39
|
+
ngOnInit() {
|
|
40
|
+
this.databaseService.watchCollectionResultSet$.subscribe((results: Collection[]) => {
|
|
41
|
+
if (results) {
|
|
42
|
+
const collectionId = this.databaseService.getCollectionId();
|
|
43
|
+
if (collectionId) {
|
|
44
|
+
const hasChildren = results.some(x => x.parent_id === collectionId);
|
|
45
|
+
this.collectionId = (hasChildren) ? 0 : collectionId;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
this.authService.watchAuthUser$.subscribe((result: AuthUser) => {
|
|
50
|
+
if (result?.email) {
|
|
51
|
+
this.currentUser = result;
|
|
52
|
+
this.gravatarUrl = this.gravatar.url(result.email, 128, 'mm');
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
this.presentationService._asideEnabled.subscribe((result) => {
|
|
56
|
+
this.asideEnabled = result;
|
|
57
|
+
});
|
|
58
|
+
this.presentationService._navigationEnabled.subscribe((result) => {
|
|
59
|
+
this.navigationEnabled = result;
|
|
60
|
+
});
|
|
61
|
+
this.presentationService._gridEnabled.subscribe((result) => {
|
|
62
|
+
this.gridEnabled = result;
|
|
63
|
+
});
|
|
64
|
+
this.presentationService._toolbarEnabled.subscribe((result) => {
|
|
65
|
+
this.toolbarEnabled = result;
|
|
66
|
+
});
|
|
67
|
+
this.presentationService._previewEnabled.subscribe((result) => {
|
|
68
|
+
this.previewEnabled = result;
|
|
69
|
+
});
|
|
70
|
+
this.presentationService._inspectEnabled.subscribe((result) => {
|
|
71
|
+
this.inspectEnabled = result;
|
|
72
|
+
});
|
|
73
|
+
this.presentationService._defaultTheme.subscribe((result) => this.enableTheme(result));
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
handleAddFonts(event: Event, collectionId: number): void {
|
|
77
|
+
event.stopPropagation();
|
|
78
|
+
|
|
79
|
+
const config = this.configService.get(StorageType.Options);
|
|
80
|
+
const importType = (config?.import?.type) ? config.import.type : 'ask';
|
|
81
|
+
|
|
82
|
+
let settings = {
|
|
83
|
+
type: 'question',
|
|
84
|
+
buttons: ['Cancel', 'Select files', 'Select folders'],
|
|
85
|
+
defaultId: 2,
|
|
86
|
+
title: 'Select Fonts',
|
|
87
|
+
message: 'Do you want to select files or folders?'
|
|
88
|
+
};
|
|
89
|
+
|
|
90
|
+
if (importType === 'ask') {
|
|
91
|
+
settings = {
|
|
92
|
+
...settings,
|
|
93
|
+
...{
|
|
94
|
+
checkboxLabel: 'Add fonts to catalog.',
|
|
95
|
+
checkboxChecked: true
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
this.messageService.showMessageBox(settings).then((response: object | any) => {
|
|
101
|
+
if (response?.response > 0) {
|
|
102
|
+
const isFiles = (response.response === 1) ? true : false;
|
|
103
|
+
const options = (isFiles) ? { properties: ['openFile', 'multiSelections'] } : { properties: ['openDirectory', 'multiSelections'] };
|
|
104
|
+
this.messageService.showOpenDialog(options).then((dialog: object | any) => {
|
|
105
|
+
if (dialog.filePaths.length) {
|
|
106
|
+
const addToCatalog = (importType === 'ask') ? response.checkboxChecked : (importType === 'catalog') ? true : false;
|
|
107
|
+
if (isFiles) {
|
|
108
|
+
this.openFiles(collectionId, { files: dialog.filePaths, addToCatalog });
|
|
109
|
+
} else {
|
|
110
|
+
this.openFolders(collectionId, { folders: dialog.filePaths, addToCatalog });
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
openFiles(collectionId: number, options: any): void {
|
|
119
|
+
this.presentationService.setLoadingSpinner(true);
|
|
120
|
+
this.alertService.info('Adding fonts please wait..', 1e3, true);
|
|
121
|
+
this.messageService.scanFiles({ ...options, collectionId }).then(this.utils.delay(1e3)).then(() => {
|
|
122
|
+
this.messageService.collectionUpdateCount(collectionId).then((result: Collection[]) => this.databaseService.setCollectionResultSet(result));
|
|
123
|
+
this.presentationService.setLoadingSpinner(false);
|
|
124
|
+
this.alertService.dismiss();
|
|
125
|
+
this.messageService.log(`Added fonts to collection id #${collectionId}.`, 1);
|
|
126
|
+
|
|
127
|
+
this.messageService.collectionEnable(collectionId, { enabled: true }).then((results: Collection[]) => {
|
|
128
|
+
this.databaseService.resetPage(1);
|
|
129
|
+
this.databaseService.setCollectionId(collectionId);
|
|
130
|
+
this.databaseService.setCollectionResultSet(results);
|
|
131
|
+
});
|
|
132
|
+
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
openFolders(collectionId: number, options: any): void {
|
|
137
|
+
this.presentationService.setLoadingSpinner(true);
|
|
138
|
+
this.alertService.info('Adding fonts please wait..', 1e3, true);
|
|
139
|
+
this.messageService.scanFolders({ ...options, collectionId }).then(this.utils.delay(1e3)).then(() => {
|
|
140
|
+
this.messageService.collectionUpdateCount(collectionId).then((result: Collection[]) => this.databaseService.setCollectionResultSet(result));
|
|
141
|
+
this.presentationService.setLoadingSpinner(false);
|
|
142
|
+
this.alertService.dismiss();
|
|
143
|
+
this.messageService.log(`Added folders to collection id #${collectionId}.`, 1);
|
|
144
|
+
|
|
145
|
+
this.messageService.collectionEnable(collectionId, { enabled: true }).then((results: Collection[]) => {
|
|
146
|
+
this.databaseService.resetPage(1);
|
|
147
|
+
this.databaseService.setCollectionId(collectionId);
|
|
148
|
+
this.databaseService.setCollectionResultSet(results);
|
|
149
|
+
});
|
|
150
|
+
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
handleCreateCollection(_event: Event): void {
|
|
155
|
+
this.modalService.open('collection-create');
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
handleLogout(_event: Event): void {
|
|
159
|
+
this.authService.logout();
|
|
160
|
+
this.router.navigate(['/settings']);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
handleToggleAside(_event: Event): void {
|
|
164
|
+
this.presentationService.setAsideEnabled(!this.asideEnabled);
|
|
165
|
+
this.presentationService.saveLayoutSettings();
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
handleToggleNavigation(_event: Event): void {
|
|
169
|
+
this.presentationService.setNavigationEnabled(!this.navigationEnabled);
|
|
170
|
+
this.presentationService.saveLayoutSettings();
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
handleTogglePreview(_event: Event): void {
|
|
174
|
+
this.presentationService.setPreviewEnabled(!this.previewEnabled);
|
|
175
|
+
this.presentationService.saveLayoutSettings();
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
handleToggleInspect(_event: Event): void {
|
|
179
|
+
this.presentationService.setInspectEnabled(!this.inspectEnabled);
|
|
180
|
+
this.presentationService.saveLayoutSettings();
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
handleToggleToolbar(_event: Event): void {
|
|
184
|
+
this.presentationService.setToolbarEnabled(!this.toolbarEnabled);
|
|
185
|
+
this.presentationService.saveLayoutSettings();
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
handleToggleGrid(_event: Event): void {
|
|
189
|
+
this.presentationService.setGridEnabled(!this.gridEnabled);
|
|
190
|
+
this.presentationService.saveLayoutSettings();
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
enableTheme(theme: string): void {
|
|
194
|
+
const body = document.querySelector('body');
|
|
195
|
+
const themes = this.presentationService.getThemes();
|
|
196
|
+
if (themes.map(item => item.key).includes(theme)) {
|
|
197
|
+
body.setAttribute('data-theme', theme);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
handleSwitchTheme(_event: Event): void {
|
|
202
|
+
const body = document.querySelector('body') as HTMLBodyElement;
|
|
203
|
+
const attr = body.getAttribute('data-theme');
|
|
204
|
+
const themes = this.presentationService.getThemes();
|
|
205
|
+
|
|
206
|
+
let idx = themes.map(item => item.key).indexOf(attr);
|
|
207
|
+
|
|
208
|
+
if (idx < themes.length - 1) {
|
|
209
|
+
idx++;
|
|
210
|
+
} else {
|
|
211
|
+
idx = 0;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
if (themes[idx]) {
|
|
215
|
+
const theme: string = themes[idx].key;
|
|
216
|
+
body.setAttribute('data-theme', theme);
|
|
217
|
+
this.presentationService.setTheme(theme);
|
|
218
|
+
this.presentationService.setThemeVars(theme);
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
handleToggleSearch(_event: Event): void {
|
|
223
|
+
this.presentationService._asideComponent.next('search');
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
handleLoadSettings(): void {
|
|
227
|
+
this.modalService.open('system-settings');
|
|
228
|
+
}
|
|
229
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<div class="application main" [class.navigation]="navigationEnabled" [class.aside]="asideEnabled">
|
|
2
|
+
<app-header></app-header>
|
|
3
|
+
<app-navigation></app-navigation>
|
|
4
|
+
<main>
|
|
5
|
+
<router-outlet></router-outlet>
|
|
6
|
+
</main>
|
|
7
|
+
<app-aside></app-aside>
|
|
8
|
+
<app-footer></app-footer>
|
|
9
|
+
</div>
|
|
10
|
+
|
|
11
|
+
<app-glyph></app-glyph>
|
|
12
|
+
<app-settings></app-settings>
|
|
13
|
+
<app-update-collection></app-update-collection>
|
|
14
|
+
<app-create-collection></app-create-collection>
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
@import "../../styles/tools/variables";
|
|
2
|
+
|
|
3
|
+
app-header {
|
|
4
|
+
grid-area: header;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
app-footer {
|
|
8
|
+
grid-area: footer;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
main {
|
|
12
|
+
grid-area: main;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
app-navigation {
|
|
16
|
+
grid-area: navigation;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
app-aside {
|
|
20
|
+
grid-area: aside;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.application {
|
|
24
|
+
display: grid;
|
|
25
|
+
grid-template-areas: "header" "main" "footer";
|
|
26
|
+
grid-template-columns: 1fr;
|
|
27
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.application.navigation {
|
|
31
|
+
display: grid;
|
|
32
|
+
grid-template-areas: "header header" "navigation main" "footer footer";
|
|
33
|
+
grid-template-columns: 240px 1fr;
|
|
34
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.application.aside {
|
|
38
|
+
display: grid;
|
|
39
|
+
grid-template-areas: "header header header" "main aside" "footer footer footer";
|
|
40
|
+
grid-template-columns: 240px 1fr 240px;
|
|
41
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.application.main {
|
|
45
|
+
display: grid;
|
|
46
|
+
grid-template-areas: "header" "main" "footer";
|
|
47
|
+
grid-template-columns: 1fr;
|
|
48
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.application.main.aside {
|
|
52
|
+
display: grid;
|
|
53
|
+
grid-template-areas: "header header" "main aside" "footer footer";
|
|
54
|
+
grid-template-columns: 1fr 240px;
|
|
55
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.application.main.navigation {
|
|
59
|
+
display: grid;
|
|
60
|
+
grid-template-areas: "header header" "navigation main" "footer footer";
|
|
61
|
+
grid-template-columns: 240px 1fr;
|
|
62
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.application.main.aside.navigation {
|
|
66
|
+
display: grid;
|
|
67
|
+
grid-template-areas: "header header header" "navigation main aside" "footer footer footer";
|
|
68
|
+
grid-template-columns: 240px 1fr 240px;
|
|
69
|
+
grid-template-rows: $appHeaderHeight 1fr 30px;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
app-header,
|
|
73
|
+
app-footer,
|
|
74
|
+
app-navigation,
|
|
75
|
+
app-aside {
|
|
76
|
+
position: relative;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
app-navigation {
|
|
80
|
+
visibility: hidden;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
app-aside {
|
|
84
|
+
visibility: hidden;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.application.navigation {
|
|
88
|
+
app-navigation {
|
|
89
|
+
visibility: visible;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.application.aside {
|
|
94
|
+
app-aside {
|
|
95
|
+
visibility: visible;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
@media only screen and (min-width: 1440px) {
|
|
100
|
+
.application.navigation {
|
|
101
|
+
grid-template-columns: 300px 1fr;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.application.aside {
|
|
105
|
+
grid-template-columns: 300px 1fr 300px;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.application.main.aside {
|
|
109
|
+
grid-template-columns: 1fr 300px;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.application.main.navigation {
|
|
113
|
+
grid-template-columns: 300px 1fr;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.application.main.aside.navigation {
|
|
117
|
+
grid-template-columns: 300px 1fr 300px;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Component, OnInit } from '@angular/core';
|
|
2
|
+
import { PresentationService } from '@app/core/services';
|
|
3
|
+
|
|
4
|
+
@Component({
|
|
5
|
+
selector: 'app-layout',
|
|
6
|
+
templateUrl: './layout.component.html',
|
|
7
|
+
styleUrls: ['./layout.component.scss']
|
|
8
|
+
})
|
|
9
|
+
export class LayoutComponent implements OnInit {
|
|
10
|
+
|
|
11
|
+
navigationEnabled = true;
|
|
12
|
+
asideEnabled = true;
|
|
13
|
+
|
|
14
|
+
constructor(
|
|
15
|
+
private presentationService: PresentationService
|
|
16
|
+
) { }
|
|
17
|
+
|
|
18
|
+
ngOnInit() {
|
|
19
|
+
this.presentationService._navigationEnabled.subscribe((result) => this.navigationEnabled = result);
|
|
20
|
+
this.presentationService._asideEnabled.subscribe((result) => this.asideEnabled = result);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
3
|
+
import { RouterModule } from '@angular/router';
|
|
4
|
+
import { FormsModule } from '@angular/forms';
|
|
5
|
+
|
|
6
|
+
import { SharedModule } from '@app/shared/shared.module';
|
|
7
|
+
|
|
8
|
+
import { LayoutComponent } from './layout.component';
|
|
9
|
+
import { HeaderComponent } from './header/header.component';
|
|
10
|
+
import { FooterComponent } from './footer/footer.component';
|
|
11
|
+
import { NavigationComponent } from './navigation/navigation.component';
|
|
12
|
+
import { AsideComponent } from './aside/aside.component';
|
|
13
|
+
|
|
14
|
+
@NgModule({
|
|
15
|
+
imports: [
|
|
16
|
+
CommonModule,
|
|
17
|
+
SharedModule,
|
|
18
|
+
FormsModule,
|
|
19
|
+
RouterModule
|
|
20
|
+
],
|
|
21
|
+
declarations: [
|
|
22
|
+
LayoutComponent,
|
|
23
|
+
HeaderComponent,
|
|
24
|
+
FooterComponent,
|
|
25
|
+
NavigationComponent,
|
|
26
|
+
AsideComponent
|
|
27
|
+
],
|
|
28
|
+
exports: [
|
|
29
|
+
LayoutComponent
|
|
30
|
+
]
|
|
31
|
+
})
|
|
32
|
+
export class LayoutModule { }
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Routes, Route } from '@angular/router';
|
|
2
|
+
import { LayoutComponent } from './layout.component';
|
|
3
|
+
|
|
4
|
+
export class LayoutService {
|
|
5
|
+
static childRoutes(routes: Routes): Route {
|
|
6
|
+
return {
|
|
7
|
+
path: '',
|
|
8
|
+
component: LayoutComponent,
|
|
9
|
+
children: routes,
|
|
10
|
+
data: { reuse: true }
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
<nav class="component border-right">
|
|
2
|
+
<div class="component__panel">
|
|
3
|
+
|
|
4
|
+
<figure class="figure-stats border-bottom" [class.collapsed]="statsCollapsed === true">
|
|
5
|
+
|
|
6
|
+
<figcaption class="border-bottom">
|
|
7
|
+
<span class="material-icons" (click)="toggleCollapse($event)" data-figure-stats>
|
|
8
|
+
<ng-container *ngIf="statsCollapsed === true; else elseStatsCollapsed">
|
|
9
|
+
arrow_drop_down
|
|
10
|
+
</ng-container>
|
|
11
|
+
<ng-template #elseStatsCollapsed>
|
|
12
|
+
arrow_right
|
|
13
|
+
</ng-template>
|
|
14
|
+
</span>
|
|
15
|
+
<span class="grow">System Statistics</span>
|
|
16
|
+
<span class="flex items-center justify-end mr-1 material-icons-rounded">
|
|
17
|
+
<span class="material-icons cursor-pointer" (click)="toggleFigureCollapse()" title="Collapse">more_horiz</span>
|
|
18
|
+
</span>
|
|
19
|
+
</figcaption>
|
|
20
|
+
|
|
21
|
+
<ul class="statistics">
|
|
22
|
+
<li>
|
|
23
|
+
<a href="#" (click)="handleClickAll($event)">
|
|
24
|
+
<span class="material-icons">playlist_add</span>
|
|
25
|
+
<span class="statistics__title ml-[5px] w-full" title="All Collections">Font Count</span>
|
|
26
|
+
<span class="statistics__count">{{ rowCount }}</span>
|
|
27
|
+
</a>
|
|
28
|
+
</li>
|
|
29
|
+
<li>
|
|
30
|
+
<a href="#" (click)="handleClickFavorites($event)">
|
|
31
|
+
<span class="material-icons">playlist_add</span>
|
|
32
|
+
<span class="statistics__title ml-[5px] w-full" title="My Favorites">My Favorites</span>
|
|
33
|
+
<span class="statistics__count">{{ favoriteCount }}</span>
|
|
34
|
+
</a>
|
|
35
|
+
</li>
|
|
36
|
+
<li>
|
|
37
|
+
<a href="#" (click)="handleClickSystem($event)">
|
|
38
|
+
<span class="material-icons">playlist_add</span>
|
|
39
|
+
<span class="statistics__title ml-[5px] w-full" title="System Fonts">System Fonts</span>
|
|
40
|
+
<span class="statistics__count">{{ systemCount }}</span>
|
|
41
|
+
</a>
|
|
42
|
+
</li>
|
|
43
|
+
<li>
|
|
44
|
+
<a href="#" (click)="handleClickActivated($event)">
|
|
45
|
+
<span class="material-icons">playlist_add</span>
|
|
46
|
+
<span class="statistics__title ml-[5px] w-full" title="Activated Fonts">Activated Fonts</span>
|
|
47
|
+
<span class="statistics__count">{{ activatedCount }}</span>
|
|
48
|
+
</a>
|
|
49
|
+
</li>
|
|
50
|
+
</ul>
|
|
51
|
+
|
|
52
|
+
</figure>
|
|
53
|
+
|
|
54
|
+
<figure class="figure-folders" [class.collapsed]="foldersCollapsed === true">
|
|
55
|
+
<figcaption class="border-bottom">
|
|
56
|
+
<span class="material-icons" (click)="toggleCollapse($event)" data-figure-folders>
|
|
57
|
+
<ng-container *ngIf="foldersCollapsed === true; else elseFoldersCollapsed">
|
|
58
|
+
arrow_drop_down
|
|
59
|
+
</ng-container>
|
|
60
|
+
<ng-template #elseFoldersCollapsed>
|
|
61
|
+
arrow_right
|
|
62
|
+
</ng-template>
|
|
63
|
+
</span>
|
|
64
|
+
<span class="grow">Font Collections</span>
|
|
65
|
+
<span class="flex items-center justify-end mr-1 material-icons-rounded">
|
|
66
|
+
<span class="material-icons cursor-pointer" (click)="toggleDetailsOpen()" title="Collapse">more_horiz</span>
|
|
67
|
+
</span>
|
|
68
|
+
</figcaption>
|
|
69
|
+
|
|
70
|
+
<div *ngIf="resultSet.length" class="flex flex-col w-full h-full overflow-hidden">
|
|
71
|
+
|
|
72
|
+
<div class="hover-scrollbox-x hover-scrollbox-y p-0">
|
|
73
|
+
<ng-template #recursiveList let-items>
|
|
74
|
+
<ng-container *ngFor="let item of items">
|
|
75
|
+
<details [attr.open]="item.collapsed ? '1' : null" [attr.data-id]="item.id">
|
|
76
|
+
|
|
77
|
+
<summary [class.selected]="item.enabled">
|
|
78
|
+
<span class="flex items-center justify-center">
|
|
79
|
+
<span class="material-icons collapsed-icon cursor-pointer" (click)="handleCollapse($event, item.id)"></span>
|
|
80
|
+
</span>
|
|
81
|
+
<span class="flex grow w-full cursor-pointer" [attr.title]="item.title" (click)="handleNavigate($event, item.id)">{{item.title}}</span>
|
|
82
|
+
<span class="flex items-center justify-center mr-1.5" *ngIf="item.enabled" >
|
|
83
|
+
<span class="material-icons cursor-pointer" (click)="handleUpdate($event)" [attr.data-id]="item.id" title="Update Collection">more_horiz</span>
|
|
84
|
+
</span>
|
|
85
|
+
</summary>
|
|
86
|
+
|
|
87
|
+
<ng-container *ngIf="item.children.length; else elseif1">
|
|
88
|
+
<ng-container *ngTemplateOutlet="recursiveList; context:{ $implicit: item.children }"></ng-container>
|
|
89
|
+
</ng-container>
|
|
90
|
+
<ng-template #elseif1>
|
|
91
|
+
<ul>
|
|
92
|
+
<li class="flex items-center justify-start"><span>Font count:</span>
|
|
93
|
+
<span>{{item.storeCount}}</span>
|
|
94
|
+
</li>
|
|
95
|
+
<li class="flex items-center justify-start"><span>Installable:</span>
|
|
96
|
+
<span>{{item.installableCount}}</span>
|
|
97
|
+
</li>
|
|
98
|
+
<li class="flex items-center justify-start"><span>Activated:</span>
|
|
99
|
+
<span>{{item.activatedCount}}</span>
|
|
100
|
+
</li>
|
|
101
|
+
<li class="flex items-center justify-start"><span>Favorited:</span>
|
|
102
|
+
<span>{{item.favoriteCount}}</span>
|
|
103
|
+
</li>
|
|
104
|
+
<li class="flex items-center justify-start"><span>Temporary :</span>
|
|
105
|
+
<span>{{item.temporaryCount}}</span>
|
|
106
|
+
</li>
|
|
107
|
+
</ul>
|
|
108
|
+
</ng-template>
|
|
109
|
+
|
|
110
|
+
</details>
|
|
111
|
+
</ng-container>
|
|
112
|
+
</ng-template>
|
|
113
|
+
|
|
114
|
+
<ng-container *ngTemplateOutlet="recursiveList; context:{ $implicit: resultSet }"></ng-container>
|
|
115
|
+
|
|
116
|
+
</div>
|
|
117
|
+
|
|
118
|
+
</div>
|
|
119
|
+
</figure>
|
|
120
|
+
|
|
121
|
+
<figure class="figure-options hidden" [class.collapsed]="optionsCollapsed === true">
|
|
122
|
+
<figcaption class="border-bottom">
|
|
123
|
+
<span class="material-icons" (click)="toggleCollapse($event)" data-figure-options>
|
|
124
|
+
<ng-container *ngIf="optionsCollapsed === true; else elseOptionsCollapsed">
|
|
125
|
+
arrow_drop_down
|
|
126
|
+
</ng-container>
|
|
127
|
+
<ng-template #elseOptionsCollapsed>
|
|
128
|
+
arrow_right
|
|
129
|
+
</ng-template>
|
|
130
|
+
</span>
|
|
131
|
+
<span class="grow">Folder Options</span>
|
|
132
|
+
<span class="flex items-center justify-end mr-3">{{resultSet.length}}</span>
|
|
133
|
+
</figcaption>
|
|
134
|
+
<ul class="w-full py-2 hidden">
|
|
135
|
+
<li class="py-1 px-4">Sort collection</li>
|
|
136
|
+
<li class="py-1 px-4">Sort collection</li>
|
|
137
|
+
<li class="py-1 px-4">Sort collection</li>
|
|
138
|
+
</ul>
|
|
139
|
+
</figure>
|
|
140
|
+
|
|
141
|
+
</div>
|
|
142
|
+
</nav>
|
|
File without changes
|