@finema/core 1.4.220 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +79 -60
- package/dist/module.d.mts +4 -24
- package/dist/module.json +4 -3
- package/dist/module.mjs +75 -213
- package/dist/runtime/components/App.vue +27 -0
- package/dist/runtime/components/App.vue.d.ts +12 -0
- package/dist/runtime/components/DevToolsWindow/index.vue +312 -0
- package/dist/runtime/components/DevToolsWindow/index.vue.d.ts +2 -0
- package/dist/runtime/components/Dialog/index.vue +77 -110
- package/dist/runtime/components/Dialog/index.vue.d.ts +10 -0
- package/dist/runtime/components/Empty.vue +33 -18
- package/dist/runtime/components/Empty.vue.d.ts +12 -0
- package/dist/runtime/components/FlexDeck/Base.vue +154 -159
- package/dist/runtime/components/FlexDeck/Base.vue.d.ts +63 -0
- package/dist/runtime/components/FlexDeck/index.vue +67 -68
- package/dist/runtime/components/FlexDeck/index.vue.d.ts +43 -0
- package/dist/runtime/components/Form/FieldWrapper.vue +35 -23
- package/dist/runtime/components/Form/FieldWrapper.vue.d.ts +16 -0
- package/dist/runtime/components/Form/Fields.vue +92 -230
- package/dist/runtime/components/Form/Fields.vue.d.ts +14 -0
- package/dist/runtime/components/Form/InputCheckbox/index.vue +53 -28
- package/dist/runtime/components/Form/InputCheckbox/index.vue.d.ts +3 -0
- package/dist/runtime/components/Form/InputCheckbox/types.d.ts +5 -1
- package/dist/runtime/components/Form/InputDateTime/date_time_field.types.d.ts +1 -1
- package/dist/runtime/components/Form/InputDateTime/index.vue +97 -68
- package/dist/runtime/components/Form/InputDateTime/index.vue.d.ts +4 -0
- package/dist/runtime/components/Form/InputNumber/index.vue +61 -27
- package/dist/runtime/components/Form/InputNumber/index.vue.d.ts +5 -0
- package/dist/runtime/components/Form/InputNumber/types.d.ts +10 -5
- package/dist/runtime/components/Form/InputSelect/index.vue +95 -55
- package/dist/runtime/components/Form/InputSelect/index.vue.d.ts +5 -0
- package/dist/runtime/components/Form/InputSelect/types.d.ts +14 -8
- package/dist/runtime/components/Form/InputSelectMultiple/index.vue +108 -54
- package/dist/runtime/components/Form/InputSelectMultiple/index.vue.d.ts +3 -0
- package/dist/runtime/components/Form/InputSelectMultiple/types.d.ts +9 -8
- package/dist/runtime/components/Form/InputText/index.vue +135 -68
- package/dist/runtime/components/Form/InputText/index.vue.d.ts +5 -0
- package/dist/runtime/components/Form/InputText/types.d.ts +4 -3
- package/dist/runtime/components/Form/InputTextarea/index.vue +57 -25
- package/dist/runtime/components/Form/InputTextarea/index.vue.d.ts +3 -0
- package/dist/runtime/components/Form/InputTextarea/types.d.ts +7 -2
- package/dist/runtime/components/Form/InputToggle/index.vue +51 -27
- package/dist/runtime/components/Form/InputToggle/index.vue.d.ts +3 -0
- package/dist/runtime/components/Form/InputToggle/types.d.ts +5 -1
- package/dist/runtime/components/Form/index.vue +5 -6
- package/dist/runtime/components/Form/index.vue.d.ts +12 -0
- package/dist/runtime/components/Form/types.d.ts +13 -27
- package/dist/runtime/components/Image.vue +51 -36
- package/dist/runtime/components/Image.vue.d.ts +13 -0
- package/dist/runtime/components/Loader.vue +29 -27
- package/dist/runtime/components/Loader.vue.d.ts +22 -0
- package/dist/runtime/components/{LogItem.vue → Log/LogItem.vue} +44 -41
- package/dist/runtime/components/Log/LogItem.vue.d.ts +6 -0
- package/dist/runtime/components/Log/index.vue +28 -0
- package/dist/runtime/components/Log/index.vue.d.ts +7 -0
- package/dist/runtime/components/Table/Base.vue +166 -161
- package/dist/runtime/components/Table/Base.vue.d.ts +47 -0
- package/dist/runtime/components/Table/ColumnDate.vue +14 -16
- package/dist/runtime/components/Table/ColumnDate.vue.d.ts +8 -0
- package/dist/runtime/components/Table/ColumnDateTime.vue +16 -18
- package/dist/runtime/components/Table/ColumnDateTime.vue.d.ts +8 -0
- package/dist/runtime/components/Table/ColumnImage.vue +16 -15
- package/dist/runtime/components/Table/ColumnImage.vue.d.ts +8 -0
- package/dist/runtime/components/Table/ColumnNumber.vue +14 -14
- package/dist/runtime/components/Table/ColumnNumber.vue.d.ts +8 -0
- package/dist/runtime/components/Table/ColumnText.vue +24 -29
- package/dist/runtime/components/Table/ColumnText.vue.d.ts +8 -0
- package/dist/runtime/components/Table/Simple.vue +69 -70
- package/dist/runtime/components/Table/Simple.vue.d.ts +24 -0
- package/dist/runtime/components/Table/index.vue +178 -65
- package/dist/runtime/components/Table/index.vue.d.ts +25 -0
- package/dist/runtime/components/Table/types.d.ts +14 -18
- package/dist/runtime/components/Table/{types.mjs → types.js} +1 -0
- package/dist/runtime/components/TeleportSafe.vue +42 -40
- package/dist/runtime/components/TeleportSafe.vue.d.ts +16 -0
- package/dist/runtime/composables/loaderList.d.ts +2 -2
- package/dist/runtime/composables/loaderList.js +51 -0
- package/dist/runtime/composables/loaderObject.d.ts +1 -1
- package/dist/runtime/composables/loaderObject.js +50 -0
- package/dist/runtime/composables/loaderPage.d.ts +10 -11
- package/dist/runtime/composables/loaderPage.js +243 -0
- package/dist/runtime/composables/useApp.d.ts +4 -9
- package/dist/runtime/composables/{useApp.mjs → useApp.js} +0 -12
- package/dist/runtime/composables/useConfig.d.ts +3 -3
- package/dist/runtime/composables/useConfig.js +12 -0
- package/dist/runtime/composables/useDialog.d.ts +1 -7
- package/dist/runtime/composables/useDialog.js +53 -0
- package/dist/runtime/composables/useFlexDeck.d.ts +1 -1
- package/dist/runtime/composables/{useFlexDeck.mjs → useFlexDeck.js} +5 -5
- package/dist/runtime/composables/useForm.d.ts +5 -2
- package/dist/runtime/composables/useForm.js +37 -0
- package/dist/runtime/composables/useNotification.d.ts +6 -22
- package/dist/runtime/composables/{useNotification.mjs → useNotification.js} +5 -21
- package/dist/runtime/composables/useTable.d.ts +12 -11
- package/dist/runtime/composables/{useTable.mjs → useTable.js} +3 -8
- package/dist/runtime/composables/useUpload.d.ts +2 -2
- package/dist/runtime/composables/{useUpload.mjs → useUpload.js} +1 -1
- package/dist/runtime/helpers/apiBaseHelper.d.ts +29 -0
- package/dist/runtime/helpers/apiBaseHelper.js +63 -0
- package/dist/runtime/helpers/apiListHelper.d.ts +4 -6
- package/dist/runtime/helpers/apiListHelper.js +50 -0
- package/dist/runtime/helpers/apiObjectHelper.d.ts +19 -20
- package/dist/runtime/helpers/apiObjectHelper.js +51 -0
- package/dist/runtime/helpers/apiPageHelper.d.ts +44 -44
- package/dist/runtime/helpers/apiPageHelper.js +287 -0
- package/dist/runtime/helpers/componentHelper.d.ts +11 -12
- package/dist/runtime/helpers/{componentHelper.mjs → componentHelper.js} +2 -7
- package/dist/runtime/i18n/valibot.d.ts +69 -0
- package/dist/runtime/i18n/valibot.js +72 -0
- package/dist/runtime/plugin.d.ts +1 -1
- package/dist/runtime/plugin.js +12 -0
- package/dist/runtime/server/tsconfig.json +3 -0
- package/dist/runtime/theme/button.d.ts +5 -0
- package/dist/runtime/theme/button.js +1 -0
- package/dist/runtime/theme/dialog.d.ts +31 -0
- package/dist/runtime/theme/dialog.js +21 -0
- package/dist/runtime/theme/empty.d.ts +7 -0
- package/dist/runtime/theme/empty.js +7 -0
- package/dist/runtime/theme/form.d.ts +18 -0
- package/dist/runtime/theme/form.js +16 -0
- package/dist/runtime/theme/index.d.ts +10 -0
- package/dist/runtime/theme/index.js +10 -0
- package/dist/runtime/theme/input.d.ts +8 -0
- package/dist/runtime/theme/input.js +4 -0
- package/dist/runtime/theme/inputNumber.d.ts +8 -0
- package/dist/runtime/theme/inputNumber.js +4 -0
- package/dist/runtime/theme/loader.d.ts +28 -0
- package/dist/runtime/theme/loader.js +18 -0
- package/dist/runtime/theme/selectMenu.d.ts +17 -0
- package/dist/runtime/theme/selectMenu.js +18 -0
- package/dist/runtime/theme/table.d.ts +10 -0
- package/dist/runtime/theme/table.js +10 -0
- package/dist/runtime/theme/textarea.d.ts +5 -0
- package/dist/runtime/theme/textarea.js +1 -0
- package/dist/runtime/types/lib.d.ts +1 -1
- package/dist/runtime/utils/ArrayHelper.d.ts +1 -1
- package/dist/runtime/utils/{ArrayHelper.mjs → ArrayHelper.js} +1 -1
- package/dist/runtime/utils/ObjectHelper.d.ts +3 -3
- package/dist/runtime/utils/{ObjectHelper.mjs → ObjectHelper.js} +3 -3
- package/dist/runtime/utils/ParamHelper.d.ts +1 -1
- package/dist/runtime/utils/{ParamHelper.mjs → ParamHelper.js} +1 -1
- package/dist/types.d.mts +2 -15
- package/package.json +91 -100
- package/dist/module.cjs +0 -5
- package/dist/module.d.ts +0 -50
- package/dist/runtime/components/Alert.vue +0 -48
- package/dist/runtime/components/Avatar.vue +0 -27
- package/dist/runtime/components/Badge.vue +0 -11
- package/dist/runtime/components/Breadcrumb.vue +0 -44
- package/dist/runtime/components/Button/Group.vue +0 -37
- package/dist/runtime/components/Button/index.vue +0 -75
- package/dist/runtime/components/Card.vue +0 -38
- package/dist/runtime/components/Core.vue +0 -45
- package/dist/runtime/components/Dropdown/index.vue +0 -70
- package/dist/runtime/components/Dropdown/types.d.ts +0 -2
- package/dist/runtime/components/Dropdown/types.mjs +0 -17
- package/dist/runtime/components/Form/InputDateTimeRange/date_range_time_field.types.d.ts +0 -17
- package/dist/runtime/components/Form/InputDateTimeRange/index.vue +0 -91
- package/dist/runtime/components/Form/InputRadio/index.vue +0 -27
- package/dist/runtime/components/Form/InputRadio/types.d.ts +0 -8
- package/dist/runtime/components/Form/InputStatic/index.vue +0 -16
- package/dist/runtime/components/Form/InputStatic/types.d.ts +0 -4
- package/dist/runtime/components/Form/InputTags/index.vue +0 -141
- package/dist/runtime/components/Form/InputTags/types.d.ts +0 -11
- package/dist/runtime/components/Form/InputTextarea/types.mjs +0 -0
- package/dist/runtime/components/Form/InputToggle/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadDropzone/index.vue +0 -206
- package/dist/runtime/components/Form/InputUploadDropzone/types.d.ts +0 -11
- package/dist/runtime/components/Form/InputUploadDropzone/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadDropzoneAuto/index.vue +0 -362
- package/dist/runtime/components/Form/InputUploadDropzoneAuto/types.d.ts +0 -23
- package/dist/runtime/components/Form/InputUploadDropzoneAuto/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadDropzoneAutoMultiple/ItemUpload.vue +0 -241
- package/dist/runtime/components/Form/InputUploadDropzoneAutoMultiple/ItemView.vue +0 -110
- package/dist/runtime/components/Form/InputUploadDropzoneAutoMultiple/index.vue +0 -171
- package/dist/runtime/components/Form/InputUploadDropzoneAutoMultiple/types.d.ts +0 -23
- package/dist/runtime/components/Form/InputUploadDropzoneAutoMultiple/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadDropzoneImageAutoMultiple/ItemUpload.vue +0 -161
- package/dist/runtime/components/Form/InputUploadDropzoneImageAutoMultiple/ItemView.vue +0 -64
- package/dist/runtime/components/Form/InputUploadDropzoneImageAutoMultiple/index.vue +0 -178
- package/dist/runtime/components/Form/InputUploadDropzoneImageAutoMultiple/types.d.ts +0 -21
- package/dist/runtime/components/Form/InputUploadDropzoneImageAutoMultiple/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadFileClassic/index.vue +0 -95
- package/dist/runtime/components/Form/InputUploadFileClassic/types.d.ts +0 -13
- package/dist/runtime/components/Form/InputUploadFileClassic/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadFileClassicAuto/index.vue +0 -151
- package/dist/runtime/components/Form/InputUploadFileClassicAuto/types.d.ts +0 -18
- package/dist/runtime/components/Form/InputUploadFileClassicAuto/types.mjs +0 -0
- package/dist/runtime/components/Form/InputUploadImageAuto/index.vue +0 -219
- package/dist/runtime/components/Form/InputUploadImageAuto/types.d.ts +0 -20
- package/dist/runtime/components/Form/InputUploadImageAuto/types.mjs +0 -0
- package/dist/runtime/components/Form/InputWYSIWYG/UploadImageForm.vue +0 -55
- package/dist/runtime/components/Form/InputWYSIWYG/index.vue +0 -230
- package/dist/runtime/components/Form/InputWYSIWYG/types.d.ts +0 -19
- package/dist/runtime/components/Form/InputWYSIWYG/types.mjs +0 -0
- package/dist/runtime/components/Icon.vue +0 -23
- package/dist/runtime/components/Log.vue +0 -22
- package/dist/runtime/components/Modal/index.vue +0 -146
- package/dist/runtime/components/OTPInput.vue +0 -127
- package/dist/runtime/components/QRCode.vue +0 -22
- package/dist/runtime/components/SimplePagination.vue +0 -96
- package/dist/runtime/components/Slideover/index.vue +0 -110
- package/dist/runtime/components/Tabs/index.vue +0 -64
- package/dist/runtime/composables/loaderList.mjs +0 -52
- package/dist/runtime/composables/loaderObject.mjs +0 -52
- package/dist/runtime/composables/loaderPage.mjs +0 -229
- package/dist/runtime/composables/useConfig.mjs +0 -9
- package/dist/runtime/composables/useDialog.mjs +0 -81
- package/dist/runtime/composables/useForm.mjs +0 -18
- package/dist/runtime/core.config.d.ts +0 -14
- package/dist/runtime/core.config.mjs +0 -14
- package/dist/runtime/helpers/apiListHelper.mjs +0 -44
- package/dist/runtime/helpers/apiObjectHelper.mjs +0 -46
- package/dist/runtime/helpers/apiPageHelper.mjs +0 -270
- package/dist/runtime/plugin.mjs +0 -149
- package/dist/runtime/types/common.mjs +0 -0
- package/dist/runtime/types/config.d.ts +0 -1
- package/dist/runtime/types/config.mjs +0 -0
- package/dist/runtime/types/lib.mjs +0 -0
- package/dist/runtime/ui.config/alert.d.ts +0 -3
- package/dist/runtime/ui.config/alert.mjs +0 -6
- package/dist/runtime/ui.config/badge.d.ts +0 -3
- package/dist/runtime/ui.config/badge.mjs +0 -1
- package/dist/runtime/ui.config/breadcrumb.d.ts +0 -1
- package/dist/runtime/ui.config/breadcrumb.mjs +0 -7
- package/dist/runtime/ui.config/button.d.ts +0 -3
- package/dist/runtime/ui.config/button.mjs +0 -8
- package/dist/runtime/ui.config/buttonGroup.d.ts +0 -3
- package/dist/runtime/ui.config/buttonGroup.mjs +0 -1
- package/dist/runtime/ui.config/card.d.ts +0 -1
- package/dist/runtime/ui.config/card.mjs +0 -2
- package/dist/runtime/ui.config/checkbox.d.ts +0 -3
- package/dist/runtime/ui.config/checkbox.mjs +0 -1
- package/dist/runtime/ui.config/formGroup.d.ts +0 -3
- package/dist/runtime/ui.config/formGroup.mjs +0 -5
- package/dist/runtime/ui.config/icon.d.ts +0 -3
- package/dist/runtime/ui.config/icon.mjs +0 -3
- package/dist/runtime/ui.config/index.d.ts +0 -16
- package/dist/runtime/ui.config/index.mjs +0 -16
- package/dist/runtime/ui.config/input.d.ts +0 -3
- package/dist/runtime/ui.config/input.mjs +0 -5
- package/dist/runtime/ui.config/modal.d.ts +0 -1
- package/dist/runtime/ui.config/modal.mjs +0 -34
- package/dist/runtime/ui.config/notification.d.ts +0 -11
- package/dist/runtime/ui.config/notification.mjs +0 -13
- package/dist/runtime/ui.config/notifications.d.ts +0 -3
- package/dist/runtime/ui.config/notifications.mjs +0 -3
- package/dist/runtime/ui.config/pagination.d.ts +0 -3
- package/dist/runtime/ui.config/pagination.mjs +0 -37
- package/dist/runtime/ui.config/select.d.ts +0 -3
- package/dist/runtime/ui.config/select.mjs +0 -5
- package/dist/runtime/ui.config/selectMenu.d.ts +0 -3
- package/dist/runtime/ui.config/selectMenu.mjs +0 -5
- package/dist/runtime/ui.config/slideover.d.ts +0 -1
- package/dist/runtime/ui.config/slideover.mjs +0 -16
- package/dist/runtime/ui.config/table.d.ts +0 -3
- package/dist/runtime/ui.config/table.mjs +0 -47
- package/dist/runtime/ui.config/tabs.d.ts +0 -3
- package/dist/runtime/ui.config/tabs.mjs +0 -4
- package/dist/runtime/ui.config/tags.d.ts +0 -25
- package/dist/runtime/ui.config/tags.mjs +0 -25
- package/dist/runtime/ui.config/textarea.d.ts +0 -3
- package/dist/runtime/ui.config/textarea.mjs +0 -5
- package/dist/runtime/ui.config/toggle.d.ts +0 -3
- package/dist/runtime/ui.config/toggle.mjs +0 -5
- package/dist/runtime/ui.config/uploadDropzoneImage.d.ts +0 -83
- package/dist/runtime/ui.config/uploadDropzoneImage.mjs +0 -26
- package/dist/runtime/ui.config/uploadFileDropzone.d.ts +0 -61
- package/dist/runtime/ui.config/uploadFileDropzone.mjs +0 -61
- package/dist/runtime/ui.config/uploadFileInputClassicAuto.d.ts +0 -8
- package/dist/runtime/ui.config/uploadFileInputClassicAuto.mjs +0 -8
- package/dist/runtime/ui.config/uploadImage.d.ts +0 -34
- package/dist/runtime/ui.config/uploadImage.mjs +0 -36
- package/dist/runtime/ui.css +0 -1
- package/dist/runtime/utils/ArrayHelper.spec.d.ts +0 -1
- package/dist/runtime/utils/ArrayHelper.spec.mjs +0 -112
- package/dist/runtime/utils/FileHelper.spec.d.ts +0 -1
- package/dist/runtime/utils/FileHelper.spec.mjs +0 -14
- package/dist/runtime/utils/ObjectHelper.spec.d.ts +0 -1
- package/dist/runtime/utils/ObjectHelper.spec.mjs +0 -52
- package/dist/runtime/utils/ParamHelper.spec.d.ts +0 -1
- package/dist/runtime/utils/ParamHelper.spec.mjs +0 -78
- package/dist/runtime/utils/StringHelper.spec.d.ts +0 -1
- package/dist/runtime/utils/StringHelper.spec.mjs +0 -76
- package/dist/runtime/utils/TimeHelper.spec.d.ts +0 -1
- package/dist/runtime/utils/TimeHelper.spec.mjs +0 -79
- package/dist/runtime/utils/TimeHelper.thai.spec.d.ts +0 -1
- package/dist/runtime/utils/TimeHelper.thai.spec.mjs +0 -31
- package/dist/types.d.ts +0 -16
- package/dist/runtime/components/FlexDeck/{types.mjs → types.js} +0 -0
- package/dist/runtime/components/Form/InputCheckbox/{types.mjs → types.js} +0 -0
- package/dist/runtime/components/Form/InputDateTime/{date_time_field.types.mjs → date_time_field.types.js} +0 -0
- package/dist/runtime/components/Form/{InputDateTimeRange/date_range_time_field.types.mjs → InputNumber/types.js} +0 -0
- package/dist/runtime/components/Form/{InputNumber/types.mjs → InputSelect/types.js} +0 -0
- package/dist/runtime/components/Form/{InputRadio/types.mjs → InputSelectMultiple/types.js} +0 -0
- package/dist/runtime/components/Form/{InputSelect/types.mjs → InputText/types.js} +0 -0
- package/dist/runtime/components/Form/{InputSelectMultiple/types.mjs → InputTextarea/types.js} +0 -0
- package/dist/runtime/components/Form/{InputStatic/types.mjs → InputToggle/types.js} +0 -0
- package/dist/runtime/components/Form/{types.mjs → types.js} +0 -0
- package/dist/runtime/composables/{useWatch.mjs → useWatch.js} +0 -0
- package/dist/runtime/lib/{Requester.mjs → Requester.js} +0 -0
- package/dist/runtime/{components/Form/InputTags/types.mjs → types/common.js} +0 -0
- package/dist/runtime/{components/Form/InputText/types.mjs → types/lib.js} +0 -0
- package/dist/runtime/utils/{FileHelper.mjs → FileHelper.js} +0 -0
- package/dist/runtime/utils/{StringHelper.mjs → StringHelper.js} +0 -0
- package/dist/runtime/utils/{TimeHelper.mjs → TimeHelper.js} +1 -1
- /package/dist/runtime/utils/{lodash.mjs → lodash.js} +0 -0
|
@@ -1,27 +1,61 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<FieldWrapper v-bind="wrapperProps">
|
|
3
|
-
<
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
:
|
|
7
|
-
:
|
|
8
|
-
:
|
|
9
|
-
:
|
|
10
|
-
:
|
|
11
|
-
:
|
|
12
|
-
:
|
|
13
|
-
:
|
|
14
|
-
:
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<FieldWrapper v-bind="wrapperProps">
|
|
3
|
+
<InputNumber
|
|
4
|
+
:model-value="value"
|
|
5
|
+
:disabled="wrapperProps.disabled"
|
|
6
|
+
:name="name"
|
|
7
|
+
:placeholder="wrapperProps.placeholder"
|
|
8
|
+
:autofocus="!!autoFocus"
|
|
9
|
+
:readonly="readonly"
|
|
10
|
+
:orientation="orientation"
|
|
11
|
+
:increment-disabled="incrementDisabled"
|
|
12
|
+
:decrement-disabled="decrementDisabled"
|
|
13
|
+
:min="min"
|
|
14
|
+
:max="max"
|
|
15
|
+
:step="step"
|
|
16
|
+
:disable-wheel-change="disableWheelChange"
|
|
17
|
+
:format-options="formatOptions"
|
|
18
|
+
:ui="ui"
|
|
19
|
+
@update:model-value="onChange"
|
|
20
|
+
/>
|
|
21
|
+
</FieldWrapper>
|
|
22
|
+
</template>
|
|
23
|
+
|
|
24
|
+
<script setup>
|
|
25
|
+
import { useFieldHOC } from "#core/composables/useForm";
|
|
26
|
+
import FieldWrapper from "#core/components/Form/FieldWrapper.vue";
|
|
27
|
+
const emits = defineEmits(["change"]);
|
|
28
|
+
const props = defineProps({
|
|
29
|
+
orientation: { type: null, required: false, default: "vertical" },
|
|
30
|
+
incrementDisabled: { type: null, required: false },
|
|
31
|
+
decrementDisabled: { type: null, required: false },
|
|
32
|
+
min: { type: null, required: false },
|
|
33
|
+
max: { type: null, required: false },
|
|
34
|
+
step: { type: null, required: false },
|
|
35
|
+
disableWheelChange: { type: null, required: false },
|
|
36
|
+
formatOptions: { type: null, required: false },
|
|
37
|
+
form: { type: Object, required: false },
|
|
38
|
+
name: { type: String, required: true },
|
|
39
|
+
errorMessage: { type: String, required: false },
|
|
40
|
+
label: { type: null, required: false },
|
|
41
|
+
description: { type: String, required: false },
|
|
42
|
+
hint: { type: String, required: false },
|
|
43
|
+
rules: { type: null, required: false },
|
|
44
|
+
autoFocus: { type: Boolean, required: false },
|
|
45
|
+
placeholder: { type: String, required: false },
|
|
46
|
+
disabled: { type: Boolean, required: false },
|
|
47
|
+
readonly: { type: Boolean, required: false },
|
|
48
|
+
required: { type: Boolean, required: false },
|
|
49
|
+
help: { type: String, required: false },
|
|
50
|
+
ui: { type: null, required: false }
|
|
51
|
+
});
|
|
52
|
+
const {
|
|
53
|
+
value,
|
|
54
|
+
wrapperProps,
|
|
55
|
+
handleChange
|
|
56
|
+
} = useFieldHOC(props);
|
|
57
|
+
const onChange = (value2) => {
|
|
58
|
+
handleChange(value2);
|
|
59
|
+
emits("change", value2);
|
|
60
|
+
};
|
|
61
|
+
</script>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { INumberFieldProps } from '#core/components/Form/InputNumber/types';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<INumberFieldProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, any, string, import("vue").PublicProps, any, {
|
|
3
|
+
orientation: "horizontal" | "vertical";
|
|
4
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
5
|
+
export default _default;
|
|
@@ -1,10 +1,15 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { IFieldProps, IFormFieldBase, INPUT_TYPES } from '#core/components/Form/types';
|
|
2
|
+
import type { InputNumberProps } from '#ui/components/InputNumber.vue';
|
|
2
3
|
export interface INumberFieldProps extends IFieldProps {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
4
|
+
orientation?: InputNumberProps['orientation'];
|
|
5
|
+
incrementDisabled?: InputNumberProps['incrementDisabled'];
|
|
6
|
+
decrementDisabled?: InputNumberProps['decrementDisabled'];
|
|
7
|
+
min?: InputNumberProps['min'];
|
|
8
|
+
max?: InputNumberProps['max'];
|
|
9
|
+
step?: InputNumberProps['step'];
|
|
10
|
+
disableWheelChange?: InputNumberProps['disableWheelChange'];
|
|
11
|
+
formatOptions?: InputNumberProps['formatOptions'];
|
|
6
12
|
}
|
|
7
13
|
export type INumberField = IFormFieldBase<INPUT_TYPES.NUMBER, INumberFieldProps, {
|
|
8
14
|
change?: (value: string) => void;
|
|
9
|
-
blur?: (value: string) => void;
|
|
10
15
|
}>;
|
|
@@ -1,55 +1,95 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<FieldWrapper v-bind="wrapperProps">
|
|
3
|
-
<
|
|
4
|
-
:model-value="value"
|
|
5
|
-
:
|
|
6
|
-
:
|
|
7
|
-
:
|
|
8
|
-
:
|
|
9
|
-
:
|
|
10
|
-
:
|
|
11
|
-
value-
|
|
12
|
-
|
|
13
|
-
:icon="icon"
|
|
14
|
-
:
|
|
15
|
-
:
|
|
16
|
-
:
|
|
17
|
-
:
|
|
18
|
-
@update:
|
|
19
|
-
>
|
|
20
|
-
<template #
|
|
21
|
-
<div
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<FieldWrapper v-bind="wrapperProps">
|
|
3
|
+
<SelectMenu
|
|
4
|
+
:model-value="value"
|
|
5
|
+
:items="options"
|
|
6
|
+
:placeholder="wrapperProps.placeholder"
|
|
7
|
+
:disabled="wrapperProps.disabled"
|
|
8
|
+
:loading="loading"
|
|
9
|
+
:search-input="searchInput"
|
|
10
|
+
:selected-icon="selectedIcon"
|
|
11
|
+
value-key="value"
|
|
12
|
+
label-key="label"
|
|
13
|
+
:icon="icon"
|
|
14
|
+
:ui="ui"
|
|
15
|
+
:leading-icon="options.find((item) => item.value === value)?.icon"
|
|
16
|
+
:avatar="options.find((item) => item.value === value)?.avatar"
|
|
17
|
+
@update:modelValue="onChange"
|
|
18
|
+
@update:searchTerm="onSearch"
|
|
19
|
+
>
|
|
20
|
+
<template #default="{ modelValue }">
|
|
21
|
+
<div
|
|
22
|
+
v-if="value"
|
|
23
|
+
:class="theme.selectedWrapper({
|
|
24
|
+
class: [ui?.selectedWrapper]
|
|
25
|
+
})"
|
|
26
|
+
>
|
|
27
|
+
<span
|
|
28
|
+
:class="theme.selectedLabel({
|
|
29
|
+
class: [ui?.selectedLabel]
|
|
30
|
+
})"
|
|
31
|
+
>
|
|
32
|
+
{{ options.find((item) => item.value === modelValue)?.label || modelValue }}
|
|
33
|
+
</span>
|
|
34
|
+
<Icon
|
|
35
|
+
v-if="clearable"
|
|
36
|
+
:name="clearIcon"
|
|
37
|
+
:class="theme.clearIcon({
|
|
38
|
+
class: [ui?.clearIcon]
|
|
39
|
+
})"
|
|
40
|
+
@click.stop="onChange(void 0)"
|
|
41
|
+
/>
|
|
42
|
+
</div>
|
|
43
|
+
</template>
|
|
44
|
+
</SelectMenu>
|
|
45
|
+
</FieldWrapper>
|
|
46
|
+
</template>
|
|
47
|
+
|
|
48
|
+
<script setup>
|
|
49
|
+
import { computed } from "vue";
|
|
50
|
+
import FieldWrapper from "#core/components/Form/FieldWrapper.vue";
|
|
51
|
+
import { useFieldHOC } from "#core/composables/useForm";
|
|
52
|
+
import { selectMenuTheme } from "#core/theme/selectMenu";
|
|
53
|
+
import { useUiConfig } from "#core/composables/useConfig";
|
|
54
|
+
const emits = defineEmits([
|
|
55
|
+
"change"
|
|
56
|
+
// 'search',
|
|
57
|
+
]);
|
|
58
|
+
const props = defineProps({
|
|
59
|
+
icon: { type: String, required: false },
|
|
60
|
+
trailingIcon: { type: String, required: false },
|
|
61
|
+
clearIcon: { type: String, required: false, default: "ph:x-circle-fill" },
|
|
62
|
+
selectedIcon: { type: String, required: false },
|
|
63
|
+
searchInput: { type: Object, required: false },
|
|
64
|
+
clearable: { type: Boolean, required: false },
|
|
65
|
+
loading: { type: Boolean, required: false },
|
|
66
|
+
options: { type: Array, required: true },
|
|
67
|
+
form: { type: Object, required: false },
|
|
68
|
+
name: { type: String, required: true },
|
|
69
|
+
errorMessage: { type: String, required: false },
|
|
70
|
+
label: { type: null, required: false },
|
|
71
|
+
description: { type: String, required: false },
|
|
72
|
+
hint: { type: String, required: false },
|
|
73
|
+
rules: { type: null, required: false },
|
|
74
|
+
autoFocus: { type: Boolean, required: false },
|
|
75
|
+
placeholder: { type: String, required: false },
|
|
76
|
+
disabled: { type: Boolean, required: false },
|
|
77
|
+
readonly: { type: Boolean, required: false },
|
|
78
|
+
required: { type: Boolean, required: false },
|
|
79
|
+
help: { type: String, required: false },
|
|
80
|
+
ui: { type: null, required: false }
|
|
81
|
+
});
|
|
82
|
+
const theme = computed(() => useUiConfig(selectMenuTheme, "select")());
|
|
83
|
+
const {
|
|
84
|
+
value,
|
|
85
|
+
wrapperProps,
|
|
86
|
+
handleChange
|
|
87
|
+
} = useFieldHOC(props);
|
|
88
|
+
const onChange = (value2) => {
|
|
89
|
+
handleChange(value2);
|
|
90
|
+
emits("change", value2);
|
|
91
|
+
};
|
|
92
|
+
const onSearch = (value2) => {
|
|
93
|
+
emits("search", value2);
|
|
94
|
+
};
|
|
95
|
+
</script>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { ISelectFieldProps } from '#core/components/Form/InputSelect/types';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<ISelectFieldProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, any, string, import("vue").PublicProps, any, {
|
|
3
|
+
clearIcon: string;
|
|
4
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
5
|
+
export default _default;
|
|
@@ -1,17 +1,23 @@
|
|
|
1
1
|
import type { IFieldProps, IFormFieldBase, INPUT_TYPES } from '#core/components/Form/types';
|
|
2
|
-
import {
|
|
3
|
-
|
|
2
|
+
import type { SelectMenuItem } from '#ui/components/SelectMenu.vue';
|
|
3
|
+
export type SelectOption = SelectMenuItem & {
|
|
4
|
+
label?: string;
|
|
5
|
+
value?: any;
|
|
6
|
+
};
|
|
4
7
|
export interface ISelectFieldProps extends IFieldProps {
|
|
5
|
-
color?: string;
|
|
6
8
|
icon?: string;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
+
trailingIcon?: string;
|
|
10
|
+
clearIcon?: string;
|
|
11
|
+
selectedIcon?: string;
|
|
12
|
+
searchInput?: {
|
|
13
|
+
placeholder?: string;
|
|
14
|
+
icon?: string;
|
|
15
|
+
};
|
|
9
16
|
clearable?: boolean;
|
|
10
17
|
loading?: boolean;
|
|
11
|
-
|
|
12
|
-
options: IOption[];
|
|
13
|
-
searchable?: ((q: string) => PromiseLike<IOption[]>) | boolean;
|
|
18
|
+
options: SelectOption[];
|
|
14
19
|
}
|
|
15
20
|
export type ISelectField = IFormFieldBase<INPUT_TYPES.SELECT, ISelectFieldProps, {
|
|
16
21
|
change?: (value: string) => void;
|
|
22
|
+
search?: (value: string) => void;
|
|
17
23
|
}>;
|
|
@@ -1,54 +1,108 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<FieldWrapper v-bind="wrapperProps">
|
|
3
|
-
<
|
|
4
|
-
:model-value="value
|
|
5
|
-
|
|
6
|
-
multiple
|
|
7
|
-
:
|
|
8
|
-
:
|
|
9
|
-
:
|
|
10
|
-
:
|
|
11
|
-
:
|
|
12
|
-
value-
|
|
13
|
-
|
|
14
|
-
:icon="icon"
|
|
15
|
-
:
|
|
16
|
-
:
|
|
17
|
-
:
|
|
18
|
-
:
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
</
|
|
1
|
+
<template>
|
|
2
|
+
<FieldWrapper v-bind="wrapperProps">
|
|
3
|
+
<SelectMenu
|
|
4
|
+
:model-value="value"
|
|
5
|
+
:items="options"
|
|
6
|
+
multiple
|
|
7
|
+
:placeholder="wrapperProps.placeholder"
|
|
8
|
+
:disabled="wrapperProps.disabled"
|
|
9
|
+
:loading="loading"
|
|
10
|
+
:search-input="searchInput"
|
|
11
|
+
:selected-icon="selectedIcon"
|
|
12
|
+
value-key="value"
|
|
13
|
+
label-key="label"
|
|
14
|
+
:icon="icon"
|
|
15
|
+
:ui="ui"
|
|
16
|
+
:ignore-filter="!!$attrs.onSearch"
|
|
17
|
+
@update:model-value="onChange"
|
|
18
|
+
@update:searchTerm="onSearch"
|
|
19
|
+
>
|
|
20
|
+
<template #default="{ modelValue }">
|
|
21
|
+
<div
|
|
22
|
+
v-if="!ArrayHelper.isEmpty(value)"
|
|
23
|
+
:class="theme.tagsWrapper({
|
|
24
|
+
class: [ui?.tagsWrapper]
|
|
25
|
+
})"
|
|
26
|
+
>
|
|
27
|
+
<div
|
|
28
|
+
v-for="_value in ArrayHelper.toArray(modelValue)"
|
|
29
|
+
:key="_value"
|
|
30
|
+
:class="theme.tagsItem({
|
|
31
|
+
class: [ui?.tagsItem]
|
|
32
|
+
})"
|
|
33
|
+
>
|
|
34
|
+
<div
|
|
35
|
+
:class="theme.tagsItemText({
|
|
36
|
+
class: [ui?.tagsItemText]
|
|
37
|
+
})"
|
|
38
|
+
>
|
|
39
|
+
{{ options.find((item) => item.value === _value)?.label || _value }}
|
|
40
|
+
<Icon
|
|
41
|
+
:name="theme.tagsItemDeleteIcon({
|
|
42
|
+
class: [ui?.tagsItemDeleteIcon]
|
|
43
|
+
})"
|
|
44
|
+
:class="theme.tagsItemDelete({
|
|
45
|
+
class: [ui?.tagsItemDelete]
|
|
46
|
+
})"
|
|
47
|
+
@click.stop="handleDelete(_value)"
|
|
48
|
+
/>
|
|
49
|
+
</div>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
</template>
|
|
53
|
+
</SelectMenu>
|
|
54
|
+
</FieldWrapper>
|
|
55
|
+
</template>
|
|
56
|
+
|
|
57
|
+
<script setup>
|
|
58
|
+
import { computed } from "vue";
|
|
59
|
+
import { ArrayHelper } from "#core/utils/ArrayHelper";
|
|
60
|
+
import FieldWrapper from "#core/components/Form/FieldWrapper.vue";
|
|
61
|
+
import { useFieldHOC } from "#core/composables/useForm";
|
|
62
|
+
import { useUiConfig } from "#core/composables/useConfig";
|
|
63
|
+
import { selectMenuTheme } from "#core/theme/selectMenu";
|
|
64
|
+
const emits = defineEmits([
|
|
65
|
+
"change"
|
|
66
|
+
// 'search',
|
|
67
|
+
]);
|
|
68
|
+
const props = defineProps({
|
|
69
|
+
icon: { type: String, required: false },
|
|
70
|
+
trailingIcon: { type: String, required: false },
|
|
71
|
+
clearIcon: { type: String, required: false },
|
|
72
|
+
selectedIcon: { type: String, required: false },
|
|
73
|
+
searchInput: { type: Object, required: false },
|
|
74
|
+
clearable: { type: Boolean, required: false },
|
|
75
|
+
loading: { type: Boolean, required: false },
|
|
76
|
+
options: { type: Array, required: true },
|
|
77
|
+
form: { type: Object, required: false },
|
|
78
|
+
name: { type: String, required: true },
|
|
79
|
+
errorMessage: { type: String, required: false },
|
|
80
|
+
label: { type: null, required: false },
|
|
81
|
+
description: { type: String, required: false },
|
|
82
|
+
hint: { type: String, required: false },
|
|
83
|
+
rules: { type: null, required: false },
|
|
84
|
+
autoFocus: { type: Boolean, required: false },
|
|
85
|
+
placeholder: { type: String, required: false },
|
|
86
|
+
disabled: { type: Boolean, required: false },
|
|
87
|
+
readonly: { type: Boolean, required: false },
|
|
88
|
+
required: { type: Boolean, required: false },
|
|
89
|
+
help: { type: String, required: false },
|
|
90
|
+
ui: { type: null, required: false }
|
|
91
|
+
});
|
|
92
|
+
const theme = computed(() => useUiConfig(selectMenuTheme, "select")());
|
|
93
|
+
const {
|
|
94
|
+
value,
|
|
95
|
+
wrapperProps,
|
|
96
|
+
handleChange
|
|
97
|
+
} = useFieldHOC(props);
|
|
98
|
+
const onChange = (value2) => {
|
|
99
|
+
handleChange(value2);
|
|
100
|
+
emits("change", value2);
|
|
101
|
+
};
|
|
102
|
+
const onSearch = (value2) => {
|
|
103
|
+
emits("search", value2);
|
|
104
|
+
};
|
|
105
|
+
const handleDelete = (_value) => {
|
|
106
|
+
value.value = ArrayHelper.toArray(value.value).filter((item) => item !== _value);
|
|
107
|
+
};
|
|
108
|
+
</script>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { ISelectFieldProps } from '#core/components/Form/InputSelect/types';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<ISelectFieldProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, any, string, import("vue").PublicProps, any, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
3
|
+
export default _default;
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
import type { IFieldProps, IFormFieldBase, INPUT_TYPES } from '#core/components/Form/types';
|
|
2
|
-
import {
|
|
3
|
-
import type { SelectSize } from '#ui/types';
|
|
2
|
+
import type { SelectOption } from '#core/components/Form/InputSelect/types';
|
|
4
3
|
export interface ISelectMultipleFieldProps extends IFieldProps {
|
|
5
|
-
color?: string;
|
|
6
4
|
icon?: string;
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
trailingIcon?: string;
|
|
6
|
+
selectedIcon?: string;
|
|
7
|
+
searchInput?: {
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
icon?: string;
|
|
10
|
+
};
|
|
9
11
|
loading?: boolean;
|
|
10
|
-
|
|
11
|
-
options: IOption[];
|
|
12
|
-
badgeUi?: object | any;
|
|
12
|
+
options: SelectOption[];
|
|
13
13
|
}
|
|
14
14
|
export type ISelectMultipleField = IFormFieldBase<INPUT_TYPES.SELECT_MULTIPLE, ISelectMultipleFieldProps, {
|
|
15
15
|
change?: (value: string) => void;
|
|
16
|
+
search?: (value: string) => void;
|
|
16
17
|
}>;
|