@fecommunity/reactpress 4.0.0-beta.1 → 4.0.0-beta.11
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/README.md +20 -26
- package/dist/utils/server-bundle.js +7 -0
- package/out/bin/reactpress-theme-client.js +64 -1
- package/out/bin/reactpress.js +96 -514
- package/out/core/services/config.js +4 -1
- package/out/core/services/database/index.js +18 -5
- package/out/core/services/database/sqlite.js +28 -5
- package/out/core/services/init.js +1 -53
- package/out/core/services/local-site.js +15 -10
- package/out/core/services/theme-bootstrap.js +51 -0
- package/out/core/utils/env-file.js +99 -0
- package/out/core/utils/paths.js +5 -4
- package/out/lib/api-dev.js +11 -1
- package/out/lib/bootstrap.js +13 -40
- package/out/lib/cli-events.js +54 -0
- package/out/lib/command-palette.js +53 -0
- package/out/lib/context-status.js +154 -0
- package/out/lib/create-site.js +187 -0
- package/out/lib/database-mode.js +45 -0
- package/out/lib/design-tokens.js +55 -0
- package/out/lib/dev-banner.js +10 -5
- package/out/lib/dev-session.js +9 -2
- package/out/lib/dev.js +68 -25
- package/out/lib/docker.js +12 -0
- package/out/lib/doctor.js +131 -10
- package/out/lib/http.js +20 -0
- package/out/lib/i18n/index.js +5 -1
- package/out/lib/i18n/strings.js +161 -81
- package/out/lib/lifecycle.js +21 -1
- package/out/lib/menu-actions.js +418 -0
- package/out/lib/nginx.js +5 -2
- package/out/lib/paths.js +11 -0
- package/out/lib/pm2.js +9 -2
- package/out/lib/ports.js +134 -13
- package/out/lib/publish.js +3 -0
- package/out/lib/remote-dev.js +5 -1
- package/out/lib/server-bundle.js +84 -0
- package/out/lib/shell-mode.js +23 -0
- package/out/lib/theme-warmup.js +1 -1
- package/out/shell/app.js +384 -0
- package/out/shell/components/brand-banner.js +93 -0
- package/out/shell/components/command-palette.js +77 -0
- package/out/shell/components/dev-stepper.js +54 -0
- package/out/shell/components/ink-theme.js +86 -0
- package/out/shell/components/menu-list.js +49 -0
- package/out/shell/components/pulse-bar.js +55 -0
- package/out/shell/components/status-rack.js +47 -0
- package/out/shell/hooks/use-terminal-size.js +27 -0
- package/out/shell/ink-shell.mjs +12056 -0
- package/out/shell/lib/shell-layout.js +60 -0
- package/out/shell/runtime/render-ink.js +89 -0
- package/out/ui/banner-startup.js +117 -0
- package/out/ui/banner.js +404 -277
- package/out/ui/interactive.js +149 -125
- package/out/ui/startup-splash.js +185 -0
- package/out/ui/theme.js +62 -10
- package/package.json +5 -3
- package/server/bin/reactpress-server.js +29 -2
- package/server/dist/app.module.js +18 -30
- package/server/dist/filters/http-exception.filter.js +1 -1
- package/server/dist/generate-swagger.js +12 -11
- package/server/dist/interceptors/transform.interceptor.js +10 -5
- package/server/dist/logger/index.js +5 -4
- package/server/dist/main.js +47 -23
- package/server/dist/modules/article/article.controller.js +103 -48
- package/server/dist/modules/article/article.entity.js +61 -41
- package/server/dist/modules/article/article.module.js +18 -3
- package/server/dist/modules/article/article.service.js +151 -29
- package/server/dist/modules/auth/auth.controller.js +11 -11
- package/server/dist/modules/auth/auth.module.js +4 -4
- package/server/dist/modules/auth/auth.service.js +8 -7
- package/server/dist/modules/auth/jwt-auth.guard.js +4 -3
- package/server/dist/modules/auth/jwt.strategy.js +4 -3
- package/server/dist/modules/auth/roles.guard.js +2 -2
- package/server/dist/modules/category/category.controller.js +21 -20
- package/server/dist/modules/category/category.entity.js +13 -13
- package/server/dist/modules/category/category.module.js +1 -1
- package/server/dist/modules/category/category.service.js +5 -4
- package/server/dist/modules/comment/comment.controller.js +24 -20
- package/server/dist/modules/comment/comment.entity.js +31 -31
- package/server/dist/modules/comment/comment.module.js +11 -2
- package/server/dist/modules/comment/comment.service.js +43 -16
- package/server/dist/modules/comment/html.js +3 -3
- package/server/dist/modules/extension/preview-draft.store.js +1 -1
- package/server/dist/modules/extension/theme.service.js +19 -19
- package/server/dist/modules/file/file.controller.js +22 -20
- package/server/dist/modules/file/file.entity.js +20 -15
- package/server/dist/modules/file/file.module.js +16 -4
- package/server/dist/modules/file/file.service.js +70 -24
- package/server/dist/modules/install/install.controller.js +5 -5
- package/server/dist/modules/install/install.module.js +1 -1
- package/server/dist/modules/install/install.service.js +2 -2
- package/server/dist/modules/knowledge/knowledge.controller.js +35 -33
- package/server/dist/modules/knowledge/knowledge.entity.js +33 -33
- package/server/dist/modules/knowledge/knowledge.module.js +1 -1
- package/server/dist/modules/knowledge/knowledge.service.js +12 -11
- package/server/dist/modules/page/page.controller.js +24 -23
- package/server/dist/modules/page/page.entity.js +27 -27
- package/server/dist/modules/page/page.module.js +1 -1
- package/server/dist/modules/page/page.service.js +12 -12
- package/server/dist/modules/search/search.controller.js +12 -12
- package/server/dist/modules/search/search.entity.js +13 -13
- package/server/dist/modules/search/search.module.js +1 -1
- package/server/dist/modules/search/search.service.js +2 -2
- package/server/dist/modules/setting/setting.constant.js +3 -19
- package/server/dist/modules/setting/setting.controller.js +11 -11
- package/server/dist/modules/setting/setting.entity.js +64 -49
- package/server/dist/modules/setting/setting.module.js +2 -2
- package/server/dist/modules/setting/setting.service.js +169 -24
- package/server/dist/modules/smtp/mail.util.js +5 -9
- package/server/dist/modules/smtp/smtp.controller.js +27 -14
- package/server/dist/modules/smtp/smtp.entity.js +15 -15
- package/server/dist/modules/smtp/smtp.module.js +2 -2
- package/server/dist/modules/smtp/smtp.service.js +40 -12
- package/server/dist/modules/tag/tag.controller.js +24 -22
- package/server/dist/modules/tag/tag.entity.js +12 -12
- package/server/dist/modules/tag/tag.module.js +1 -1
- package/server/dist/modules/tag/tag.service.js +5 -4
- package/server/dist/modules/user/user.controller.js +39 -28
- package/server/dist/modules/user/user.entity.js +22 -22
- package/server/dist/modules/user/user.module.js +2 -2
- package/server/dist/modules/user/user.service.js +16 -12
- package/server/dist/modules/view/view.controller.js +20 -19
- package/server/dist/modules/view/view.entity.js +24 -24
- package/server/dist/modules/view/view.module.js +1 -1
- package/server/dist/modules/view/view.service.js +4 -4
- package/server/dist/starter.js +202 -14
- package/server/dist/utils/date.util.js +1 -1
- package/server/dist/utils/markdown.util.js +1 -1
- package/server/dist/utils/oss/aliyun-oss-client.js +5 -0
- package/server/dist/utils/oss.util.js +6 -1
- package/server/dist/utils/theme-placeholder-cover.js +94 -0
- package/server/dist/utils/uniqueid.util.js +1 -1
- package/server/dist/utils/upload.util.js +23 -8
- package/server/dist/utils/user.util.js +6 -2
- package/server/package-lock.json +21114 -0
- package/server/package.json +13 -10
- package/server/public/favicon.png +0 -0
- package/templates/config.local.json +1 -1
- package/templates/env.local.default +1 -1
- package/toolkit/dist/.source-fingerprint-toolkit +1 -0
- package/toolkit/dist/admin/index.js +18 -0
- package/toolkit/dist/admin/permissions.js +33 -0
- package/toolkit/dist/admin/registry.js +79 -0
- package/toolkit/dist/api/Article.js +188 -0
- package/toolkit/dist/api/Auth.js +58 -0
- package/toolkit/dist/api/Category.js +84 -0
- package/toolkit/dist/api/Comment.js +97 -0
- package/toolkit/dist/api/File.js +71 -0
- package/toolkit/dist/api/HttpClient.js +96 -0
- package/toolkit/dist/api/Knowledge.js +123 -0
- package/toolkit/dist/api/Page.js +97 -0
- package/toolkit/dist/api/Search.js +58 -0
- package/toolkit/dist/api/Setting.js +45 -0
- package/toolkit/dist/api/Smtp.js +73 -0
- package/toolkit/dist/api/Tag.js +97 -0
- package/toolkit/dist/api/User.js +72 -0
- package/toolkit/dist/api/View.js +84 -0
- package/toolkit/dist/api/index.js +30 -0
- package/toolkit/dist/api/instance.js +71 -0
- package/toolkit/dist/app/createReactPressApp.js +265 -0
- package/toolkit/dist/app/createThemeApp.js +51 -0
- package/toolkit/dist/app/devChunkRecovery.js +68 -0
- package/toolkit/dist/app/index.js +11 -0
- package/toolkit/dist/config/env.js +103 -0
- package/toolkit/dist/config/global.js +396 -0
- package/toolkit/dist/config/i18n.js +59 -0
- package/toolkit/dist/config/index.js +26 -0
- package/toolkit/dist/config/locales/en.json +125 -0
- package/toolkit/dist/config/locales/zh.json +125 -0
- package/toolkit/dist/dev/index.js +12 -0
- package/toolkit/dist/dev/portRedirect.js +93 -0
- package/toolkit/dist/dev/vitePortRedirectPlugin.js +40 -0
- package/toolkit/dist/extension/branding-mods.js +65 -0
- package/toolkit/dist/extension/configuration/defaults.js +32 -0
- package/toolkit/dist/extension/configuration/formily.js +170 -0
- package/toolkit/dist/extension/configuration/index.js +28 -0
- package/toolkit/dist/extension/configuration/paths.js +50 -0
- package/toolkit/dist/extension/configuration/presets/twentytwentyfive.js +94 -0
- package/toolkit/dist/extension/configuration/resolve.js +98 -0
- package/toolkit/dist/extension/configuration/types.js +3 -0
- package/toolkit/dist/extension/configuration/validate.js +21 -0
- package/toolkit/dist/extension/index.js +35 -0
- package/toolkit/dist/extension/manifest-normalize.js +75 -0
- package/toolkit/dist/extension/node.js +6 -0
- package/toolkit/dist/extension/presets/twentytwentyfive-appearance.js +193 -0
- package/toolkit/dist/extension/presets/twentytwentyfive-customizer.js +199 -0
- package/toolkit/dist/extension/preview.js +92 -0
- package/toolkit/dist/extension/site-notices.js +88 -0
- package/toolkit/dist/extension/site-settings.js +144 -0
- package/toolkit/dist/extension/theme-admin-locale.io.js +54 -0
- package/toolkit/dist/extension/theme-admin-locale.js +81 -0
- package/toolkit/dist/extension/theme.js +93 -0
- package/toolkit/dist/extension/twentytwentyfive-vars.js +100 -0
- package/toolkit/dist/index.js +60 -0
- package/toolkit/dist/plugin/admin/index.js +20 -0
- package/toolkit/dist/plugin/admin/permissions.js +33 -0
- package/toolkit/dist/plugin/admin/plugin-admin.js +41 -0
- package/toolkit/dist/plugin/admin/registry.js +79 -0
- package/toolkit/dist/plugin/admin/slots.js +16 -0
- package/toolkit/dist/plugin/client/client.js +95 -0
- package/toolkit/dist/plugin/client/index.js +11 -0
- package/toolkit/dist/plugin/client/runtime.js +30 -0
- package/toolkit/dist/plugin/dev/index.js +16 -0
- package/toolkit/dist/plugin/dev/portRedirect.js +111 -0
- package/toolkit/dist/plugin/dev/vitePortRedirectPlugin.js +40 -0
- package/toolkit/dist/plugin/extension/index.js +20 -0
- package/toolkit/dist/plugin/extension/plugin-admin-locale.io.js +54 -0
- package/toolkit/dist/plugin/extension/plugin-admin-locale.js +60 -0
- package/toolkit/dist/plugin/extension/plugin.js +146 -0
- package/toolkit/dist/plugin/extension/security.js +74 -0
- package/toolkit/dist/plugin/extension/validate.js +55 -0
- package/toolkit/dist/plugin/index.js +52 -0
- package/toolkit/dist/plugin/node.js +6 -0
- package/toolkit/dist/plugin/react/client.js +95 -0
- package/toolkit/dist/plugin/react/index.js +19 -0
- package/toolkit/dist/plugin/react/plugin-admin-ui.js +38 -0
- package/toolkit/dist/plugin/react/runtime.js +30 -0
- package/toolkit/dist/plugin/server/hook-reject.js +39 -0
- package/toolkit/dist/plugin/server/index.js +18 -0
- package/toolkit/dist/plugin/server/types.js +3 -0
- package/toolkit/dist/primitives/AntdStyleTransitionFix.js +16 -0
- package/toolkit/dist/primitives/Badge.js +9 -0
- package/toolkit/dist/primitives/Button.js +38 -0
- package/toolkit/dist/primitives/ColorModeToggle.js +13 -0
- package/toolkit/dist/primitives/IconButton.js +13 -0
- package/toolkit/dist/primitives/ScrollToTarget.js +48 -0
- package/toolkit/dist/primitives/Separator.js +9 -0
- package/toolkit/dist/primitives/Skeleton.js +9 -0
- package/toolkit/dist/primitives/Slot.js +25 -0
- package/toolkit/dist/primitives/Spinner.js +9 -0
- package/toolkit/dist/primitives/animation/ConditionTransition.js +13 -0
- package/toolkit/dist/primitives/animation/ListTrail.js +14 -0
- package/toolkit/dist/primitives/animation/Opacity.js +10 -0
- package/toolkit/dist/primitives/animation/Spring.js +29 -0
- package/toolkit/dist/primitives/animation/index.js +11 -0
- package/toolkit/dist/primitives/cn.js +7 -0
- package/toolkit/dist/primitives/icons.js +15 -0
- package/toolkit/dist/primitives/index.js +44 -0
- package/toolkit/dist/react/client.js +95 -0
- package/toolkit/dist/react/index.js +11 -0
- package/toolkit/dist/react/runtime.js +30 -0
- package/toolkit/dist/theme/antdDocument.js +59 -0
- package/toolkit/dist/theme/api/api-data.js +8 -0
- package/toolkit/dist/theme/api/api.js +27 -0
- package/toolkit/dist/theme/api/httpClient.js +83 -0
- package/toolkit/dist/theme/api/json.js +5 -0
- package/toolkit/dist/theme/api/jsonp.js +5 -0
- package/toolkit/dist/theme/api-data.js +22 -0
- package/toolkit/dist/theme/api.js +27 -0
- package/toolkit/dist/theme/appearance.js +16 -0
- package/toolkit/dist/theme/assets.js +27 -0
- package/toolkit/dist/theme/authSession.js +92 -0
- package/toolkit/dist/theme/build/antdDocument.js +70 -0
- package/toolkit/dist/theme/build/next-config.js +63 -0
- package/toolkit/dist/theme/build/node.js +6 -0
- package/toolkit/dist/theme/colorMode.js +45 -0
- package/toolkit/dist/theme/commentAuthor.js +48 -0
- package/toolkit/dist/theme/content/archiveSlim.js +38 -0
- package/toolkit/dist/theme/content/articleSlim.js +35 -0
- package/toolkit/dist/theme/content/assets.js +106 -0
- package/toolkit/dist/theme/content/carouselArticles.js +39 -0
- package/toolkit/dist/theme/content/excerpt.js +42 -0
- package/toolkit/dist/theme/content/nav.js +30 -0
- package/toolkit/dist/theme/content/seo.js +12 -0
- package/toolkit/dist/theme/createAntdApp.js +175 -0
- package/toolkit/dist/theme/createApp.js +141 -0
- package/toolkit/dist/theme/createCatalogApp.js +168 -0
- package/toolkit/dist/theme/customizer.js +5 -0
- package/toolkit/dist/theme/excerpt.js +31 -0
- package/toolkit/dist/theme/extension/branding-mods.js +65 -0
- package/toolkit/dist/theme/extension/configuration/defaults.js +32 -0
- package/toolkit/dist/theme/extension/configuration/formily.js +170 -0
- package/toolkit/dist/theme/extension/configuration/index.js +28 -0
- package/toolkit/dist/theme/extension/configuration/paths.js +7 -0
- package/toolkit/dist/theme/extension/configuration/presets/twentytwentyfive.js +94 -0
- package/toolkit/dist/theme/extension/configuration/resolve.js +98 -0
- package/toolkit/dist/theme/extension/configuration/types.js +3 -0
- package/toolkit/dist/theme/extension/configuration/validate.js +21 -0
- package/toolkit/dist/theme/extension/index.js +38 -0
- package/toolkit/dist/theme/extension/manifest-normalize.js +75 -0
- package/toolkit/dist/theme/extension/presets/twentytwentyfive-appearance.js +193 -0
- package/toolkit/dist/theme/extension/preview.js +92 -0
- package/toolkit/dist/theme/extension/site-notices.js +88 -0
- package/toolkit/dist/theme/extension/site-settings.js +144 -0
- package/toolkit/dist/theme/extension/siteNav.js +17 -0
- package/toolkit/dist/theme/extension/theme-admin-locale.io.js +54 -0
- package/toolkit/dist/theme/extension/theme-admin-locale.js +68 -0
- package/toolkit/dist/theme/extension/theme.js +93 -0
- package/toolkit/dist/theme/extension/twentytwentyfive-vars.js +103 -0
- package/toolkit/dist/theme/fetch.js +241 -0
- package/toolkit/dist/theme/format.js +48 -0
- package/toolkit/dist/theme/httpClient.js +89 -0
- package/toolkit/dist/theme/index.js +226 -0
- package/toolkit/dist/theme/json.js +17 -0
- package/toolkit/dist/theme/jsonp.js +27 -0
- package/toolkit/dist/theme/locale.js +55 -0
- package/toolkit/dist/theme/nav.js +30 -0
- package/toolkit/dist/theme/next-config.js +18 -0
- package/toolkit/dist/theme/node.js +18 -0
- package/toolkit/dist/theme/preview/preview-config.js +65 -0
- package/toolkit/dist/theme/preview/preview-draft.js +51 -0
- package/toolkit/dist/theme/preview/preview-mods.js +78 -0
- package/toolkit/dist/theme/preview-config.js +65 -0
- package/toolkit/dist/theme/preview-draft.js +51 -0
- package/toolkit/dist/theme/preview-mods.js +78 -0
- package/toolkit/dist/theme/providers/index.js +251 -0
- package/toolkit/dist/theme/providers/setup.js +29 -0
- package/toolkit/dist/theme/runtime.js +19 -0
- package/toolkit/dist/theme/seo.js +12 -0
- package/toolkit/dist/theme/server.js +177 -0
- package/toolkit/dist/theme/setting.js +42 -0
- package/toolkit/dist/theme/ssr/bootstrap.js +112 -0
- package/toolkit/dist/theme/ssr/fetch.js +264 -0
- package/toolkit/dist/theme/ssr/format.js +8 -0
- package/toolkit/dist/theme/ssr/pageProps.js +155 -0
- package/toolkit/dist/theme/ssr/setting.js +45 -0
- package/toolkit/dist/theme/ssr/slimBootstrap.js +75 -0
- package/toolkit/dist/theme/ssr/static.js +17 -0
- package/toolkit/dist/theme/ssr/templates.js +50 -0
- package/toolkit/dist/theme/static.js +17 -0
- package/toolkit/dist/theme/templates.js +38 -0
- package/toolkit/dist/theme/ui-optional.js +21 -0
- package/toolkit/dist/theme/visitor/appearance.js +16 -0
- package/toolkit/dist/theme/visitor/authSession.js +92 -0
- package/toolkit/dist/theme/visitor/colorMode.js +59 -0
- package/toolkit/dist/theme/visitor/commentAuthor.js +45 -0
- package/toolkit/dist/theme/visitor/i18n.js +28 -0
- package/toolkit/dist/theme/visitor/locale.js +72 -0
- package/toolkit/dist/theme/visitor/runtime.js +19 -0
- package/toolkit/dist/theme/visitor/visitorLocale.js +56 -0
- package/toolkit/dist/theme/visitorLocale.js +39 -0
- package/toolkit/dist/types/index.js +12 -0
- package/toolkit/dist/ui/AntdStyleTransitionFix.js +16 -0
- package/toolkit/dist/ui/ArchiveEmptyState.js +8 -0
- package/toolkit/dist/ui/ArchivePageLayout.js +8 -0
- package/toolkit/dist/ui/ArticleCard.js +16 -0
- package/toolkit/dist/ui/ArticleList.js +16 -0
- package/toolkit/dist/ui/BaseGlobalStyles.js +18 -0
- package/toolkit/dist/ui/LocaleSwitcher.js +15 -0
- package/toolkit/dist/ui/NavMenu.js +8 -0
- package/toolkit/dist/ui/NotFoundPanel.js +8 -0
- package/toolkit/dist/ui/PageHeader.js +8 -0
- package/toolkit/dist/ui/SiteBranding.js +14 -0
- package/toolkit/dist/ui/SiteDocument.js +13 -0
- package/toolkit/dist/ui/SiteDocumentFallback.js +9 -0
- package/toolkit/dist/ui/SiteLogo.js +16 -0
- package/toolkit/dist/ui/SiteTagline.js +15 -0
- package/toolkit/dist/ui/TaxonomyList.js +30 -0
- package/toolkit/dist/ui/ThemeCssVars.js +85 -0
- package/toolkit/dist/ui/ThemeLayout.js +11 -0
- package/toolkit/dist/ui/components/AntdStyleTransitionFix.js +16 -0
- package/toolkit/dist/ui/components/ArchiveEmptyState.js +8 -0
- package/toolkit/dist/ui/components/ArchivePageLayout.js +8 -0
- package/toolkit/dist/ui/components/ArticleCard.js +16 -0
- package/toolkit/dist/ui/components/ArticleList.js +16 -0
- package/toolkit/dist/ui/components/BaseGlobalStyles.js +18 -0
- package/toolkit/dist/ui/components/LocaleSwitcher.js +11 -0
- package/toolkit/dist/ui/components/NavMenu.js +8 -0
- package/toolkit/dist/ui/components/NotFoundPanel.js +8 -0
- package/toolkit/dist/ui/components/PageHeader.js +8 -0
- package/toolkit/dist/ui/components/RouteProgress.js +40 -0
- package/toolkit/dist/ui/components/SiteAnalytics.js +42 -0
- package/toolkit/dist/ui/components/SiteBranding.js +14 -0
- package/toolkit/dist/ui/components/SiteDocument.js +13 -0
- package/toolkit/dist/ui/components/SiteDocumentFallback.js +9 -0
- package/toolkit/dist/ui/components/SiteLogo.js +23 -0
- package/toolkit/dist/ui/components/SiteSeo.js +19 -0
- package/toolkit/dist/ui/components/SiteTagline.js +15 -0
- package/toolkit/dist/ui/components/TaxonomyList.js +30 -0
- package/toolkit/dist/ui/components/ThemeCssVars.js +85 -0
- package/toolkit/dist/ui/components/ThemeLayout.js +11 -0
- package/toolkit/dist/ui/components/content/ArticleReader.js +23 -0
- package/toolkit/dist/ui/components/content/ArticleToc.js +75 -0
- package/toolkit/dist/ui/components/content/HtmlContent.js +237 -0
- package/toolkit/dist/ui/components/content/Image.js +13 -0
- package/toolkit/dist/ui/components/content/ImageViewer.js +33 -0
- package/toolkit/dist/ui/components/content/LocaleTime.js +63 -0
- package/toolkit/dist/ui/components/content/index.js +18 -0
- package/toolkit/dist/ui/components/toolbar/LocaleToggleButton.js +18 -0
- package/toolkit/dist/ui/components/toolbar/ThemeToggleButton.js +10 -0
- package/toolkit/dist/ui/components/toolbar/ToolbarIconButton.js +22 -0
- package/toolkit/dist/ui/components/toolbar/constants.js +8 -0
- package/toolkit/dist/ui/components/toolbar/icons.js +44 -0
- package/toolkit/dist/ui/components/toolbar/index.js +25 -0
- package/toolkit/dist/ui/components/toolbar/locale-label.js +19 -0
- package/toolkit/dist/ui/context/LocaleContext.js +59 -0
- package/toolkit/dist/ui/context/ReactPressProvider.js +10 -0
- package/toolkit/dist/ui/context/SiteCatalogContext.js +60 -0
- package/toolkit/dist/ui/context/ThemeRuntimeContext.js +59 -0
- package/toolkit/dist/ui/context/index.js +26 -0
- package/toolkit/dist/ui/context/siteCatalogTypes.js +20 -0
- package/toolkit/dist/ui/context/types.js +2 -0
- package/toolkit/dist/ui/hooks/index.js +29 -0
- package/toolkit/dist/ui/hooks/useAsyncLoading.js +31 -0
- package/toolkit/dist/ui/hooks/useForceUpdate.js +11 -0
- package/toolkit/dist/ui/hooks/useNavActive.js +11 -0
- package/toolkit/dist/ui/hooks/usePagination.js +55 -0
- package/toolkit/dist/ui/hooks/useReportArticleView.js +40 -0
- package/toolkit/dist/ui/hooks/useReportPageView.js +28 -0
- package/toolkit/dist/ui/hooks/useRouteParam.js +15 -0
- package/toolkit/dist/ui/hooks/useToggle.js +17 -0
- package/toolkit/dist/ui/hooks/useWarningOnExit.js +59 -0
- package/toolkit/dist/ui/index.js +87 -0
- package/toolkit/dist/utils/api-envelope.js +31 -0
- package/toolkit/dist/utils/clipboard.js +24 -0
- package/toolkit/dist/utils/cookie.js +15 -0
- package/toolkit/dist/utils/date.js +45 -0
- package/toolkit/dist/utils/email.js +9 -0
- package/toolkit/dist/utils/error.js +26 -0
- package/toolkit/dist/utils/image.js +34 -0
- package/toolkit/dist/utils/index.js +39 -0
- package/toolkit/dist/utils/json.js +18 -0
- package/toolkit/dist/utils/jsonp.js +27 -0
- package/toolkit/dist/utils/object.js +63 -0
- package/toolkit/dist/utils/setting.js +13 -0
- package/toolkit/dist/utils/string.js +15 -0
- package/toolkit/dist/utils/viewport.js +14 -0
- package/toolkit/package-lock.json +452 -0
- package/toolkit/package.json +108 -0
- package/dist/cli.d.ts +0 -4
- package/dist/cli.d.ts.map +0 -1
- package/dist/cli.js.map +0 -1
- package/dist/commands/config.d.ts +0 -8
- package/dist/commands/config.d.ts.map +0 -1
- package/dist/commands/config.js.map +0 -1
- package/dist/commands/init.d.ts +0 -6
- package/dist/commands/init.d.ts.map +0 -1
- package/dist/commands/init.js.map +0 -1
- package/dist/commands/restart.d.ts +0 -2
- package/dist/commands/restart.d.ts.map +0 -1
- package/dist/commands/restart.js.map +0 -1
- package/dist/commands/start.d.ts +0 -2
- package/dist/commands/start.d.ts.map +0 -1
- package/dist/commands/start.js.map +0 -1
- package/dist/commands/status.d.ts +0 -2
- package/dist/commands/status.d.ts.map +0 -1
- package/dist/commands/status.js.map +0 -1
- package/dist/commands/stop.d.ts +0 -5
- package/dist/commands/stop.d.ts.map +0 -1
- package/dist/commands/stop.js.map +0 -1
- package/dist/index.d.ts +0 -3
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/services/config.d.ts +0 -11
- package/dist/services/config.d.ts.map +0 -1
- package/dist/services/config.js.map +0 -1
- package/dist/services/database.d.ts +0 -43
- package/dist/services/database.d.ts.map +0 -1
- package/dist/services/database.js.map +0 -1
- package/dist/services/exec.d.ts +0 -22
- package/dist/services/exec.d.ts.map +0 -1
- package/dist/services/exec.js.map +0 -1
- package/dist/services/init.d.ts +0 -10
- package/dist/services/init.d.ts.map +0 -1
- package/dist/services/init.js.map +0 -1
- package/dist/services/process.d.ts +0 -9
- package/dist/services/process.d.ts.map +0 -1
- package/dist/services/process.js.map +0 -1
- package/dist/services/server-health.d.ts +0 -4
- package/dist/services/server-health.d.ts.map +0 -1
- package/dist/services/server-health.js.map +0 -1
- package/dist/services/server.d.ts +0 -19
- package/dist/services/server.d.ts.map +0 -1
- package/dist/services/server.js.map +0 -1
- package/dist/types/config.d.ts +0 -30
- package/dist/types/config.d.ts.map +0 -1
- package/dist/types/config.js.map +0 -1
- package/dist/utils/cli-context.d.ts +0 -4
- package/dist/utils/cli-context.d.ts.map +0 -1
- package/dist/utils/cli-context.js.map +0 -1
- package/dist/utils/logger.d.ts +0 -10
- package/dist/utils/logger.d.ts.map +0 -1
- package/dist/utils/logger.js.map +0 -1
- package/dist/utils/paths.d.ts +0 -17
- package/dist/utils/paths.d.ts.map +0 -1
- package/dist/utils/paths.js.map +0 -1
- package/dist/utils/platform.d.ts +0 -8
- package/dist/utils/platform.d.ts.map +0 -1
- package/dist/utils/platform.js.map +0 -1
- package/dist/utils/port.d.ts +0 -5
- package/dist/utils/port.d.ts.map +0 -1
- package/dist/utils/port.js.map +0 -1
- package/dist/utils/server-bundle.d.ts +0 -11
- package/dist/utils/server-bundle.d.ts.map +0 -1
- package/dist/utils/server-bundle.js.map +0 -1
- package/out/bin/reactpress-cli-shim.d.ts +0 -3
- package/out/bin/reactpress-cli-shim.d.ts.map +0 -1
- package/out/bin/reactpress-cli-shim.js.map +0 -1
- package/out/bin/reactpress-theme-client.d.ts +0 -3
- package/out/bin/reactpress-theme-client.d.ts.map +0 -1
- package/out/bin/reactpress-theme-client.js.map +0 -1
- package/out/bin/reactpress.d.ts +0 -3
- package/out/bin/reactpress.d.ts.map +0 -1
- package/out/bin/reactpress.js.map +0 -1
- package/out/core/services/config.d.ts +0 -12
- package/out/core/services/config.d.ts.map +0 -1
- package/out/core/services/config.js.map +0 -1
- package/out/core/services/database/index.d.ts +0 -17
- package/out/core/services/database/index.d.ts.map +0 -1
- package/out/core/services/database/index.js.map +0 -1
- package/out/core/services/database/mysql.d.ts +0 -14
- package/out/core/services/database/mysql.d.ts.map +0 -1
- package/out/core/services/database/mysql.js.map +0 -1
- package/out/core/services/database/profile.d.ts +0 -6
- package/out/core/services/database/profile.d.ts.map +0 -1
- package/out/core/services/database/profile.js.map +0 -1
- package/out/core/services/database/sqlite.d.ts +0 -10
- package/out/core/services/database/sqlite.d.ts.map +0 -1
- package/out/core/services/database/sqlite.js.map +0 -1
- package/out/core/services/exec.d.ts +0 -21
- package/out/core/services/exec.d.ts.map +0 -1
- package/out/core/services/exec.js.map +0 -1
- package/out/core/services/init.d.ts +0 -11
- package/out/core/services/init.d.ts.map +0 -1
- package/out/core/services/init.js.map +0 -1
- package/out/core/services/local-site.d.ts +0 -24
- package/out/core/services/local-site.d.ts.map +0 -1
- package/out/core/services/local-site.js.map +0 -1
- package/out/core/utils/cli-context.d.ts +0 -3
- package/out/core/utils/cli-context.d.ts.map +0 -1
- package/out/core/utils/cli-context.js.map +0 -1
- package/out/core/utils/paths.d.ts +0 -20
- package/out/core/utils/paths.d.ts.map +0 -1
- package/out/core/utils/paths.js.map +0 -1
- package/out/core/utils/platform.d.ts +0 -7
- package/out/core/utils/platform.d.ts.map +0 -1
- package/out/core/utils/platform.js.map +0 -1
- package/out/core/utils/port.d.ts +0 -4
- package/out/core/utils/port.d.ts.map +0 -1
- package/out/core/utils/port.js.map +0 -1
- package/out/lib/api-dev-runner.d.ts +0 -3
- package/out/lib/api-dev-runner.d.ts.map +0 -1
- package/out/lib/api-dev-runner.js.map +0 -1
- package/out/lib/api-dev.d.ts +0 -2
- package/out/lib/api-dev.d.ts.map +0 -1
- package/out/lib/api-dev.js.map +0 -1
- package/out/lib/bootstrap.d.ts +0 -18
- package/out/lib/bootstrap.d.ts.map +0 -1
- package/out/lib/bootstrap.js.map +0 -1
- package/out/lib/build.d.ts +0 -2
- package/out/lib/build.d.ts.map +0 -1
- package/out/lib/build.js.map +0 -1
- package/out/lib/db-backup.d.ts +0 -2
- package/out/lib/db-backup.d.ts.map +0 -1
- package/out/lib/db-backup.js.map +0 -1
- package/out/lib/dev-banner.d.ts +0 -2
- package/out/lib/dev-banner.d.ts.map +0 -1
- package/out/lib/dev-banner.js.map +0 -1
- package/out/lib/dev-child-io.d.ts +0 -2
- package/out/lib/dev-child-io.d.ts.map +0 -1
- package/out/lib/dev-child-io.js.map +0 -1
- package/out/lib/dev-log.d.ts +0 -2
- package/out/lib/dev-log.d.ts.map +0 -1
- package/out/lib/dev-log.js.map +0 -1
- package/out/lib/dev-session.d.ts +0 -2
- package/out/lib/dev-session.d.ts.map +0 -1
- package/out/lib/dev-session.js.map +0 -1
- package/out/lib/dev.d.ts +0 -2
- package/out/lib/dev.d.ts.map +0 -1
- package/out/lib/dev.js.map +0 -1
- package/out/lib/docker.d.ts +0 -2
- package/out/lib/docker.d.ts.map +0 -1
- package/out/lib/docker.js.map +0 -1
- package/out/lib/doctor.d.ts +0 -2
- package/out/lib/doctor.d.ts.map +0 -1
- package/out/lib/doctor.js.map +0 -1
- package/out/lib/health-parse.d.ts +0 -5
- package/out/lib/health-parse.d.ts.map +0 -1
- package/out/lib/health-parse.js.map +0 -1
- package/out/lib/health-parse.test.d.ts +0 -2
- package/out/lib/health-parse.test.d.ts.map +0 -1
- package/out/lib/health-parse.test.js.map +0 -1
- package/out/lib/http.d.ts +0 -2
- package/out/lib/http.d.ts.map +0 -1
- package/out/lib/http.js.map +0 -1
- package/out/lib/i18n/index.d.ts +0 -2
- package/out/lib/i18n/index.d.ts.map +0 -1
- package/out/lib/i18n/index.js.map +0 -1
- package/out/lib/i18n/strings.d.ts +0 -2
- package/out/lib/i18n/strings.d.ts.map +0 -1
- package/out/lib/i18n/strings.js.map +0 -1
- package/out/lib/lifecycle.d.ts +0 -2
- package/out/lib/lifecycle.d.ts.map +0 -1
- package/out/lib/lifecycle.js.map +0 -1
- package/out/lib/nginx.d.ts +0 -2
- package/out/lib/nginx.d.ts.map +0 -1
- package/out/lib/nginx.js.map +0 -1
- package/out/lib/paths.d.ts +0 -2
- package/out/lib/paths.d.ts.map +0 -1
- package/out/lib/paths.js.map +0 -1
- package/out/lib/plugin-build.d.ts +0 -2
- package/out/lib/plugin-build.d.ts.map +0 -1
- package/out/lib/plugin-build.js.map +0 -1
- package/out/lib/plugin-cli.d.ts +0 -2
- package/out/lib/plugin-cli.d.ts.map +0 -1
- package/out/lib/plugin-cli.js.map +0 -1
- package/out/lib/pm2.d.ts +0 -2
- package/out/lib/pm2.d.ts.map +0 -1
- package/out/lib/pm2.js.map +0 -1
- package/out/lib/ports.d.ts +0 -2
- package/out/lib/ports.d.ts.map +0 -1
- package/out/lib/ports.js.map +0 -1
- package/out/lib/process.d.ts +0 -2
- package/out/lib/process.d.ts.map +0 -1
- package/out/lib/process.js.map +0 -1
- package/out/lib/prod-memory.d.ts +0 -6
- package/out/lib/prod-memory.d.ts.map +0 -1
- package/out/lib/prod-memory.js.map +0 -1
- package/out/lib/project-type.d.ts +0 -2
- package/out/lib/project-type.d.ts.map +0 -1
- package/out/lib/project-type.js.map +0 -1
- package/out/lib/publish.d.ts +0 -3
- package/out/lib/publish.d.ts.map +0 -1
- package/out/lib/publish.js.map +0 -1
- package/out/lib/remote-dev.d.ts +0 -2
- package/out/lib/remote-dev.d.ts.map +0 -1
- package/out/lib/remote-dev.js.map +0 -1
- package/out/lib/root.d.ts +0 -2
- package/out/lib/root.d.ts.map +0 -1
- package/out/lib/root.js.map +0 -1
- package/out/lib/spawn.d.ts +0 -2
- package/out/lib/spawn.d.ts.map +0 -1
- package/out/lib/spawn.js.map +0 -1
- package/out/lib/status.d.ts +0 -2
- package/out/lib/status.d.ts.map +0 -1
- package/out/lib/status.js.map +0 -1
- package/out/lib/theme-catalog.d.ts +0 -2
- package/out/lib/theme-catalog.d.ts.map +0 -1
- package/out/lib/theme-catalog.js.map +0 -1
- package/out/lib/theme-cli.d.ts +0 -2
- package/out/lib/theme-cli.d.ts.map +0 -1
- package/out/lib/theme-cli.js.map +0 -1
- package/out/lib/theme-dev.d.ts +0 -2
- package/out/lib/theme-dev.d.ts.map +0 -1
- package/out/lib/theme-dev.js.map +0 -1
- package/out/lib/theme-env.d.ts +0 -2
- package/out/lib/theme-env.d.ts.map +0 -1
- package/out/lib/theme-env.js.map +0 -1
- package/out/lib/theme-install.d.ts +0 -2
- package/out/lib/theme-install.d.ts.map +0 -1
- package/out/lib/theme-install.js.map +0 -1
- package/out/lib/theme-lock.d.ts +0 -2
- package/out/lib/theme-lock.d.ts.map +0 -1
- package/out/lib/theme-lock.js.map +0 -1
- package/out/lib/theme-paths.d.ts +0 -2
- package/out/lib/theme-paths.d.ts.map +0 -1
- package/out/lib/theme-paths.js.map +0 -1
- package/out/lib/theme-placeholder-cover.d.ts +0 -13
- package/out/lib/theme-placeholder-cover.d.ts.map +0 -1
- package/out/lib/theme-placeholder-cover.js.map +0 -1
- package/out/lib/theme-preview-frame.d.ts +0 -2
- package/out/lib/theme-preview-frame.d.ts.map +0 -1
- package/out/lib/theme-preview-frame.js.map +0 -1
- package/out/lib/theme-preview-pool.d.ts +0 -2
- package/out/lib/theme-preview-pool.d.ts.map +0 -1
- package/out/lib/theme-preview-pool.js.map +0 -1
- package/out/lib/theme-preview-proxy.d.ts +0 -2
- package/out/lib/theme-preview-proxy.d.ts.map +0 -1
- package/out/lib/theme-preview-proxy.js.map +0 -1
- package/out/lib/theme-prod.d.ts +0 -2
- package/out/lib/theme-prod.d.ts.map +0 -1
- package/out/lib/theme-prod.js.map +0 -1
- package/out/lib/theme-registry.d.ts +0 -2
- package/out/lib/theme-registry.d.ts.map +0 -1
- package/out/lib/theme-registry.js.map +0 -1
- package/out/lib/theme-runtime.d.ts +0 -2
- package/out/lib/theme-runtime.d.ts.map +0 -1
- package/out/lib/theme-runtime.js.map +0 -1
- package/out/lib/theme-sources.d.ts +0 -2
- package/out/lib/theme-sources.d.ts.map +0 -1
- package/out/lib/theme-sources.js.map +0 -1
- package/out/lib/theme-warmup.d.ts +0 -2
- package/out/lib/theme-warmup.d.ts.map +0 -1
- package/out/lib/theme-warmup.js.map +0 -1
- package/out/lib/toolkit-build.d.ts +0 -2
- package/out/lib/toolkit-build.d.ts.map +0 -1
- package/out/lib/toolkit-build.js.map +0 -1
- package/out/types/config.d.ts +0 -57
- package/out/types/config.d.ts.map +0 -1
- package/out/types/config.js.map +0 -1
- package/out/ui/banner.d.ts +0 -2
- package/out/ui/banner.d.ts.map +0 -1
- package/out/ui/banner.js.map +0 -1
- package/out/ui/interactive.d.ts +0 -2
- package/out/ui/interactive.d.ts.map +0 -1
- package/out/ui/interactive.js.map +0 -1
- package/out/ui/prompts.d.ts +0 -2
- package/out/ui/prompts.d.ts.map +0 -1
- package/out/ui/prompts.js.map +0 -1
- package/out/ui/theme.d.ts +0 -2
- package/out/ui/theme.d.ts.map +0 -1
- package/out/ui/theme.js.map +0 -1
- package/server/dist/app.module.d.ts +0 -2
- package/server/dist/app.module.js.map +0 -1
- package/server/dist/common/api-messages.d.ts +0 -41
- package/server/dist/common/api-messages.js.map +0 -1
- package/server/dist/database/typeorm-options.d.ts +0 -3
- package/server/dist/database/typeorm-options.js.map +0 -1
- package/server/dist/filters/http-exception.filter.d.ts +0 -4
- package/server/dist/filters/http-exception.filter.js.map +0 -1
- package/server/dist/generate-swagger.d.ts +0 -1
- package/server/dist/generate-swagger.js.map +0 -1
- package/server/dist/interceptors/transform.interceptor.d.ts +0 -9
- package/server/dist/interceptors/transform.interceptor.js.map +0 -1
- package/server/dist/logger/index.d.ts +0 -4
- package/server/dist/logger/index.js.map +0 -1
- package/server/dist/main.d.ts +0 -6
- package/server/dist/main.js.map +0 -1
- package/server/dist/modules/api-key/api-key.controller.d.ts +0 -14
- package/server/dist/modules/api-key/api-key.controller.js.map +0 -1
- package/server/dist/modules/api-key/api-key.entity.d.ts +0 -11
- package/server/dist/modules/api-key/api-key.entity.js.map +0 -1
- package/server/dist/modules/api-key/api-key.guard.d.ts +0 -7
- package/server/dist/modules/api-key/api-key.guard.js.map +0 -1
- package/server/dist/modules/api-key/api-key.module.d.ts +0 -2
- package/server/dist/modules/api-key/api-key.module.js.map +0 -1
- package/server/dist/modules/api-key/api-key.service.d.ts +0 -15
- package/server/dist/modules/api-key/api-key.service.js.map +0 -1
- package/server/dist/modules/article/article-revision.entity.d.ts +0 -11
- package/server/dist/modules/article/article-revision.entity.js.map +0 -1
- package/server/dist/modules/article/article-slug.util.d.ts +0 -2
- package/server/dist/modules/article/article-slug.util.js.map +0 -1
- package/server/dist/modules/article/article.controller.d.ts +0 -27
- package/server/dist/modules/article/article.controller.js.map +0 -1
- package/server/dist/modules/article/article.entity.d.ts +0 -23
- package/server/dist/modules/article/article.entity.js.map +0 -1
- package/server/dist/modules/article/article.module.d.ts +0 -2
- package/server/dist/modules/article/article.module.js.map +0 -1
- package/server/dist/modules/article/article.service.d.ts +0 -30
- package/server/dist/modules/article/article.service.js.map +0 -1
- package/server/dist/modules/article/article.util.d.ts +0 -1
- package/server/dist/modules/article/article.util.js.map +0 -1
- package/server/dist/modules/article/scheduled-publish.service.d.ts +0 -13
- package/server/dist/modules/article/scheduled-publish.service.js.map +0 -1
- package/server/dist/modules/auth/auth.controller.d.ts +0 -12
- package/server/dist/modules/auth/auth.controller.js.map +0 -1
- package/server/dist/modules/auth/auth.module.d.ts +0 -2
- package/server/dist/modules/auth/auth.module.js.map +0 -1
- package/server/dist/modules/auth/auth.service.d.ts +0 -26
- package/server/dist/modules/auth/auth.service.js.map +0 -1
- package/server/dist/modules/auth/jwt-auth.guard.d.ts +0 -7
- package/server/dist/modules/auth/jwt-auth.guard.js.map +0 -1
- package/server/dist/modules/auth/jwt.strategy.d.ts +0 -9
- package/server/dist/modules/auth/jwt.strategy.js.map +0 -1
- package/server/dist/modules/auth/roles.guard.d.ts +0 -10
- package/server/dist/modules/auth/roles.guard.js.map +0 -1
- package/server/dist/modules/bootstrap/bootstrap.constants.d.ts +0 -20
- package/server/dist/modules/bootstrap/bootstrap.constants.js.map +0 -1
- package/server/dist/modules/bootstrap/bootstrap.service.d.ts +0 -22
- package/server/dist/modules/bootstrap/bootstrap.service.js.map +0 -1
- package/server/dist/modules/bootstrap/install-locale.d.ts +0 -2
- package/server/dist/modules/bootstrap/install-locale.js.map +0 -1
- package/server/dist/modules/category/category.controller.d.ts +0 -11
- package/server/dist/modules/category/category.controller.js.map +0 -1
- package/server/dist/modules/category/category.entity.d.ts +0 -9
- package/server/dist/modules/category/category.entity.js.map +0 -1
- package/server/dist/modules/category/category.module.d.ts +0 -2
- package/server/dist/modules/category/category.module.js.map +0 -1
- package/server/dist/modules/category/category.service.d.ts +0 -12
- package/server/dist/modules/category/category.service.js.map +0 -1
- package/server/dist/modules/comment/comment.controller.d.ts +0 -12
- package/server/dist/modules/comment/comment.controller.js.map +0 -1
- package/server/dist/modules/comment/comment.entity.d.ts +0 -17
- package/server/dist/modules/comment/comment.entity.js.map +0 -1
- package/server/dist/modules/comment/comment.module.d.ts +0 -2
- package/server/dist/modules/comment/comment.module.js.map +0 -1
- package/server/dist/modules/comment/comment.service.d.ts +0 -24
- package/server/dist/modules/comment/comment.service.js.map +0 -1
- package/server/dist/modules/comment/html.d.ts +0 -15
- package/server/dist/modules/comment/html.js.map +0 -1
- package/server/dist/modules/extension/extension.module.d.ts +0 -9
- package/server/dist/modules/extension/extension.module.js.map +0 -1
- package/server/dist/modules/extension/plugin-loader.service.d.ts +0 -12
- package/server/dist/modules/extension/plugin-loader.service.js.map +0 -1
- package/server/dist/modules/extension/plugin-registry.bridge.d.ts +0 -3
- package/server/dist/modules/extension/plugin-registry.bridge.js.map +0 -1
- package/server/dist/modules/extension/plugin.controller.d.ts +0 -22
- package/server/dist/modules/extension/plugin.controller.js.map +0 -1
- package/server/dist/modules/extension/plugin.service.d.ts +0 -52
- package/server/dist/modules/extension/plugin.service.js.map +0 -1
- package/server/dist/modules/extension/preview-draft.store.d.ts +0 -13
- package/server/dist/modules/extension/preview-draft.store.js.map +0 -1
- package/server/dist/modules/extension/theme-registry.bridge.d.ts +0 -56
- package/server/dist/modules/extension/theme-registry.bridge.js.map +0 -1
- package/server/dist/modules/extension/theme.controller.d.ts +0 -66
- package/server/dist/modules/extension/theme.controller.js.map +0 -1
- package/server/dist/modules/extension/theme.service.d.ts +0 -140
- package/server/dist/modules/extension/theme.service.js.map +0 -1
- package/server/dist/modules/file/file-optimization.controller.d.ts +0 -12
- package/server/dist/modules/file/file-optimization.controller.js.map +0 -1
- package/server/dist/modules/file/file-optimization.service.d.ts +0 -36
- package/server/dist/modules/file/file-optimization.service.js.map +0 -1
- package/server/dist/modules/file/file-optimization.types.d.ts +0 -66
- package/server/dist/modules/file/file-optimization.types.js.map +0 -1
- package/server/dist/modules/file/file.controller.d.ts +0 -10
- package/server/dist/modules/file/file.controller.js.map +0 -1
- package/server/dist/modules/file/file.entity.d.ts +0 -9
- package/server/dist/modules/file/file.entity.js.map +0 -1
- package/server/dist/modules/file/file.module.d.ts +0 -2
- package/server/dist/modules/file/file.module.js.map +0 -1
- package/server/dist/modules/file/file.service.d.ts +0 -17
- package/server/dist/modules/file/file.service.js.map +0 -1
- package/server/dist/modules/file/image-optimizer-plugin.guard.d.ts +0 -7
- package/server/dist/modules/file/image-optimizer-plugin.guard.js.map +0 -1
- package/server/dist/modules/health/health.controller.d.ts +0 -11
- package/server/dist/modules/health/health.controller.js.map +0 -1
- package/server/dist/modules/health/health.module.d.ts +0 -2
- package/server/dist/modules/health/health.module.js.map +0 -1
- package/server/dist/modules/hook/hook.module.d.ts +0 -2
- package/server/dist/modules/hook/hook.module.js.map +0 -1
- package/server/dist/modules/hook/hook.service.d.ts +0 -26
- package/server/dist/modules/hook/hook.service.js.map +0 -1
- package/server/dist/modules/install/install.controller.d.ts +0 -11
- package/server/dist/modules/install/install.controller.js.map +0 -1
- package/server/dist/modules/install/install.module.d.ts +0 -2
- package/server/dist/modules/install/install.module.js.map +0 -1
- package/server/dist/modules/install/install.service.d.ts +0 -12
- package/server/dist/modules/install/install.service.js.map +0 -1
- package/server/dist/modules/knowledge/knowledge.controller.d.ts +0 -14
- package/server/dist/modules/knowledge/knowledge.controller.js.map +0 -1
- package/server/dist/modules/knowledge/knowledge.entity.d.ts +0 -18
- package/server/dist/modules/knowledge/knowledge.entity.js.map +0 -1
- package/server/dist/modules/knowledge/knowledge.module.d.ts +0 -2
- package/server/dist/modules/knowledge/knowledge.module.js.map +0 -1
- package/server/dist/modules/knowledge/knowledge.service.d.ts +0 -14
- package/server/dist/modules/knowledge/knowledge.service.js.map +0 -1
- package/server/dist/modules/page/page.controller.d.ts +0 -12
- package/server/dist/modules/page/page.controller.js.map +0 -1
- package/server/dist/modules/page/page.entity.d.ts +0 -15
- package/server/dist/modules/page/page.entity.js.map +0 -1
- package/server/dist/modules/page/page.module.d.ts +0 -2
- package/server/dist/modules/page/page.module.js.map +0 -1
- package/server/dist/modules/page/page.service.d.ts +0 -12
- package/server/dist/modules/page/page.service.js.map +0 -1
- package/server/dist/modules/search/search.controller.d.ts +0 -8
- package/server/dist/modules/search/search.controller.js.map +0 -1
- package/server/dist/modules/search/search.entity.d.ts +0 -8
- package/server/dist/modules/search/search.entity.js.map +0 -1
- package/server/dist/modules/search/search.module.d.ts +0 -2
- package/server/dist/modules/search/search.module.js.map +0 -1
- package/server/dist/modules/search/search.service.d.ts +0 -12
- package/server/dist/modules/search/search.service.js.map +0 -1
- package/server/dist/modules/setting/setting.constant.d.ts +0 -3
- package/server/dist/modules/setting/setting.constant.js.map +0 -1
- package/server/dist/modules/setting/setting.controller.d.ts +0 -12
- package/server/dist/modules/setting/setting.controller.js.map +0 -1
- package/server/dist/modules/setting/setting.entity.d.ts +0 -26
- package/server/dist/modules/setting/setting.entity.js.map +0 -1
- package/server/dist/modules/setting/setting.module.d.ts +0 -2
- package/server/dist/modules/setting/setting.module.js.map +0 -1
- package/server/dist/modules/setting/setting.service.d.ts +0 -10
- package/server/dist/modules/setting/setting.service.js.map +0 -1
- package/server/dist/modules/smtp/mail.util.d.ts +0 -6
- package/server/dist/modules/smtp/mail.util.js.map +0 -1
- package/server/dist/modules/smtp/smtp.controller.d.ts +0 -9
- package/server/dist/modules/smtp/smtp.controller.js.map +0 -1
- package/server/dist/modules/smtp/smtp.entity.d.ts +0 -9
- package/server/dist/modules/smtp/smtp.entity.js.map +0 -1
- package/server/dist/modules/smtp/smtp.module.d.ts +0 -2
- package/server/dist/modules/smtp/smtp.module.js.map +0 -1
- package/server/dist/modules/smtp/smtp.service.d.ts +0 -11
- package/server/dist/modules/smtp/smtp.service.js.map +0 -1
- package/server/dist/modules/tag/tag.controller.d.ts +0 -12
- package/server/dist/modules/tag/tag.controller.js.map +0 -1
- package/server/dist/modules/tag/tag.entity.d.ts +0 -9
- package/server/dist/modules/tag/tag.entity.js.map +0 -1
- package/server/dist/modules/tag/tag.module.d.ts +0 -2
- package/server/dist/modules/tag/tag.module.js.map +0 -1
- package/server/dist/modules/tag/tag.service.d.ts +0 -13
- package/server/dist/modules/tag/tag.service.js.map +0 -1
- package/server/dist/modules/user/user.controller.d.ts +0 -13
- package/server/dist/modules/user/user.controller.js.map +0 -1
- package/server/dist/modules/user/user.entity.d.ts +0 -15
- package/server/dist/modules/user/user.entity.js.map +0 -1
- package/server/dist/modules/user/user.module.d.ts +0 -2
- package/server/dist/modules/user/user.module.js.map +0 -1
- package/server/dist/modules/user/user.service.d.ts +0 -16
- package/server/dist/modules/user/user.service.js.map +0 -1
- package/server/dist/modules/view/view.controller.d.ts +0 -11
- package/server/dist/modules/view/view.controller.js.map +0 -1
- package/server/dist/modules/view/view.entity.d.ts +0 -14
- package/server/dist/modules/view/view.entity.js.map +0 -1
- package/server/dist/modules/view/view.module.d.ts +0 -2
- package/server/dist/modules/view/view.module.js.map +0 -1
- package/server/dist/modules/view/view.service.d.ts +0 -11
- package/server/dist/modules/view/view.service.js.map +0 -1
- package/server/dist/modules/webhook/webhook.controller.d.ts +0 -12
- package/server/dist/modules/webhook/webhook.controller.js.map +0 -1
- package/server/dist/modules/webhook/webhook.entity.d.ts +0 -9
- package/server/dist/modules/webhook/webhook.entity.js.map +0 -1
- package/server/dist/modules/webhook/webhook.module.d.ts +0 -2
- package/server/dist/modules/webhook/webhook.module.js.map +0 -1
- package/server/dist/modules/webhook/webhook.service.d.ts +0 -16
- package/server/dist/modules/webhook/webhook.service.js.map +0 -1
- package/server/dist/node-polyfills.d.ts +0 -18
- package/server/dist/node-polyfills.js.map +0 -1
- package/server/dist/public/apple-touch-icon.png +0 -0
- package/server/dist/public/favicon-16.png +0 -0
- package/server/dist/public/favicon-32.png +0 -0
- package/server/dist/public/favicon-48.png +0 -0
- package/server/dist/public/favicon.ico +0 -0
- package/server/dist/public/favicon.png +0 -0
- package/server/dist/public/icon-192.png +0 -0
- package/server/dist/public/icon-512.png +0 -0
- package/server/dist/public/index.html +0 -439
- package/server/dist/public/logo-200.png +0 -0
- package/server/dist/public/logo-400.png +0 -0
- package/server/dist/public/logo.png +0 -0
- package/server/dist/public/logo.svg +0 -7
- package/server/dist/public/swagger/custom.css +0 -11
- package/server/dist/public/uploads/2026-05-30/QR3X4UZQ93ZTUPGXCFA9II..png +0 -0
- package/server/dist/public/uploads/2026-05-31/BXQV3NX9ZVWHGNOSX9AXD8.webp +0 -0
- package/server/dist/public/uploads/2026-05-31/BXQV3NX9ZVWHGNOSX9AXD8_medium.webp +0 -0
- package/server/dist/public/uploads/2026-05-31/BXQV3NX9ZVWHGNOSX9AXD8_thumb.webp +0 -0
- package/server/dist/public/uploads/2026-05-31/I2SZC0ONA7CF31UM46MN56..jpg +0 -0
- package/server/dist/starter.d.ts +0 -1
- package/server/dist/starter.js.map +0 -1
- package/server/dist/tsconfig.build.tsbuildinfo +0 -16764
- package/server/dist/tsconfig.tsbuildinfo +0 -1
- package/server/dist/utils/date.util.d.ts +0 -1
- package/server/dist/utils/date.util.js.map +0 -1
- package/server/dist/utils/html-sanitize.util.d.ts +0 -1
- package/server/dist/utils/html-sanitize.util.js.map +0 -1
- package/server/dist/utils/image-processor.util.d.ts +0 -23
- package/server/dist/utils/image-processor.util.js.map +0 -1
- package/server/dist/utils/ip.util.d.ts +0 -2
- package/server/dist/utils/ip.util.js.map +0 -1
- package/server/dist/utils/local-api-quiet.util.d.ts +0 -1
- package/server/dist/utils/local-api-quiet.util.js.map +0 -1
- package/server/dist/utils/markdown.util.d.ts +0 -4
- package/server/dist/utils/markdown.util.js.map +0 -1
- package/server/dist/utils/oss/aliyun-oss-client.d.ts +0 -6
- package/server/dist/utils/oss/aliyun-oss-client.js.map +0 -1
- package/server/dist/utils/oss/oss-client.d.ts +0 -6
- package/server/dist/utils/oss/oss-client.js.map +0 -1
- package/server/dist/utils/oss.util.d.ts +0 -13
- package/server/dist/utils/oss.util.js.map +0 -1
- package/server/dist/utils/project-root.util.d.ts +0 -2
- package/server/dist/utils/project-root.util.js.map +0 -1
- package/server/dist/utils/query-whitelist.util.d.ts +0 -1
- package/server/dist/utils/query-whitelist.util.js.map +0 -1
- package/server/dist/utils/ua.util.d.ts +0 -9
- package/server/dist/utils/ua.util.js.map +0 -1
- package/server/dist/utils/uniqueid.util.d.ts +0 -1
- package/server/dist/utils/uniqueid.util.js.map +0 -1
- package/server/dist/utils/upload.util.d.ts +0 -5
- package/server/dist/utils/upload.util.js.map +0 -1
- package/server/dist/utils/user.util.d.ts +0 -1
- package/server/dist/utils/user.util.js.map +0 -1
- package/server/logs/error/error.log.-2026-05-19.log +0 -135
- package/server/logs/request/request.log.-2026-05-19.log +0 -0
- package/server/logs/response/response.log.-2026-05-19.log +0 -121
- package/server/public/uploads/2026-05-30/QR3X4UZQ93ZTUPGXCFA9II..png +0 -0
- package/server/public/uploads/2026-05-31/BXQV3NX9ZVWHGNOSX9AXD8.webp +0 -0
- package/server/public/uploads/2026-05-31/BXQV3NX9ZVWHGNOSX9AXD8_medium.webp +0 -0
- package/server/public/uploads/2026-05-31/BXQV3NX9ZVWHGNOSX9AXD8_thumb.webp +0 -0
- package/server/public/uploads/2026-05-31/I2SZC0ONA7CF31UM46MN56..jpg +0 -0
|
@@ -27,7 +27,7 @@ let ViewController = class ViewController {
|
|
|
27
27
|
create(req, data) {
|
|
28
28
|
const userAgent = req.headers['user-agent'];
|
|
29
29
|
const url = data.url;
|
|
30
|
-
return this.viewService.create(ip_util_1.getClientIP(req), userAgent, url);
|
|
30
|
+
return this.viewService.create((0, ip_util_1.getClientIP)(req), userAgent, url);
|
|
31
31
|
}
|
|
32
32
|
findAll(queryParam) {
|
|
33
33
|
return this.viewService.findAll(queryParam);
|
|
@@ -43,49 +43,50 @@ let ViewController = class ViewController {
|
|
|
43
43
|
}
|
|
44
44
|
};
|
|
45
45
|
__decorate([
|
|
46
|
-
swagger_1.ApiResponse({ status: 200, description: '访问记录添加成功', type: [view_entity_1.View] }),
|
|
47
|
-
common_1.Post(),
|
|
48
|
-
__param(0,
|
|
46
|
+
(0, swagger_1.ApiResponse)({ status: 200, description: '访问记录添加成功', type: [view_entity_1.View] }),
|
|
47
|
+
(0, common_1.Post)(),
|
|
48
|
+
__param(0, (0, common_1.Request)()),
|
|
49
|
+
__param(1, (0, common_1.Body)()),
|
|
49
50
|
__metadata("design:type", Function),
|
|
50
51
|
__metadata("design:paramtypes", [Object, Object]),
|
|
51
52
|
__metadata("design:returntype", void 0)
|
|
52
53
|
], ViewController.prototype, "create", null);
|
|
53
54
|
__decorate([
|
|
54
|
-
common_1.Get(),
|
|
55
|
-
common_1.UseGuards(jwt_auth_guard_1.JwtAuthGuard),
|
|
56
|
-
__param(0, common_1.Query()),
|
|
55
|
+
(0, common_1.Get)(),
|
|
56
|
+
(0, common_1.UseGuards)(jwt_auth_guard_1.JwtAuthGuard),
|
|
57
|
+
__param(0, (0, common_1.Query)()),
|
|
57
58
|
__metadata("design:type", Function),
|
|
58
59
|
__metadata("design:paramtypes", [Object]),
|
|
59
60
|
__metadata("design:returntype", void 0)
|
|
60
61
|
], ViewController.prototype, "findAll", null);
|
|
61
62
|
__decorate([
|
|
62
|
-
common_1.Get('/url'),
|
|
63
|
-
__param(0, common_1.Query('url')),
|
|
63
|
+
(0, common_1.Get)('/url'),
|
|
64
|
+
__param(0, (0, common_1.Query)('url')),
|
|
64
65
|
__metadata("design:type", Function),
|
|
65
66
|
__metadata("design:paramtypes", [Object]),
|
|
66
67
|
__metadata("design:returntype", void 0)
|
|
67
68
|
], ViewController.prototype, "findByUrl", null);
|
|
68
69
|
__decorate([
|
|
69
|
-
common_1.Get(':id'),
|
|
70
|
-
common_1.UseGuards(jwt_auth_guard_1.JwtAuthGuard),
|
|
71
|
-
__param(0, common_1.Param('id')),
|
|
70
|
+
(0, common_1.Get)(':id'),
|
|
71
|
+
(0, common_1.UseGuards)(jwt_auth_guard_1.JwtAuthGuard),
|
|
72
|
+
__param(0, (0, common_1.Param)('id')),
|
|
72
73
|
__metadata("design:type", Function),
|
|
73
74
|
__metadata("design:paramtypes", [Object]),
|
|
74
75
|
__metadata("design:returntype", void 0)
|
|
75
76
|
], ViewController.prototype, "findById", null);
|
|
76
77
|
__decorate([
|
|
77
|
-
common_1.Delete(':id'),
|
|
78
|
-
roles_guard_1.Roles('admin'),
|
|
79
|
-
common_1.UseGuards(jwt_auth_guard_1.JwtAuthGuard),
|
|
80
|
-
__param(0, common_1.Param('id')),
|
|
78
|
+
(0, common_1.Delete)(':id'),
|
|
79
|
+
(0, roles_guard_1.Roles)('admin'),
|
|
80
|
+
(0, common_1.UseGuards)(jwt_auth_guard_1.JwtAuthGuard),
|
|
81
|
+
__param(0, (0, common_1.Param)('id')),
|
|
81
82
|
__metadata("design:type", Function),
|
|
82
83
|
__metadata("design:paramtypes", [Object]),
|
|
83
84
|
__metadata("design:returntype", void 0)
|
|
84
85
|
], ViewController.prototype, "deleteById", null);
|
|
85
86
|
ViewController = __decorate([
|
|
86
|
-
swagger_1.ApiTags('View'),
|
|
87
|
-
common_1.Controller('view'),
|
|
88
|
-
common_1.UseGuards(roles_guard_1.RolesGuard),
|
|
87
|
+
(0, swagger_1.ApiTags)('View'),
|
|
88
|
+
(0, common_1.Controller)('view'),
|
|
89
|
+
(0, common_1.UseGuards)(roles_guard_1.RolesGuard),
|
|
89
90
|
__metadata("design:paramtypes", [view_service_1.ViewService])
|
|
90
91
|
], ViewController);
|
|
91
92
|
exports.ViewController = ViewController;
|
|
@@ -15,57 +15,57 @@ const typeorm_1 = require("typeorm");
|
|
|
15
15
|
let View = class View {
|
|
16
16
|
};
|
|
17
17
|
__decorate([
|
|
18
|
-
typeorm_1.PrimaryGeneratedColumn('uuid'),
|
|
18
|
+
(0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
|
|
19
19
|
__metadata("design:type", String)
|
|
20
20
|
], View.prototype, "id", void 0);
|
|
21
21
|
__decorate([
|
|
22
|
-
swagger_1.ApiProperty(),
|
|
23
|
-
typeorm_1.Column(),
|
|
22
|
+
(0, swagger_1.ApiProperty)(),
|
|
23
|
+
(0, typeorm_1.Column)(),
|
|
24
24
|
__metadata("design:type", String)
|
|
25
25
|
], View.prototype, "ip", void 0);
|
|
26
26
|
__decorate([
|
|
27
|
-
swagger_1.ApiProperty(),
|
|
28
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
27
|
+
(0, swagger_1.ApiProperty)(),
|
|
28
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
29
29
|
__metadata("design:type", String)
|
|
30
30
|
], View.prototype, "userAgent", void 0);
|
|
31
31
|
__decorate([
|
|
32
|
-
swagger_1.ApiProperty(),
|
|
33
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
32
|
+
(0, swagger_1.ApiProperty)(),
|
|
33
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
34
34
|
__metadata("design:type", String)
|
|
35
35
|
], View.prototype, "url", void 0);
|
|
36
36
|
__decorate([
|
|
37
|
-
swagger_1.ApiProperty(),
|
|
38
|
-
typeorm_1.Column({ default: 1 }),
|
|
37
|
+
(0, swagger_1.ApiProperty)(),
|
|
38
|
+
(0, typeorm_1.Column)({ default: 1 }),
|
|
39
39
|
__metadata("design:type", Number)
|
|
40
40
|
], View.prototype, "count", void 0);
|
|
41
41
|
__decorate([
|
|
42
|
-
swagger_1.ApiProperty(),
|
|
43
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
42
|
+
(0, swagger_1.ApiProperty)(),
|
|
43
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
44
44
|
__metadata("design:type", String)
|
|
45
45
|
], View.prototype, "address", void 0);
|
|
46
46
|
__decorate([
|
|
47
|
-
swagger_1.ApiProperty(),
|
|
48
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
47
|
+
(0, swagger_1.ApiProperty)(),
|
|
48
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
49
49
|
__metadata("design:type", String)
|
|
50
50
|
], View.prototype, "browser", void 0);
|
|
51
51
|
__decorate([
|
|
52
|
-
swagger_1.ApiProperty(),
|
|
53
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
52
|
+
(0, swagger_1.ApiProperty)(),
|
|
53
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
54
54
|
__metadata("design:type", String)
|
|
55
55
|
], View.prototype, "engine", void 0);
|
|
56
56
|
__decorate([
|
|
57
|
-
swagger_1.ApiProperty(),
|
|
58
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
57
|
+
(0, swagger_1.ApiProperty)(),
|
|
58
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
59
59
|
__metadata("design:type", String)
|
|
60
60
|
], View.prototype, "os", void 0);
|
|
61
61
|
__decorate([
|
|
62
|
-
swagger_1.ApiProperty(),
|
|
63
|
-
typeorm_1.Column({ type: 'text', default: null }),
|
|
62
|
+
(0, swagger_1.ApiProperty)(),
|
|
63
|
+
(0, typeorm_1.Column)({ type: 'text', default: null }),
|
|
64
64
|
__metadata("design:type", String)
|
|
65
65
|
], View.prototype, "device", void 0);
|
|
66
66
|
__decorate([
|
|
67
|
-
swagger_1.ApiProperty(),
|
|
68
|
-
typeorm_1.CreateDateColumn({
|
|
67
|
+
(0, swagger_1.ApiProperty)(),
|
|
68
|
+
(0, typeorm_1.CreateDateColumn)({
|
|
69
69
|
type: 'datetime',
|
|
70
70
|
comment: '创建时间',
|
|
71
71
|
name: 'create_at',
|
|
@@ -73,8 +73,8 @@ __decorate([
|
|
|
73
73
|
__metadata("design:type", Date)
|
|
74
74
|
], View.prototype, "createAt", void 0);
|
|
75
75
|
__decorate([
|
|
76
|
-
swagger_1.ApiProperty(),
|
|
77
|
-
typeorm_1.UpdateDateColumn({
|
|
76
|
+
(0, swagger_1.ApiProperty)(),
|
|
77
|
+
(0, typeorm_1.UpdateDateColumn)({
|
|
78
78
|
type: 'datetime',
|
|
79
79
|
comment: '更新时间',
|
|
80
80
|
name: 'update_at',
|
|
@@ -82,7 +82,7 @@ __decorate([
|
|
|
82
82
|
__metadata("design:type", Date)
|
|
83
83
|
], View.prototype, "updateAt", void 0);
|
|
84
84
|
View = __decorate([
|
|
85
|
-
typeorm_1.Entity()
|
|
85
|
+
(0, typeorm_1.Entity)()
|
|
86
86
|
], View);
|
|
87
87
|
exports.View = View;
|
|
88
88
|
//# sourceMappingURL=view.entity.js.map
|
|
@@ -16,7 +16,7 @@ const view_service_1 = require("./view.service");
|
|
|
16
16
|
let ViewModule = class ViewModule {
|
|
17
17
|
};
|
|
18
18
|
ViewModule = __decorate([
|
|
19
|
-
common_1.Module({
|
|
19
|
+
(0, common_1.Module)({
|
|
20
20
|
imports: [typeorm_1.TypeOrmModule.forFeature([view_entity_1.View]), auth_module_1.AuthModule],
|
|
21
21
|
exports: [view_service_1.ViewService],
|
|
22
22
|
providers: [view_service_1.ViewService],
|
|
@@ -46,8 +46,8 @@ let ViewService = class ViewService {
|
|
|
46
46
|
await this.viewRepository.save(newData);
|
|
47
47
|
return newData;
|
|
48
48
|
}
|
|
49
|
-
const { data: uaInfo } = ua_util_1.parseUserAgent(userAgent);
|
|
50
|
-
const address = ip_util_1.parseIp(ip);
|
|
49
|
+
const { data: uaInfo } = (0, ua_util_1.parseUserAgent)(userAgent);
|
|
50
|
+
const address = (0, ip_util_1.parseIp)(ip);
|
|
51
51
|
const newData = await this.viewRepository.create(Object.assign({ ip, userAgent, url, address }, uaInfo));
|
|
52
52
|
await this.viewRepository.save(newData);
|
|
53
53
|
return newData;
|
|
@@ -81,8 +81,8 @@ let ViewService = class ViewService {
|
|
|
81
81
|
}
|
|
82
82
|
};
|
|
83
83
|
ViewService = __decorate([
|
|
84
|
-
common_1.Injectable(),
|
|
85
|
-
__param(0, typeorm_1.InjectRepository(view_entity_1.View)),
|
|
84
|
+
(0, common_1.Injectable)(),
|
|
85
|
+
__param(0, (0, typeorm_1.InjectRepository)(view_entity_1.View)),
|
|
86
86
|
__metadata("design:paramtypes", [typeorm_2.Repository])
|
|
87
87
|
], ViewService);
|
|
88
88
|
exports.ViewService = ViewService;
|
package/server/dist/starter.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.bootstrap = void 0;
|
|
4
|
+
require("./node-polyfills");
|
|
4
5
|
const core_1 = require("@nestjs/core");
|
|
5
6
|
const swagger_1 = require("@nestjs/swagger");
|
|
6
7
|
const bodyParser = require("body-parser");
|
|
@@ -8,25 +9,176 @@ const compression = require("compression");
|
|
|
8
9
|
const express = require("express");
|
|
9
10
|
const rateLimit = require("express-rate-limit");
|
|
10
11
|
const helmet = require("helmet");
|
|
12
|
+
const http = require("http");
|
|
13
|
+
const net = require("net");
|
|
14
|
+
const fs_1 = require("fs");
|
|
11
15
|
const path_1 = require("path");
|
|
12
16
|
const swagger_themes_1 = require("swagger-themes");
|
|
13
17
|
const app_module_1 = require("./app.module");
|
|
18
|
+
const api_messages_1 = require("./common/api-messages");
|
|
14
19
|
const http_exception_filter_1 = require("./filters/http-exception.filter");
|
|
15
20
|
const transform_interceptor_1 = require("./interceptors/transform.interceptor");
|
|
21
|
+
const project_root_util_1 = require("./utils/project-root.util");
|
|
22
|
+
const local_api_quiet_util_1 = require("./utils/local-api-quiet.util");
|
|
23
|
+
let nestApp = null;
|
|
24
|
+
function isPortOpen(port) {
|
|
25
|
+
return new Promise((resolve) => {
|
|
26
|
+
const socket = net.createConnection({ port, host: '127.0.0.1' }, () => {
|
|
27
|
+
socket.destroy();
|
|
28
|
+
resolve(true);
|
|
29
|
+
});
|
|
30
|
+
socket.on('error', () => resolve(false));
|
|
31
|
+
socket.setTimeout(800, () => {
|
|
32
|
+
socket.destroy();
|
|
33
|
+
resolve(false);
|
|
34
|
+
});
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
function normalizeHealthPayload(raw) {
|
|
38
|
+
if (!raw || typeof raw !== 'object')
|
|
39
|
+
return null;
|
|
40
|
+
const body = raw;
|
|
41
|
+
const nested = body.data;
|
|
42
|
+
if (nested && typeof nested === 'object' && ('status' in nested || 'database' in nested)) {
|
|
43
|
+
return nested;
|
|
44
|
+
}
|
|
45
|
+
return body;
|
|
46
|
+
}
|
|
47
|
+
function isHealthPayloadReady(payload) {
|
|
48
|
+
if (!payload)
|
|
49
|
+
return false;
|
|
50
|
+
if (Object.prototype.hasOwnProperty.call(payload, 'database')) {
|
|
51
|
+
return payload.status === 'ok' && payload.database === 'up';
|
|
52
|
+
}
|
|
53
|
+
return payload.status === 'ok' || payload.status === 'OK';
|
|
54
|
+
}
|
|
55
|
+
function probeApiHealth(port, prefix = '/api') {
|
|
56
|
+
return new Promise((resolve) => {
|
|
57
|
+
const req = http.request({
|
|
58
|
+
hostname: '127.0.0.1',
|
|
59
|
+
port,
|
|
60
|
+
path: `${prefix.replace(/\/$/, '')}/health`,
|
|
61
|
+
method: 'GET',
|
|
62
|
+
timeout: 2000,
|
|
63
|
+
}, (res) => {
|
|
64
|
+
let body = '';
|
|
65
|
+
res.on('data', (c) => {
|
|
66
|
+
body += c;
|
|
67
|
+
});
|
|
68
|
+
res.on('end', () => {
|
|
69
|
+
if (res.statusCode !== 200) {
|
|
70
|
+
resolve(false);
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
try {
|
|
74
|
+
const payload = normalizeHealthPayload(JSON.parse(body));
|
|
75
|
+
resolve(isHealthPayloadReady(payload));
|
|
76
|
+
}
|
|
77
|
+
catch (_a) {
|
|
78
|
+
resolve(false);
|
|
79
|
+
}
|
|
80
|
+
});
|
|
81
|
+
});
|
|
82
|
+
req.on('error', () => resolve(false));
|
|
83
|
+
req.on('timeout', () => {
|
|
84
|
+
req.destroy();
|
|
85
|
+
resolve(false);
|
|
86
|
+
});
|
|
87
|
+
req.end();
|
|
88
|
+
});
|
|
89
|
+
}
|
|
16
90
|
async function bootstrap() {
|
|
91
|
+
var _a;
|
|
92
|
+
(0, project_root_util_1.resolveProjectRoot)();
|
|
93
|
+
const configuredPort = Number(process.env.SERVER_PORT || 3002);
|
|
94
|
+
const apiPrefix = String(process.env.SERVER_API_PREFIX || '/api');
|
|
95
|
+
if (process.env.REACTPRESS_API_ENTRY === 'starter' &&
|
|
96
|
+
(await isPortOpen(configuredPort)) &&
|
|
97
|
+
(await probeApiHealth(configuredPort, apiPrefix))) {
|
|
98
|
+
console.log(`[ReactPress] API already healthy on :${configuredPort} (nest watch reload — skip bootstrap)`);
|
|
99
|
+
return null;
|
|
100
|
+
}
|
|
17
101
|
try {
|
|
18
|
-
|
|
102
|
+
if (nestApp) {
|
|
103
|
+
await nestApp.close();
|
|
104
|
+
nestApp = null;
|
|
105
|
+
}
|
|
106
|
+
const app = await core_1.NestFactory.create(app_module_1.AppModule, {
|
|
107
|
+
logger: (0, local_api_quiet_util_1.isLocalApiQuiet)() ? ['error', 'warn'] : undefined,
|
|
108
|
+
});
|
|
19
109
|
const configService = app.get('ConfigService');
|
|
110
|
+
const listenPort = Number(configService.get('SERVER_PORT', configuredPort));
|
|
111
|
+
app.use((req, res, next) => {
|
|
112
|
+
const { shouldRedirectDevPortToNginx, buildDevPortRedirectUrl } = require('@fecommunity/reactpress-toolkit/plugin/dev');
|
|
113
|
+
if (!shouldRedirectDevPortToNginx({
|
|
114
|
+
host: req.headers.host,
|
|
115
|
+
method: req.method,
|
|
116
|
+
accept: req.headers.accept,
|
|
117
|
+
directPort: listenPort,
|
|
118
|
+
pathname: req.path,
|
|
119
|
+
skipPathPrefixes: ['/public'],
|
|
120
|
+
})) {
|
|
121
|
+
next();
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
res.redirect(302, buildDevPortRedirectUrl({
|
|
125
|
+
directPort: listenPort,
|
|
126
|
+
pathname: req.path,
|
|
127
|
+
search: req.url.includes('?') ? req.url.slice(req.url.indexOf('?')) : '',
|
|
128
|
+
}));
|
|
129
|
+
});
|
|
20
130
|
app.enableCors();
|
|
21
|
-
|
|
131
|
+
const apiPrefix = String(configService.get('SERVER_API_PREFIX', '/api')).replace(/\/$/, '');
|
|
132
|
+
app.setGlobalPrefix(apiPrefix);
|
|
22
133
|
app.use(rateLimit({
|
|
23
134
|
windowMs: 60 * 1000,
|
|
24
135
|
max: 10000,
|
|
25
136
|
}));
|
|
26
|
-
|
|
137
|
+
app.use(`${apiPrefix}/auth/login`, rateLimit({
|
|
138
|
+
windowMs: 15 * 60 * 1000,
|
|
139
|
+
max: 5,
|
|
140
|
+
skipSuccessfulRequests: true,
|
|
141
|
+
standardHeaders: true,
|
|
142
|
+
legacyHeaders: false,
|
|
143
|
+
handler(_req, res) {
|
|
144
|
+
res.status(429).json({
|
|
145
|
+
statusCode: 429,
|
|
146
|
+
msg: api_messages_1.ApiMsg.TOO_MANY_LOGIN_ATTEMPTS,
|
|
147
|
+
success: false,
|
|
148
|
+
data: null,
|
|
149
|
+
});
|
|
150
|
+
},
|
|
151
|
+
}));
|
|
152
|
+
const rootDir = (0, path_1.join)(__dirname, '../public');
|
|
153
|
+
const uploadDir = (_a = process.env.REACTPRESS_UPLOAD_DIR) === null || _a === void 0 ? void 0 : _a.trim();
|
|
154
|
+
if (uploadDir && (0, fs_1.existsSync)(uploadDir)) {
|
|
155
|
+
app.use('/public/uploads', express.static(uploadDir));
|
|
156
|
+
}
|
|
27
157
|
app.use('/public', express.static(rootDir));
|
|
158
|
+
for (const name of ['logo.png', 'favicon.png', 'favicon.ico']) {
|
|
159
|
+
const filePath = (0, path_1.join)(rootDir, name);
|
|
160
|
+
if ((0, fs_1.existsSync)(filePath)) {
|
|
161
|
+
app.use(`/${name}`, (_req, res) => {
|
|
162
|
+
res.sendFile(filePath);
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
}
|
|
28
166
|
app.use(compression());
|
|
29
|
-
app.use(helmet(
|
|
167
|
+
app.use(helmet({
|
|
168
|
+
contentSecurityPolicy: {
|
|
169
|
+
directives: {
|
|
170
|
+
defaultSrc: ["'self'"],
|
|
171
|
+
scriptSrc: ["'self'", "'unsafe-inline'"],
|
|
172
|
+
styleSrc: ["'self'", "'unsafe-inline'"],
|
|
173
|
+
imgSrc: ["'self'", 'data:', 'blob:'],
|
|
174
|
+
connectSrc: ["'self'"],
|
|
175
|
+
fontSrc: ["'self'"],
|
|
176
|
+
objectSrc: ["'none'"],
|
|
177
|
+
mediaSrc: ["'self'"],
|
|
178
|
+
frameSrc: ["'none'"],
|
|
179
|
+
},
|
|
180
|
+
},
|
|
181
|
+
}));
|
|
30
182
|
app.useGlobalInterceptors(new transform_interceptor_1.TransformInterceptor());
|
|
31
183
|
app.useGlobalFilters(new http_exception_filter_1.HttpExceptionFilter());
|
|
32
184
|
app.use(bodyParser.json({ limit: '10mb' }));
|
|
@@ -34,7 +186,7 @@ async function bootstrap() {
|
|
|
34
186
|
const swaggerConfig = new swagger_1.DocumentBuilder()
|
|
35
187
|
.setTitle('ReactPress API Documentation')
|
|
36
188
|
.setDescription('Comprehensive API documentation for ReactPress - A modern content management system built with NestJS')
|
|
37
|
-
.setVersion('
|
|
189
|
+
.setVersion('3.0')
|
|
38
190
|
.setContact('ReactPress Team', 'https://github.com/fecommunity/reactpress', 'admin@gaoredu.com')
|
|
39
191
|
.setLicense('MIT', 'https://github.com/fecommunity/reactpress/blob/main/LICENSE')
|
|
40
192
|
.addServer(configService.get('SERVER_SITE_URL', 'http://localhost:3002'), 'API Server')
|
|
@@ -44,7 +196,7 @@ async function bootstrap() {
|
|
|
44
196
|
const options = {
|
|
45
197
|
customCss: theme.getBuffer(swagger_themes_1.SwaggerThemeNameEnum.MATERIAL),
|
|
46
198
|
customSiteTitle: 'ReactPress API Documentation',
|
|
47
|
-
customfavIcon: '/public/favicon.
|
|
199
|
+
customfavIcon: '/public/favicon.ico',
|
|
48
200
|
swaggerOptions: {
|
|
49
201
|
docExpansion: 'list',
|
|
50
202
|
filter: true,
|
|
@@ -57,15 +209,35 @@ async function bootstrap() {
|
|
|
57
209
|
customCssUrl: '/public/swagger/custom.css',
|
|
58
210
|
};
|
|
59
211
|
swagger_1.SwaggerModule.setup('api', app, document, options);
|
|
60
|
-
const
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
212
|
+
const listenPrefix = String(configService.get('SERVER_API_PREFIX', apiPrefix));
|
|
213
|
+
if (process.env.REACTPRESS_API_ENTRY === 'starter' &&
|
|
214
|
+
(await isPortOpen(listenPort)) &&
|
|
215
|
+
(await probeApiHealth(listenPort, listenPrefix))) {
|
|
216
|
+
console.log(`[ReactPress] API already healthy on :${listenPort} (nest watch reload — skip duplicate listen)`);
|
|
217
|
+
await app.close();
|
|
218
|
+
return null;
|
|
219
|
+
}
|
|
220
|
+
await app.listen(listenPort);
|
|
221
|
+
nestApp = app;
|
|
222
|
+
if ((0, local_api_quiet_util_1.isLocalApiQuiet)()) {
|
|
223
|
+
const dbType = String(configService.get('DB_TYPE') || 'mysql').toLowerCase();
|
|
224
|
+
console.log(`[ReactPress] Local API ready · ${dbType === 'sqlite' ? 'SQLite' : dbType} · http://127.0.0.1:${listenPort}${listenPrefix}/health`);
|
|
225
|
+
}
|
|
226
|
+
else {
|
|
227
|
+
console.log(`[ReactPress] Application started on http://localhost:${listenPort}`);
|
|
228
|
+
console.log(`[ReactPress] API Documentation available at http://localhost:${listenPort}/api`);
|
|
229
|
+
}
|
|
64
230
|
return app;
|
|
65
231
|
}
|
|
66
232
|
catch (error) {
|
|
67
233
|
console.error('[ReactPress] Failed to start application:', error);
|
|
68
234
|
if (error.code === 'EADDRINUSE') {
|
|
235
|
+
const port = Number(process.env.SERVER_PORT || 3002);
|
|
236
|
+
const prefix = process.env.SERVER_API_PREFIX || '/api';
|
|
237
|
+
if (process.env.REACTPRESS_API_ENTRY === 'starter' && (await probeApiHealth(port, prefix))) {
|
|
238
|
+
console.log(`[ReactPress] Port :${port} in use but API healthy — treating watch reload as success`);
|
|
239
|
+
return null;
|
|
240
|
+
}
|
|
69
241
|
console.error('[ReactPress] Port is already in use. Please check for other running instances.');
|
|
70
242
|
console.error('[ReactPress] You can change the port in your .env file or terminate the conflicting process.');
|
|
71
243
|
}
|
|
@@ -73,12 +245,28 @@ async function bootstrap() {
|
|
|
73
245
|
}
|
|
74
246
|
}
|
|
75
247
|
exports.bootstrap = bootstrap;
|
|
76
|
-
|
|
77
|
-
console.log(
|
|
248
|
+
async function shutdownNest(signal) {
|
|
249
|
+
console.log(`\n[ReactPress] Received ${signal}, shutting down…`);
|
|
250
|
+
if (nestApp) {
|
|
251
|
+
try {
|
|
252
|
+
await nestApp.close();
|
|
253
|
+
}
|
|
254
|
+
catch (_a) {
|
|
255
|
+
}
|
|
256
|
+
nestApp = null;
|
|
257
|
+
}
|
|
78
258
|
process.exit(0);
|
|
259
|
+
}
|
|
260
|
+
process.on('SIGINT', () => {
|
|
261
|
+
void shutdownNest('SIGINT');
|
|
79
262
|
});
|
|
80
263
|
process.on('SIGTERM', () => {
|
|
81
|
-
|
|
82
|
-
process.exit(0);
|
|
264
|
+
void shutdownNest('SIGTERM');
|
|
83
265
|
});
|
|
266
|
+
if (require.main === module) {
|
|
267
|
+
bootstrap().catch((err) => {
|
|
268
|
+
console.error('[ReactPress] Failed to start:', err);
|
|
269
|
+
process.exit(1);
|
|
270
|
+
});
|
|
271
|
+
}
|
|
84
272
|
//# sourceMappingURL=starter.js.map
|
|
@@ -7,7 +7,7 @@ const dateFormat = (date = null, format = 'yyyy-MM-dd HH:mm:ss') => {
|
|
|
7
7
|
date = new Date();
|
|
8
8
|
}
|
|
9
9
|
const t = date instanceof Date ? date : new Date(date);
|
|
10
|
-
return date_fns_1.format(t, format);
|
|
10
|
+
return (0, date_fns_1.format)(t, format);
|
|
11
11
|
};
|
|
12
12
|
exports.dateFormat = dateFormat;
|
|
13
13
|
//# sourceMappingURL=date.util.js.map
|
|
@@ -27,7 +27,7 @@ const marked = (content) => {
|
|
|
27
27
|
const toc = [];
|
|
28
28
|
renderer.heading = (text, level) => {
|
|
29
29
|
const anchor = 'heading-' + toc.length;
|
|
30
|
-
toc.push(
|
|
30
|
+
toc.push({ level, id: anchor, text });
|
|
31
31
|
return `<h${level} id="${anchor}">${text}</h${level}>`;
|
|
32
32
|
};
|
|
33
33
|
const marked = (text) => {
|
|
@@ -19,6 +19,11 @@ class AliyunOssClient extends oss_client_1.OssClient {
|
|
|
19
19
|
const { url } = await client.put(filepath, buffer);
|
|
20
20
|
return url;
|
|
21
21
|
}
|
|
22
|
+
async getFile(filepath) {
|
|
23
|
+
const client = await this.buildClient();
|
|
24
|
+
const result = await client.get(filepath);
|
|
25
|
+
return result.content;
|
|
26
|
+
}
|
|
22
27
|
async deleteFile(url) {
|
|
23
28
|
const client = await this.buildClient();
|
|
24
29
|
await client.delete(url);
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Oss = void 0;
|
|
4
4
|
const common_1 = require("@nestjs/common");
|
|
5
|
+
const api_messages_1 = require("../common/api-messages");
|
|
5
6
|
const aliyun_oss_client_1 = require("./oss/aliyun-oss-client");
|
|
6
7
|
class Oss {
|
|
7
8
|
constructor(settingService) {
|
|
@@ -21,7 +22,7 @@ class Oss {
|
|
|
21
22
|
const data = await this.settingService.findAll(true);
|
|
22
23
|
const config = JSON.parse(data.oss);
|
|
23
24
|
if (!config) {
|
|
24
|
-
throw new common_1.HttpException(
|
|
25
|
+
throw new common_1.HttpException(api_messages_1.ApiMsg.OSS_CONFIG_INCOMPLETE, common_1.HttpStatus.BAD_REQUEST);
|
|
25
26
|
}
|
|
26
27
|
return config;
|
|
27
28
|
}
|
|
@@ -39,6 +40,10 @@ class Oss {
|
|
|
39
40
|
const url = await client.putFile(filepath, buffer);
|
|
40
41
|
return url;
|
|
41
42
|
}
|
|
43
|
+
async getFile(filepath) {
|
|
44
|
+
const client = await this.getOssClient();
|
|
45
|
+
return client.getFile(filepath);
|
|
46
|
+
}
|
|
42
47
|
async deleteFile(url) {
|
|
43
48
|
const client = await this.getOssClient();
|
|
44
49
|
await client.deleteFile(url);
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.buildThemePlaceholderCoverSvg = void 0;
|
|
4
|
+
function escapeXml(text) {
|
|
5
|
+
return String(text).replace(/[<>&"']/g, (ch) => {
|
|
6
|
+
var _a;
|
|
7
|
+
const map = {
|
|
8
|
+
'<': '<',
|
|
9
|
+
'>': '>',
|
|
10
|
+
'&': '&',
|
|
11
|
+
'"': '"',
|
|
12
|
+
"'": ''',
|
|
13
|
+
};
|
|
14
|
+
return (_a = map[ch]) !== null && _a !== void 0 ? _a : ch;
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
function sanitizeColor(color, fallback) {
|
|
18
|
+
if (!color)
|
|
19
|
+
return fallback;
|
|
20
|
+
const trimmed = String(color).trim();
|
|
21
|
+
if (/^#[0-9a-fA-F]{3,8}$/.test(trimmed))
|
|
22
|
+
return trimmed;
|
|
23
|
+
return fallback;
|
|
24
|
+
}
|
|
25
|
+
function safeSvgId(id) {
|
|
26
|
+
return String(id).replace(/[^a-zA-Z0-9_-]/g, '') || 'theme';
|
|
27
|
+
}
|
|
28
|
+
function buildThemePlaceholderCoverSvg(options) {
|
|
29
|
+
var _a, _b;
|
|
30
|
+
const svgId = safeSvgId(options.id);
|
|
31
|
+
const primary = sanitizeColor(options.primary, '#2563eb');
|
|
32
|
+
const accent = sanitizeColor(options.accent, '#7c3aed');
|
|
33
|
+
const rawName = String((_b = (_a = options.name) !== null && _a !== void 0 ? _a : options.id) !== null && _b !== void 0 ? _b : 'Theme');
|
|
34
|
+
const safeName = escapeXml(rawName.length > 48 ? `${rawName.slice(0, 45)}…` : rawName);
|
|
35
|
+
const version = options.version ? escapeXml(String(options.version)) : '';
|
|
36
|
+
const versionBadge = version
|
|
37
|
+
? `<rect x="656" y="28" width="112" height="26" rx="13" fill="#ffffff" fill-opacity="0.08"/>
|
|
38
|
+
<text x="712" y="45" text-anchor="middle" fill="#ffffff" fill-opacity="0.65" font-family="system-ui,-apple-system,sans-serif" font-size="11" font-weight="500">v${version}</text>`
|
|
39
|
+
: '';
|
|
40
|
+
return `<svg xmlns="http://www.w3.org/2000/svg" width="800" height="500" viewBox="0 0 800 500" role="img" aria-label="${safeName}">
|
|
41
|
+
<defs>
|
|
42
|
+
<linearGradient id="${svgId}-bg" x1="0" y1="0" x2="800" y2="500" gradientUnits="userSpaceOnUse">
|
|
43
|
+
<stop offset="0%" stop-color="#0b1220"/>
|
|
44
|
+
<stop offset="100%" stop-color="#151b2b"/>
|
|
45
|
+
</linearGradient>
|
|
46
|
+
<linearGradient id="${svgId}-hero" x1="0" y1="0" x2="512" y2="0" gradientUnits="userSpaceOnUse">
|
|
47
|
+
<stop offset="0%" stop-color="${primary}"/>
|
|
48
|
+
<stop offset="100%" stop-color="${accent}"/>
|
|
49
|
+
</linearGradient>
|
|
50
|
+
<radialGradient id="${svgId}-glow1" cx="0" cy="0" r="1" gradientTransform="translate(96 48) rotate(90) scale(220 220)">
|
|
51
|
+
<stop offset="0%" stop-color="${primary}" stop-opacity="0.38"/>
|
|
52
|
+
<stop offset="100%" stop-color="${primary}" stop-opacity="0"/>
|
|
53
|
+
</radialGradient>
|
|
54
|
+
<radialGradient id="${svgId}-glow2" cx="0" cy="0" r="1" gradientTransform="translate(704 432) rotate(90) scale(260 260)">
|
|
55
|
+
<stop offset="0%" stop-color="${accent}" stop-opacity="0.3"/>
|
|
56
|
+
<stop offset="100%" stop-color="${accent}" stop-opacity="0"/>
|
|
57
|
+
</radialGradient>
|
|
58
|
+
<pattern id="${svgId}-grid" width="32" height="32" patternUnits="userSpaceOnUse">
|
|
59
|
+
<path d="M32 0H0V32" fill="none" stroke="#ffffff" stroke-opacity="0.045" stroke-width="1"/>
|
|
60
|
+
</pattern>
|
|
61
|
+
<filter id="${svgId}-shadow" x="-16%" y="-16%" width="132%" height="132%">
|
|
62
|
+
<feDropShadow dx="0" dy="18" stdDeviation="22" flood-color="#000000" flood-opacity="0.38"/>
|
|
63
|
+
</filter>
|
|
64
|
+
</defs>
|
|
65
|
+
<rect width="800" height="500" fill="url(#${svgId}-bg)"/>
|
|
66
|
+
<rect width="800" height="500" fill="url(#${svgId}-glow1)"/>
|
|
67
|
+
<rect width="800" height="500" fill="url(#${svgId}-glow2)"/>
|
|
68
|
+
<rect width="800" height="500" fill="url(#${svgId}-grid)"/>
|
|
69
|
+
<rect x="32" y="28" width="112" height="26" rx="13" fill="#ffffff" fill-opacity="0.08"/>
|
|
70
|
+
<text x="74" y="45" text-anchor="middle" fill="#ffffff" fill-opacity="0.75" font-family="system-ui,-apple-system,sans-serif" font-size="11" font-weight="600" letter-spacing="0.08em">REACTPRESS</text>
|
|
71
|
+
${versionBadge}
|
|
72
|
+
<g transform="translate(120 68)" filter="url(#${svgId}-shadow)">
|
|
73
|
+
<rect width="560" height="328" rx="14" fill="#ffffff"/>
|
|
74
|
+
<path d="M0 14C0 6.268 6.268 0 14 0h532c7.732 0 14 6.268 14 14v38H0V14z" fill="#f8fafc"/>
|
|
75
|
+
<circle cx="28" cy="19" r="5.5" fill="#ff5f57" fill-opacity="0.88"/>
|
|
76
|
+
<circle cx="48" cy="19" r="5.5" fill="#febc2e" fill-opacity="0.88"/>
|
|
77
|
+
<circle cx="68" cy="19" r="5.5" fill="#28c840" fill-opacity="0.88"/>
|
|
78
|
+
<rect x="120" y="12" width="320" height="14" rx="7" fill="#e2e8f0"/>
|
|
79
|
+
<rect x="24" y="62" width="512" height="108" rx="10" fill="url(#${svgId}-hero)"/>
|
|
80
|
+
<rect x="40" y="86" width="196" height="14" rx="7" fill="#ffffff" fill-opacity="0.92"/>
|
|
81
|
+
<rect x="40" y="108" width="272" height="10" rx="5" fill="#ffffff" fill-opacity="0.55"/>
|
|
82
|
+
<rect x="24" y="194" width="340" height="10" rx="5" fill="#e2e8f0"/>
|
|
83
|
+
<rect x="24" y="214" width="420" height="8" rx="4" fill="#f1f5f9"/>
|
|
84
|
+
<rect x="24" y="228" width="380" height="8" rx="4" fill="#f1f5f9"/>
|
|
85
|
+
<rect x="24" y="252" width="160" height="52" rx="8" fill="#f8fafc" stroke="#e2e8f0" stroke-width="1"/>
|
|
86
|
+
<rect x="200" y="252" width="160" height="52" rx="8" fill="#f8fafc" stroke="#e2e8f0" stroke-width="1"/>
|
|
87
|
+
<rect x="376" y="252" width="136" height="52" rx="8" fill="#f8fafc" stroke="#e2e8f0" stroke-width="1"/>
|
|
88
|
+
</g>
|
|
89
|
+
<text x="400" y="456" text-anchor="middle" fill="#ffffff" font-family="system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif" font-size="24" font-weight="600">${safeName}</text>
|
|
90
|
+
<text x="400" y="478" text-anchor="middle" fill="#ffffff" fill-opacity="0.5" font-family="system-ui,-apple-system,sans-serif" font-size="12" font-weight="500">Theme Preview</text>
|
|
91
|
+
</svg>`;
|
|
92
|
+
}
|
|
93
|
+
exports.buildThemePlaceholderCoverSvg = buildThemePlaceholderCoverSvg;
|
|
94
|
+
//# sourceMappingURL=theme-placeholder-cover.js.map
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.uniqueid = void 0;
|
|
4
4
|
const nuid_1 = require("nuid");
|
|
5
5
|
function uniqueid() {
|
|
6
|
-
return nuid_1.next();
|
|
6
|
+
return (0, nuid_1.next)();
|
|
7
7
|
}
|
|
8
8
|
exports.uniqueid = uniqueid;
|
|
9
9
|
//# sourceMappingURL=uniqueid.util.js.map
|