feat(editor): SSO onboarding (#5756)
* feat(editor): SSO onboarding * fix(editor): add SAML onboarding page * fix(editor): submit user name on SAML onboarding
This commit is contained in:
44
packages/editor-ui/src/views/SamlOnboarding.vue
Normal file
44
packages/editor-ui/src/views/SamlOnboarding.vue
Normal file
@@ -0,0 +1,44 @@
|
||||
<script lang="ts" setup>
|
||||
import { reactive, ref } from 'vue';
|
||||
import { IFormBoxConfig } from 'n8n-design-system';
|
||||
import AuthView from '@/views/AuthView.vue';
|
||||
import { i18n as locale } from '@/plugins/i18n';
|
||||
import { useSSOStore } from '@/stores/sso';
|
||||
|
||||
const ssoStore = useSSOStore();
|
||||
|
||||
const loading = ref(false);
|
||||
const FORM_CONFIG: IFormBoxConfig = reactive({
|
||||
title: locale.baseText('auth.signup.setupYourAccount'),
|
||||
buttonText: locale.baseText('auth.signup.finishAccountSetup'),
|
||||
inputs: [
|
||||
{
|
||||
name: 'firstName',
|
||||
properties: {
|
||||
label: locale.baseText('auth.firstName'),
|
||||
maxlength: 32,
|
||||
required: true,
|
||||
autocomplete: 'given-name',
|
||||
capitalize: true,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'lastName',
|
||||
properties: {
|
||||
label: locale.baseText('auth.lastName'),
|
||||
maxlength: 32,
|
||||
required: true,
|
||||
autocomplete: 'family-name',
|
||||
capitalize: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
});
|
||||
const onSubmit = (values: { firstName: string; lastName: string }) => {
|
||||
ssoStore.updateUser(values);
|
||||
};
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<AuthView :form="FORM_CONFIG" :formLoading="loading" @submit="onSubmit" />
|
||||
</template>
|
||||
Reference in New Issue
Block a user