mirror of
https://github.com/open-webui/open-webui.git
synced 2026-12-03 02:07:46 -05:00
refac
This commit is contained in:
1 parent
a9478213a2
commit
08c109d20f
3 files changed
+18
-12
No files matched your search
@@ -43,9 +43,6 @@
|
||||
|
||||
<form class="space-y-2 text-xs" on:submit|preventDefault={submit} aria-busy={cloning}>
|
||||
<div class="space-y-2 px-2">
|
||||
<div class="break-all text-gray-500">
|
||||
{$i18n.t('Clone into {{directory}}', { directory: cloning ? cloningDirectory : directory })}
|
||||
</div>
|
||||
<label class="block">
|
||||
<span class="text-gray-600 dark:text-gray-400">{$i18n.t('Repository URL')}</span>
|
||||
<input
|
||||
@@ -64,23 +61,32 @@
|
||||
>
|
||||
{error}
|
||||
</div>{/if}
|
||||
{#if cloning}<div role="status" class="text-gray-500">
|
||||
{$i18n.t('Cloning continues if you close this picker.')}
|
||||
</div>{/if}
|
||||
</div>
|
||||
<div class="flex justify-end gap-2 px-2">
|
||||
<div class="flex items-center gap-2 px-2">
|
||||
<div
|
||||
class="min-w-0 flex-1 truncate text-gray-500"
|
||||
title={cloning ? cloningDirectory : directory}
|
||||
>
|
||||
{$i18n.t('Clone into {{directory}}', { directory: cloning ? cloningDirectory : directory })}
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
class="h-7 rounded-lg px-2 hover:bg-gray-100 dark:hover:bg-gray-850 disabled:opacity-50"
|
||||
class="h-7 shrink-0 rounded-lg px-2 hover:bg-gray-100 dark:hover:bg-gray-850 disabled:opacity-50"
|
||||
disabled={cloning}
|
||||
on:click={onCancel}>{$i18n.t('Cancel')}</button
|
||||
>
|
||||
<button
|
||||
type="submit"
|
||||
class="flex h-7 items-center gap-1.5 rounded-lg bg-gray-900 px-2 text-white hover:bg-black disabled:cursor-not-allowed disabled:opacity-50 dark:bg-gray-100 dark:text-gray-900"
|
||||
class="flex h-7 shrink-0 items-center gap-1.5 rounded-lg bg-gray-900 px-2 text-white hover:bg-black dark:bg-gray-100 dark:text-gray-900 {cloning
|
||||
? 'cursor-wait'
|
||||
: 'disabled:cursor-not-allowed disabled:opacity-50'}"
|
||||
disabled={disabled || cloning || !url.trim()}
|
||||
aria-busy={cloning}
|
||||
>
|
||||
{#if cloning}<Spinner className="size-3" />{:else}<Icon name="git-branch" size={14} />{/if}
|
||||
{#if cloning}<Spinner className="size-4 shrink-0" />{:else}<Icon
|
||||
name="git-branch"
|
||||
size={14}
|
||||
/>{/if}
|
||||
{cloning ? $i18n.t('Cloning…') : $i18n.t('Clone repository')}
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -252,7 +252,7 @@
|
||||
{#if showPicker}
|
||||
<Modal bind:show={showPicker} ariaLabel={$i18n.t('Choose working directory')} size="md">
|
||||
<div class="px-2 py-4">
|
||||
<div class="mb-3 flex items-center justify-between text-sm">
|
||||
<div class="mb-3 flex items-center justify-between px-2 text-sm">
|
||||
<span>{$i18n.t('Choose working directory')}</span>
|
||||
<button
|
||||
type="button"
|
||||
|
||||
@@ -489,7 +489,7 @@
|
||||
{#if show && showDirectoryPicker && data.terminal_id}
|
||||
<Modal bind:show={showDirectoryPicker} ariaLabel={$i18n.t('Choose working directory')} size="md">
|
||||
<div class="px-2 py-4">
|
||||
<div class="mb-3 flex items-center justify-between text-sm">
|
||||
<div class="mb-3 flex items-center justify-between px-2 text-sm">
|
||||
<span>{$i18n.t('Choose working directory')}</span>
|
||||
<button
|
||||
type="button"
|
||||
|
||||
Reference in new issue
Block a user