@baseplate-dev/plugin-auth 0.6.3 → 0.6.4
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 +18 -0
- package/dist/local-auth/core/components/local-auth-definition-editor.d.ts.map +1 -1
- package/dist/local-auth/core/components/local-auth-definition-editor.js +3 -2
- package/dist/local-auth/core/components/local-auth-definition-editor.js.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.d.ts +1 -0
- package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.js +7 -1
- package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.js.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/generated/index.d.ts +3 -1
- package/dist/local-auth/core/generators/auth-email-password/generated/index.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/generated/typed-templates.d.ts +6 -2
- package/dist/local-auth/core/generators/auth-email-password/generated/typed-templates.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/generated/typed-templates.js +1 -1
- package/dist/local-auth/core/generators/auth-email-password/generated/typed-templates.js.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/schema/user-password.mutations.js +5 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/schema/user-password.mutations.js.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/schema/user-password.mutations.ts +5 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.d.ts +2 -0
- package/dist/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.js +4 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.js.map +1 -1
- package/dist/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.ts +6 -1
- package/dist/local-auth/core/generators/auth-routes/auth-routes.generator.d.ts +4 -1
- package/dist/local-auth/core/generators/auth-routes/auth-routes.generator.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/auth-routes.generator.js +37 -4
- package/dist/local-auth/core/generators/auth-routes/auth-routes.generator.js.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/generated/index.d.ts +6 -4
- package/dist/local-auth/core/generators/auth-routes/generated/index.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/generated/typed-templates.d.ts +12 -8
- package/dist/local-auth/core/generators/auth-routes/generated/typed-templates.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/generated/typed-templates.js +5 -2
- package/dist/local-auth/core/generators/auth-routes/generated/typed-templates.js.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/templates/routes/auth_/login.js +1 -1
- package/dist/local-auth/core/generators/auth-routes/templates/routes/auth_/login.tsx +1 -1
- package/dist/local-auth/core/generators/auth-routes/templates/routes/auth_/register.d.ts.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/templates/routes/auth_/register.js +3 -10
- package/dist/local-auth/core/generators/auth-routes/templates/routes/auth_/register.js.map +1 -1
- package/dist/local-auth/core/generators/auth-routes/templates/routes/auth_/register.tsx +6 -10
- package/dist/local-auth/core/node.d.ts.map +1 -1
- package/dist/local-auth/core/node.js +6 -2
- package/dist/local-auth/core/node.js.map +1 -1
- package/dist/local-auth/core/schema/plugin-definition.d.ts +1 -0
- package/dist/local-auth/core/schema/plugin-definition.d.ts.map +1 -1
- package/dist/local-auth/core/schema/plugin-definition.js +1 -0
- package/dist/local-auth/core/schema/plugin-definition.js.map +1 -1
- package/dist/web/assets/{__federation_expose_authCoreCommon-CnNoa4tF.js → __federation_expose_authCoreCommon-D8SAyij-.js} +3 -3
- package/dist/web/assets/{__federation_expose_authCoreCommon-CnNoa4tF.js.map → __federation_expose_authCoreCommon-D8SAyij-.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_authCoreWeb-BL_U7yuj.js → __federation_expose_authCoreWeb-BSv8GVI2.js} +6 -6
- package/dist/web/assets/{__federation_expose_authCoreWeb-BL_U7yuj.js.map → __federation_expose_authCoreWeb-BSv8GVI2.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_better-authCoreCommon-D-mTcxYO.js → __federation_expose_better-authCoreCommon-BJhkN6zV.js} +3 -3
- package/dist/web/assets/{__federation_expose_better-authCoreCommon-D-mTcxYO.js.map → __federation_expose_better-authCoreCommon-BJhkN6zV.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_better-authCoreWeb-CXHL-Ghf.js → __federation_expose_better-authCoreWeb-2kA00dBg.js} +5 -5
- package/dist/web/assets/{__federation_expose_better-authCoreWeb-CXHL-Ghf.js.map → __federation_expose_better-authCoreWeb-2kA00dBg.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_local-authAdminCommon-LIsARRNU.js → __federation_expose_local-authAdminCommon-IuYupUXE.js} +2 -2
- package/dist/web/assets/{__federation_expose_local-authAdminCommon-LIsARRNU.js.map → __federation_expose_local-authAdminCommon-IuYupUXE.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_local-authAdminWeb-DyYUDLm9.js → __federation_expose_local-authAdminWeb-BzhksqwO.js} +2 -2
- package/dist/web/assets/{__federation_expose_local-authAdminWeb-DyYUDLm9.js.map → __federation_expose_local-authAdminWeb-BzhksqwO.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_local-authCoreCommon-p_UbExc7.js → __federation_expose_local-authCoreCommon-DO5xRAoM.js} +3 -3
- package/dist/web/assets/{__federation_expose_local-authCoreCommon-p_UbExc7.js.map → __federation_expose_local-authCoreCommon-DO5xRAoM.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_local-authCoreWeb-8TcUJFT6.js → __federation_expose_local-authCoreWeb-QdXa2aao.js} +23 -7
- package/dist/web/assets/__federation_expose_local-authCoreWeb-QdXa2aao.js.map +1 -0
- package/dist/web/assets/{__federation_expose_placeholder-authCoreCommon-CtZXaDUc.js → __federation_expose_placeholder-authCoreCommon-hGIPuBy3.js} +3 -3
- package/dist/web/assets/{__federation_expose_placeholder-authCoreCommon-CtZXaDUc.js.map → __federation_expose_placeholder-authCoreCommon-hGIPuBy3.js.map} +1 -1
- package/dist/web/assets/{__federation_expose_placeholder-authCoreWeb-CZAKokTb.js → __federation_expose_placeholder-authCoreWeb-P4Qq8Zf6.js} +5 -5
- package/dist/web/assets/{__federation_expose_placeholder-authCoreWeb-CZAKokTb.js.map → __federation_expose_placeholder-authCoreWeb-P4Qq8Zf6.js.map} +1 -1
- package/dist/web/assets/{__federation_fn_import-3DENgil8.js → __federation_fn_import-CzLgVaFb.js} +2 -2
- package/dist/web/assets/{__federation_fn_import-3DENgil8.js.map → __federation_fn_import-CzLgVaFb.js.map} +1 -1
- package/dist/web/assets/__federation_shared_@baseplate-dev/project-builder-lib/{web-B5bdbzFj.js → web-DA-fkeD5.js} +10 -8
- package/dist/web/assets/__federation_shared_@baseplate-dev/project-builder-lib/web-DA-fkeD5.js.map +1 -0
- package/dist/web/assets/__federation_shared_@baseplate-dev/{project-builder-lib-DCA3vO4J.js → project-builder-lib-zJirGIS1.js} +6 -6
- package/dist/web/assets/__federation_shared_@baseplate-dev/project-builder-lib-zJirGIS1.js.map +1 -0
- package/dist/web/assets/__federation_shared_@baseplate-dev/{ui-components-BvL7RO9S.js → ui-components-Ds8y9Suz.js} +7 -7
- package/dist/web/assets/__federation_shared_@baseplate-dev/{ui-components-BvL7RO9S.js.map → ui-components-Ds8y9Suz.js.map} +1 -1
- package/dist/web/assets/__federation_shared_@baseplate-dev/{utils-0-N5BG4T.js → utils-DnBM79-7.js} +2 -2
- package/dist/web/assets/__federation_shared_@baseplate-dev/{utils-0-N5BG4T.js.map → utils-DnBM79-7.js.map} +1 -1
- package/dist/web/assets/__federation_shared_@tanstack/{react-router-DSniiJ6U.js → react-router-BoEohCHh.js} +2 -2
- package/dist/web/assets/__federation_shared_@tanstack/{react-router-DSniiJ6U.js.map → react-router-BoEohCHh.js.map} +1 -1
- package/dist/web/assets/{get-auth-plugin-definition-DHcbFujw.js → get-auth-plugin-definition-DM6kosCC.js} +2 -2
- package/dist/web/assets/{get-auth-plugin-definition-DHcbFujw.js.map → get-auth-plugin-definition-DM6kosCC.js.map} +1 -1
- package/dist/web/assets/{index-DQKNnI1w.js → index-EshpyU4T.js} +2 -2
- package/dist/web/assets/{index-DQKNnI1w.js.map → index-EshpyU4T.js.map} +1 -1
- package/dist/web/assets/{index.esm-Dpqxgpya.js → index.esm-CYY7gyrG.js} +2 -2
- package/dist/web/assets/{index.esm-Dpqxgpya.js.map → index.esm-CYY7gyrG.js.map} +1 -1
- package/dist/web/assets/{model-utils-BFX3c3dn.js → model-utils-WWo9T1Zx.js} +30 -2
- package/dist/web/assets/{model-utils-BFX3c3dn.js.map → model-utils-WWo9T1Zx.js.map} +1 -1
- package/dist/web/assets/{plugin-definition-CEQb6mWV.js → plugin-definition-BCrs3YSY.js} +2 -2
- package/dist/web/assets/{plugin-definition-CEQb6mWV.js.map → plugin-definition-BCrs3YSY.js.map} +1 -1
- package/dist/web/assets/{plugin-definition-DrsKbcJc.js → plugin-definition-BwAJGzRn.js} +4 -3
- package/dist/web/assets/plugin-definition-BwAJGzRn.js.map +1 -0
- package/dist/web/assets/{plugin-definition-KEpaSB6p.js → plugin-definition-CqP9VmOQ.js} +2 -2
- package/dist/web/assets/{plugin-definition-KEpaSB6p.js.map → plugin-definition-CqP9VmOQ.js.map} +1 -1
- package/dist/web/assets/{plugin-definition-B86WQ7Ni.js → plugin-definition-y6VVQ5_O.js} +2 -2
- package/dist/web/assets/{plugin-definition-B86WQ7Ni.js.map → plugin-definition-y6VVQ5_O.js.map} +1 -1
- package/dist/web/assets/{react-hu8Hx0R4.js → react-B6Fz4KB7.js} +2 -2
- package/dist/web/assets/{react-hu8Hx0R4.js.map → react-B6Fz4KB7.js.map} +1 -1
- package/dist/web/assets/remoteEntry.js +10 -10
- package/dist/web/assets/{styles-CpKtlIgU.js → styles-0yxEwdyo.js} +3 -3
- package/dist/web/assets/{styles-CpKtlIgU.js.map → styles-0yxEwdyo.js.map} +1 -1
- package/package.json +12 -12
- package/dist/web/assets/__federation_expose_local-authCoreWeb-8TcUJFT6.js.map +0 -1
- package/dist/web/assets/__federation_shared_@baseplate-dev/project-builder-lib/web-B5bdbzFj.js.map +0 -1
- package/dist/web/assets/__federation_shared_@baseplate-dev/project-builder-lib-DCA3vO4J.js.map +0 -1
- package/dist/web/assets/plugin-definition-DrsKbcJc.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @baseplate-dev/plugin-auth
|
|
2
2
|
|
|
3
|
+
## 0.6.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#836](https://github.com/halfdomelabs/baseplate/pull/836) [`9369fd4`](https://github.com/halfdomelabs/baseplate/commit/9369fd4e38f2eaf370ac37b8bca8f552845d0f9c) Thanks [@kingston](https://github.com/kingston)! - Add `requireNameOnRegistration` option to local auth plugin. When enabled, the registration form collects and requires a name field from users.
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`ba315aa`](https://github.com/halfdomelabs/baseplate/commit/ba315aaaec0e8842ec7fadb765b1fed5e3abda5a), [`ba315aa`](https://github.com/halfdomelabs/baseplate/commit/ba315aaaec0e8842ec7fadb765b1fed5e3abda5a), [`ba315aa`](https://github.com/halfdomelabs/baseplate/commit/ba315aaaec0e8842ec7fadb765b1fed5e3abda5a)]:
|
|
10
|
+
- @baseplate-dev/ui-components@0.6.4
|
|
11
|
+
- @baseplate-dev/project-builder-lib@0.6.4
|
|
12
|
+
- @baseplate-dev/plugin-rate-limit@0.6.4
|
|
13
|
+
- @baseplate-dev/plugin-email@0.6.4
|
|
14
|
+
- @baseplate-dev/plugin-queue@0.6.4
|
|
15
|
+
- @baseplate-dev/core-generators@0.6.4
|
|
16
|
+
- @baseplate-dev/fastify-generators@0.6.4
|
|
17
|
+
- @baseplate-dev/react-generators@0.6.4
|
|
18
|
+
- @baseplate-dev/sync@0.6.4
|
|
19
|
+
- @baseplate-dev/utils@0.6.4
|
|
20
|
+
|
|
3
21
|
## 0.6.3
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"local-auth-definition-editor.d.ts","sourceRoot":"","sources":["../../../../src/local-auth/core/components/local-auth-definition-editor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACzE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"local-auth-definition-editor.d.ts","sourceRoot":"","sources":["../../../../src/local-auth/core/components/local-auth-definition-editor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACzE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAoC/B,OAAO,iBAAiB,CAAC;AAEzB,wBAAgB,yBAAyB,CAAC,EACxC,UAAU,EAAE,cAAc,EAC1B,QAAQ,EACR,MAAM,GACP,EAAE,cAAc,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAyLpC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { applyMergedDefinition, diffDefinition, PluginUtils, } from '@baseplate-dev/project-builder-lib';
|
|
3
3
|
import { DefinitionDiffAlert, useBlockUnsavedChangesNavigate, useDefinitionSchema, useProjectDefinition, useResettableForm, } from '@baseplate-dev/project-builder-lib/web';
|
|
4
|
-
import { FormActionBar, MultiComboboxFieldController, SectionList, SectionListSection, SectionListSectionContent, SectionListSectionDescription, SectionListSectionHeader, SectionListSectionTitle, } from '@baseplate-dev/ui-components';
|
|
4
|
+
import { FormActionBar, MultiComboboxFieldController, SectionList, SectionListSection, SectionListSectionContent, SectionListSectionDescription, SectionListSectionHeader, SectionListSectionTitle, SwitchFieldController, } from '@baseplate-dev/ui-components';
|
|
5
5
|
import { zodResolver } from '@hookform/resolvers/zod';
|
|
6
6
|
import { useMemo } from 'react';
|
|
7
7
|
import { getAuthPluginDefinition } from '#src/auth/utils/get-auth-plugin-definition.js';
|
|
@@ -26,6 +26,7 @@ export function LocalAuthDefinitionEditor({ definition: pluginMetadata, metadata
|
|
|
26
26
|
return {
|
|
27
27
|
initialUserRoles: [],
|
|
28
28
|
userAdminRoles: [],
|
|
29
|
+
requireNameOnRegistration: false,
|
|
29
30
|
};
|
|
30
31
|
}, [pluginMetadata?.config]);
|
|
31
32
|
const form = useResettableForm({
|
|
@@ -54,6 +55,6 @@ export function LocalAuthDefinitionEditor({ definition: pluginMetadata, metadata
|
|
|
54
55
|
useBlockUnsavedChangesNavigate({ control, reset, onSubmit });
|
|
55
56
|
return (_jsxs("div", { className: "auth:relative auth:flex auth:h-full auth:flex-1 auth:flex-col auth:gap-4 auth:overflow-hidden", children: [_jsx(AuthConfigTabs, {}), _jsx("div", { className: "auth:mb-[--action-bar-height] auth:flex auth:flex-1 auth:overflow-y-auto", style: {
|
|
56
57
|
'--action-bar-height': '52px',
|
|
57
|
-
}, children: _jsxs("form", { onSubmit: onSubmit, className: "auth:max-w-6xl auth:flex-1", children: [_jsx("div", { className: "auth:pb-16", children: _jsxs(SectionList, { children: [_jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "Local Auth User Models" }), _jsx(SectionListSectionDescription, { children: "The plugin will automatically configure the models it needs." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(DefinitionDiffAlert, { diff: diff, upToDateMessage: "All required models are already configured correctly. No changes needed." }) })] }), _jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "Initial User Setup" }), _jsx(SectionListSectionDescription, { children: "In order to access the admin panel, an initial user must be created. To make it easier, the plugin will automatically add a seed script to create the initial user provided a .seed.env exists with the INTIIAL_USER_EMAIL and INTIIAL_USER_PASSWORD variables." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(MultiComboboxFieldController, { label: "Initial User Roles", name: "initialUserRoles", control: control, options: roles, description: "The roles that will be assigned to the initial user." }) })] }), _jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "User Management Permissions" }), _jsx(SectionListSectionDescription, { children: "Configure which roles can manage users and assign roles to other users in the admin interface." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(MultiComboboxFieldController, { label: "User Admin Roles", name: "userAdminRoles", control: control, options: roles, description: "Roles that can manage users and assign roles to other users." }) })] })] }) }), _jsx(FormActionBar, { form: form, allowSaveWithoutDirty: !pluginMetadata || diff.hasChanges })] }) })] }));
|
|
58
|
+
}, children: _jsxs("form", { onSubmit: onSubmit, className: "auth:max-w-6xl auth:flex-1", children: [_jsx("div", { className: "auth:pb-16", children: _jsxs(SectionList, { children: [_jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "Local Auth User Models" }), _jsx(SectionListSectionDescription, { children: "The plugin will automatically configure the models it needs." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(DefinitionDiffAlert, { diff: diff, upToDateMessage: "All required models are already configured correctly. No changes needed." }) })] }), _jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "Initial User Setup" }), _jsx(SectionListSectionDescription, { children: "In order to access the admin panel, an initial user must be created. To make it easier, the plugin will automatically add a seed script to create the initial user provided a .seed.env exists with the INTIIAL_USER_EMAIL and INTIIAL_USER_PASSWORD variables." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(MultiComboboxFieldController, { label: "Initial User Roles", name: "initialUserRoles", control: control, options: roles, description: "The roles that will be assigned to the initial user." }) })] }), _jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "User Management Permissions" }), _jsx(SectionListSectionDescription, { children: "Configure which roles can manage users and assign roles to other users in the admin interface." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(MultiComboboxFieldController, { label: "User Admin Roles", name: "userAdminRoles", control: control, options: roles, description: "Roles that can manage users and assign roles to other users." }) })] }), _jsxs(SectionListSection, { children: [_jsxs(SectionListSectionHeader, { children: [_jsx(SectionListSectionTitle, { children: "Registration Settings" }), _jsx(SectionListSectionDescription, { children: "Configure what information is collected during user registration." })] }), _jsx(SectionListSectionContent, { className: "auth:space-y-6", children: _jsx(SwitchFieldController, { label: "Require Name on Registration", name: "requireNameOnRegistration", control: control, description: "When enabled, users must provide their name when registering." }) })] })] }) }), _jsx(FormActionBar, { form: form, allowSaveWithoutDirty: !pluginMetadata || diff.hasChanges })] }) })] }));
|
|
58
59
|
}
|
|
59
60
|
//# sourceMappingURL=local-auth-definition-editor.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"local-auth-definition-editor.js","sourceRoot":"","sources":["../../../../src/local-auth/core/components/local-auth-definition-editor.tsx"],"names":[],"mappings":";AAGA,OAAO,EACL,qBAAqB,EACrB,cAAc,EACd,WAAW,GACZ,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EACL,mBAAmB,EACnB,8BAA8B,EAC9B,mBAAmB,EACnB,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACL,aAAa,EACb,4BAA4B,EAC5B,WAAW,EACX,kBAAkB,EAClB,yBAAyB,EACzB,6BAA6B,EAC7B,wBAAwB,EACxB,uBAAuB,
|
|
1
|
+
{"version":3,"file":"local-auth-definition-editor.js","sourceRoot":"","sources":["../../../../src/local-auth/core/components/local-auth-definition-editor.tsx"],"names":[],"mappings":";AAGA,OAAO,EACL,qBAAqB,EACrB,cAAc,EACd,WAAW,GACZ,MAAM,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AC3B,KAAC,yBAAyB,IAAC,SAAS,EAAC,gBAAgB,YACnD,KAAC,4BAA4B,IAC3B,KAAK,EAAC,kBAAkB,EACxB,IAAI,EAAC,gBAAgB,EACrB,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,KAAK,EACd,WAAW,EAAC,8DAA8D,GAC1E,GACwB,IACT,EACrB,MAAC,kBAAkB,eACjB,MAAC,wBAAwB,eACvB,KAAC,uBAAuB,wCAEE,EAC1B,KAAC,6BAA6B,oFAGE,IACP,EAC3B,KAAC,yBAAyB,IAAC,SAAS,EAAC,gBAAgB,YACnD,KAAC,qBAAqB,IACpB,KAAK,EAAC,8BAA8B,EACpC,IAAI,EAAC,2BAA2B,EAChC,OAAO,EAAE,OAAO,EAChB,WAAW,EAAC,+DAA+D,GAC3E,GACwB,IACT,IACT,GACV,EAEN,KAAC,aAAa,IACZ,IAAI,EAAE,IAAI,EACV,qBAAqB,EAAE,CAAC,cAAc,IAAI,IAAI,CAAC,UAAU,GACzD,IACG,GACH,IACF,CACP,CAAC;AACJ,CAAC"}
|
package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.d.ts
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
export declare const authEmailPasswordGenerator: import("@baseplate-dev/sync").GeneratorBundleCreator<{
|
|
5
5
|
adminRoles: string[];
|
|
6
6
|
devWebDomainPort: number;
|
|
7
|
+
requireNameOnRegistration: boolean;
|
|
7
8
|
}, {
|
|
8
9
|
paths: import("@baseplate-dev/sync").GeneratorTask<{
|
|
9
10
|
localAuthCoreAuthEmailPasswordPaths: import("@baseplate-dev/sync").ProviderExport<import("./generated/template-paths.js").LocalAuthCoreAuthEmailPasswordPaths>;
|
package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-email-password.generator.d.ts","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-email-password/auth-email-password.generator.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"auth-email-password.generator.d.ts","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-email-password/auth-email-password.generator.ts"],"names":[],"mappings":"AA0BA;;GAEG;AACH,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiGrC,CAAC"}
|
package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.js
CHANGED
|
@@ -9,6 +9,7 @@ import { LOCAL_AUTH_CORE_AUTH_EMAIL_PASSWORD_GENERATED as GENERATED_TEMPLATES }
|
|
|
9
9
|
const descriptorSchema = z.object({
|
|
10
10
|
adminRoles: z.array(z.string()),
|
|
11
11
|
devWebDomainPort: z.number(),
|
|
12
|
+
requireNameOnRegistration: z.boolean(),
|
|
12
13
|
});
|
|
13
14
|
/**
|
|
14
15
|
* Sets up email / password authentication
|
|
@@ -17,7 +18,7 @@ export const authEmailPasswordGenerator = createGenerator({
|
|
|
17
18
|
name: 'local-auth/core/auth-email-password',
|
|
18
19
|
generatorFileUrl: import.meta.url,
|
|
19
20
|
descriptorSchema,
|
|
20
|
-
buildTasks: ({ adminRoles, devWebDomainPort }) => ({
|
|
21
|
+
buildTasks: ({ adminRoles, devWebDomainPort, requireNameOnRegistration, }) => ({
|
|
21
22
|
paths: GENERATED_TEMPLATES.paths.task,
|
|
22
23
|
imports: GENERATED_TEMPLATES.imports.task,
|
|
23
24
|
renderers: GENERATED_TEMPLATES.renderers.task,
|
|
@@ -59,6 +60,11 @@ export const authEmailPasswordGenerator = createGenerator({
|
|
|
59
60
|
TPL_PASSWORD_RESET_EMAIL: TsCodeUtils.importFragment('PasswordResetEmail', transactionalLibPackageName),
|
|
60
61
|
TPL_PASSWORD_CHANGED_EMAIL: TsCodeUtils.importFragment('PasswordChangedEmail', transactionalLibPackageName),
|
|
61
62
|
},
|
|
63
|
+
servicesUserPassword: {
|
|
64
|
+
TPL_NAME_REQUIRED_CHECK: requireNameOnRegistration
|
|
65
|
+
? tsCodeFragment("if (!name) {\n throw new BadRequestError('Name is required', 'name-required');\n }")
|
|
66
|
+
: '',
|
|
67
|
+
},
|
|
62
68
|
},
|
|
63
69
|
}));
|
|
64
70
|
await builder.apply(renderers.servicesEmailVerification.render({
|
package/dist/local-auth/core/generators/auth-email-password/auth-email-password.generator.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-email-password.generator.js","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-email-password/auth-email-password.generator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAC7E,OAAO,EACL,iBAAiB,EACjB,qBAAqB,EACrB,sCAAsC,EACtC,wBAAwB,GACzB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,8BAA8B,EAAE,MAAM,6BAA6B,CAAC;AAC7E,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,kBAAkB,GACnB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAE7E,OAAO,EAAE,6CAA6C,IAAI,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAE5G,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IAChC,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC;IAC/B,gBAAgB,EAAE,CAAC,CAAC,MAAM,EAAE;
|
|
1
|
+
{"version":3,"file":"auth-email-password.generator.js","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth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AAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAC1C;oCACD,oBAAoB,EAClB,cAAc,CAAC,gBAAgB,EAAE,CAAC,QAAQ;iCAC7C;gCACD,qBAAqB,EAAE;oCACrB,wBAAwB,EAAE,WAAW,CAAC,cAAc,CAClD,oBAAoB,EACpB,2BAA2B,CAC5B;oCACD,0BAA0B,EAAE,WAAW,CAAC,cAAc,CACpD,sBAAsB,EACtB,2BAA2B,CAC5B;iCACF;gCACD,oBAAoB,EAAE;oCACpB,uBAAuB,EAAE,yBAAyB;wCAChD,CAAC,CAAC,cAAc,CACZ,wFAAwF,CACzF;wCACH,CAAC,CAAC,EAAE;iCACP;6BACF;yBACF,CAAC,CACH,CAAC;wBACF,MAAM,OAAO,CAAC,KAAK,CACjB,SAAS,CAAC,yBAAyB,CAAC,MAAM,CAAC;4BACzC,SAAS,EAAE;gCACT,8BAA8B,EAAE,WAAW,CAAC,cAAc,CACxD,0BAA0B,EAC1B,2BAA2B,CAC5B;6BACF;yBACF,CAAC,CACH,CAAC;wBACF,MAAM,OAAO,CAAC,KAAK,CACjB,SAAS,CAAC,gCAAgC,CAAC,MAAM,CAAC,EAAE,CAAC,CACtD,CAAC;oBACJ,CAAC;iBACF,CAAC;YACJ,CAAC;SACF,CAAC;KACH,CAAC;CACH,CAAC,CAAC"}
|
|
@@ -219,7 +219,9 @@ export declare const LOCAL_AUTH_CORE_AUTH_EMAIL_PASSWORD_GENERATED: {
|
|
|
219
219
|
}, {
|
|
220
220
|
constantsPassword: {};
|
|
221
221
|
}>;
|
|
222
|
-
servicesUserPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
222
|
+
servicesUserPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
223
|
+
TPL_NAME_REQUIRED_CHECK: {};
|
|
224
|
+
}, {
|
|
223
225
|
errorHandlerServiceImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
224
226
|
BadRequestError: {};
|
|
225
227
|
ForbiddenError: {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-email-password/generated/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,6CAA6C
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-email-password/generated/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,6CAA6C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAKzD,CAAC"}
|
|
@@ -96,7 +96,9 @@ export declare const moduleGroup: {
|
|
|
96
96
|
}, {
|
|
97
97
|
constantsPassword: {};
|
|
98
98
|
}>;
|
|
99
|
-
servicesUserPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
99
|
+
servicesUserPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
100
|
+
TPL_NAME_REQUIRED_CHECK: {};
|
|
101
|
+
}, {
|
|
100
102
|
errorHandlerServiceImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
101
103
|
BadRequestError: {};
|
|
102
104
|
ForbiddenError: {};
|
|
@@ -255,7 +257,9 @@ export declare const LOCAL_AUTH_CORE_AUTH_EMAIL_PASSWORD_TEMPLATES: {
|
|
|
255
257
|
}, {
|
|
256
258
|
constantsPassword: {};
|
|
257
259
|
}>;
|
|
258
|
-
servicesUserPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
260
|
+
servicesUserPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
261
|
+
TPL_NAME_REQUIRED_CHECK: {};
|
|
262
|
+
}, {
|
|
259
263
|
errorHandlerServiceImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
260
264
|
BadRequestError: {};
|
|
261
265
|
ForbiddenError: {};
|
package/dist/local-auth/core/generators/auth-email-password/generated/typed-templates.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typed-templates.d.ts","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-email-password/generated/typed-templates.ts"],"names":[],"mappings":"AAoIA,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"typed-templates.d.ts","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-email-password/generated/typed-templates.ts"],"names":[],"mappings":"AAoIA,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAMvB,CAAC;AAsCF,eAAO,MAAM,6CAA6C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAIzD,CAAC"}
|
|
@@ -96,7 +96,7 @@ const servicesUserPassword = createTsTemplateFile({
|
|
|
96
96
|
source: {
|
|
97
97
|
path: path.join(import.meta.dirname, '../templates/module/services/user-password.service.ts'),
|
|
98
98
|
},
|
|
99
|
-
variables: {},
|
|
99
|
+
variables: { TPL_NAME_REQUIRED_CHECK: {} },
|
|
100
100
|
});
|
|
101
101
|
export const moduleGroup = {
|
|
102
102
|
constantsPassword,
|
package/dist/local-auth/core/generators/auth-email-password/generated/typed-templates.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typed-templates.js","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-email-password/generated/typed-templates.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,EACL,4BAA4B,EAC5B,kCAAkC,EAClC,oCAAoC,EACpC,qBAAqB,EACrB,8BAA8B,EAC9B,qBAAqB,EACrB,oCAAoC,EACpC,iCAAiC,EACjC,+BAA+B,GAChC,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAC;AACzE,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,yBAAyB,EAAE,MAAM,8EAA8E,CAAC;AAEzH,MAAM,iBAAiB,GAAG,oBAAoB,CAAC;IAC7C,WAAW,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE;IAClC,KAAK,EAAE,QAAQ;IACf,kBAAkB,EAAE,EAAE;IACtB,IAAI,EAAE,oBAAoB;IAC1B,cAAc,EAAE;QACd,mBAAmB,EAAE,EAAE;QACvB,mBAAmB,EAAE,EAAE;QACvB,+BAA+B,EAAE,EAAE;KACpC;IACD,MAAM,EAAE;QACN,IAAI,EAAE,IAAI,CAAC,IAAI,CACb,MAAM,CAAC,IAAI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AI,CAAC,IAAI,CACb,MAAM,CAAC,IAAI,CAAC,OAAO,EACnB,uDAAuD,CACxD;KACF;IACD,SAAS,EAAE,EAAE;
|
|
1
|
+
{"version":3,"file":"typed-templates.js","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-email-password/generated/typed-templates.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,EACL,4BAA4B,EAC5B,kCAAkC,EAClC,oCAAoC,EACpC,qBAAqB,EACrB,8BAA8B,EAC9B,qBAAqB,EACrB,oCAAoC,EACpC,iCAAiC,EACjC,+BAA+B,GAChC,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,0BAA0B,EAAE,MAAM,6BAA6B,CAAC;AACzE,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,yBAAyB,EAAE,MAAM,8EAA8E,CAAC;AAEzH,MAAM,iBAAiB,GAAG,oBAAoB,CAAC;IAC7C,WAAW,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE;IAClC,KAAK,EAAE,QAAQ;IACf,kBAAkB,EAAE,EAAE;IACtB,IAAI,EAAE,oBAAoB;IAC1B,cAAc,EAAE;QACd,mBAAmB,EAAE,EAAE;QACvB,mBAAmB,EAAE,EAAE;QACvB,+BAA+B,EAAE,EAAE;KACpC;IACD,MAAM,EAAE;QACN,IAAI,EAAE,IAAI,CAAC,IAAI,CACb,MAAM,CAAC,IAAI,CAAC,OAAO,EACnB,qDAAqD,CACtD;KACF;IACD,SAAS,EAAE,EAAE;CACd,CAAC,CAAC;AAEH,MAAM,4BAA4B,GAAG,oBAAoB,CAAC;IACxD,WAAW,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE;IAClC,KAAK,EAAE,QAAQ;IACf,kBAAkB,EAAE,EAAE,aAAa,EAAE,qBAAqB,EAAE;IAC5D,IAAI,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rB,CAAC;AAEF,MAAM,gCAAgC,GAAG,oBAAoB,CAAC;IAC5D,WAAW,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE;IAClC,kBAAkB,EAAE,EAAE,aAAa,EAAE,qBAAqB,EAAE;IAC5D,IAAI,EAAE,qCAAqC;IAC3C,4BAA4B,EAAE,EAAE,yBAAyB,EAAE,EAAE,EAAE;IAC/D,MAAM,EAAE;QACN,IAAI,EAAE,IAAI,CAAC,IAAI,CACb,MAAM,CAAC,IAAI,CAAC,OAAO,EACnB,4DAA4D,CAC7D;KACF;IACD,SAAS,EAAE,EAAE;CACd,CAAC,CAAC;AAEH,MAAM,yBAAyB,GAAG,oBAAoB,CAAC;IACrD,WAAW,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE;IAClC,kBAAkB,EAAE;QAClB,iBAAiB,EAAE,yBAAyB;QAC5C,oBAAoB,EAAE,4BAA4B;QAClD,kBAAkB,EAAE,0BAA0B;QAC9C,0BAA0B,EAAE,kCAAkC;QAC9D,aAAa,EAAE,qBAAqB;QACpC,gBAAgB,EAAE,wBAAwB;QAC1C,4BAA4B,EAAE,oCAAoC;KACnE;IACD,IAAI,EAAE,6BAA6B;IACnC,4BAA4B,EAAE,EAAE,iBAAiB,EAAE,EAAE,EAAE;IACvD,MAAM,EAAE;QACN,IAAI,EAAE,IAAI,CAAC,IAAI,CACb,MAAM,CAAC,IAAI,CAAC,OAAO,EACnB,4DAA4D,CAC7D;KACF;IACD,SAAS,EAAE,EAAE,8BAA8B,EAAE,EAAE,EAAE;CAClD,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,6CAA6C,GAAG;IAC3D,WAAW;IACX,gCAAgC;IAChC,yBAAyB;CAC1B,CAAC"}
|
|
@@ -9,10 +9,14 @@ builder.mutationField('registerWithEmailPassword', (t) => t.fieldWithInputPayloa
|
|
|
9
9
|
},
|
|
10
10
|
input: {
|
|
11
11
|
email: t.input.field({ required: true, type: 'String' }),
|
|
12
|
+
name: t.input.field({ required: false, type: 'String' }),
|
|
12
13
|
password: t.input.field({ required: true, type: 'String' }),
|
|
13
14
|
},
|
|
14
15
|
resolve: async (root, { input }, context) => registerUserWithEmailAndPassword({
|
|
15
|
-
input
|
|
16
|
+
input: {
|
|
17
|
+
...input,
|
|
18
|
+
name: input.name ?? undefined,
|
|
19
|
+
},
|
|
16
20
|
context,
|
|
17
21
|
}),
|
|
18
22
|
}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-password.mutations.js","sourceRoot":"","sources":["../../../../../../../../src/local-auth/core/generators/auth-email-password/templates/module/schema/user-password.mutations.ts"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,EACL,oCAAoC,EACpC,kBAAkB,EAClB,gCAAgC,EAChC,iBAAiB,GAClB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEzC,OAAO,CAAC,aAAa,CAAC,2BAA2B,EAAE,CAAC,CAAC,EAAE,EAAE,CACvD,CAAC,CAAC,qBAAqB,CAAC;IACtB,SAAS,EAAE,CAAC,QAAQ,CAAC;IACrB,OAAO,EAAE;QACP,OAAO,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,IAAI,EAAE,kBAAkB,EAAE,CAAC;KACvD;IACD,KAAK,EAAE;QACL,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;QACxD,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;KAC5D;IACD,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,CAC1C,gCAAgC,CAAC;QAC/B,KAAK;
|
|
1
|
+
{"version":3,"file":"user-password.mutations.js","sourceRoot":"","sources":["../../../../../../../../src/local-auth/core/generators/auth-email-password/templates/module/schema/user-password.mutations.ts"],"names":[],"mappings":"AAAA,cAAc;AAEd,OAAO,EACL,oCAAoC,EACpC,kBAAkB,EAClB,gCAAgC,EAChC,iBAAiB,GAClB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEzC,OAAO,CAAC,aAAa,CAAC,2BAA2B,EAAE,CAAC,CAAC,EAAE,EAAE,CACvD,CAAC,CAAC,qBAAqB,CAAC;IACtB,SAAS,EAAE,CAAC,QAAQ,CAAC;IACrB,OAAO,EAAE;QACP,OAAO,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,IAAI,EAAE,kBAAkB,EAAE,CAAC;KACvD;IACD,KAAK,EAAE;QACL,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;QACxD,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;QACxD,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;KAC5D;IACD,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,CAC1C,gCAAgC,CAAC;QAC/B,KAAK,EAAE;YACL,GAAG,KAAK;YACR,IAAI,EAAE,KAAK,CAAC,IAAI,IAAI,SAAS;SAC9B;QACD,OAAO;KACR,CAAC;CACL,CAAC,CACH,CAAC;AAEF,OAAO,CAAC,aAAa,C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,EAAE;QAC3C,MAAM,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,aAAa,EAAE,CAAC;QAC5C,MAAM,IAAI,GAAG,MAAM,kBAAkB,CAAC;YACpC,MAAM;YACN,KAAK;SACN,CAAC,CAAC;QACH,OAAO,EAAE,IAAI,EAAE,CAAC;IAClB,CAAC;CACF,CAAC,CACH,CAAC;AAEF,OAAO,CAAC,aAAa,CAAC,mBAAmB,EAAE,CAAC,CAAC,EAAE,EAAE,CAC/C,CAAC,CAAC,qBAAqB,CAAC;IACtB,SAAS,EAAE,eAAe;IAC1B,OAAO,EAAE;QACP,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC;YACpB,IAAI,EAAE,oBAAoB;SAC3B,CAAC;KACH;IACD,KAAK,EAAE;QACL,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;QACvD,WAAW,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;KAC/D;IACD,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE;QAClC,MAAM,IAAI,GAAG,MAAM,iBAAiB,CAAC;YACnC,MAAM,EAAE,KAAK,CAAC,MAAM;YACpB,KAAK,EAAE,EAAE,WAAW,EAAE,KAAK,CAAC,WAAW,EAAE;SAC1C,CAAC,CAAC;QACH,OAAO,EAAE,IAAI,EAAE,CAAC;IAClB,CAAC;CACF,CAAC,CACH,CAAC"}
|
|
@@ -17,11 +17,15 @@ builder.mutationField('registerWithEmailPassword', (t) =>
|
|
|
17
17
|
},
|
|
18
18
|
input: {
|
|
19
19
|
email: t.input.field({ required: true, type: 'String' }),
|
|
20
|
+
name: t.input.field({ required: false, type: 'String' }),
|
|
20
21
|
password: t.input.field({ required: true, type: 'String' }),
|
|
21
22
|
},
|
|
22
23
|
resolve: async (root, { input }, context) =>
|
|
23
24
|
registerUserWithEmailAndPassword({
|
|
24
|
-
input
|
|
25
|
+
input: {
|
|
26
|
+
...input,
|
|
27
|
+
name: input.name ?? undefined,
|
|
28
|
+
},
|
|
25
29
|
context,
|
|
26
30
|
}),
|
|
27
31
|
}),
|
|
@@ -5,12 +5,14 @@ export declare function createUserWithEmailAndPassword({ input, }: {
|
|
|
5
5
|
input: {
|
|
6
6
|
email: string;
|
|
7
7
|
password: string;
|
|
8
|
+
name?: string;
|
|
8
9
|
};
|
|
9
10
|
}): Promise<User>;
|
|
10
11
|
export declare function registerUserWithEmailAndPassword({ input, context, }: {
|
|
11
12
|
input: {
|
|
12
13
|
email: string;
|
|
13
14
|
password: string;
|
|
15
|
+
name?: string;
|
|
14
16
|
};
|
|
15
17
|
context: RequestServiceContext;
|
|
16
18
|
}): Promise<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-password.service.d.ts","sourceRoot":"","sources":["../../../../../../../../src/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,yBAAyB,CAAC;AACpD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAC3E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"user-password.service.d.ts","sourceRoot":"","sources":["../../../../../../../../src/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,yBAAyB,CAAC;AACpD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,+BAA+B,CAAC;AAC3E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAwDnE,wBAAsB,8BAA8B,CAAC,EACnD,KAAK,GACN,EAAE;IAC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z.object({
|
|
|
14
14
|
.max(PASSWORD_MAX_LENGTH)
|
|
15
15
|
.transform((value) => value.toLowerCase()),
|
|
16
16
|
password: z.string().min(PASSWORD_MIN_LENGTH).max(PASSWORD_MAX_LENGTH),
|
|
17
|
+
name: z.string().min(1).max(100).optional(),
|
|
17
18
|
});
|
|
18
19
|
/**
|
|
19
20
|
* Rate limiters for authentication operations.
|
|
@@ -34,9 +35,10 @@ const getLoginConsecutiveFailsLimiter = memoizeRateLimiter('login-consecutive-fa
|
|
|
34
35
|
blockDuration: 60 * 15, // Block for 15 minutes after 5 consecutive fails
|
|
35
36
|
});
|
|
36
37
|
export async function createUserWithEmailAndPassword({ input, }) {
|
|
37
|
-
const { email, password } = await emailPasswordSchema
|
|
38
|
+
const { email, password, name } = await emailPasswordSchema
|
|
38
39
|
.parseAsync(input)
|
|
39
40
|
.catch(handleZodRequestValidationError);
|
|
41
|
+
TPL_NAME_REQUIRED_CHECK;
|
|
40
42
|
// check if user with that email already exists
|
|
41
43
|
const existingUser = await prisma.userAccount.findUnique({
|
|
42
44
|
where: {
|
|
@@ -53,6 +55,7 @@ export async function createUserWithEmailAndPassword({ input, }) {
|
|
|
53
55
|
const user = await prisma.user.create({
|
|
54
56
|
data: {
|
|
55
57
|
email,
|
|
58
|
+
name,
|
|
56
59
|
accounts: {
|
|
57
60
|
create: {
|
|
58
61
|
accountId: email,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-password.service.js","sourceRoot":"","sources":["../../../../../../../../src/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.ts"],"names":[],"mappings":"AAAA,cAAc;AAMd,OAAO,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACtE,OAAO,EACL,eAAe,EACf,+BAA+B,EAC/B,QAAQ,EACR,aAAa,EACb,oBAAoB,GACrB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,kBAAkB,EAClB,kBAAkB,GACnB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AACxC,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,MAAM,WAAW,GAAG,gBAAgB,CAAC;AAErC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IACnC,KAAK,EAAE,CAAC;SACL,KAAK,EAAE;SACP,GAAG,CAAC,mBAAmB,CAAC;SACxB,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC;IAC5C,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC,GAAG,CAAC,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"user-password.service.js","sourceRoot":"","sources":["../../../../../../../../src/local-auth/core/generators/auth-email-password/templates/module/services/user-password.service.ts"],"names":[],"mappings":"AAAA,cAAc;AAMd,OAAO,EAAE,mBAAmB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAC9E,OAAO,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACtE,OAAO,EACL,eAAe,EACf,+BAA+B,EAC/B,QAAQ,EACR,aAAa,EACb,oBAAoB,GACrB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,kBAAkB,EAClB,kBAAkB,GACnB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AACxC,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,MAAM,WAAW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AAkB,CAAC,WAAW,CAAC,CAAC;IAC3D,MAAM,MAAM,CAAC,WAAW,CAAC,MAAM,CAAC;QAC9B,KAAK,EAAE;YACL,oBAAoB,EAAE;gBACpB,SAAS,EAAE,IAAI,CAAC,KAAK;gBACrB,UAAU,EAAE,WAAW;aACxB;SACF;QACD,MAAM,EAAE;YACN,IAAI,EAAE;gBACJ,OAAO,EAAE;oBACP,EAAE,EAAE,MAAM;iBACX;aACF;YACD,SAAS,EAAE,IAAI,CAAC,KAAK;YACrB,UAAU,EAAE,WAAW;YACvB,QAAQ,EAAE,YAAY;SACvB;QACD,MAAM,EAAE;YACN,QAAQ,EAAE,YAAY;SACvB;KACF,CAAC,CAAC;IAEH,OAAO,IAAI,CAAC;AACd,CAAC"}
|
|
@@ -30,6 +30,7 @@ const emailPasswordSchema = z.object({
|
|
|
30
30
|
.max(PASSWORD_MAX_LENGTH)
|
|
31
31
|
.transform((value) => value.toLowerCase()),
|
|
32
32
|
password: z.string().min(PASSWORD_MIN_LENGTH).max(PASSWORD_MAX_LENGTH),
|
|
33
|
+
name: z.string().min(1).max(100).optional(),
|
|
33
34
|
});
|
|
34
35
|
|
|
35
36
|
/**
|
|
@@ -63,11 +64,13 @@ export async function createUserWithEmailAndPassword({
|
|
|
63
64
|
input: {
|
|
64
65
|
email: string;
|
|
65
66
|
password: string;
|
|
67
|
+
name?: string;
|
|
66
68
|
};
|
|
67
69
|
}): Promise<User> {
|
|
68
|
-
const { email, password } = await emailPasswordSchema
|
|
70
|
+
const { email, password, name } = await emailPasswordSchema
|
|
69
71
|
.parseAsync(input)
|
|
70
72
|
.catch(handleZodRequestValidationError);
|
|
73
|
+
TPL_NAME_REQUIRED_CHECK;
|
|
71
74
|
// check if user with that email already exists
|
|
72
75
|
const existingUser = await prisma.userAccount.findUnique({
|
|
73
76
|
where: {
|
|
@@ -86,6 +89,7 @@ export async function createUserWithEmailAndPassword({
|
|
|
86
89
|
const user = await prisma.user.create({
|
|
87
90
|
data: {
|
|
88
91
|
email,
|
|
92
|
+
name,
|
|
89
93
|
accounts: {
|
|
90
94
|
create: {
|
|
91
95
|
accountId: email,
|
|
@@ -106,6 +110,7 @@ export async function registerUserWithEmailAndPassword({
|
|
|
106
110
|
input: {
|
|
107
111
|
email: string;
|
|
108
112
|
password: string;
|
|
113
|
+
name?: string;
|
|
109
114
|
};
|
|
110
115
|
context: RequestServiceContext;
|
|
111
116
|
}): Promise<{ session: UserSessionPayload; user: User }> {
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Generator for auth routes for logging in and registering
|
|
3
3
|
*/
|
|
4
|
-
export declare const authRoutesGenerator: import("@baseplate-dev/sync").GeneratorBundleCreator<
|
|
4
|
+
export declare const authRoutesGenerator: import("@baseplate-dev/sync").GeneratorBundleCreator<{
|
|
5
|
+
requireNameOnRegistration: boolean;
|
|
6
|
+
}, {
|
|
5
7
|
paths: import("@baseplate-dev/sync").GeneratorTask<{
|
|
6
8
|
authCoreAuthRoutesPaths: import("@baseplate-dev/sync").ProviderExport<import("./generated/template-paths.js").AuthCoreAuthRoutesPaths>;
|
|
7
9
|
}, {
|
|
@@ -258,6 +260,7 @@ export declare const authRoutesGenerator: import("@baseplate-dev/sync").Generato
|
|
|
258
260
|
}, undefined>;
|
|
259
261
|
main: import("@baseplate-dev/sync").GeneratorTask<any, {
|
|
260
262
|
renderers: import("@baseplate-dev/sync").ProviderType<import("./generated/template-renderers.js").AuthCoreAuthRoutesRenderers>;
|
|
263
|
+
paths: import("@baseplate-dev/sync").ProviderType<import("./generated/template-paths.js").AuthCoreAuthRoutesPaths>;
|
|
261
264
|
}, any>;
|
|
262
265
|
}>;
|
|
263
266
|
//# sourceMappingURL=auth-routes.generator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-routes.generator.d.ts","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-routes/auth-routes.generator.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"auth-routes.generator.d.ts","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-routes/auth-routes.generator.ts"],"names":[],"mappings":"AAcA;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkE9B,CAAC"}
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
+
import { TsCodeUtils, tsImportBuilder, tsTemplateWithImports, } from '@baseplate-dev/core-generators';
|
|
1
2
|
import { createGenerator, createGeneratorTask } from '@baseplate-dev/sync';
|
|
2
3
|
import { z } from 'zod';
|
|
3
4
|
import { AUTH_CORE_AUTH_ROUTES_GENERATED as GENERATED_TEMPLATES } from './generated/index.js';
|
|
4
|
-
const descriptorSchema = z.object({
|
|
5
|
+
const descriptorSchema = z.object({
|
|
6
|
+
requireNameOnRegistration: z.boolean(),
|
|
7
|
+
});
|
|
5
8
|
/**
|
|
6
9
|
* Generator for auth routes for logging in and registering
|
|
7
10
|
*/
|
|
@@ -9,18 +12,48 @@ export const authRoutesGenerator = createGenerator({
|
|
|
9
12
|
name: 'auth/core/auth-routes',
|
|
10
13
|
generatorFileUrl: import.meta.url,
|
|
11
14
|
descriptorSchema,
|
|
12
|
-
buildTasks: () => ({
|
|
15
|
+
buildTasks: ({ requireNameOnRegistration }) => ({
|
|
13
16
|
paths: GENERATED_TEMPLATES.paths.task,
|
|
14
17
|
renderers: GENERATED_TEMPLATES.renderers.task,
|
|
15
18
|
main: createGeneratorTask({
|
|
16
19
|
dependencies: {
|
|
17
20
|
renderers: GENERATED_TEMPLATES.renderers.provider,
|
|
21
|
+
paths: GENERATED_TEMPLATES.paths.provider,
|
|
18
22
|
},
|
|
19
|
-
run({ renderers }) {
|
|
23
|
+
run({ renderers, paths }) {
|
|
24
|
+
const schemaFields = {
|
|
25
|
+
email: 'z.email().transform((value) => value.toLowerCase())',
|
|
26
|
+
...(requireNameOnRegistration
|
|
27
|
+
? { name: 'z.string().min(1).max(100)' }
|
|
28
|
+
: {}),
|
|
29
|
+
password: `z.string().min(PASSWORD_MIN_LENGTH).max(PASSWORD_MAX_LENGTH)`,
|
|
30
|
+
};
|
|
31
|
+
const registerSchema = tsTemplateWithImports(tsImportBuilder(['PASSWORD_MAX_LENGTH', 'PASSWORD_MIN_LENGTH']).from(paths.constants)) `z.object(${TsCodeUtils.mergeFragmentsAsObject(schemaFields)})`;
|
|
32
|
+
const inputFields = {
|
|
33
|
+
email: 'data.email',
|
|
34
|
+
...(requireNameOnRegistration ? { name: 'data.name' } : {}),
|
|
35
|
+
password: 'data.password',
|
|
36
|
+
};
|
|
37
|
+
const registerInput = TsCodeUtils.mergeFragmentsAsObjectPresorted(inputFields, { wrapWithParenthesis: false });
|
|
20
38
|
return {
|
|
21
39
|
build: async (builder) => {
|
|
22
40
|
await builder.apply(renderers.mainGroup.render({
|
|
23
|
-
variables: {
|
|
41
|
+
variables: {
|
|
42
|
+
register: {
|
|
43
|
+
TPL_REGISTER_SCHEMA: registerSchema,
|
|
44
|
+
TPL_REGISTER_INPUT: registerInput,
|
|
45
|
+
TPL_NAME_FORM_CONTROL: requireNameOnRegistration
|
|
46
|
+
? `<InputFieldController
|
|
47
|
+
control={control}
|
|
48
|
+
name="name"
|
|
49
|
+
type="text"
|
|
50
|
+
autoComplete="name"
|
|
51
|
+
placeholder="Name"
|
|
52
|
+
label="Name"
|
|
53
|
+
/>`
|
|
54
|
+
: '',
|
|
55
|
+
},
|
|
56
|
+
},
|
|
24
57
|
}));
|
|
25
58
|
await builder.apply(renderers.verifyEmail.render({}));
|
|
26
59
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-routes.generator.js","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-routes/auth-routes.generator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAC3E,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,+BAA+B,IAAI,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAE9F,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"auth-routes.generator.js","sourceRoot":"","sources":["../../../../../src/local-auth/core/generators/auth-routes/auth-routes.generator.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,eAAe,EACf,qBAAqB,GACtB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAC3E,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,+BAA+B,IAAI,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAE9F,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IAChC,yBAAyB,EAAE,CAAC,CAAC,OAAO,EAAE;CACvC,CAAC,CAAC;AAEH;;GAEG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG,eAAe,CAAC;IACjD,IAAI,EAAE,uBAAuB;IAC7B,gBAAgB,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG;IACjC,gBAAgB;IAChB,UAAU,EAAE,CAAC,EAAE,yBAAyB,EAAE,EAAE,EAAE,CAAC,CAAC;QAC9C,KAAK,EAAE,mBAAmB,CAAC,KAAK,CAAC,IAAI;QACrC,SAAS,EAAE,mBAAmB,CAAC,SAAS,CAAC,IAAI;QAC7C,IAAI,EAAE,mBAAmB,CA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;yBACF,CAAC,CACH,CAAC;wBACF,MAAM,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC;oBACxD,CAAC;iBACF,CAAC;YACJ,CAAC;SACF,CAAC;KACH,CAAC;CACH,CAAC,CAAC"}
|
|
@@ -759,7 +759,11 @@ export declare const AUTH_CORE_AUTH_ROUTES_GENERATED: {
|
|
|
759
759
|
}, {
|
|
760
760
|
constants: {};
|
|
761
761
|
}>;
|
|
762
|
-
register: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
762
|
+
register: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
763
|
+
TPL_NAME_FORM_CONTROL: {};
|
|
764
|
+
TPL_REGISTER_INPUT: {};
|
|
765
|
+
TPL_REGISTER_SCHEMA: {};
|
|
766
|
+
}, {
|
|
763
767
|
apolloErrorImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
764
768
|
getApolloErrorCode: {};
|
|
765
769
|
}>>;
|
|
@@ -1003,9 +1007,7 @@ export declare const AUTH_CORE_AUTH_ROUTES_GENERATED: {
|
|
|
1003
1007
|
UserSessionClient: {};
|
|
1004
1008
|
userSessionClient: {};
|
|
1005
1009
|
}>>;
|
|
1006
|
-
},
|
|
1007
|
-
constants: {};
|
|
1008
|
-
}>;
|
|
1010
|
+
}, Record<never, Record<never, never>>>;
|
|
1009
1011
|
resetPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{}, {
|
|
1010
1012
|
apolloErrorImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
1011
1013
|
getApolloErrorCode: {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/local-auth/core/generators/auth-routes/generated/index.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,+BAA+B
|
|
1
|
+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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAK3C,CAAC"}
|
|
@@ -487,7 +487,11 @@ export declare const mainGroup: {
|
|
|
487
487
|
}, {
|
|
488
488
|
constants: {};
|
|
489
489
|
}>;
|
|
490
|
-
register: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
490
|
+
register: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
491
|
+
TPL_NAME_FORM_CONTROL: {};
|
|
492
|
+
TPL_REGISTER_INPUT: {};
|
|
493
|
+
TPL_REGISTER_SCHEMA: {};
|
|
494
|
+
}, {
|
|
491
495
|
apolloErrorImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
492
496
|
getApolloErrorCode: {};
|
|
493
497
|
}>>;
|
|
@@ -731,9 +735,7 @@ export declare const mainGroup: {
|
|
|
731
735
|
UserSessionClient: {};
|
|
732
736
|
userSessionClient: {};
|
|
733
737
|
}>>;
|
|
734
|
-
},
|
|
735
|
-
constants: {};
|
|
736
|
-
}>;
|
|
738
|
+
}, Record<never, Record<never, never>>>;
|
|
737
739
|
resetPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{}, {
|
|
738
740
|
apolloErrorImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
739
741
|
getApolloErrorCode: {};
|
|
@@ -1469,7 +1471,11 @@ export declare const AUTH_CORE_AUTH_ROUTES_TEMPLATES: {
|
|
|
1469
1471
|
}, {
|
|
1470
1472
|
constants: {};
|
|
1471
1473
|
}>;
|
|
1472
|
-
register: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
1474
|
+
register: import("@baseplate-dev/core-generators").TsTemplateFile<{
|
|
1475
|
+
TPL_NAME_FORM_CONTROL: {};
|
|
1476
|
+
TPL_REGISTER_INPUT: {};
|
|
1477
|
+
TPL_REGISTER_SCHEMA: {};
|
|
1478
|
+
}, {
|
|
1473
1479
|
apolloErrorImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
1474
1480
|
getApolloErrorCode: {};
|
|
1475
1481
|
}>>;
|
|
@@ -1713,9 +1719,7 @@ export declare const AUTH_CORE_AUTH_ROUTES_TEMPLATES: {
|
|
|
1713
1719
|
UserSessionClient: {};
|
|
1714
1720
|
userSessionClient: {};
|
|
1715
1721
|
}>>;
|
|
1716
|
-
},
|
|
1717
|
-
constants: {};
|
|
1718
|
-
}>;
|
|
1722
|
+
}, Record<never, Record<never, never>>>;
|
|
1719
1723
|
resetPassword: import("@baseplate-dev/core-generators").TsTemplateFile<{}, {
|
|
1720
1724
|
apolloErrorImports: import("@baseplate-dev/sync").ProviderType<import("@baseplate-dev/core-generators").InferTsImportMapFromSchema<{
|
|
1721
1725
|
getApolloErrorCode: {};
|