fix: place model editor capability checkboxes directly before their labels (#27788)
This commit is contained in:
@@ -78,12 +78,7 @@
|
||||
<div class="mb-1.5 text-xs text-gray-400 dark:text-gray-600">{$i18n.t('Builtin Tools')}</div>
|
||||
<div class="grid grid-cols-1 gap-x-5 gap-y-1 sm:grid-cols-2 lg:grid-cols-3">
|
||||
{#each allTools as tool}
|
||||
<div class="flex min-h-6 items-center justify-between gap-2.5">
|
||||
<div class="min-w-0 text-xs text-gray-600 dark:text-gray-400">
|
||||
<Tooltip content={marked.parse(toolLabels[tool].description)}>
|
||||
<span class="truncate">{$i18n.t(toolLabels[tool].label)}</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
<div class="flex min-h-6 items-center gap-2.5">
|
||||
<Checkbox
|
||||
ariaLabel={$i18n.t(toolLabels[tool].label)}
|
||||
state={builtinTools[tool] !== false ? 'checked' : 'unchecked'}
|
||||
@@ -96,6 +91,11 @@
|
||||
builtinTools = builtinTools;
|
||||
}}
|
||||
/>
|
||||
<div class="min-w-0 text-xs text-gray-600 dark:text-gray-400">
|
||||
<Tooltip content={marked.parse(toolLabels[tool].description)}>
|
||||
<span class="truncate">{$i18n.t(toolLabels[tool].label)}</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
</div>
|
||||
{/each}
|
||||
</div>
|
||||
|
||||
@@ -80,12 +80,7 @@
|
||||
<div class="mb-1.5 text-xs text-gray-400 dark:text-gray-600">{$i18n.t('Capabilities')}</div>
|
||||
<div class="grid grid-cols-1 gap-x-5 gap-y-1 sm:grid-cols-2 lg:grid-cols-3">
|
||||
{#each visibleCapabilities as capability}
|
||||
<div class="flex min-h-6 items-center justify-between gap-2.5">
|
||||
<div class="min-w-0 text-xs text-gray-600 dark:text-gray-400">
|
||||
<Tooltip content={marked.parse(capabilityLabels[capability].description)}>
|
||||
<span class="truncate">{$i18n.t(capabilityLabels[capability].label)}</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
<div class="flex min-h-6 items-center gap-2.5">
|
||||
<Checkbox
|
||||
ariaLabel={$i18n.t(capabilityLabels[capability].label)}
|
||||
state={capabilities[capability] ? 'checked' : 'unchecked'}
|
||||
@@ -93,6 +88,11 @@
|
||||
capabilities[capability] = e.detail === 'checked';
|
||||
}}
|
||||
/>
|
||||
<div class="min-w-0 text-xs text-gray-600 dark:text-gray-400">
|
||||
<Tooltip content={marked.parse(capabilityLabels[capability].description)}>
|
||||
<span class="truncate">{$i18n.t(capabilityLabels[capability].label)}</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
</div>
|
||||
{/each}
|
||||
</div>
|
||||
|
||||
@@ -29,12 +29,7 @@
|
||||
<div class="mb-1.5 text-xs text-gray-400 dark:text-gray-600">{$i18n.t('Default Features')}</div>
|
||||
<div class="grid grid-cols-1 gap-x-5 gap-y-1 sm:grid-cols-2 lg:grid-cols-3">
|
||||
{#each availableFeatures as feature}
|
||||
<div class="flex min-h-6 items-center justify-between gap-2.5">
|
||||
<div class="min-w-0 text-xs text-gray-600 dark:text-gray-400">
|
||||
<Tooltip content={marked.parse(featureLabels[feature].description)}>
|
||||
<span class="truncate">{$i18n.t(featureLabels[feature].label)}</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
<div class="flex min-h-6 items-center gap-2.5">
|
||||
<Checkbox
|
||||
ariaLabel={$i18n.t(featureLabels[feature].label)}
|
||||
state={featureIds.includes(feature) ? 'checked' : 'unchecked'}
|
||||
@@ -46,6 +41,11 @@
|
||||
}
|
||||
}}
|
||||
/>
|
||||
<div class="min-w-0 text-xs text-gray-600 dark:text-gray-400">
|
||||
<Tooltip content={marked.parse(featureLabels[feature].description)}>
|
||||
<span class="truncate">{$i18n.t(featureLabels[feature].label)}</span>
|
||||
</Tooltip>
|
||||
</div>
|
||||
</div>
|
||||
{/each}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user