refac
This commit is contained in:
1 parent
a7fbf66269
commit
aedb6bef4e
208 files changed
+1056
-1066
No files matched your search
@@ -236,14 +236,14 @@
|
||||
|
||||
{#if loaded}
|
||||
<div
|
||||
class="fixed bg-transparent min-h-screen w-full flex justify-center font-primary z-50 text-black dark:text-white"
|
||||
class="fixed bg-transparent min-h-screen w-full flex justify-center z-50 text-black dark:text-white"
|
||||
id="auth-container"
|
||||
>
|
||||
<div class="w-full px-10 min-h-screen flex flex-col text-center">
|
||||
{#if ($config?.features.auth_trusted_header ?? false) || $config?.features.auth === false}
|
||||
<div class=" my-auto pb-10 w-full sm:max-w-md">
|
||||
<div
|
||||
class="flex items-center justify-center gap-3 text-xl sm:text-2xl text-center font-medium dark:text-gray-200"
|
||||
class="flex items-center justify-center gap-3 text-xl sm:text-2xl text-center font-normal dark:text-gray-200"
|
||||
>
|
||||
<div>
|
||||
{$i18n.t('Signing in to {{WEBUI_NAME}}', { WEBUI_NAME: $WEBUI_NAME })}
|
||||
@@ -276,7 +276,7 @@
|
||||
}}
|
||||
>
|
||||
<div class="mb-1">
|
||||
<div class=" text-2xl font-medium">
|
||||
<div class=" text-2xl font-normal">
|
||||
{#if $config?.onboarding ?? false}
|
||||
{$i18n.t(`Get started with {{WEBUI_NAME}}`, { WEBUI_NAME: $WEBUI_NAME })}
|
||||
{:else if mode === 'ldap'}
|
||||
@@ -289,7 +289,7 @@
|
||||
</div>
|
||||
|
||||
{#if $config?.onboarding ?? false}
|
||||
<div class="mt-1 text-xs font-medium text-gray-600 dark:text-gray-500">
|
||||
<div class="mt-1 text-xs font-normal text-gray-600 dark:text-gray-500">
|
||||
ⓘ {$WEBUI_NAME}
|
||||
{$i18n.t(
|
||||
'does not make any external connections, and your data stays securely on your locally hosted server.'
|
||||
@@ -302,7 +302,7 @@
|
||||
<div class="flex flex-col mt-4">
|
||||
{#if mode === 'signup'}
|
||||
<div class="mb-2">
|
||||
<label for="name" class="text-sm font-medium text-left mb-1 block"
|
||||
<label for="name" class="text-sm font-normal text-left mb-1 block"
|
||||
>{$i18n.t('Name')}</label
|
||||
>
|
||||
<input
|
||||
@@ -319,7 +319,7 @@
|
||||
|
||||
{#if mode === 'ldap'}
|
||||
<div class="mb-2">
|
||||
<label for="username" class="text-sm font-medium text-left mb-1 block"
|
||||
<label for="username" class="text-sm font-normal text-left mb-1 block"
|
||||
>{$i18n.t('Username')}</label
|
||||
>
|
||||
<input
|
||||
@@ -335,7 +335,7 @@
|
||||
</div>
|
||||
{:else}
|
||||
<div class="mb-2">
|
||||
<label for="email" class="text-sm font-medium text-left mb-1 block"
|
||||
<label for="email" class="text-sm font-normal text-left mb-1 block"
|
||||
>{$i18n.t('Email')}</label
|
||||
>
|
||||
<input
|
||||
@@ -352,7 +352,7 @@
|
||||
{/if}
|
||||
|
||||
<div>
|
||||
<label for="password" class="text-sm font-medium text-left mb-1 block"
|
||||
<label for="password" class="text-sm font-normal text-left mb-1 block"
|
||||
>{$i18n.t('Password')}</label
|
||||
>
|
||||
<SensitiveInput
|
||||
@@ -373,7 +373,7 @@
|
||||
<div class="mt-2">
|
||||
<label
|
||||
for="confirm-password"
|
||||
class="text-sm font-medium text-left mb-1 block"
|
||||
class="text-sm font-normal text-left mb-1 block"
|
||||
>{$i18n.t('Confirm Password')}</label
|
||||
>
|
||||
<SensitiveInput
|
||||
@@ -394,14 +394,14 @@
|
||||
{#if $config?.features.enable_login_form || $config?.features.enable_ldap || form}
|
||||
{#if mode === 'ldap'}
|
||||
<button
|
||||
class="bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
type="submit"
|
||||
>
|
||||
{$i18n.t('Authenticate')}
|
||||
</button>
|
||||
{:else}
|
||||
<button
|
||||
class="bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
type="submit"
|
||||
>
|
||||
{mode === 'signin'
|
||||
@@ -418,7 +418,7 @@
|
||||
: $i18n.t('Already have an account?')}
|
||||
|
||||
<button
|
||||
class=" font-medium underline"
|
||||
class=" font-normal underline"
|
||||
type="button"
|
||||
on:click={() => {
|
||||
if (mode === 'signin') {
|
||||
@@ -442,7 +442,7 @@
|
||||
<hr class="w-32 h-px my-4 border-0 dark:bg-gray-100/10 bg-gray-700/10" />
|
||||
{#if $config?.features.enable_login_form || $config?.features.enable_ldap || form}
|
||||
<span
|
||||
class="px-3 text-sm font-medium text-gray-900 dark:text-white bg-transparent"
|
||||
class="px-3 text-sm font-normal text-gray-900 dark:text-white bg-transparent"
|
||||
>{$i18n.t('or')}</span
|
||||
>
|
||||
{/if}
|
||||
@@ -452,7 +452,7 @@
|
||||
<div class="flex flex-col space-y-2">
|
||||
{#if $config?.oauth?.providers?.google}
|
||||
<button
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
on:click={() => {
|
||||
window.location.href = `${WEBUI_BASE_URL}/oauth/google/login`;
|
||||
}}
|
||||
@@ -482,7 +482,7 @@
|
||||
{/if}
|
||||
{#if $config?.oauth?.providers?.microsoft}
|
||||
<button
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
on:click={() => {
|
||||
window.location.href = `${WEBUI_BASE_URL}/oauth/microsoft/login`;
|
||||
}}
|
||||
@@ -513,7 +513,7 @@
|
||||
{/if}
|
||||
{#if $config?.oauth?.providers?.github}
|
||||
<button
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
on:click={() => {
|
||||
window.location.href = `${WEBUI_BASE_URL}/oauth/github/login`;
|
||||
}}
|
||||
@@ -534,7 +534,7 @@
|
||||
{/if}
|
||||
{#if $config?.oauth?.providers?.oidc}
|
||||
<button
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
on:click={() => {
|
||||
window.location.href = `${WEBUI_BASE_URL}/oauth/oidc/login`;
|
||||
}}
|
||||
@@ -564,7 +564,7 @@
|
||||
{/if}
|
||||
{#if $config?.oauth?.providers?.feishu}
|
||||
<button
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-medium text-sm py-2.5"
|
||||
class="flex justify-center items-center bg-gray-700/5 hover:bg-gray-700/10 dark:bg-gray-100/5 dark:hover:bg-gray-100/10 dark:text-gray-300 dark:hover:text-white transition w-full rounded-full font-normal text-sm py-2.5"
|
||||
on:click={() => {
|
||||
window.location.href = `${WEBUI_BASE_URL}/oauth/feishu/login`;
|
||||
}}
|
||||
|
||||
Reference in new issue
Block a user