flame-plus 0.1.33 → 0.1.35
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/.browserslistrc +3 -0
- package/.env +0 -0
- package/.eslintrc.js +20 -0
- package/README.md +1 -7
- package/package.json +48 -23
- package/{src/packages → packages}/components/base/flmButton/flmButton.vue +1 -1
- package/{src/packages → packages}/components/base/flmCascader/flmCascader.vue +1 -1
- package/{src/packages → packages}/components/base/flmCheckbox/flmCheckbox.vue +1 -1
- package/{src/packages → packages}/components/base/flmCheckbox/flmCheckboxGroup.vue +1 -1
- package/{src/packages → packages}/components/base/flmColorPicker/flmColorPicker.vue +1 -1
- package/{src/packages → packages}/components/base/flmDatePicker/flmDatePicker.vue +1 -1
- package/{src/packages → packages}/components/base/flmDialog/flmDialog.vue +1 -1
- package/{src/packages → packages}/components/base/flmInput/flmInput.vue +1 -1
- package/{src/packages → packages}/components/base/flmInputNumber/flmInputNumber.vue +1 -1
- package/{src/packages → packages}/components/base/flmPagination/flmPagination.vue +1 -1
- package/{src/packages → packages}/components/base/flmRadio/flmRadio.vue +1 -1
- package/{src/packages → packages}/components/base/flmRate/flmRate.vue +1 -1
- package/{src/packages → packages}/components/base/flmRead/flmRead.vue +2 -2
- package/{src/packages → packages}/components/base/flmSelect/flmSelect.vue +1 -1
- package/{src/packages → packages}/components/base/flmSlider/flmSlider.vue +1 -1
- package/{src/packages → packages}/components/base/flmSwitch/flmSwitch.vue +1 -1
- package/{src/packages → packages}/components/base/flmTimePicker/flmTimePicker.vue +1 -1
- package/{src/packages → packages}/components/base/flmTimeSelect/flmTimeSelect.vue +1 -1
- package/{src/packages → packages}/components/base/flmTransfer/flmTransfer.vue +1 -1
- package/{src/packages → packages}/components/complex/flmForm/flmForm.vue +1 -2
- package/{src/packages → packages}/components/complex/flmSearch/flmSearch.vue +1 -1
- package/{src/packages → packages}/components/complex/flmTable/flmTable.vue +1 -1
- package/{src/packages → packages}/components/complex/flmToolbar/flmToolbar.vue +2 -2
- package/{src/packages → packages}/components/index.ts +1 -2
- package/{src/packages → packages}/components/page/flmReportPage/flmReportPage.vue +122 -79
- package/packages/index.ts +8 -0
- package/packages/model/flmComponentConfig/base/flmButton.ts +53 -0
- package/packages/model/flmComponentConfig/base/flmCascader.ts +77 -0
- package/packages/model/flmComponentConfig/base/flmCheckbox.ts +51 -0
- package/packages/model/flmComponentConfig/base/flmColorPicker.ts +30 -0
- package/packages/model/flmComponentConfig/base/flmDatePicker.ts +73 -0
- package/packages/model/flmComponentConfig/base/flmDialog.ts +49 -0
- package/packages/model/flmComponentConfig/base/flmInput.ts +57 -0
- package/packages/model/flmComponentConfig/base/flmInputNumber.ts +37 -0
- package/packages/model/flmComponentConfig/base/flmPagination.ts +37 -0
- package/packages/model/flmComponentConfig/base/flmRadio.ts +42 -0
- package/packages/model/flmComponentConfig/base/flmRate.ts +49 -0
- package/packages/model/flmComponentConfig/base/flmRead.ts +6 -0
- package/packages/model/flmComponentConfig/base/flmSelect.ts +104 -0
- package/packages/model/flmComponentConfig/base/flmSlider.ts +51 -0
- package/packages/model/flmComponentConfig/base/flmSwitch.ts +37 -0
- package/packages/model/flmComponentConfig/base/flmTimePicker.ts +61 -0
- package/packages/model/flmComponentConfig/base/flmTimeSelect.ts +44 -0
- package/packages/model/flmComponentConfig/base/flmTransfer.ts +51 -0
- package/packages/model/flmComponentConfig/complex/flmForm.ts +147 -0
- package/packages/model/flmComponentConfig/complex/flmSearch.ts +5 -0
- package/packages/model/flmComponentConfig/complex/flmTable.ts +132 -0
- package/packages/model/flmComponentConfig/complex/flmToolbar.ts +13 -0
- package/packages/model/flmComponentConfig/index.ts +31 -0
- package/packages/model/flmComponentConfig/page/flmReportPage.ts +31 -0
- package/packages/model/flmComponentConfig/public.ts +293 -0
- package/tsconfig.json +73 -20
- package/typings/lodash.d.ts +4 -0
- package/webpack.config.js +15 -0
- package/.vscode/extensions.json +0 -3
- package/flameDist/flame-plus.es.js +0 -5128
- package/flameDist/flame-plus.es.js.map +0 -1
- package/flameDist/flame-plus.umd.js +0 -16
- package/flameDist/flame-plus.umd.js.map +0 -1
- package/flameDist/style.css +0 -1
- package/flameDist/vite.svg +0 -1
- package/index.html +0 -13
- package/pnpm-lock.yaml +0 -2107
- package/public/vite.svg +0 -1
- package/src/App.vue +0 -10
- package/src/assets/vue.svg +0 -1
- package/src/components/HelloWorld.vue +0 -33
- package/src/main.ts +0 -19
- package/src/packages/components/page/flmExportPage/flmExportPage.vue +0 -219
- package/src/packages/index.ts +0 -96
- package/src/shims-vue.d.ts +0 -9
- package/vite.config.js +0 -37
- /package/{src/packages → packages}/utils/filterConfig.ts +0 -0
- /package/{src/packages → packages}/utils/index.ts +0 -0
- /package/{src/packages → packages}/utils/isValidKey.ts +0 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/** @dialog 弹窗 */
|
|
2
|
+
// 弹窗设置(https://element-plus.gitee.io/zh-CN/component/dialog.html)
|
|
3
|
+
export interface DialogConfig {
|
|
4
|
+
// 默认属性
|
|
5
|
+
'model-value'?: boolean
|
|
6
|
+
'title'?: string
|
|
7
|
+
'width'?: string | number
|
|
8
|
+
'fullscreen'?: false
|
|
9
|
+
'top'?: string
|
|
10
|
+
'modal'?: boolean
|
|
11
|
+
'append-to-body'?: boolean
|
|
12
|
+
'lock-scroll'?: boolean
|
|
13
|
+
'custom-class'?: string
|
|
14
|
+
'open-delay'?: number
|
|
15
|
+
'close-delay'?: number
|
|
16
|
+
'close-on-click-modal'?: boolean
|
|
17
|
+
'close-on-press-escape'?: boolean
|
|
18
|
+
'show-close'?: boolean
|
|
19
|
+
'before-close'?: Function
|
|
20
|
+
'draggable'?: boolean
|
|
21
|
+
'center'?: boolean
|
|
22
|
+
'destroy-on-close'?: boolean
|
|
23
|
+
}
|
|
24
|
+
// 日期选择器默认事件
|
|
25
|
+
export interface DialogDefaultEvent {
|
|
26
|
+
'onOpen': () => void,
|
|
27
|
+
'onOpened': () => void,
|
|
28
|
+
'onClose': () => void,
|
|
29
|
+
'onClosed': () => void,
|
|
30
|
+
'onOpenAutoFocus': () => void,
|
|
31
|
+
'onCloseAutoFocus': () => void,
|
|
32
|
+
}
|
|
33
|
+
// 弹窗默认设置
|
|
34
|
+
export const dialogDefaultConfig: DialogConfig = {
|
|
35
|
+
'width': '50%',
|
|
36
|
+
'fullscreen': false,
|
|
37
|
+
'top': '15vh',
|
|
38
|
+
'modal': true,
|
|
39
|
+
'append-to-body': false,
|
|
40
|
+
'lock-scroll': true,
|
|
41
|
+
'open-delay': 0,
|
|
42
|
+
'close-delay': 0,
|
|
43
|
+
'close-on-click-modal': true,
|
|
44
|
+
'close-on-press-escape': true,
|
|
45
|
+
'show-close': true,
|
|
46
|
+
'draggable': false,
|
|
47
|
+
'center': false,
|
|
48
|
+
'destroy-on-close': false,
|
|
49
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { ElementSize } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @input 输入框 */
|
|
4
|
+
// 输入框设置(https://element-plus.gitee.io/zh-CN/component/input.html)
|
|
5
|
+
export interface InputConfig {
|
|
6
|
+
// 默认属性
|
|
7
|
+
'type'?: 'text' | 'textarea'
|
|
8
|
+
'modelValue'?: string | number
|
|
9
|
+
'maxlength'?: string | number
|
|
10
|
+
'minlength'?: string | number
|
|
11
|
+
'show-word-limit'?: boolean
|
|
12
|
+
'placeholder'?: string
|
|
13
|
+
'clearable'?: boolean
|
|
14
|
+
'show-password'?: boolean
|
|
15
|
+
'disabled'?: boolean
|
|
16
|
+
'size'?: ElementSize
|
|
17
|
+
'prefix-icon'?: string
|
|
18
|
+
'suffix-icon'?: string
|
|
19
|
+
'rows'?: number
|
|
20
|
+
'autosize'?: boolean | { minRows: number, maxRows: number }
|
|
21
|
+
'autocomplete'?: string
|
|
22
|
+
'name'?: string
|
|
23
|
+
'readonly'?: boolean
|
|
24
|
+
'max'?: any
|
|
25
|
+
'min'?: any
|
|
26
|
+
'step'?: any
|
|
27
|
+
'resize'?: 'none' | 'both' | 'horizontal' | 'vertical'
|
|
28
|
+
'autofocus'?: boolean
|
|
29
|
+
'form'?: string
|
|
30
|
+
'label'?: string
|
|
31
|
+
'tabindex'?: string | number
|
|
32
|
+
'validate-event'?: boolean
|
|
33
|
+
'input-style'?: object
|
|
34
|
+
}
|
|
35
|
+
// 输入框默认事件
|
|
36
|
+
export interface InputDefaultEvent {
|
|
37
|
+
'onBlur': () => void,
|
|
38
|
+
'onFocus': () => void,
|
|
39
|
+
'onChange': (value: InputConfig['modelValue']) => void,
|
|
40
|
+
'onInput': (value: InputConfig['modelValue']) => void,
|
|
41
|
+
'onClear': () => void,
|
|
42
|
+
}
|
|
43
|
+
// 输入框默认设置
|
|
44
|
+
export const inputDefaultConfig: InputConfig = {
|
|
45
|
+
'type': 'text',
|
|
46
|
+
'show-word-limit': false,
|
|
47
|
+
'clearable': false,
|
|
48
|
+
'show-password': false,
|
|
49
|
+
'disabled': false,
|
|
50
|
+
'rows': 2,
|
|
51
|
+
'autosize': false,
|
|
52
|
+
'autocomplete': 'off',
|
|
53
|
+
'readonly': false,
|
|
54
|
+
'autofocus': false,
|
|
55
|
+
'validate-event': true,
|
|
56
|
+
'input-style': {},
|
|
57
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { ElementSize } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @inputNumber 数字输入框 */
|
|
4
|
+
// 数字输入框设置(https://element-plus.gitee.io/zh-CN/component/input-number.html)
|
|
5
|
+
export interface InputNumberConfig {
|
|
6
|
+
// 默认属性
|
|
7
|
+
'model-value'?: number | undefined
|
|
8
|
+
'min'?: number
|
|
9
|
+
'max'?: number
|
|
10
|
+
'step'?: number
|
|
11
|
+
'step-strictly'?: boolean
|
|
12
|
+
'precision'?: number
|
|
13
|
+
'size'?: ElementSize
|
|
14
|
+
'disabled'?: boolean
|
|
15
|
+
'controls'?: boolean
|
|
16
|
+
'controls-position'?: string
|
|
17
|
+
'name'?: string
|
|
18
|
+
'label'?: string
|
|
19
|
+
'placeholder'?: string
|
|
20
|
+
'value-on-clear'?: string | number | null
|
|
21
|
+
}
|
|
22
|
+
// 数字输入框默认事件
|
|
23
|
+
export interface InputNumberDefaultEvent {
|
|
24
|
+
onChange: (value: InputNumberConfig['model-value']) => void
|
|
25
|
+
onBlur: () => void
|
|
26
|
+
onFocus: () => void
|
|
27
|
+
}
|
|
28
|
+
// 数字输入框默认设置
|
|
29
|
+
export const inputNumberDefaultConfig: InputNumberConfig = {
|
|
30
|
+
'min': -Infinity,
|
|
31
|
+
'max': Infinity,
|
|
32
|
+
'step': 1,
|
|
33
|
+
'step-strictly': false,
|
|
34
|
+
'size': ElementSize['default'],
|
|
35
|
+
'disabled': false,
|
|
36
|
+
'controls': true
|
|
37
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/** @pagination 分页 */
|
|
2
|
+
// 分页设置(https://element-plus.gitee.io/zh-CN/component/pagination.html)
|
|
3
|
+
export interface PaginationConfig {
|
|
4
|
+
'small'?: boolean
|
|
5
|
+
'background'?: boolean
|
|
6
|
+
'page-size'?: number
|
|
7
|
+
'default-page-size'?: number
|
|
8
|
+
'total'?: number
|
|
9
|
+
'page-count'?: number
|
|
10
|
+
'pager-count'?: number
|
|
11
|
+
'current-page'?: number
|
|
12
|
+
'default-current-page'?: number
|
|
13
|
+
'layout'?: string
|
|
14
|
+
'page-sizes'?: Array<number>
|
|
15
|
+
'popper-class'?: string
|
|
16
|
+
'prev-text'?: string
|
|
17
|
+
'next-text'?: string
|
|
18
|
+
'disabled'?: boolean
|
|
19
|
+
'hide-on-single-page'?: boolean
|
|
20
|
+
}
|
|
21
|
+
// 分页默认事件
|
|
22
|
+
export interface PaginationDefaultEvent {
|
|
23
|
+
'onSizeChange': (pageSize: number) => void,
|
|
24
|
+
'onCurrentChange': (current: number) => void,
|
|
25
|
+
'onPrevClick': (current: number) => void,
|
|
26
|
+
'onNextClick': (current: number) => void
|
|
27
|
+
}
|
|
28
|
+
// 分页默认设置
|
|
29
|
+
export const paginationDefaultConfig: PaginationConfig = {
|
|
30
|
+
'small': false,
|
|
31
|
+
'background': false,
|
|
32
|
+
'page-size': 10,
|
|
33
|
+
'pager-count': 7,
|
|
34
|
+
'layout': 'prev, pager, next, jumper, ->, total',
|
|
35
|
+
'page-sizes': [10, 20, 30, 40, 50, 100],
|
|
36
|
+
'disabled': false,
|
|
37
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { ElementSize } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @radio 单选框 */
|
|
4
|
+
// 单选框设置(https://element-plus.gitee.io/zh-CN/component/radio.html)
|
|
5
|
+
export interface RadioConfig {
|
|
6
|
+
// 默认属性
|
|
7
|
+
'model-value'?: string | number | boolean
|
|
8
|
+
'label'?: string | number | boolean
|
|
9
|
+
'disabled'?: boolean
|
|
10
|
+
'border'?: boolean
|
|
11
|
+
'size'?: ElementSize
|
|
12
|
+
'name'?: string
|
|
13
|
+
}
|
|
14
|
+
// 单选框组
|
|
15
|
+
export interface RadioGroupConfig {
|
|
16
|
+
// 默认属性
|
|
17
|
+
'model-value'?: string | number | boolean
|
|
18
|
+
'size'?: ElementSize
|
|
19
|
+
'disabled'?: boolean
|
|
20
|
+
'text-color'?: string
|
|
21
|
+
'fill'?: string
|
|
22
|
+
// 自定义属性
|
|
23
|
+
'useButton'?: boolean
|
|
24
|
+
'radios'?: Array<RadioConfig>
|
|
25
|
+
}
|
|
26
|
+
// 单选框默认事件
|
|
27
|
+
export interface RadioGroupDefaultEvent {
|
|
28
|
+
onChange: (value: RadioConfig['model-value']) => void
|
|
29
|
+
}
|
|
30
|
+
// 单选框默认设置
|
|
31
|
+
export const radioDefaultConfig: RadioConfig = {
|
|
32
|
+
'disabled': false,
|
|
33
|
+
'border': false
|
|
34
|
+
}
|
|
35
|
+
// 单选框组默认设置
|
|
36
|
+
export const radioGroupDefaultConfig: RadioGroupConfig = {
|
|
37
|
+
// 默认属性
|
|
38
|
+
'size': ElementSize['default'],
|
|
39
|
+
'disabled': false,
|
|
40
|
+
'text-color': '#FFF',
|
|
41
|
+
'fill': '#409EFF',
|
|
42
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { ElementSize, ElementIcons } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @rate 评分 */
|
|
4
|
+
// 评分设置(https://element-plus.gitee.io/zh-CN/component/rate.html)
|
|
5
|
+
export interface RateConfig {
|
|
6
|
+
// 默认属性
|
|
7
|
+
'model-value'?: number
|
|
8
|
+
'max'?: number
|
|
9
|
+
'size'?: ElementSize
|
|
10
|
+
'disabled'?: boolean
|
|
11
|
+
'allow-half'?: boolean
|
|
12
|
+
'low-threshold'?: number
|
|
13
|
+
'high-threshold'?: number
|
|
14
|
+
'colors'?: Array<string> | object
|
|
15
|
+
'void-color'?: string
|
|
16
|
+
'disabled-void-color'?: string
|
|
17
|
+
'icons'?: Array<ElementIcons> | object
|
|
18
|
+
'void-icon'?: ElementIcons
|
|
19
|
+
'disabled-void-icon'?: ElementIcons
|
|
20
|
+
'show-text'?: boolean
|
|
21
|
+
'show-score'?: boolean
|
|
22
|
+
'text-color'?: string
|
|
23
|
+
'texts'?: Array<string>
|
|
24
|
+
'score-template'?: string
|
|
25
|
+
}
|
|
26
|
+
// 评分默认事件
|
|
27
|
+
export interface RateDefaultEvent {
|
|
28
|
+
onChange: (value: RateConfig['model-value']) => void
|
|
29
|
+
}
|
|
30
|
+
// 评分默认设置
|
|
31
|
+
export const rateDefaultConfig: RateConfig = {
|
|
32
|
+
'model-value': 0,
|
|
33
|
+
'max': 5,
|
|
34
|
+
'size': ElementSize['default'],
|
|
35
|
+
'disabled': false,
|
|
36
|
+
'allow-half': false,
|
|
37
|
+
'low-threshold': 2,
|
|
38
|
+
'high-threshold': 4,
|
|
39
|
+
'colors': ['#F7BA2A', '#F7BA2A', '#F7BA2A'],
|
|
40
|
+
'void-color': '#C6D1DE',
|
|
41
|
+
'disabled-void-color': '#EFF2F7',
|
|
42
|
+
'icons': [ElementIcons['StarFilled'], ElementIcons['StarFilled'], ElementIcons['StarFilled']],
|
|
43
|
+
'void-icon': ElementIcons['Star'],
|
|
44
|
+
'disabled-void-icon': ElementIcons['StarFilled'],
|
|
45
|
+
'show-text': false,
|
|
46
|
+
'show-score': false,
|
|
47
|
+
'text-color': '#1F2D3D',
|
|
48
|
+
'texts': ['Extremely bad', 'Disappointed', 'Fair', 'Satisfied', 'Surprise'],
|
|
49
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import { ElementSize } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @select 选择器 */
|
|
4
|
+
|
|
5
|
+
// 标签类型
|
|
6
|
+
export enum SelectTagType {
|
|
7
|
+
'success' = 'success',
|
|
8
|
+
'info' = 'info',
|
|
9
|
+
'warning' = 'warning',
|
|
10
|
+
'danger' = 'danger',
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// 选择器设置(https://element-plus.gitee.io/zh-CN/component/select.html)
|
|
14
|
+
export interface SelectConfig {
|
|
15
|
+
// 默认属性
|
|
16
|
+
'model-value'?: string | number | boolean | object
|
|
17
|
+
'multiple'?: boolean
|
|
18
|
+
'disabled'?: boolean
|
|
19
|
+
'value-key'?: string
|
|
20
|
+
'size'?: ElementSize
|
|
21
|
+
'clearable'?: boolean
|
|
22
|
+
'collapse-tags'?: boolean
|
|
23
|
+
'collapse-tags-tooltip'?: boolean
|
|
24
|
+
'multiple-limit'?: number
|
|
25
|
+
'name'?: string
|
|
26
|
+
'effect'?: 'dark' | 'light'
|
|
27
|
+
'autocomplete'?: string
|
|
28
|
+
'placeholder'?: string
|
|
29
|
+
'filterable'?: boolean
|
|
30
|
+
'allow-create'?: boolean
|
|
31
|
+
'filter-method'?: Function
|
|
32
|
+
'remote'?: boolean
|
|
33
|
+
'remote-method'?: Function
|
|
34
|
+
'loading'?: boolean
|
|
35
|
+
'loading-text'?: string
|
|
36
|
+
'no-match-text'?: string
|
|
37
|
+
'no-data-text'?: string
|
|
38
|
+
'popper-class'?: string
|
|
39
|
+
'reserve-keyword'?: boolean
|
|
40
|
+
'default-first-option'?: boolean
|
|
41
|
+
'popper-append-to-body'?: boolean
|
|
42
|
+
'teleported'?: boolean
|
|
43
|
+
'persistent'?: boolean
|
|
44
|
+
'automatic-dropdown'?: boolean
|
|
45
|
+
'clear-icon'?: string
|
|
46
|
+
'fit-input-width'?: boolean
|
|
47
|
+
'suffix-icon'?: string
|
|
48
|
+
'tag-type'?: SelectTagType
|
|
49
|
+
// 自定义属性
|
|
50
|
+
'hasGroup'?: boolean // 是否有分组,分组使用分组选项,没有分组使用普通选项
|
|
51
|
+
'groups'?: Array<OptionGroupConfig> // 分组选项
|
|
52
|
+
'options'?: Array<OptionConfig> // 选项
|
|
53
|
+
}
|
|
54
|
+
export interface SelectDefaultEvent {
|
|
55
|
+
onChange: (value: SelectConfig['model-value']) => void,
|
|
56
|
+
onVisibleChange: (showOption: boolean) => void,
|
|
57
|
+
onRemoveTag: (tagValue: SelectConfig['model-value']) => void,
|
|
58
|
+
onClear: () => void,
|
|
59
|
+
onBlur: () => void,
|
|
60
|
+
onFocus: () => void,
|
|
61
|
+
}
|
|
62
|
+
// 选择器分组选项设置
|
|
63
|
+
export interface OptionGroupConfig {
|
|
64
|
+
'label'?: string
|
|
65
|
+
'disabled'?: boolean
|
|
66
|
+
'options'?: Array<OptionConfig>
|
|
67
|
+
}
|
|
68
|
+
// 选择器选项设置
|
|
69
|
+
export interface OptionConfig {
|
|
70
|
+
'value'?: string | number | boolean | object
|
|
71
|
+
'label'?: string | number
|
|
72
|
+
'disabled'?: boolean
|
|
73
|
+
}
|
|
74
|
+
// 选择器默认设置
|
|
75
|
+
export const selectDefaultConfig: SelectConfig = {
|
|
76
|
+
'multiple': false,
|
|
77
|
+
'disabled': false,
|
|
78
|
+
'value-key': 'value',
|
|
79
|
+
'size': ElementSize['default'],
|
|
80
|
+
'clearable': false,
|
|
81
|
+
'collapse-tags': false,
|
|
82
|
+
'collapse-tags-tooltip': false,
|
|
83
|
+
'multiple-limit': 0,
|
|
84
|
+
'effect': 'light',
|
|
85
|
+
'autocomplete': 'off',
|
|
86
|
+
'placeholder': '请选择',
|
|
87
|
+
'filterable': false,
|
|
88
|
+
'allow-create': false,
|
|
89
|
+
'remote': false,
|
|
90
|
+
'loading': false,
|
|
91
|
+
'loading-text': '加载中',
|
|
92
|
+
'no-match-text': '没有匹配的数据',
|
|
93
|
+
'no-data-text': '无数据',
|
|
94
|
+
'reserve-keyword': true,
|
|
95
|
+
'default-first-option': false,
|
|
96
|
+
'popper-append-to-body': true,
|
|
97
|
+
'teleported': true,
|
|
98
|
+
'persistent': true,
|
|
99
|
+
'automatic-dropdown': false,
|
|
100
|
+
'clear-icon': 'CircleClose',
|
|
101
|
+
'fit-input-width': false,
|
|
102
|
+
'suffix-icon': 'ArrowUp',
|
|
103
|
+
'tag-type': SelectTagType['info'],
|
|
104
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { ElementSize } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @slider 滑块 */
|
|
4
|
+
// 滑块设置(https://element-plus.gitee.io/zh-CN/component/slider.html)
|
|
5
|
+
export interface SliderConfig {
|
|
6
|
+
// 默认属性
|
|
7
|
+
'model-value'?: number
|
|
8
|
+
'min'?: number
|
|
9
|
+
'max'?: number
|
|
10
|
+
'disabled'?: boolean
|
|
11
|
+
'step'?: number
|
|
12
|
+
'show-input'?: boolean
|
|
13
|
+
'show-input-controls'?: boolean
|
|
14
|
+
'size'?: ElementSize
|
|
15
|
+
'input-size'?: ElementSize
|
|
16
|
+
'show-stops'?: boolean
|
|
17
|
+
'show-tooltip'?: boolean
|
|
18
|
+
'format-tooltip'?: Function
|
|
19
|
+
'range'?: boolean
|
|
20
|
+
'vertical'?: boolean
|
|
21
|
+
'height'?: string
|
|
22
|
+
'label'?: string
|
|
23
|
+
'range-start-label'?: string
|
|
24
|
+
'range-end-label'?: string
|
|
25
|
+
'format-value-text'?: Function
|
|
26
|
+
'debounce'?: number
|
|
27
|
+
'tooltip-class'?: string
|
|
28
|
+
'marks'?: Record<number, any>
|
|
29
|
+
}
|
|
30
|
+
// 滑块默认事件
|
|
31
|
+
export interface SliderDefaultEvent {
|
|
32
|
+
onChange: (value: SliderConfig['model-value']) => void
|
|
33
|
+
onInput: (value: SliderConfig['model-value']) => void
|
|
34
|
+
}
|
|
35
|
+
// 滑块默认设置
|
|
36
|
+
export const sliderDefaultConfig: SliderConfig = {
|
|
37
|
+
'model-value': 0,
|
|
38
|
+
'min': 0,
|
|
39
|
+
'max': 100,
|
|
40
|
+
'disabled': false,
|
|
41
|
+
'step': 1,
|
|
42
|
+
'show-input': false,
|
|
43
|
+
'show-input-controls': true,
|
|
44
|
+
'size': ElementSize['default'],
|
|
45
|
+
'input-size': ElementSize['default'],
|
|
46
|
+
'show-stops': false,
|
|
47
|
+
'show-tooltip': true,
|
|
48
|
+
'range': false,
|
|
49
|
+
'vertical': false,
|
|
50
|
+
'debounce': 300,
|
|
51
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { ElementSize } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @switch 开关 */
|
|
4
|
+
// 开关设置(https://element-plus.gitee.io/zh-CN/component/switch.html)
|
|
5
|
+
export interface SwitchConfig {
|
|
6
|
+
'model-value'?: boolean | string | number
|
|
7
|
+
'disabled'?: boolean
|
|
8
|
+
'loading'?: boolean
|
|
9
|
+
'size'?: ElementSize
|
|
10
|
+
'width'?: number
|
|
11
|
+
'inline-prompt'?: boolean
|
|
12
|
+
'active-icon'?: string
|
|
13
|
+
'inactive-icon'?: string
|
|
14
|
+
'active-text'?: string
|
|
15
|
+
'inactive-text'?: string
|
|
16
|
+
'active-value'?: boolean | string | number
|
|
17
|
+
'inactive-value'?: boolean | string | number
|
|
18
|
+
'active-color'?: string
|
|
19
|
+
'inactive-color'?: string
|
|
20
|
+
'border-color'?: string
|
|
21
|
+
'name'?: string
|
|
22
|
+
'validate-event'?: boolean
|
|
23
|
+
'before-change'?: Function
|
|
24
|
+
}
|
|
25
|
+
// 开关默认设置
|
|
26
|
+
export const switchDefaultConfig: SwitchConfig = {
|
|
27
|
+
'disabled': false,
|
|
28
|
+
'loading': false,
|
|
29
|
+
'size': ElementSize.default,
|
|
30
|
+
'width': 40,
|
|
31
|
+
'inline-prompt': false,
|
|
32
|
+
'active-value': true,
|
|
33
|
+
'inactive-value': false,
|
|
34
|
+
'active-color': '#409EFF',
|
|
35
|
+
'inactive-color': '#C0CCDA',
|
|
36
|
+
'validate-event': true,
|
|
37
|
+
}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { ElementSize, ElementIcons } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @timePicker 时间选择器 */
|
|
4
|
+
|
|
5
|
+
// 时间选择器对齐方式
|
|
6
|
+
export enum TimePickerAlign {
|
|
7
|
+
'left' = 'left',
|
|
8
|
+
'center' = 'center',
|
|
9
|
+
'right' = 'right'
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
// 时间选择器设置(https://element-plus.gitee.io/zh-CN/component/time-picker.html)
|
|
13
|
+
export interface TimePickerConfig {
|
|
14
|
+
// 默认属性
|
|
15
|
+
'model-value'?: Date
|
|
16
|
+
'readonly'?: boolean
|
|
17
|
+
'disabled'?: boolean
|
|
18
|
+
'editable'?: boolean
|
|
19
|
+
'clearable'?: boolean
|
|
20
|
+
'size'?: ElementSize
|
|
21
|
+
'placeholder'?: string
|
|
22
|
+
'start-placeholder'?: string
|
|
23
|
+
'end-placeholder'?: string
|
|
24
|
+
'is-range'?: boolean
|
|
25
|
+
'arrow-control'?: boolean
|
|
26
|
+
'align'?: TimePickerAlign
|
|
27
|
+
'popper-class'?: string
|
|
28
|
+
'range-separator'?: string
|
|
29
|
+
'format'?: string
|
|
30
|
+
'default-value'?: Date | string
|
|
31
|
+
'id'?: string | Array<string>
|
|
32
|
+
'name'?: string
|
|
33
|
+
'prefix-icon'?: ElementIcons
|
|
34
|
+
'clear-icon'?: ElementIcons
|
|
35
|
+
'disabled-hours'?: Function
|
|
36
|
+
'disabled-minutes'?: Function
|
|
37
|
+
'disabled-seconds'?: Function
|
|
38
|
+
'teleported'?: boolean
|
|
39
|
+
}
|
|
40
|
+
// 时间选择默认事件
|
|
41
|
+
export interface TimePickerDefaultEvent {
|
|
42
|
+
'onUpdate:modelValue': (value: TimePickerConfig['model-value']) => void, // v-model 不用改不了值
|
|
43
|
+
// 'onChange': (value: TimePickerConfig['model-value']) => void,
|
|
44
|
+
'onBlur': (event: any) => void,
|
|
45
|
+
'onFocus': (event: any) => void,
|
|
46
|
+
'onVisibleChange': (event: boolean) => void,
|
|
47
|
+
}
|
|
48
|
+
// 时间选择器默认设置
|
|
49
|
+
export const timePickerDefaultConfig: TimePickerConfig = {
|
|
50
|
+
'readonly': false,
|
|
51
|
+
'disabled': false,
|
|
52
|
+
'editable': true,
|
|
53
|
+
'clearable': true,
|
|
54
|
+
'is-range': false,
|
|
55
|
+
'arrow-control': false,
|
|
56
|
+
'align': TimePickerAlign['left'],
|
|
57
|
+
'format': 'HH:mm:ss',
|
|
58
|
+
'prefix-icon': ElementIcons['Clock'],
|
|
59
|
+
'clear-icon': ElementIcons['CircleClose'],
|
|
60
|
+
'teleported': true,
|
|
61
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { ElementSize, ElementIcons } from '../../../model/flmComponentConfig'
|
|
2
|
+
|
|
3
|
+
/** @timeSelect 时间选择 */
|
|
4
|
+
// 时间选择设置(https://element-plus.gitee.io/zh-CN/component/time-select.html)
|
|
5
|
+
export interface TimeSelectConfig {
|
|
6
|
+
// 默认属性
|
|
7
|
+
'model-value'?: string
|
|
8
|
+
'disabled'?: boolean
|
|
9
|
+
'editable'?: boolean
|
|
10
|
+
'clearable'?: boolean
|
|
11
|
+
'size'?: ElementSize
|
|
12
|
+
'placeholder'?: string
|
|
13
|
+
'name'?: string
|
|
14
|
+
'effect'?: string
|
|
15
|
+
'prefix-icon'?: ElementIcons
|
|
16
|
+
'clear-icon'?: ElementIcons
|
|
17
|
+
'start'?: string
|
|
18
|
+
'end'?: string
|
|
19
|
+
'step'?: string
|
|
20
|
+
'min-time'?: string
|
|
21
|
+
'max-time'?: string
|
|
22
|
+
'format'?: string
|
|
23
|
+
}
|
|
24
|
+
// 时间选择默认事件
|
|
25
|
+
export interface TimeSelectDefaultEvent {
|
|
26
|
+
onChange: (value: TimeSelectConfig['model-value']) => void
|
|
27
|
+
onBlur: () => void
|
|
28
|
+
onFocus: () => void
|
|
29
|
+
}
|
|
30
|
+
// 时间选择默认设置
|
|
31
|
+
export const timeSelectDefaultConfig: TimeSelectConfig = {
|
|
32
|
+
'disabled': false,
|
|
33
|
+
'editable': true,
|
|
34
|
+
'clearable': true,
|
|
35
|
+
'size': ElementSize['default'],
|
|
36
|
+
'effect': 'light',
|
|
37
|
+
'prefix-icon': ElementIcons['Clock'],
|
|
38
|
+
'clear-icon': ElementIcons['CircleClose'],
|
|
39
|
+
'start': '09:00',
|
|
40
|
+
'end': '18:00',
|
|
41
|
+
'step': '00:30',
|
|
42
|
+
'min-time': '00:00',
|
|
43
|
+
'format': 'HH:mm',
|
|
44
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/** @transfer 穿梭框 */
|
|
2
|
+
|
|
3
|
+
// 右侧排序方式
|
|
4
|
+
export enum TargetSort {
|
|
5
|
+
'original' = 'original', // 和原始数据一致
|
|
6
|
+
'push' = 'push', // 新元素在最后
|
|
7
|
+
'unshift' = 'unshift', // 新元素在最前
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
// 数据单项格式
|
|
11
|
+
export interface TransferItem {
|
|
12
|
+
key?: any
|
|
13
|
+
label?: any
|
|
14
|
+
disabled?: any
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
// 穿梭框设置(https://element-plus.gitee.io/zh-CN/component/transfer.html)
|
|
18
|
+
export interface TransferConfig {
|
|
19
|
+
// 默认属性
|
|
20
|
+
'model-value'?: Array<TransferItem>
|
|
21
|
+
'data'?: Array<TransferItem>
|
|
22
|
+
'filterable'?: boolean
|
|
23
|
+
'filter-placeholder'?: string
|
|
24
|
+
'filter-method'?: Function
|
|
25
|
+
'target-order'?: TargetSort
|
|
26
|
+
'titles'?: Array<string>
|
|
27
|
+
'button-texts'?: Array<string>
|
|
28
|
+
'render-content'?: Function
|
|
29
|
+
'format'?: { 'noChecked'?: string, 'hasChecked'?: string }
|
|
30
|
+
'props'?: TransferItem
|
|
31
|
+
'left-default-checked'?: Array<any>
|
|
32
|
+
'right-default-checked'?: Array<any>
|
|
33
|
+
}
|
|
34
|
+
// 穿梭框默认事件
|
|
35
|
+
export interface TransferDefaultEvent {
|
|
36
|
+
onChange: (value: TransferConfig['model-value']) => void
|
|
37
|
+
onLeftCheckChange: (value: TransferConfig['model-value']) => void
|
|
38
|
+
onRightCheckChange: (value: TransferConfig['model-value']) => void
|
|
39
|
+
}
|
|
40
|
+
// 穿梭框默认设置
|
|
41
|
+
export const transferDefaultConfig: TransferConfig = {
|
|
42
|
+
'data': [],
|
|
43
|
+
'filterable': false,
|
|
44
|
+
'filter-placeholder': 'Enter keyword',
|
|
45
|
+
'target-order': TargetSort['original'],
|
|
46
|
+
'titles': ['List 1', 'List 2'],
|
|
47
|
+
'button-texts': [],
|
|
48
|
+
'format': { 'noChecked': '${checked}/${total}', 'hasChecked': '${checked}/${total}' },
|
|
49
|
+
'left-default-checked': [],
|
|
50
|
+
'right-default-checked': [],
|
|
51
|
+
}
|