Skip to content

Commit b850b8a

Browse files
committed
refac: styling
1 parent 05af003 commit b850b8a

File tree

1 file changed

+30
-20
lines changed

1 file changed

+30
-20
lines changed

src/lib/components/admin/Settings/CodeExecution.svelte

Lines changed: 30 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,8 @@
138138

139139
<hr class=" border-gray-100 dark:border-gray-850 my-2" />
140140

141-
<div>
142-
<div class=" py-0.5 flex w-full justify-between">
141+
<div class="mb-2.5">
142+
<div class=" flex w-full justify-between">
143143
<div class=" self-center text-xs font-medium">
144144
{$i18n.t('Enable Code Interpreter')}
145145
</div>
@@ -149,27 +149,37 @@
149149
</div>
150150

151151
{#if config.ENABLE_CODE_INTERPRETER}
152-
<div class=" py-0.5 flex w-full justify-between">
153-
<div class=" self-center text-xs font-medium">
154-
{$i18n.t('Code Interpreter Engine')}
155-
</div>
156-
<div class="flex items-center relative">
157-
<select
158-
class="dark:bg-gray-900 w-fit pr-8 rounded-sm px-2 p-1 text-xs bg-transparent outline-hidden text-right"
159-
bind:value={config.CODE_INTERPRETER_ENGINE}
160-
placeholder={$i18n.t('Select a engine')}
161-
required
162-
>
163-
<option disabled selected value="">{$i18n.t('Select a engine')}</option>
164-
{#each engines as engine}
165-
<option value={engine}>{engine}</option>
166-
{/each}
167-
</select>
152+
<div class="mb-2.5">
153+
<div class=" flex w-full justify-between">
154+
<div class=" self-center text-xs font-medium">
155+
{$i18n.t('Code Interpreter Engine')}
156+
</div>
157+
<div class="flex items-center relative">
158+
<select
159+
class="dark:bg-gray-900 w-fit pr-8 rounded-sm px-2 p-1 text-xs bg-transparent outline-hidden text-right"
160+
bind:value={config.CODE_INTERPRETER_ENGINE}
161+
placeholder={$i18n.t('Select a engine')}
162+
required
163+
>
164+
<option disabled selected value="">{$i18n.t('Select a engine')}</option>
165+
{#each engines as engine}
166+
<option value={engine}>{engine}</option>
167+
{/each}
168+
</select>
169+
</div>
168170
</div>
171+
172+
{#if config.CODE_EXECUTION_ENGINE === 'jupyter'}
173+
<div class="text-gray-500 text-xs">
174+
{$i18n.t(
175+
'Warning: Jupyter execution enables arbitrary code execution, posing severe security risks—proceed with extreme caution.'
176+
)}
177+
</div>
178+
{/if}
169179
</div>
170180

171181
{#if config.CODE_INTERPRETER_ENGINE === 'jupyter'}
172-
<div class="mt-1 flex flex-col gap-1.5 mb-1 w-full">
182+
<div class="mb-2.5 flex flex-col gap-1.5 w-full">
173183
<div class="text-xs font-medium">
174184
{$i18n.t('Jupyter URL')}
175185
</div>
@@ -187,7 +197,7 @@
187197
</div>
188198
</div>
189199

190-
<div class="mt-1 flex gap-2 mb-1 w-full items-center justify-between">
200+
<div class="flex gap-2 w-full items-center justify-between">
191201
<div class="text-xs font-medium">
192202
{$i18n.t('Jupyter Auth')}
193203
</div>

0 commit comments

Comments
 (0)