studiocms 0.2.0 → 0.4.0
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/CHANGELOG.md +122 -0
- package/dist/cli/add/index.d.ts +2 -2
- package/dist/cli/add/index.js +4 -3
- package/dist/cli/add/npm-utils.d.ts +6 -6
- package/dist/cli/add/tryToInstallPlugins.d.ts +1 -1
- package/dist/cli/add/tryToInstallPlugins.js +6 -5
- package/dist/cli/add/updateStudioCMSConfig.d.ts +1 -1
- package/dist/cli/add/updateStudioCMSConfig.js +3 -4
- package/dist/cli/add/validatePlugins.d.ts +1 -2
- package/dist/cli/add/validatePlugins.js +15 -9
- package/dist/cli/crypto/genJWT/index.d.ts +1 -1
- package/dist/cli/crypto/genJWT/index.js +8 -9
- package/dist/cli/crypto/index.d.ts +1 -1
- package/dist/cli/init/steps/env.js +14 -4
- package/dist/cli/init/steps/next.d.ts +1 -1
- package/dist/cli/init/steps/next.js +6 -5
- package/dist/cli/migrator/index.d.ts +1 -1
- package/dist/cli/migrator/index.js +2 -2
- package/dist/cli/users/index.d.ts +1 -1
- package/dist/cli/users/shared.js +2 -2
- package/dist/cli/users/steps/createUsers.js +7 -7
- package/dist/cli/users/steps/modifyUsers.js +2 -2
- package/dist/cli/users/steps/next.d.ts +1 -1
- package/dist/cli/utils/checkRequiredEnvVars.js +2 -2
- package/dist/cli/utils/context.d.ts +2 -4
- package/dist/cli/utils/context.js +1 -3
- package/dist/cli/utils/getCliDbClient.d.ts +1 -1
- package/dist/cli/utils/intro.d.ts +1 -1
- package/dist/cli/utils/loadConfig.d.ts +54 -49
- package/dist/cli/utils/loadConfig.js +5 -8
- package/dist/cli/utils/logger.js +3 -3
- package/dist/cli/utils/user-utils.d.ts +1 -1
- package/dist/cli/utils/user-utils.js +4 -3
- package/dist/client/apiClient.d.ts +4923 -0
- package/dist/client/apiClient.js +72 -0
- package/dist/config.d.ts +1734 -1
- package/dist/consts.d.ts +5 -5
- package/dist/consts.js +3 -2
- package/dist/db/plugins.d.ts +1 -1
- package/dist/db/plugins.js +5 -8
- package/dist/handlers/frontend/routes.d.ts +4 -18
- package/dist/handlers/frontend/routes.js +13 -152
- package/dist/handlers/frontend/types.d.ts +1 -1
- package/dist/handlers/frontend/utils.js +0 -18
- package/dist/handlers/pluginHandler.d.ts +34 -257
- package/dist/handlers/pluginHandler.js +92 -46
- package/dist/handlers/routeHandler.js +32 -11
- package/dist/handlers/setupDbStudio.d.ts +3 -1
- package/dist/handlers/setupDbStudio.js +19 -10
- package/dist/handlers/storage-manager/core/effectify-astro-context.d.ts +25 -0
- package/dist/handlers/storage-manager/core/effectify-astro-context.js +78 -0
- package/dist/handlers/storage-manager/no-op.d.ts +2 -2
- package/dist/handlers/storage-manager/no-op.js +2 -3
- package/dist/index.d.ts +0 -1
- package/dist/index.js +10 -20
- package/dist/integrations/robots/index.d.ts +2 -2
- package/dist/integrations/robots/index.js +1 -3
- package/dist/integrations/robots/schema.d.ts +102 -273
- package/dist/integrations/robots/schema.js +220 -209
- package/dist/plugins/analytics/assets/schemas.d.ts +14 -9
- package/dist/plugins/analytics/assets/schemas.js +25 -17
- package/dist/plugins/analytics/db-client.d.ts +1 -1
- package/dist/plugins/analytics/index.d.ts +823 -3
- package/dist/plugins/analytics/index.js +4 -5
- package/dist/plugins/analytics/schemas.d.ts +54 -62
- package/dist/plugins/analytics/schemas.js +64 -13
- package/dist/plugins/analytics/table.d.ts +1 -1
- package/dist/plugins.d.ts +0 -1
- package/dist/schemas/config/api.d.ts +17 -0
- package/dist/schemas/config/api.js +14 -0
- package/dist/schemas/config/auth.d.ts +55 -59
- package/dist/schemas/config/auth.js +34 -11
- package/dist/schemas/config/dashboard.d.ts +43 -79
- package/dist/schemas/config/dashboard.js +43 -12
- package/dist/schemas/config/db.d.ts +15 -17
- package/dist/schemas/config/db.js +13 -5
- package/dist/schemas/config/developer.d.ts +33 -45
- package/dist/schemas/config/developer.js +22 -5
- package/dist/schemas/config/index.d.ts +398 -521
- package/dist/schemas/config/index.js +115 -57
- package/dist/schemas/config/sdk.d.ts +50 -196
- package/dist/schemas/config/sdk.js +61 -73
- package/dist/schemas/custom.d.ts +40 -0
- package/dist/schemas/custom.js +41 -0
- package/dist/schemas/external-schemas.d.ts +171 -0
- package/dist/schemas/external-schemas.js +179 -0
- package/dist/schemas/index.d.ts +2 -0
- package/dist/schemas/index.js +2 -0
- package/dist/schemas/plugins/i18n.d.ts +59 -39
- package/dist/schemas/plugins/i18n.js +42 -5
- package/dist/schemas/plugins/index.d.ts +7126 -10296
- package/dist/schemas/plugins/index.js +260 -276
- package/dist/schemas/plugins/shared.d.ts +1293 -3718
- package/dist/schemas/plugins/shared.js +320 -329
- package/dist/test-utils.d.ts +15 -4
- package/dist/test-utils.js +27 -11
- package/dist/toolbar/db-viewer/db-shared-types.d.ts +6 -6
- package/dist/toolbar/db-viewer/studio/connection.d.ts +8 -4
- package/dist/toolbar/db-viewer/studio/connection.js +2 -28
- package/dist/toolbar/db-viewer/studio/env/libsql.d.ts +7 -0
- package/dist/toolbar/db-viewer/studio/env/libsql.js +17 -0
- package/dist/toolbar/db-viewer/studio/env/mysql.d.ts +7 -0
- package/dist/toolbar/db-viewer/studio/env/mysql.js +23 -0
- package/dist/toolbar/db-viewer/studio/env/postgres.d.ts +7 -0
- package/dist/toolbar/db-viewer/studio/env/postgres.js +23 -0
- package/dist/toolbar/db-viewer/studio/index.js +20 -56
- package/dist/toolbar/db-viewer/studio/type.d.ts +1 -2
- package/dist/toolbar/db-viewer/studio/virtual-connection/libsql.d.ts +3 -0
- package/dist/toolbar/db-viewer/studio/virtual-connection/libsql.js +24 -0
- package/dist/toolbar/db-viewer/studio/virtual-connection/mysql.d.ts +3 -0
- package/dist/toolbar/db-viewer/studio/virtual-connection/mysql.js +9 -0
- package/dist/toolbar/db-viewer/studio/virtual-connection/postgres.d.ts +3 -0
- package/dist/toolbar/db-viewer/studio/virtual-connection/postgres.js +9 -0
- package/dist/toolbar/db-viewer/viewer.js +20 -21
- package/dist/types.d.ts +30 -0
- package/dist/utils/effects/smtp.d.ts +1 -1
- package/dist/utils/lang-helper.d.ts +10 -2
- package/dist/virtual.d.ts +35 -28
- package/dist/virtuals/auth/core.d.ts +5 -5
- package/dist/virtuals/auth/verify-email.d.ts +6 -6
- package/dist/virtuals/components/Generator.astro +2 -2
- package/dist/virtuals/components/Renderer.astro +9 -1
- package/dist/virtuals/components/renderFn.d.ts +3 -1
- package/dist/virtuals/components/renderFn.js +18 -0
- package/dist/virtuals/lib/headDefaults.d.ts +4 -2
- package/dist/virtuals/lib/headDefaults.js +0 -2
- package/dist/virtuals/lib/routeMap.d.ts +0 -12
- package/dist/virtuals/lib/routeMap.js +2 -14
- package/dist/virtuals/mailer/index.d.ts +3 -3
- package/dist/virtuals/notifier/index.d.ts +5 -5
- package/dist/virtuals/plugins/dashboard-pages.d.ts +2 -64
- package/dist/virtuals/scripts/StorageFileBrowser.d.ts +1 -172
- package/dist/virtuals/scripts/StorageFileBrowser.js +216 -119
- package/dist/virtuals/template-engine/index.d.ts +4 -4
- package/frontend/components/dashboard/configuration/ConfigForm.astro +218 -110
- package/frontend/components/dashboard/content-mgmt/ContentSearch.astro +21 -22
- package/frontend/components/dashboard/content-mgmt/CreateFolder.astro +66 -54
- package/frontend/components/dashboard/content-mgmt/CreatePage.astro +58 -104
- package/frontend/components/dashboard/content-mgmt/EditFolder.astro +65 -67
- package/frontend/components/dashboard/content-mgmt/EditPage.astro +86 -134
- package/frontend/components/dashboard/content-mgmt/InnerSidebarElement.astro +0 -1
- package/frontend/components/dashboard/content-mgmt/PageHeader.astro +33 -52
- package/frontend/components/dashboard/content-mgmt/PageTypeHandler.astro +2 -2
- package/frontend/components/dashboard/profile/APITokens.astro +219 -158
- package/frontend/components/dashboard/profile/BasicInfo.astro +165 -106
- package/frontend/components/dashboard/profile/Notifications.astro +27 -18
- package/frontend/components/dashboard/profile/UpdatePassword.astro +134 -94
- package/frontend/components/dashboard/sidebar/VersionCheck.astro +31 -16
- package/frontend/components/dashboard/sidebar/VersionCheckChangelog.astro +18 -11
- package/frontend/components/dashboard/sidebar-modals/VersionModal.astro +2 -2
- package/frontend/components/dashboard/smtp-config/TemplateEditor.astro +14 -14
- package/frontend/components/dashboard/taxonomy/InnerSidebarElement.astro +0 -1
- package/frontend/components/dashboard/taxonomy/MetaContainer.astro +0 -2
- package/frontend/components/dashboard/taxonomy/PageHeader.astro +16 -24
- package/frontend/components/dashboard/taxonomy/TaxonomySearch.astro +23 -27
- package/frontend/components/dashboard/user-mgmt/InnerSidebarElement.astro +111 -104
- package/frontend/components/dashboard/user-mgmt/UserListItem.astro +9 -22
- package/frontend/components/dashboard/user-mgmt/UserListItems.astro +18 -0
- package/frontend/components/first-time-setup/snippets/{opt2-studiocms.config.diff → studiocms.config.diff} +1 -0
- package/frontend/components/shared/Code.astro +1 -4
- package/frontend/components/shared/DynamicSettingsRenderer.astro +1 -1
- package/frontend/components/shared/SSRUser.astro +2 -4
- package/frontend/components/shared/foldertree/FolderTreeNode.astro +0 -6
- package/frontend/components/shared/storage-manager/StorageCopyOutput.astro +0 -1
- package/frontend/components/shared/taxonomy/TaxonomyTreeNode.astro +0 -6
- package/frontend/layouts/DashboardLayout.astro +1 -10
- package/frontend/layouts/TaxonomyLayout.astro +0 -1
- package/frontend/middleware/index.ts +102 -61
- package/frontend/pages/404.astro +5 -9
- package/frontend/pages/[dashboard]/[...pluginPage].astro +10 -1
- package/frontend/pages/[dashboard]/configuration.astro +10 -1
- package/frontend/pages/[dashboard]/content-management/createfolder.astro +10 -1
- package/frontend/pages/[dashboard]/content-management/createpage.astro +10 -1
- package/frontend/pages/[dashboard]/content-management/diff.astro +39 -14
- package/frontend/pages/[dashboard]/content-management/editfolder.astro +10 -1
- package/frontend/pages/[dashboard]/content-management/editpage.astro +10 -1
- package/frontend/pages/[dashboard]/content-management/index.astro +10 -1
- package/frontend/pages/[dashboard]/index.astro +10 -1
- package/frontend/pages/[dashboard]/login.astro +86 -25
- package/frontend/pages/[dashboard]/password-reset.astro +22 -16
- package/frontend/pages/[dashboard]/plugins/[plugin].astro +10 -1
- package/frontend/pages/[dashboard]/profile.astro +10 -1
- package/frontend/pages/[dashboard]/signup.astro +153 -52
- package/frontend/pages/[dashboard]/smtp-configuration.astro +77 -75
- package/frontend/pages/[dashboard]/system-management.astro +10 -1
- package/frontend/pages/[dashboard]/taxonomy/categories.astro +30 -41
- package/frontend/pages/[dashboard]/taxonomy/index.astro +10 -0
- package/frontend/pages/[dashboard]/taxonomy/tags.astro +33 -43
- package/frontend/pages/[dashboard]/unverified-email.astro +29 -21
- package/frontend/pages/[dashboard]/user-management/edit.astro +170 -90
- package/frontend/pages/[dashboard]/user-management/index.astro +10 -1
- package/frontend/pages/studiocms_api/[...all].ts +106 -0
- package/frontend/pages/studiocms_api/_handlers/_utils/auth.ts +26 -0
- package/frontend/pages/studiocms_api/_handlers/_utils/changelog.ts +147 -0
- package/frontend/pages/studiocms_api/_handlers/_utils/db-studio-driver.ts +46 -0
- package/frontend/pages/studiocms_api/_handlers/_utils/parseLogLevel.ts +27 -0
- package/frontend/pages/studiocms_api/_handlers/auth/auth.ts +459 -0
- package/frontend/pages/studiocms_api/_handlers/auth/index.ts +17 -0
- package/frontend/pages/studiocms_api/_handlers/auth/oauth.ts +91 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/_shared.ts +57 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/apiTokens.ts +134 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/config.ts +64 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/content.ts +741 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/create.ts +480 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/emailNotifications.ts +49 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/index.ts +45 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/mailer.ts +136 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/plugins.ts +80 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/profile.ts +275 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/resetPassword.ts +140 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/search.ts +63 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/taxonomy.ts +285 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/templates.ts +75 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/users.ts +312 -0
- package/frontend/pages/studiocms_api/_handlers/dashboard/verifyEndpoints.ts +307 -0
- package/frontend/pages/studiocms_api/_handlers/integration/dbStudio.ts +98 -0
- package/frontend/pages/studiocms_api/_handlers/integration/index.ts +17 -0
- package/frontend/pages/studiocms_api/_handlers/integration/storageManager.ts +107 -0
- package/frontend/pages/studiocms_api/_handlers/rest-api/index.ts +8 -0
- package/frontend/pages/studiocms_api/_handlers/rest-api/v1/_shared.ts +41 -0
- package/frontend/pages/studiocms_api/_handlers/rest-api/v1/index.ts +17 -0
- package/frontend/pages/studiocms_api/_handlers/rest-api/v1/public.ts +195 -0
- package/frontend/pages/studiocms_api/_handlers/rest-api/v1/secure.ts +1726 -0
- package/frontend/pages/studiocms_api/_handlers/sdk.ts +129 -0
- package/frontend/pages/studiocms_api/_middleware/astroLocals.ts +36 -0
- package/frontend/pages/studiocms_api/_middleware/restApi.ts +56 -0
- package/frontend/pages/studiocms_api/integrations/[...all].ts +8 -0
- package/frontend/scripts/formdata.ts +219 -0
- package/frontend/setup-pages/3-done.astro +4 -20
- package/frontend/setup-pages/studiocms_api/dashboard/step-2.ts +3 -6
- package/frontend/styles/dashboard-base.css +0 -1
- package/frontend/web-vitals/endpoint.ts +2 -1
- package/package.json +35 -31
- package/dist/global.d.ts +0 -9
- package/frontend/components/dashboard/LoginChecker.astro +0 -68
- package/frontend/components/dashboard/user-mgmt/RankCheck.astro +0 -57
- package/frontend/components/first-time-setup/snippets/opt1-astro.config.diff +0 -14
- package/frontend/components/first-time-setup/snippets/opt2-astro.config.diff +0 -9
- package/frontend/middleware/_authmap.ts +0 -63
- package/frontend/pages/studiocms_api/auth/[path].ts +0 -390
- package/frontend/pages/studiocms_api/auth/[provider]/[...id].ts +0 -64
- package/frontend/pages/studiocms_api/auth/[provider]/_effects/index.ts +0 -101
- package/frontend/pages/studiocms_api/auth/_shared.ts +0 -52
- package/frontend/pages/studiocms_api/dashboard/api-tokens.ts +0 -115
- package/frontend/pages/studiocms_api/dashboard/config.ts +0 -74
- package/frontend/pages/studiocms_api/dashboard/content/diff.ts +0 -73
- package/frontend/pages/studiocms_api/dashboard/content/folder.ts +0 -220
- package/frontend/pages/studiocms_api/dashboard/content/page.ts +0 -359
- package/frontend/pages/studiocms_api/dashboard/create-reset-link.ts +0 -77
- package/frontend/pages/studiocms_api/dashboard/create-user-invite.ts +0 -231
- package/frontend/pages/studiocms_api/dashboard/create-user.ts +0 -186
- package/frontend/pages/studiocms_api/dashboard/email-notification-settings-site.ts +0 -74
- package/frontend/pages/studiocms_api/dashboard/mailer/check-email.ts +0 -75
- package/frontend/pages/studiocms_api/dashboard/mailer/config.ts +0 -136
- package/frontend/pages/studiocms_api/dashboard/plugins/[plugin].ts +0 -80
- package/frontend/pages/studiocms_api/dashboard/profile.ts +0 -245
- package/frontend/pages/studiocms_api/dashboard/resend-verify-email.ts +0 -77
- package/frontend/pages/studiocms_api/dashboard/reset-password.ts +0 -124
- package/frontend/pages/studiocms_api/dashboard/search-list.ts +0 -59
- package/frontend/pages/studiocms_api/dashboard/taxonomy-search.ts +0 -47
- package/frontend/pages/studiocms_api/dashboard/taxonomy.ts +0 -230
- package/frontend/pages/studiocms_api/dashboard/templates.ts +0 -74
- package/frontend/pages/studiocms_api/dashboard/update-user-notifications.ts +0 -86
- package/frontend/pages/studiocms_api/dashboard/users.ts +0 -236
- package/frontend/pages/studiocms_api/dashboard/verify-email.ts +0 -83
- package/frontend/pages/studiocms_api/dashboard/verify-session.ts +0 -187
- package/frontend/pages/studiocms_api/integrations/[type]/[...id].ts +0 -15
- package/frontend/pages/studiocms_api/integrations/[type]/_routes/db-studio.ts +0 -173
- package/frontend/pages/studiocms_api/integrations/[type]/_routes/storage.ts +0 -88
- package/frontend/pages/studiocms_api/partials/editor.astro +0 -74
- package/frontend/pages/studiocms_api/partials/render.astro +0 -39
- package/frontend/pages/studiocms_api/partials/user-list-items.astro +0 -43
- package/frontend/pages/studiocms_api/rest/utils/auth-token.ts +0 -59
- package/frontend/pages/studiocms_api/rest/v1/[type]/[...id].ts +0 -23
- package/frontend/pages/studiocms_api/rest/v1/[type]/_routes/categories.ts +0 -267
- package/frontend/pages/studiocms_api/rest/v1/[type]/_routes/folders.ts +0 -283
- package/frontend/pages/studiocms_api/rest/v1/[type]/_routes/pages.ts +0 -505
- package/frontend/pages/studiocms_api/rest/v1/[type]/_routes/settings.ts +0 -100
- package/frontend/pages/studiocms_api/rest/v1/[type]/_routes/tags.ts +0 -229
- package/frontend/pages/studiocms_api/rest/v1/[type]/_routes/users.ts +0 -553
- package/frontend/pages/studiocms_api/rest/v1/public/[type]/[...id].ts +0 -19
- package/frontend/pages/studiocms_api/rest/v1/public/[type]/_routes/categories.ts +0 -74
- package/frontend/pages/studiocms_api/rest/v1/public/[type]/_routes/folders.ts +0 -85
- package/frontend/pages/studiocms_api/rest/v1/public/[type]/_routes/pages.ts +0 -103
- package/frontend/pages/studiocms_api/rest/v1/public/[type]/_routes/tags.ts +0 -67
- package/frontend/pages/studiocms_api/sdk/[...path].ts +0 -97
- package/frontend/pages/studiocms_api/sdk/utils/changelog.ts +0 -119
- package/frontend/scripts/auth/formListener.ts +0 -81
- package/frontend/scripts/formdata-utils.ts +0 -116
- package/frontend/utils/build-partial-schema.ts +0 -46
- package/frontend/utils/errors.ts +0 -6
- package/frontend/utils/param-extractor.ts +0 -83
- package/frontend/utils/rest-router.ts +0 -444
|
@@ -17,156 +17,216 @@ const lang = Astro.locals.StudioCMS.defaultLang;
|
|
|
17
17
|
const t = useTranslations(lang, '@studiocms/dashboard:profile');
|
|
18
18
|
---
|
|
19
19
|
|
|
20
|
-
<Card
|
|
21
|
-
|
|
20
|
+
<Card
|
|
21
|
+
fullWidth
|
|
22
|
+
as="form"
|
|
23
|
+
id="basic-info-form"
|
|
24
|
+
class="basic-info-form"
|
|
25
|
+
>
|
|
22
26
|
<div slot="header">
|
|
23
27
|
<h2>
|
|
24
|
-
<t-profile-basic key="basic-info-header"
|
|
28
|
+
<t-profile-basic key="basic-info-header"
|
|
29
|
+
>{t("basic-info-header")}</t-profile-basic
|
|
30
|
+
>
|
|
25
31
|
</h2>
|
|
26
|
-
|
|
32
|
+
|
|
27
33
|
<div class="form-header">
|
|
28
34
|
<Group>
|
|
29
|
-
<Button
|
|
30
|
-
|
|
35
|
+
<Button
|
|
36
|
+
id="refresh-avatar"
|
|
37
|
+
size="sm"
|
|
38
|
+
variant={"outlined"}
|
|
39
|
+
color={"info"}
|
|
40
|
+
>
|
|
41
|
+
<Icon
|
|
42
|
+
slot="start-content"
|
|
43
|
+
name="heroicons:user-circle"
|
|
44
|
+
width={24}
|
|
45
|
+
height={24}
|
|
46
|
+
/>
|
|
31
47
|
<t-profile-basic key="sync-with-libravatar">
|
|
32
|
-
{t(
|
|
48
|
+
{t("sync-with-libravatar")}
|
|
33
49
|
</t-profile-basic>
|
|
34
50
|
</Button>
|
|
35
|
-
<Button
|
|
36
|
-
|
|
51
|
+
<Button
|
|
52
|
+
type="submit"
|
|
53
|
+
size="sm"
|
|
54
|
+
variant={"solid"}
|
|
55
|
+
color="primary"
|
|
56
|
+
>
|
|
57
|
+
<Icon
|
|
58
|
+
slot="start-content"
|
|
59
|
+
name="heroicons:check"
|
|
60
|
+
width={24}
|
|
61
|
+
height={24}
|
|
62
|
+
/>
|
|
37
63
|
<t-profile-basic key="basic-info-save-button">
|
|
38
|
-
{t(
|
|
64
|
+
{t("basic-info-save-button")}
|
|
39
65
|
</t-profile-basic>
|
|
40
|
-
</Button>
|
|
66
|
+
</Button>
|
|
41
67
|
</Group>
|
|
42
68
|
</div>
|
|
43
69
|
</div>
|
|
44
70
|
|
|
45
71
|
<div class="form-inputs">
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
72
|
+
<Input
|
|
73
|
+
label={t("basic-info-display-name")}
|
|
74
|
+
placeholder="John Doe"
|
|
75
|
+
value={data?.user?.name}
|
|
76
|
+
isRequired
|
|
77
|
+
name="display-name"
|
|
78
|
+
/>
|
|
79
|
+
|
|
80
|
+
<Input
|
|
81
|
+
label={t("basic-info-username")}
|
|
82
|
+
placeholder="johndoe"
|
|
83
|
+
value={data?.user?.username}
|
|
84
|
+
isRequired
|
|
85
|
+
name="username"
|
|
86
|
+
/>
|
|
87
|
+
|
|
88
|
+
<Input
|
|
89
|
+
label={t("basic-info-email")}
|
|
90
|
+
placeholder="john@doe.com"
|
|
91
|
+
value={data?.user?.email}
|
|
92
|
+
isRequired
|
|
93
|
+
name="email"
|
|
94
|
+
/>
|
|
95
|
+
|
|
96
|
+
<Input
|
|
97
|
+
label={t("basic-info-website")}
|
|
98
|
+
placeholder="https://doe.com"
|
|
99
|
+
value={data?.user?.url}
|
|
100
|
+
name="account-url"
|
|
101
|
+
/>
|
|
102
|
+
|
|
103
|
+
<Input
|
|
104
|
+
label={t("basic-avatar-url")}
|
|
105
|
+
placeholder="https://seccdn.libravatar.org/avatar/..."
|
|
106
|
+
value={data?.user?.avatar}
|
|
107
|
+
name="avatar"
|
|
108
|
+
/>
|
|
109
|
+
|
|
110
|
+
<input type="hidden" name="email-verified" value={data?.user?.emailVerified ? "true" : "false"} />
|
|
57
111
|
</div>
|
|
58
|
-
|
|
59
112
|
</Card>
|
|
60
113
|
|
|
61
114
|
<script>
|
|
62
|
-
import {
|
|
115
|
+
import {
|
|
63
116
|
$i18n,
|
|
64
117
|
baseTranslation,
|
|
65
118
|
makeTranslation,
|
|
66
119
|
updateElmLabel,
|
|
67
|
-
} from
|
|
120
|
+
} from "studiocms:i18n/client";
|
|
68
121
|
|
|
69
|
-
const currentPage =
|
|
122
|
+
const currentPage = "@studiocms/dashboard:profile";
|
|
70
123
|
|
|
71
124
|
const i18n = $i18n(currentPage, baseTranslation[currentPage]);
|
|
72
|
-
|
|
73
|
-
i18n.subscribe(comp => {
|
|
74
|
-
updateElmLabel(
|
|
75
|
-
updateElmLabel(
|
|
76
|
-
updateElmLabel(
|
|
77
|
-
updateElmLabel(
|
|
125
|
+
|
|
126
|
+
i18n.subscribe((comp) => {
|
|
127
|
+
updateElmLabel("display-name", comp["basic-info-display-name"]);
|
|
128
|
+
updateElmLabel("username", comp["basic-info-username"]);
|
|
129
|
+
updateElmLabel("email", comp["basic-info-email"]);
|
|
130
|
+
updateElmLabel("account-url", comp["basic-info-website"]);
|
|
78
131
|
});
|
|
79
132
|
|
|
80
|
-
if (!customElements.get(
|
|
81
|
-
customElements.define(
|
|
133
|
+
if (!customElements.get("t-profile-basic")) {
|
|
134
|
+
customElements.define(
|
|
135
|
+
"t-profile-basic",
|
|
136
|
+
makeTranslation(currentPage, i18n),
|
|
137
|
+
);
|
|
82
138
|
}
|
|
83
139
|
</script>
|
|
84
140
|
|
|
85
|
-
|
|
86
141
|
<script>
|
|
87
142
|
import { toast } from "studiocms:ui/components/toaster/client";
|
|
143
|
+
import { dashboardClient, dashboardSharedCatchTags } from "studiocms:client/apiClients";
|
|
144
|
+
import * as Effect from "effect/Effect";
|
|
88
145
|
|
|
89
|
-
const syncAvatar = document.getElementById(
|
|
90
|
-
|
|
146
|
+
const syncAvatar = document.getElementById(
|
|
147
|
+
"refresh-avatar",
|
|
148
|
+
) as HTMLButtonElement;
|
|
91
149
|
|
|
92
|
-
syncAvatar.addEventListener(
|
|
150
|
+
syncAvatar.addEventListener("click", async (e) => {
|
|
93
151
|
e.preventDefault();
|
|
94
152
|
|
|
95
|
-
const response = await
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
153
|
+
const response = await dashboardClient.pipe(
|
|
154
|
+
Effect.flatMap((client) =>
|
|
155
|
+
client.profile.updateUserProfile({
|
|
156
|
+
payload: {
|
|
157
|
+
mode: "avatar",
|
|
158
|
+
},
|
|
159
|
+
}),
|
|
160
|
+
),
|
|
161
|
+
Effect.catchTags(dashboardSharedCatchTags),
|
|
162
|
+
Effect.runPromise,
|
|
163
|
+
);
|
|
164
|
+
|
|
165
|
+
if ("error" in response) {
|
|
166
|
+
toast({
|
|
167
|
+
title: "Error",
|
|
168
|
+
description: response.error,
|
|
169
|
+
type: "danger",
|
|
170
|
+
});
|
|
171
|
+
} else {
|
|
106
172
|
toast({
|
|
107
|
-
title:
|
|
108
|
-
description:
|
|
109
|
-
|
|
110
|
-
|
|
173
|
+
title: "Success",
|
|
174
|
+
description:
|
|
175
|
+
response.message || "Avatar synchronized successfully",
|
|
176
|
+
type: "success",
|
|
177
|
+
});
|
|
111
178
|
}
|
|
179
|
+
});
|
|
180
|
+
|
|
181
|
+
const basicInfoForm = document.getElementById(
|
|
182
|
+
"basic-info-form",
|
|
183
|
+
) as HTMLFormElement;
|
|
184
|
+
|
|
185
|
+
basicInfoForm.addEventListener("submit", async (e) => {
|
|
186
|
+
e.preventDefault();
|
|
112
187
|
|
|
113
|
-
|
|
188
|
+
const formData = new FormData(basicInfoForm);
|
|
189
|
+
|
|
190
|
+
const response = await dashboardClient.pipe(
|
|
191
|
+
Effect.flatMap((client) =>
|
|
192
|
+
client.profile.updateUserProfile({
|
|
193
|
+
payload: {
|
|
194
|
+
mode: "basic",
|
|
195
|
+
data: {
|
|
196
|
+
name: formData.get("display-name") as string,
|
|
197
|
+
username: formData.get("username") as string,
|
|
198
|
+
email: formData.get("email") as string,
|
|
199
|
+
url: (formData.get("account-url") ?? null) as string | null,
|
|
200
|
+
avatar: (formData.get("avatar") ?? null) as string | null,
|
|
201
|
+
emailVerified: formData.get("email-verified") === "true",
|
|
202
|
+
createdAt: undefined,
|
|
203
|
+
updatedAt: new Date().toISOString(),
|
|
204
|
+
},
|
|
205
|
+
},
|
|
206
|
+
}),
|
|
207
|
+
),
|
|
208
|
+
Effect.catchTags(dashboardSharedCatchTags),
|
|
209
|
+
Effect.runPromise,
|
|
210
|
+
);
|
|
211
|
+
|
|
212
|
+
if ("error" in response) {
|
|
213
|
+
toast({
|
|
214
|
+
title: "Error",
|
|
215
|
+
description: response.error,
|
|
216
|
+
type: "danger",
|
|
217
|
+
});
|
|
218
|
+
} else {
|
|
114
219
|
toast({
|
|
115
|
-
title:
|
|
116
|
-
description:
|
|
117
|
-
|
|
118
|
-
|
|
220
|
+
title: "Success",
|
|
221
|
+
description:
|
|
222
|
+
response.message || "Profile updated successfully",
|
|
223
|
+
type: "success",
|
|
224
|
+
});
|
|
119
225
|
}
|
|
120
|
-
})
|
|
121
|
-
|
|
122
|
-
const basicInfoForm = document.getElementById('basic-info-form') as HTMLFormElement;
|
|
123
|
-
basicInfoForm.addEventListener('submit', async (e) => {
|
|
124
|
-
e.preventDefault();
|
|
125
|
-
|
|
126
|
-
const formData = new FormData(basicInfoForm);
|
|
127
|
-
|
|
128
|
-
const data = {
|
|
129
|
-
mode: 'basic',
|
|
130
|
-
data: {
|
|
131
|
-
name: formData.get('display-name') as string,
|
|
132
|
-
username: formData.get('username') as string,
|
|
133
|
-
email: formData.get('email') as string,
|
|
134
|
-
url: formData.get('account-url') ?? null,
|
|
135
|
-
avatar: formData.get('avatar') ?? null,
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
const response = await fetch(basicInfoForm.action, {
|
|
140
|
-
method: 'POST',
|
|
141
|
-
headers: {
|
|
142
|
-
'Content-Type': 'application/json',
|
|
143
|
-
},
|
|
144
|
-
body: JSON.stringify(data)
|
|
145
|
-
})
|
|
146
|
-
|
|
147
|
-
const res = await response.json();
|
|
148
|
-
|
|
149
|
-
if (response.status !== 200) {
|
|
150
|
-
toast({
|
|
151
|
-
title: 'Error',
|
|
152
|
-
description: res.error,
|
|
153
|
-
type: 'danger'
|
|
154
|
-
})
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
if (response.status === 200) {
|
|
158
|
-
toast({
|
|
159
|
-
title: 'Success',
|
|
160
|
-
description: res.message,
|
|
161
|
-
type: 'success'
|
|
162
|
-
})
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
});
|
|
226
|
+
});
|
|
166
227
|
</script>
|
|
167
228
|
|
|
168
229
|
<style>
|
|
169
|
-
|
|
170
230
|
.basic-info-form {
|
|
171
231
|
position: relative;
|
|
172
232
|
}
|
|
@@ -187,5 +247,4 @@ const t = useTranslations(lang, '@studiocms/dashboard:profile');
|
|
|
187
247
|
top: 1rem;
|
|
188
248
|
right: 1rem;
|
|
189
249
|
}
|
|
190
|
-
|
|
191
250
|
</style>
|
|
@@ -53,7 +53,7 @@ const t = useTranslations(lang, '@studiocms/dashboard:profile-notifications');
|
|
|
53
53
|
|
|
54
54
|
type TKey = Parameters<typeof t>[0];
|
|
55
55
|
---
|
|
56
|
-
<Card fullWidth as="form" id="notifications-form" class="notifications-update-form"
|
|
56
|
+
<Card fullWidth as="form" id="notifications-form" class="notifications-update-form">
|
|
57
57
|
|
|
58
58
|
<div slot="header">
|
|
59
59
|
<h2><t-notifications key="header-title">{t('header-title')}</t-notifications></h2>
|
|
@@ -161,7 +161,9 @@ type TKey = Parameters<typeof t>[0];
|
|
|
161
161
|
|
|
162
162
|
<script>
|
|
163
163
|
import { toast } from 'studiocms:ui/components/toaster/client';
|
|
164
|
-
import { getEnabledNotificationCheckboxes, formatNotificationOptions } from 'studiocms:notifier/client'
|
|
164
|
+
import { getEnabledNotificationCheckboxes, formatNotificationOptions } from 'studiocms:notifier/client';
|
|
165
|
+
import { dashboardClient, dashboardSharedCatchTags } from 'studiocms:client/apiClients';
|
|
166
|
+
import * as Effect from 'effect/Effect';
|
|
165
167
|
|
|
166
168
|
const form = document.getElementById('notifications-form') as HTMLFormElement;
|
|
167
169
|
|
|
@@ -174,31 +176,38 @@ type TKey = Parameters<typeof t>[0];
|
|
|
174
176
|
|
|
175
177
|
const formattedOptions = formatNotificationOptions(enabledCheckboxes);
|
|
176
178
|
|
|
177
|
-
const
|
|
178
|
-
userId: formData.get('user_id'),
|
|
179
|
-
notifications: formattedOptions
|
|
180
|
-
};
|
|
179
|
+
const userId = formData.get('user_id')?.toString();
|
|
181
180
|
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
const result = await response.json();
|
|
181
|
+
if (!userId) {
|
|
182
|
+
toast({
|
|
183
|
+
title: 'Error',
|
|
184
|
+
description: 'User ID is missing. Please refresh the page and try again.',
|
|
185
|
+
type: 'danger',
|
|
186
|
+
});
|
|
187
|
+
return;
|
|
188
|
+
}
|
|
191
189
|
|
|
192
|
-
|
|
190
|
+
const response = await dashboardClient.pipe(
|
|
191
|
+
Effect.flatMap((client) => client.users.updateUserNotifications({
|
|
192
|
+
payload: {
|
|
193
|
+
id: userId,
|
|
194
|
+
notifications: formattedOptions
|
|
195
|
+
}
|
|
196
|
+
})),
|
|
197
|
+
Effect.catchTags(dashboardSharedCatchTags),
|
|
198
|
+
Effect.runPromise
|
|
199
|
+
);
|
|
200
|
+
|
|
201
|
+
if ('message' in response) {
|
|
193
202
|
toast({
|
|
194
203
|
title: 'Notifications Updated',
|
|
195
|
-
description:
|
|
204
|
+
description: response.message,
|
|
196
205
|
type: 'success',
|
|
197
206
|
})
|
|
198
207
|
} else {
|
|
199
208
|
toast({
|
|
200
209
|
title: 'Error',
|
|
201
|
-
description:
|
|
210
|
+
description: response.error,
|
|
202
211
|
type: 'danger',
|
|
203
212
|
})
|
|
204
213
|
}
|
|
@@ -18,130 +18,170 @@ const lang = Astro.locals.StudioCMS.defaultLang;
|
|
|
18
18
|
const t = useTranslations(lang, '@studiocms/dashboard:profile');
|
|
19
19
|
---
|
|
20
20
|
|
|
21
|
-
<Card
|
|
22
|
-
|
|
21
|
+
<Card
|
|
22
|
+
fullWidth
|
|
23
|
+
as="form"
|
|
24
|
+
id="password-update-form"
|
|
25
|
+
class="password-update-form"
|
|
26
|
+
>
|
|
23
27
|
<div slot="header">
|
|
24
|
-
<h2
|
|
25
|
-
|
|
28
|
+
<h2>
|
|
29
|
+
<t-profile-password key="user-password-header"
|
|
30
|
+
>{t("user-password-header")}</t-profile-password
|
|
31
|
+
>
|
|
32
|
+
</h2>
|
|
33
|
+
|
|
26
34
|
<div class="form-header">
|
|
27
|
-
<Button
|
|
28
|
-
type=
|
|
29
|
-
variant=
|
|
30
|
-
color=
|
|
35
|
+
<Button
|
|
36
|
+
type="submit"
|
|
37
|
+
variant="solid"
|
|
38
|
+
color="primary"
|
|
31
39
|
disabled={userHasNoPassword}
|
|
32
|
-
size=
|
|
33
|
-
|
|
34
|
-
<Icon
|
|
40
|
+
size="sm"
|
|
41
|
+
>
|
|
42
|
+
<Icon
|
|
43
|
+
slot="start-content"
|
|
44
|
+
name="heroicons:check"
|
|
45
|
+
width={24}
|
|
46
|
+
height={24}
|
|
47
|
+
/>
|
|
35
48
|
<t-profile-password key="user-password-save-button">
|
|
36
|
-
{t(
|
|
49
|
+
{t("user-password-save-button")}
|
|
37
50
|
</t-profile-password>
|
|
38
|
-
</Button>
|
|
51
|
+
</Button>
|
|
39
52
|
</div>
|
|
40
53
|
</div>
|
|
41
54
|
|
|
42
|
-
{
|
|
43
|
-
|
|
44
|
-
<
|
|
45
|
-
|
|
46
|
-
|
|
55
|
+
{
|
|
56
|
+
userHasNoPassword && (
|
|
57
|
+
<p>
|
|
58
|
+
<t-profile-password key="user-password-no-password">
|
|
59
|
+
{t("user-password-no-password")}
|
|
60
|
+
</t-profile-password>
|
|
61
|
+
</p>
|
|
62
|
+
)
|
|
63
|
+
}
|
|
47
64
|
|
|
48
65
|
<div class="password-form-entries">
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
placeholder='********'
|
|
66
|
+
<Input
|
|
67
|
+
label={t("user-password-current")}
|
|
68
|
+
type="password"
|
|
69
|
+
placeholder="********"
|
|
54
70
|
isRequired={!userHasNoPassword}
|
|
55
71
|
disabled={userHasNoPassword}
|
|
56
|
-
name=
|
|
57
|
-
autocomplete=
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
<Input
|
|
61
|
-
label={t(
|
|
62
|
-
type=
|
|
63
|
-
placeholder=
|
|
64
|
-
isRequired
|
|
65
|
-
autocomplete=
|
|
66
|
-
name=
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
<Input
|
|
70
|
-
label={t(
|
|
71
|
-
type=
|
|
72
|
-
placeholder=
|
|
73
|
-
isRequired
|
|
74
|
-
autocomplete=
|
|
75
|
-
name=
|
|
76
|
-
|
|
77
|
-
|
|
72
|
+
name="current-password"
|
|
73
|
+
autocomplete="current-password"
|
|
74
|
+
/>
|
|
75
|
+
|
|
76
|
+
<Input
|
|
77
|
+
label={t("user-password-new")}
|
|
78
|
+
type="password"
|
|
79
|
+
placeholder="********"
|
|
80
|
+
isRequired
|
|
81
|
+
autocomplete="password new_password"
|
|
82
|
+
name="new-password"
|
|
83
|
+
/>
|
|
84
|
+
|
|
85
|
+
<Input
|
|
86
|
+
label={t("user-password-confirm")}
|
|
87
|
+
type="password"
|
|
88
|
+
placeholder="********"
|
|
89
|
+
isRequired
|
|
90
|
+
autocomplete="password new_password"
|
|
91
|
+
name="confirm-new-password"
|
|
92
|
+
/>
|
|
78
93
|
</div>
|
|
79
94
|
</Card>
|
|
80
95
|
|
|
81
96
|
<script>
|
|
82
|
-
import {
|
|
97
|
+
import {
|
|
83
98
|
$i18n,
|
|
84
99
|
baseTranslation,
|
|
85
100
|
makeTranslation,
|
|
86
101
|
updateElmLabel,
|
|
87
|
-
} from
|
|
102
|
+
} from "studiocms:i18n/client";
|
|
88
103
|
|
|
89
|
-
const currentPage =
|
|
104
|
+
const currentPage = "@studiocms/dashboard:profile";
|
|
90
105
|
|
|
91
106
|
const i18n = $i18n(currentPage, baseTranslation[currentPage]);
|
|
92
|
-
|
|
93
|
-
i18n.subscribe(comp => {
|
|
94
|
-
updateElmLabel(
|
|
95
|
-
updateElmLabel(
|
|
96
|
-
updateElmLabel(
|
|
107
|
+
|
|
108
|
+
i18n.subscribe((comp) => {
|
|
109
|
+
updateElmLabel("current-password", comp["user-password-current"]);
|
|
110
|
+
updateElmLabel("new-password", comp["user-password-new"]);
|
|
111
|
+
updateElmLabel("confirm-new-password", comp["user-password-confirm"]);
|
|
97
112
|
});
|
|
98
113
|
|
|
99
|
-
if (!customElements.get(
|
|
100
|
-
customElements.define(
|
|
114
|
+
if (!customElements.get("t-profile-password")) {
|
|
115
|
+
customElements.define(
|
|
116
|
+
"t-profile-password",
|
|
117
|
+
makeTranslation(currentPage, i18n),
|
|
118
|
+
);
|
|
101
119
|
}
|
|
102
120
|
</script>
|
|
103
121
|
|
|
104
122
|
<script>
|
|
105
123
|
import { toast } from "studiocms:ui/components/toaster/client";
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
124
|
+
import { dashboardClient, dashboardSharedCatchTags } from "studiocms:client/apiClients";
|
|
125
|
+
import * as Effect from "effect/Effect";
|
|
126
|
+
|
|
127
|
+
const passwordUpdateForm = document.getElementById(
|
|
128
|
+
"password-update-form",
|
|
129
|
+
) as HTMLFormElement;
|
|
130
|
+
|
|
131
|
+
passwordUpdateForm.addEventListener("submit", async (e) => {
|
|
132
|
+
e.preventDefault();
|
|
133
|
+
|
|
134
|
+
const formData = new FormData(passwordUpdateForm);
|
|
135
|
+
|
|
136
|
+
const data = {
|
|
137
|
+
currentPassword: (formData.get("current-password")?.toString() ??
|
|
138
|
+
null) as string | null,
|
|
139
|
+
newPassword: formData.get("new-password")?.toString() as string,
|
|
140
|
+
confirmNewPassword: formData
|
|
141
|
+
.get("confirm-new-password")
|
|
142
|
+
?.toString() as string,
|
|
143
|
+
};
|
|
144
|
+
|
|
145
|
+
if (!data.newPassword || !data.confirmNewPassword) {
|
|
146
|
+
toast({
|
|
147
|
+
title: "Error",
|
|
148
|
+
description: "Please fill in all required fields",
|
|
149
|
+
type: "danger",
|
|
150
|
+
});
|
|
151
|
+
|
|
152
|
+
return;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
const response = await dashboardClient.pipe(
|
|
156
|
+
Effect.flatMap((client) =>
|
|
157
|
+
client.profile.updateUserProfile({
|
|
158
|
+
payload: {
|
|
159
|
+
mode: "password",
|
|
160
|
+
data,
|
|
161
|
+
},
|
|
162
|
+
}),
|
|
163
|
+
),
|
|
164
|
+
Effect.catchTags(dashboardSharedCatchTags),
|
|
165
|
+
Effect.runPromise,
|
|
166
|
+
);
|
|
167
|
+
|
|
168
|
+
if ("error" in response) {
|
|
169
|
+
toast({
|
|
170
|
+
title: "Error",
|
|
171
|
+
description: response.error,
|
|
172
|
+
type: "danger",
|
|
173
|
+
});
|
|
174
|
+
} else {
|
|
175
|
+
toast({
|
|
176
|
+
title: "Success",
|
|
177
|
+
description:
|
|
178
|
+
response.message || "Password updated successfully",
|
|
179
|
+
type: "success",
|
|
180
|
+
});
|
|
181
|
+
|
|
182
|
+
passwordUpdateForm.reset();
|
|
183
|
+
}
|
|
184
|
+
});
|
|
145
185
|
</script>
|
|
146
186
|
|
|
147
187
|
<style>
|