mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-19 01:26:01 +00:00
connection colors
This commit is contained in:
17
packages/web/src/forms/FormColorField.svelte
Normal file
17
packages/web/src/forms/FormColorField.svelte
Normal file
@@ -0,0 +1,17 @@
|
||||
<script lang="ts">
|
||||
import _ from 'lodash';
|
||||
|
||||
import FormSelectField from '../forms/FormSelectField.svelte';
|
||||
import { presetPrimaryColors } from '@ant-design/colors';
|
||||
|
||||
export let emptyLabel;
|
||||
</script>
|
||||
|
||||
<FormSelectField
|
||||
isNative
|
||||
{...$$restProps}
|
||||
options={[
|
||||
{ value: '', label: emptyLabel },
|
||||
..._.keys(presetPrimaryColors).map(color => ({ value: color, label: _.startCase(color) })),
|
||||
]}
|
||||
/>
|
||||
Reference in New Issue
Block a user