Add title to type, add to model too

This commit is contained in:
Niek van der Maas 2023-03-21 19:50:22 +01:00
parent e84ebf8a2d
commit 81b172442f
2 changed files with 3 additions and 1 deletions

View File

@ -37,6 +37,7 @@
key: 'model', key: 'model',
name: 'Model', name: 'Model',
default: 'gpt-3.5-turbo', default: 'gpt-3.5-turbo',
title: 'The model to use - GPT-3.5 is cheaper, but GPT-4 is more powerful.',
options: supportedModels, options: supportedModels,
type: 'select' type: 'select'
} }
@ -559,7 +560,7 @@
/> />
{:else if setting.type === 'select'} {:else if setting.type === 'select'}
<div class="select"> <div class="select">
<select id="settings-{setting.key}"> <select id="settings-{setting.key}" title="{setting.title}">
{#each setting.options as option} {#each setting.options as option}
<option value={option} selected={option === setting.default}>{option}</option> <option value={option} selected={option === setting.default}>{option}</option>
{/each} {/each}

View File

@ -60,6 +60,7 @@
export type Settings = { export type Settings = {
key: string; key: string;
name: string; name: string;
title: string;
} & (SettingsNumber | SettingsSelect); } & (SettingsNumber | SettingsSelect);
type ResponseOK = { type ResponseOK = {