@opentiny/vue-search-box-saas 2.27.1
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/index.css +334 -0
- package/index.js +2804 -0
- package/index.js.map +1 -0
- package/package.json +52 -0
- package/types/index.type.d.ts +190 -0
package/package.json
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@opentiny/vue-search-box-saas",
|
|
3
|
+
"version": "2.27.1",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"module": "index.js",
|
|
7
|
+
"types": "types/index.d.ts",
|
|
8
|
+
"sideEffects": [
|
|
9
|
+
"*.css"
|
|
10
|
+
],
|
|
11
|
+
"publishConfig": {
|
|
12
|
+
"access": "public"
|
|
13
|
+
},
|
|
14
|
+
"peerDependencies": {
|
|
15
|
+
"vue": "^2.6.14"
|
|
16
|
+
},
|
|
17
|
+
"dependencies": {
|
|
18
|
+
"@opentiny/vue-button": "^2.26.0",
|
|
19
|
+
"@opentiny/vue-checkbox": "^2.26.0",
|
|
20
|
+
"@opentiny/vue-checkbox-group": "^2.26.0",
|
|
21
|
+
"@opentiny/vue-date-picker": "^2.26.0",
|
|
22
|
+
"@opentiny/vue-dropdown": "^2.26.0",
|
|
23
|
+
"@opentiny/vue-dropdown-item": "^2.26.0",
|
|
24
|
+
"@opentiny/vue-dropdown-menu": "^2.26.0",
|
|
25
|
+
"@opentiny/vue-form": "^2.26.0",
|
|
26
|
+
"@opentiny/vue-form-item": "^2.26.0",
|
|
27
|
+
"@opentiny/vue-icon": "^2.26.0",
|
|
28
|
+
"@opentiny/vue-input": "^2.26.0",
|
|
29
|
+
"@opentiny/vue-loading": "^2.26.0",
|
|
30
|
+
"@opentiny/vue-option": "^2.26.0",
|
|
31
|
+
"@opentiny/vue-popover": "^2.26.0",
|
|
32
|
+
"@opentiny/vue-select": "^2.26.0",
|
|
33
|
+
"@opentiny/vue-tag": "^2.26.0",
|
|
34
|
+
"@opentiny/vue-tooltip": "^2.26.0",
|
|
35
|
+
"@opentiny/vue-common": "^2.26.0",
|
|
36
|
+
"@opentiny/vue-theme": "^3.26.0"
|
|
37
|
+
},
|
|
38
|
+
"keywords": [
|
|
39
|
+
"search",
|
|
40
|
+
"comprehensive search",
|
|
41
|
+
"opentiny"
|
|
42
|
+
],
|
|
43
|
+
"license": "MIT",
|
|
44
|
+
"repository": {
|
|
45
|
+
"type": "git",
|
|
46
|
+
"url": "git+https://github.com/opentiny/tiny-search-box.git"
|
|
47
|
+
},
|
|
48
|
+
"homepage": "https://github.com/opentiny/tiny-search-box#readme",
|
|
49
|
+
"bugs": {
|
|
50
|
+
"url": "https://github.com/opentiny/tiny-search-box/issues"
|
|
51
|
+
}
|
|
52
|
+
}
|
|
@@ -0,0 +1,190 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* tag类型, radio-默认单选, noValue-非正常tag,tag值为空, checkbox-多选,map-键值tag, numRange-数字范围tag,
|
|
3
|
+
* dateRange-日期范围tag。tag 的分类是根据键值的结果划分
|
|
4
|
+
*/
|
|
5
|
+
export type ISearchBoxTagType = 'radio' | 'noValue' | 'checkbox' | 'map' | 'numRange' | 'dateRange' | 'dateTimeRange';
|
|
6
|
+
/**
|
|
7
|
+
* 候选tag数据配置项
|
|
8
|
+
*/
|
|
9
|
+
export interface ISearchBoxItem {
|
|
10
|
+
/**
|
|
11
|
+
* 搜索字段,tag的键,'keyword' 作为组件内部保留字,请勿传入该值
|
|
12
|
+
*/
|
|
13
|
+
field: string;
|
|
14
|
+
/**
|
|
15
|
+
* tag 键的显示值,实际结果是field
|
|
16
|
+
*/
|
|
17
|
+
label: string;
|
|
18
|
+
/**
|
|
19
|
+
* 配置项可生产的tag类型
|
|
20
|
+
*/
|
|
21
|
+
type?: ISearchBoxTagType;
|
|
22
|
+
/**
|
|
23
|
+
* tag 值的选择项数据
|
|
24
|
+
*/
|
|
25
|
+
options?: Array<ISearchBoxOption>;
|
|
26
|
+
/**
|
|
27
|
+
* 自动识别匹配正则
|
|
28
|
+
* 10.0.2 新增
|
|
29
|
+
*/
|
|
30
|
+
regexp?: RegExp;
|
|
31
|
+
/**
|
|
32
|
+
* radio 单选类型可设置, 设置为false时,单选属性可以多次选择
|
|
33
|
+
*/
|
|
34
|
+
replace?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* 单选或多选值的选中项键值
|
|
37
|
+
* 10.0.2 新增
|
|
38
|
+
*/
|
|
39
|
+
optionValueKey?: string;
|
|
40
|
+
/**
|
|
41
|
+
* dateRange 类型日期显示和结果格式,dateRange时必选
|
|
42
|
+
*/
|
|
43
|
+
format?: string;
|
|
44
|
+
/**
|
|
45
|
+
* numRange 最小值,类型为number
|
|
46
|
+
* dateRange开始日期,类型为Date
|
|
47
|
+
*/
|
|
48
|
+
start?: number | Date;
|
|
49
|
+
/**
|
|
50
|
+
* numRange 最大值,类型为number
|
|
51
|
+
* dateRange起始日期,类型为Date
|
|
52
|
+
*/
|
|
53
|
+
end?: number | Date;
|
|
54
|
+
/**
|
|
55
|
+
* numRange 可填最小值,用于校验
|
|
56
|
+
* dateRange可选最小值,用于校验
|
|
57
|
+
*/
|
|
58
|
+
min?: number | Date;
|
|
59
|
+
/**
|
|
60
|
+
* numRange 可填最大值,用于校验
|
|
61
|
+
* dateRange可选最大值,用于校验
|
|
62
|
+
*/
|
|
63
|
+
max?: number | Date;
|
|
64
|
+
/**
|
|
65
|
+
* 每个item对应的提示文本
|
|
66
|
+
*/
|
|
67
|
+
placeholder?: string;
|
|
68
|
+
/**
|
|
69
|
+
* 搜索的字段范围
|
|
70
|
+
*/
|
|
71
|
+
searchKeys?: Array<string>;
|
|
72
|
+
/**
|
|
73
|
+
* 标识字段映射,3.13.0新增
|
|
74
|
+
*/
|
|
75
|
+
idMapKey?: string;
|
|
76
|
+
/**
|
|
77
|
+
* 标签分隔符[3.14.0新增]
|
|
78
|
+
*/
|
|
79
|
+
operator?: string;
|
|
80
|
+
/**
|
|
81
|
+
* type=checkbox时,设置是否合并成一个标签[3.16.0新增]
|
|
82
|
+
*/
|
|
83
|
+
mergeTag?: boolean;
|
|
84
|
+
[propName: string]: any;
|
|
85
|
+
}
|
|
86
|
+
export interface ISearchBoxOption {
|
|
87
|
+
/**
|
|
88
|
+
* 选项显示值
|
|
89
|
+
*/
|
|
90
|
+
label: string;
|
|
91
|
+
/**
|
|
92
|
+
* 搜索目标字段,只有‘label’才需要
|
|
93
|
+
*/
|
|
94
|
+
field?: string;
|
|
95
|
+
/**
|
|
96
|
+
* 控制map类型二级选项是否出现内置所有值,map类型需要
|
|
97
|
+
*/
|
|
98
|
+
allValues?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* 控制map类型二级选项是否出现内置空值,map类型需要
|
|
101
|
+
*/
|
|
102
|
+
emptyValue?: boolean;
|
|
103
|
+
/**
|
|
104
|
+
* map类型二级选项数据
|
|
105
|
+
*/
|
|
106
|
+
options?: Array<any>;
|
|
107
|
+
[propName: string]: any;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* 每个选中tag的类型
|
|
111
|
+
*/
|
|
112
|
+
export interface ISearchBoxTag {
|
|
113
|
+
/**
|
|
114
|
+
* 搜索目标搜字段
|
|
115
|
+
*/
|
|
116
|
+
field: string;
|
|
117
|
+
/**
|
|
118
|
+
* tag键,field的显示值
|
|
119
|
+
*/
|
|
120
|
+
label: string;
|
|
121
|
+
/**
|
|
122
|
+
* tag值
|
|
123
|
+
*/
|
|
124
|
+
value: string;
|
|
125
|
+
/**
|
|
126
|
+
* 类型
|
|
127
|
+
*/
|
|
128
|
+
type: ISearchBoxTagType;
|
|
129
|
+
/**
|
|
130
|
+
* 数字范围和日期范围tag 开始值
|
|
131
|
+
*/
|
|
132
|
+
start?: number | string;
|
|
133
|
+
/**
|
|
134
|
+
* 数字范围和日期范围tag 结束值
|
|
135
|
+
*/
|
|
136
|
+
end?: number | string;
|
|
137
|
+
[propName: string]: any;
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* 潜在匹配项的函数返回值类型
|
|
141
|
+
*/
|
|
142
|
+
interface ISearchBoxMatchItem {
|
|
143
|
+
label: string;
|
|
144
|
+
field: string;
|
|
145
|
+
value: string;
|
|
146
|
+
type?: string;
|
|
147
|
+
}
|
|
148
|
+
export interface ISearchBoxMatchOptions {
|
|
149
|
+
getMatchList: (arg1: string) => ISearchBoxMatchItem[];
|
|
150
|
+
}
|
|
151
|
+
export interface ISearchBoxNewTag {
|
|
152
|
+
/**
|
|
153
|
+
* type 新标签所属第一层元素的type类型值
|
|
154
|
+
*/
|
|
155
|
+
type: string;
|
|
156
|
+
/**
|
|
157
|
+
* field 新标签所属第一层元素的field值
|
|
158
|
+
*/
|
|
159
|
+
field: string;
|
|
160
|
+
/**
|
|
161
|
+
* label 新标签label值,即标签左侧值
|
|
162
|
+
*/
|
|
163
|
+
label: string;
|
|
164
|
+
/**
|
|
165
|
+
* value 新标签的value值,即标签右侧值
|
|
166
|
+
*/
|
|
167
|
+
value: string;
|
|
168
|
+
/**
|
|
169
|
+
* start 日期标签或大小标签的起始值,可选参数
|
|
170
|
+
*/
|
|
171
|
+
start?: string | number;
|
|
172
|
+
/**
|
|
173
|
+
* end 日期标签或大小标签的结束值,可选参数
|
|
174
|
+
*/
|
|
175
|
+
end?: string | number;
|
|
176
|
+
/**
|
|
177
|
+
* id 新标签的idMapKey对应的属性值,可用来识别标签,可以是id也可以是idMapKey指定的值,可选参数
|
|
178
|
+
*/
|
|
179
|
+
id?: string | number;
|
|
180
|
+
/**
|
|
181
|
+
* operator标签分隔符,可选参数
|
|
182
|
+
*/
|
|
183
|
+
operator?: string;
|
|
184
|
+
/**
|
|
185
|
+
* checkbox类型下使用mergeTag为true时,合并的标签信息,
|
|
186
|
+
*/
|
|
187
|
+
options?: ISearchBoxTag[];
|
|
188
|
+
}
|
|
189
|
+
export type ISearchBoxSize = '' | 'small';
|
|
190
|
+
export {};
|