diff --git a/client/components/editor/editor-ckeditor.vue b/client/components/editor/editor-ckeditor.vue index e9af534a..b39c93ed 100644 --- a/client/components/editor/editor-ckeditor.vue +++ b/client/components/editor/editor-ckeditor.vue @@ -18,6 +18,7 @@ import _ from 'lodash' import { get, sync } from 'vuex-pathify' import DecoupledEditor from '@requarks/ckeditor5' +// import DecoupledEditor from '../../../../wiki-ckeditor5/build/ckeditor' import EditorConflict from './ckeditor/conflict.vue' import { html as beautify } from 'js-beautify/js/lib/beautifier.min.js' @@ -110,6 +111,11 @@ export default { linkIsDownloadable: true }) break + case 'DIAGRAM': + this.editor.execute('imageInsert', { + source: `data:image/svg+xml;base64,${opts.text}` + }) + break } }) diff --git a/client/components/login.vue b/client/components/login.vue index e0dbef67..668d1d5b 100644 --- a/client/components/login.vue +++ b/client/components/login.vue @@ -40,7 +40,7 @@ hide-details ref='iptEmail' v-model='username' - :placeholder='$t("auth:fields.emailUser")' + :placeholder='$t(selectedStrategy.strategy.usernameLabel)' ) v-text-field.mt-2( solo @@ -536,6 +536,7 @@ export default { color icon useForm + usernameLabel } displayName order diff --git a/server/graph/schemas/authentication.graphql b/server/graph/schemas/authentication.graphql index 0b778918..57653f02 100644 --- a/server/graph/schemas/authentication.graphql +++ b/server/graph/schemas/authentication.graphql @@ -85,6 +85,7 @@ type AuthenticationStrategy { description: String isAvailable: Boolean useForm: Boolean! + usernameLabel: String logo: String color: String website: String diff --git a/server/modules/authentication/ldap/definition.yml b/server/modules/authentication/ldap/definition.yml index 1edc2ff7..9ef50e84 100644 --- a/server/modules/authentication/ldap/definition.yml +++ b/server/modules/authentication/ldap/definition.yml @@ -7,6 +7,7 @@ color: blue darken-3 website: https://www.microsoft.com/windowsserver isAvailable: true useForm: true +usernameLabel: 'auth:fields.username' props: url: title: LDAP URL diff --git a/server/modules/authentication/local/definition.yml b/server/modules/authentication/local/definition.yml index d083181d..f2977e36 100644 --- a/server/modules/authentication/local/definition.yml +++ b/server/modules/authentication/local/definition.yml @@ -7,4 +7,5 @@ color: primary website: https://wiki.js.org isAvailable: true useForm: true +usernameLabel: 'auth:fields.email' props: {}