feat: naive add AutoComplete
parent
cdcbd58f0e
commit
0a7ead980a
|
|
@ -16,6 +16,9 @@ import { $t } from '@vben/locales';
|
||||||
import { message } from '#/adapter/naive';
|
import { message } from '#/adapter/naive';
|
||||||
import { FileUpload, ImageUpload } from '#/components/upload';
|
import { FileUpload, ImageUpload } from '#/components/upload';
|
||||||
|
|
||||||
|
const NAutoComplete = defineAsyncComponent(() =>
|
||||||
|
import('naive-ui/es/auto-complete').then((res) => res.NAutoComplete),
|
||||||
|
);
|
||||||
const NButton = defineAsyncComponent(() =>
|
const NButton = defineAsyncComponent(() =>
|
||||||
import('naive-ui/es/button').then((res) => res.NButton),
|
import('naive-ui/es/button').then((res) => res.NButton),
|
||||||
);
|
);
|
||||||
|
|
@ -103,6 +106,7 @@ const withDefaultPlaceholder = <T extends Component>(
|
||||||
export type ComponentType =
|
export type ComponentType =
|
||||||
| 'ApiSelect'
|
| 'ApiSelect'
|
||||||
| 'ApiTreeSelect'
|
| 'ApiTreeSelect'
|
||||||
|
| 'AutoComplete'
|
||||||
| 'Checkbox'
|
| 'Checkbox'
|
||||||
| 'CheckboxGroup'
|
| 'CheckboxGroup'
|
||||||
| 'DatePicker'
|
| 'DatePicker'
|
||||||
|
|
@ -154,6 +158,7 @@ async function initComponentAdapter() {
|
||||||
visibleEvent: 'onVisibleChange',
|
visibleEvent: 'onVisibleChange',
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
AutoComplete: NAutoComplete,
|
||||||
Checkbox: NCheckbox,
|
Checkbox: NCheckbox,
|
||||||
CheckboxGroup: (props, { attrs, slots }) => {
|
CheckboxGroup: (props, { attrs, slots }) => {
|
||||||
let defaultSlot;
|
let defaultSlot;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue