fit2cloud-ui-plus 0.0.1-beta.1 → 0.0.1-beta.12

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.
Files changed (208) hide show
  1. package/README.md +61 -9
  2. package/lib/fit2cloud-ui-plus.es.js +553 -866
  3. package/lib/fit2cloud-ui-plus.umd.js +1 -1
  4. package/package.json +9 -12
  5. package/src/components/filter-bar/FuFilter.vue +19 -14
  6. package/src/components/filter-bar/FuFilterBar.vue +16 -11
  7. package/src/components/filter-bar/FuSearchInput.vue +8 -2
  8. package/src/components/filter-bar/filter-components/FuFilterDate.vue +17 -13
  9. package/src/components/filter-bar/filter-components/FuFilterDateTime.vue +16 -13
  10. package/src/components/filter-bar/filter-components/FuFilterSelect.vue +17 -12
  11. package/src/components/filter-bar/index.d.ts +2 -0
  12. package/src/components/filter-bar/index.ts +11 -12
  13. package/src/components/filter-bar/types.d.ts +22 -0
  14. package/src/components/read-write-switch/FuInputRwSwitch.vue +9 -5
  15. package/src/components/read-write-switch/FuReadWriteSwitch.vue +38 -36
  16. package/src/components/read-write-switch/FuSelectRwSwitch.vue +11 -7
  17. package/src/components/read-write-switch/index.d.ts +2 -0
  18. package/src/components/read-write-switch/types.d.ts +4 -0
  19. package/src/components/read-write-switch/types.ts +4 -0
  20. package/src/components/speed-dial/FuSpeedDial.vue +78 -69
  21. package/src/components/speed-dial/FuSpeedDial.vue.d.ts +218 -0
  22. package/src/components/speed-dial/FuSpeedDialActionButton.vue +55 -55
  23. package/src/components/speed-dial/FuSpeedDialActionButton.vue.d.ts +32 -0
  24. package/src/components/speed-dial/FuSpeedDialButton.vue +14 -11
  25. package/src/components/speed-dial/FuSpeedDialButton.vue.d.ts +42 -0
  26. package/src/components/speed-dial/FuSpeedDialItem.vue +9 -15
  27. package/src/components/speed-dial/FuSpeedDialItem.vue.d.ts +12 -0
  28. package/src/components/speed-dial/index.d.ts +2 -0
  29. package/src/components/speed-dial/types.d.ts +8 -0
  30. package/src/components/speed-dial/types.ts +12 -0
  31. package/src/components/split-pane/FuSplitPane.vue +3 -3
  32. package/src/components/split-pane/FuSplitPane.vue.d.ts +59 -0
  33. package/src/components/split-pane/index.d.ts +2 -0
  34. package/src/components/table/FuTable.vue +16 -25
  35. package/src/components/table/FuTableBody.ts +38 -34
  36. package/src/components/table/{table-column-dropdown/FuTableColumnDropdown.vue → FuTableColumnDropdown.vue} +5 -2
  37. package/src/components/table/index.d.ts +2 -0
  38. package/src/components/table/index.ts +11 -7
  39. package/src/components/table/table-column-select/FuTableColumnSelectDialog.vue +15 -20
  40. package/src/components/table/table-column-select/FuTableColumnSelectPopover.vue +12 -11
  41. package/src/components/table/table-column-select/utils.d.ts +8 -0
  42. package/src/components/table/table-column-select/utils.ts +10 -7
  43. package/src/components/table/table-operations/FuTableButton.vue +1 -4
  44. package/src/components/table/table-operations/FuTableMoreButton.vue +5 -3
  45. package/src/components/table/table-operations/FuTableOperations.vue +6 -7
  46. package/src/components/table/types.d.ts +2 -0
  47. package/src/components/table/types.ts +3 -0
  48. package/src/components/tabs/FuTabs.vue +4 -2
  49. package/src/components/tabs/FuTabs.vue.d.ts +54 -0
  50. package/src/components/tabs/index.d.ts +2 -0
  51. package/src/hooks/index.d.ts +3 -0
  52. package/src/hooks/index.ts +2 -0
  53. package/src/hooks/use-global-config/index.d.ts +1 -0
  54. package/src/hooks/use-global-config/index.ts +0 -15
  55. package/src/hooks/use-locale/index.d.ts +14 -0
  56. package/src/hooks/use-size/index.d.ts +5 -0
  57. package/src/hooks/use-size/index.ts +29 -0
  58. package/src/index.d.ts +7 -0
  59. package/src/locale/index.d.ts +10 -0
  60. package/src/locale/lang/en.d.ts +59 -0
  61. package/src/locale/lang/zh-cn.d.ts +59 -0
  62. package/src/locale/lang/zh-tw.d.ts +59 -0
  63. package/src/styles/common/variables.scss +2 -6
  64. package/src/styles/components/filter-bar.scss +3 -3
  65. package/src/styles/components/speed-dial.scss +1 -51
  66. package/src/styles/components/split-pane.scss +1 -1
  67. package/src/styles/components/steps.scss +2 -2
  68. package/src/styles/components/table.scss +3 -5
  69. package/src/styles/components/tabs.scss +1 -1
  70. package/src/styles/index.scss +0 -1
  71. package/src/tools/size.d.ts +4 -0
  72. package/src/tools/size.ts +6 -0
  73. package/src/tools/theme.d.ts +1 -0
  74. package/src/tools/theme.ts +0 -12
  75. package/src/tools/time.d.ts +2 -0
  76. package/src/tools/types.d.ts +8 -0
  77. package/src/tools/types.ts +9 -0
  78. package/src/tools/utils.d.ts +2 -0
  79. package/src/tools/utils.ts +36 -36
  80. package/src/tools/vnode.d.ts +9 -0
  81. package/src/tools/vnode.ts +47 -0
  82. package/types/examples/App.vue.d.ts +2 -0
  83. package/types/examples/components/CodeExample.vue.d.ts +29 -0
  84. package/types/examples/components/DocumentTable.vue.d.ts +14 -0
  85. package/types/examples/components/Markdown.vue.d.ts +12 -0
  86. package/types/examples/layout/components/AppHeader.vue.d.ts +2 -0
  87. package/types/examples/layout/components/Sidebar.vue.d.ts +2 -0
  88. package/types/examples/layout/index.vue.d.ts +2 -0
  89. package/types/examples/main.d.ts +2 -0
  90. package/types/examples/pages/filter-bar/attributes.d.ts +63 -0
  91. package/types/examples/pages/filter-bar/demo/BaseFilterBar.vue.d.ts +2 -0
  92. package/types/examples/pages/filter-bar/demo/SetConditionsDemo.vue.d.ts +2 -0
  93. package/types/examples/pages/filter-bar/demo/SlotDemo.vue.d.ts +2 -0
  94. package/types/examples/pages/filter-bar/index.vue.d.ts +2 -0
  95. package/types/examples/pages/index.d.ts +3 -0
  96. package/types/examples/pages/read-write-switch/attributes.d.ts +63 -0
  97. package/types/examples/pages/read-write-switch/demo/BaseDemo.vue.d.ts +2 -0
  98. package/types/examples/pages/read-write-switch/demo/CustomContentDemo.vue.d.ts +2 -0
  99. package/types/examples/pages/read-write-switch/demo/InputRwSwitchDemo.vue.d.ts +2 -0
  100. package/types/examples/pages/read-write-switch/demo/ReadSwitchDemo.vue.d.ts +2 -0
  101. package/types/examples/pages/read-write-switch/demo/SelectRwSwitchDemo.vue.d.ts +2 -0
  102. package/types/examples/pages/read-write-switch/demo/TableInnerEditDemo.vue.d.ts +2 -0
  103. package/types/examples/pages/read-write-switch/demo/WriteSwitchDemo.vue.d.ts +2 -0
  104. package/types/examples/pages/read-write-switch/index.vue.d.ts +2 -0
  105. package/types/examples/pages/speed-dial/attributes.d.ts +63 -0
  106. package/types/examples/pages/speed-dial/demo/BaseSpeedDial.vue.d.ts +2 -0
  107. package/types/examples/pages/speed-dial/demo/SpeedDialCustom.vue.d.ts +2 -0
  108. package/types/examples/pages/speed-dial/demo/SpeedDialPosition.vue.d.ts +2 -0
  109. package/types/examples/pages/speed-dial/demo/SpeedDialTrigger.vue.d.ts +2 -0
  110. package/types/examples/pages/speed-dial/index.vue.d.ts +2 -0
  111. package/types/examples/pages/split-pane/attributes.d.ts +63 -0
  112. package/types/examples/pages/split-pane/demo/BaseSplit.vue.d.ts +2 -0
  113. package/types/examples/pages/split-pane/demo/CustomResizer.vue.d.ts +2 -0
  114. package/types/examples/pages/split-pane/demo/NestSplit.vue.d.ts +2 -0
  115. package/types/examples/pages/split-pane/demo/ResizerType.vue.d.ts +2 -0
  116. package/types/examples/pages/split-pane/index.vue.d.ts +2 -0
  117. package/types/examples/pages/table/attributes.d.ts +121 -0
  118. package/types/examples/pages/table/demo/BaseTable.vue.d.ts +2 -0
  119. package/types/examples/pages/table/demo/DropdownColumn.vue.d.ts +2 -0
  120. package/types/examples/pages/table/demo/DropdownColumnSlot.vue.d.ts +2 -0
  121. package/types/examples/pages/table/demo/SaveSelectColumn.vue.d.ts +2 -0
  122. package/types/examples/pages/table/demo/SelectColumn.vue.d.ts +2 -0
  123. package/types/examples/pages/table/demo/TableOperations.vue.d.ts +2 -0
  124. package/types/examples/pages/table/demo/TablePagination.vue.d.ts +2 -0
  125. package/types/examples/pages/table/index.vue.d.ts +2 -0
  126. package/types/examples/pages/tabs/attributes.d.ts +63 -0
  127. package/types/examples/pages/tabs/demo/AddCloseTab.vue.d.ts +2 -0
  128. package/types/examples/pages/tabs/index.vue.d.ts +2 -0
  129. package/types/examples/router/doc-routes.d.ts +12 -0
  130. package/types/examples/router/index.d.ts +4 -0
  131. package/types/plugins/example-transform.d.ts +5 -0
  132. package/types/src/components/filter-bar/FuFilter.vue.d.ts +39 -0
  133. package/types/src/components/filter-bar/FuFilterBar.vue.d.ts +22 -0
  134. package/types/src/components/filter-bar/FuFilterConditions.vue.d.ts +8 -0
  135. package/types/src/components/filter-bar/FuSearchInput.vue.d.ts +17 -0
  136. package/types/src/components/filter-bar/filter-components/FuFilterDate.vue.d.ts +36 -0
  137. package/types/src/components/filter-bar/filter-components/FuFilterDateTime.vue.d.ts +36 -0
  138. package/types/src/components/filter-bar/filter-components/FuFilterOption.vue.d.ts +24 -0
  139. package/types/src/components/filter-bar/filter-components/FuFilterSelect.vue.d.ts +66 -0
  140. package/types/src/components/filter-bar/index.d.ts +2 -0
  141. package/types/src/components/filter-bar/types.d.ts +22 -0
  142. package/types/src/components/read-write-switch/FuInputRwSwitch.vue.d.ts +21 -0
  143. package/types/src/components/read-write-switch/FuReadWriteSwitch.vue.d.ts +23 -0
  144. package/types/src/components/read-write-switch/FuSelectRwSwitch.vue.d.ts +33 -0
  145. package/types/src/components/read-write-switch/index.d.ts +2 -0
  146. package/types/src/components/read-write-switch/types.d.ts +4 -0
  147. package/types/src/components/speed-dial/FuSpeedDial.vue.d.ts +218 -0
  148. package/types/src/components/speed-dial/FuSpeedDialActionButton.vue.d.ts +32 -0
  149. package/types/src/components/speed-dial/FuSpeedDialButton.vue.d.ts +42 -0
  150. package/types/src/components/speed-dial/FuSpeedDialItem.vue.d.ts +12 -0
  151. package/types/src/components/speed-dial/index.d.ts +2 -0
  152. package/types/src/components/speed-dial/types.d.ts +8 -0
  153. package/types/src/components/split-pane/FuSplitPane.vue.d.ts +59 -0
  154. package/types/src/components/split-pane/index.d.ts +2 -0
  155. package/types/src/components/table/FuTable.vue.d.ts +18 -0
  156. package/types/src/components/table/FuTableBody.d.ts +3 -0
  157. package/types/src/components/table/FuTableColumnDropdown.vue.d.ts +50 -0
  158. package/types/src/components/table/FuTablePagination.vue.d.ts +47 -0
  159. package/types/src/components/table/index.d.ts +2 -0
  160. package/types/src/components/table/table-column-select/FuTableColumnSelect.vue.d.ts +10 -0
  161. package/types/src/components/table/table-column-select/FuTableColumnSelectDialog.vue.d.ts +23 -0
  162. package/types/src/components/table/table-column-select/FuTableColumnSelectPopover.vue.d.ts +34 -0
  163. package/types/src/components/table/table-column-select/utils.d.ts +8 -0
  164. package/types/src/components/table/table-operations/FuTableButton.vue.d.ts +13 -0
  165. package/types/src/components/table/table-operations/FuTableMoreButton.vue.d.ts +37 -0
  166. package/types/src/components/table/table-operations/FuTableOperations.vue.d.ts +46 -0
  167. package/types/src/components/table/types.d.ts +2 -0
  168. package/types/src/components/tabs/FuTabs.vue.d.ts +54 -0
  169. package/types/src/components/tabs/index.d.ts +2 -0
  170. package/types/src/hooks/index.d.ts +3 -0
  171. package/types/src/hooks/use-global-config/index.d.ts +1 -0
  172. package/types/src/hooks/use-locale/index.d.ts +14 -0
  173. package/types/src/hooks/use-size/index.d.ts +5 -0
  174. package/types/src/index.d.ts +7 -0
  175. package/types/src/locale/index.d.ts +10 -0
  176. package/types/src/locale/lang/en.d.ts +59 -0
  177. package/types/src/locale/lang/zh-cn.d.ts +59 -0
  178. package/types/src/locale/lang/zh-tw.d.ts +59 -0
  179. package/types/src/tools/size.d.ts +4 -0
  180. package/types/src/tools/theme.d.ts +1 -0
  181. package/types/src/tools/time.d.ts +2 -0
  182. package/types/src/tools/types.d.ts +8 -0
  183. package/types/src/tools/utils.d.ts +2 -0
  184. package/types/src/tools/vnode.d.ts +9 -0
  185. package/src/components/search-bar/FuComplexSearch.vue +0 -108
  186. package/src/components/search-bar/FuQuickSearch.vue +0 -43
  187. package/src/components/search-bar/FuSearchBar.vue +0 -165
  188. package/src/components/search-bar/FuSearchBarButton.vue +0 -14
  189. package/src/components/search-bar/FuSearchContions.vue +0 -24
  190. package/src/components/search-bar/index.ts +0 -13
  191. package/src/components/search-bar/store.ts +0 -25
  192. package/src/components/steps/FuHorizontalNavigation.vue +0 -18
  193. package/src/components/steps/FuHorizontalSteps.vue +0 -94
  194. package/src/components/steps/FuStep.vue +0 -13
  195. package/src/components/steps/FuSteps.vue +0 -22
  196. package/src/components/steps/FuStepsFooter.ts +0 -79
  197. package/src/components/steps/FuVerticalNavigation.vue +0 -35
  198. package/src/components/steps/FuVerticalSteps.vue +0 -79
  199. package/src/components/steps/Stepper.ts +0 -188
  200. package/src/components/steps/index.ts +0 -11
  201. package/src/components/table/table-column-dropdown/index.ts +0 -7
  202. package/src/components/table/table-column-select/index.ts +0 -8
  203. package/src/components/table/table-operations/index.ts +0 -12
  204. package/src/components/virtual-scroller/FuVirtualHorizontalScroll.js +0 -96
  205. package/src/components/virtual-scroller/FuVirtualScroll.js +0 -15
  206. package/src/components/virtual-scroller/FuVirtualVerticalScroll.js +0 -95
  207. package/src/components/virtual-scroller/index.js +0 -10
  208. package/src/styles/components/search-bar.scss +0 -285
@@ -0,0 +1,37 @@
1
+ import { PropType } from "vue";
2
+ import { DropdownProps } from "@/tools/types";
3
+ declare const _default: import("vue").DefineComponent<{
4
+ row: ObjectConstructor;
5
+ buttons: {
6
+ type: PropType<DropdownProps[]>;
7
+ required: true;
8
+ };
9
+ size: {
10
+ type: StringConstructor;
11
+ default: string;
12
+ };
13
+ type: {
14
+ type: StringConstructor;
15
+ default: string;
16
+ validator: (value: string) => boolean;
17
+ };
18
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
19
+ row: ObjectConstructor;
20
+ buttons: {
21
+ type: PropType<DropdownProps[]>;
22
+ required: true;
23
+ };
24
+ size: {
25
+ type: StringConstructor;
26
+ default: string;
27
+ };
28
+ type: {
29
+ type: StringConstructor;
30
+ default: string;
31
+ validator: (value: string) => boolean;
32
+ };
33
+ }>>, {
34
+ type: string;
35
+ size: string;
36
+ }>;
37
+ export default _default;
@@ -0,0 +1,46 @@
1
+ declare const _default: import("vue").DefineComponent<{
2
+ align: {
3
+ type: StringConstructor;
4
+ default: string;
5
+ };
6
+ width: (StringConstructor | NumberConstructor)[];
7
+ minWidth: (StringConstructor | NumberConstructor)[];
8
+ ellipsis: {
9
+ type: NumberConstructor;
10
+ default: number;
11
+ };
12
+ buttons: {
13
+ type: ArrayConstructor;
14
+ required: true;
15
+ };
16
+ type: {
17
+ type: StringConstructor;
18
+ default: string;
19
+ validator: (value: string) => boolean;
20
+ };
21
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
22
+ align: {
23
+ type: StringConstructor;
24
+ default: string;
25
+ };
26
+ width: (StringConstructor | NumberConstructor)[];
27
+ minWidth: (StringConstructor | NumberConstructor)[];
28
+ ellipsis: {
29
+ type: NumberConstructor;
30
+ default: number;
31
+ };
32
+ buttons: {
33
+ type: ArrayConstructor;
34
+ required: true;
35
+ };
36
+ type: {
37
+ type: StringConstructor;
38
+ default: string;
39
+ validator: (value: string) => boolean;
40
+ };
41
+ }>>, {
42
+ type: string;
43
+ align: string;
44
+ ellipsis: number;
45
+ }>;
46
+ export default _default;
@@ -0,0 +1,2 @@
1
+ import { InjectionKey } from "vue";
2
+ export declare const LocalKey: InjectionKey<string | undefined>;
@@ -0,0 +1,54 @@
1
+ import { PropType } from "vue";
2
+ import { DropdownProps } from "@/tools/types";
3
+ declare const _default: import("vue").DefineComponent<{
4
+ addType: {
5
+ type: StringConstructor;
6
+ default: string;
7
+ validator: (val: string) => boolean;
8
+ };
9
+ dropdownMenus: {
10
+ type: PropType<DropdownProps[]>;
11
+ default: () => never[];
12
+ };
13
+ addTrigger: {
14
+ type: StringConstructor;
15
+ default: string;
16
+ validator: (val: string) => boolean;
17
+ };
18
+ addIcon: {
19
+ type: StringConstructor;
20
+ default: string;
21
+ };
22
+ addButtonLabel: StringConstructor;
23
+ addable: BooleanConstructor;
24
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "command"[], "command", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
25
+ addType: {
26
+ type: StringConstructor;
27
+ default: string;
28
+ validator: (val: string) => boolean;
29
+ };
30
+ dropdownMenus: {
31
+ type: PropType<DropdownProps[]>;
32
+ default: () => never[];
33
+ };
34
+ addTrigger: {
35
+ type: StringConstructor;
36
+ default: string;
37
+ validator: (val: string) => boolean;
38
+ };
39
+ addIcon: {
40
+ type: StringConstructor;
41
+ default: string;
42
+ };
43
+ addButtonLabel: StringConstructor;
44
+ addable: BooleanConstructor;
45
+ }>> & {
46
+ onCommand?: ((...args: any[]) => any) | undefined;
47
+ }, {
48
+ addable: boolean;
49
+ addType: string;
50
+ dropdownMenus: DropdownProps[];
51
+ addTrigger: string;
52
+ addIcon: string;
53
+ }>;
54
+ export default _default;
@@ -0,0 +1,2 @@
1
+ import FuTabs from "./FuTabs.vue";
2
+ export default FuTabs;
@@ -0,0 +1,3 @@
1
+ export * from './use-global-config';
2
+ export * from './use-locale';
3
+ export * from './use-size';
@@ -0,0 +1 @@
1
+ export declare function useGlobalConfig(key?: keyof any, defaultValue?: undefined): import("vue").Ref<any>;
@@ -0,0 +1,14 @@
1
+ import type { MaybeRef } from '@vueuse/core';
2
+ import type { Ref } from 'vue';
3
+ import type { Language } from '@/locale';
4
+ export declare type TranslatorOption = Record<string, string | number>;
5
+ export declare type Translator = (path: string, option?: TranslatorOption) => string;
6
+ export declare type LocaleContext = {
7
+ locale: Ref<Language>;
8
+ lang: Ref<string>;
9
+ t: Translator;
10
+ };
11
+ export declare const buildTranslator: (locale: MaybeRef<Language>) => Translator;
12
+ export declare const translate: (path: string, option: undefined | TranslatorOption, locale: Language) => string;
13
+ export declare const buildLocaleContext: (locale: MaybeRef<Language>) => LocaleContext;
14
+ export declare const useLocale: () => LocaleContext;
@@ -0,0 +1,5 @@
1
+ import type { ComputedRef } from 'vue';
2
+ import type { ComponentSize } from '@/tools/size';
3
+ import type { MaybeRef } from '@vueuse/core';
4
+ export declare const useProp: <T>(name: string) => ComputedRef<T | undefined>;
5
+ export declare const useSize: (fallback?: MaybeRef<ComponentSize | undefined>, ignore?: Partial<Record<'prop' | 'global', boolean>>) => ComputedRef<string>;
@@ -0,0 +1,7 @@
1
+ import type { App } from 'vue';
2
+ declare const plugin: {
3
+ name: string;
4
+ version: string;
5
+ install: (app: App) => void;
6
+ };
7
+ export default plugin;
@@ -0,0 +1,10 @@
1
+ export { default as en } from './lang/en';
2
+ export { default as zhCn } from './lang/zh-cn';
3
+ export { default as zhTw } from './lang/zh-tw';
4
+ export declare type TranslatePair = {
5
+ [key: string]: string | string[] | TranslatePair;
6
+ };
7
+ export declare type Language = {
8
+ name: string;
9
+ el: TranslatePair;
10
+ };
@@ -0,0 +1,59 @@
1
+ declare const _default: {
2
+ name: string;
3
+ fu: {
4
+ filter_bar: {
5
+ filter: string;
6
+ results: string;
7
+ clear: string;
8
+ drawer_title: string;
9
+ cancel: string;
10
+ search: string;
11
+ select_all: string;
12
+ more: string;
13
+ };
14
+ search_bar: {
15
+ search: string;
16
+ adv_search: string;
17
+ ok: string;
18
+ cancel: string;
19
+ please_select: string;
20
+ please_input: string;
21
+ like: string;
22
+ not_like: string;
23
+ in: string;
24
+ not_in: string;
25
+ gt: string;
26
+ ge: string;
27
+ lt: string;
28
+ le: string;
29
+ eq: string;
30
+ ne: string;
31
+ between: string;
32
+ select_date: string;
33
+ start_date: string;
34
+ end_date: string;
35
+ select_date_time: string;
36
+ start_date_time: string;
37
+ end_date_time: string;
38
+ range_separator: string;
39
+ data_time_error: string;
40
+ clean: string;
41
+ refresh: string;
42
+ };
43
+ table: {
44
+ ok: string;
45
+ reset: string;
46
+ custom_table_fields: string;
47
+ custom_table_fields_desc: string;
48
+ custom_table_rows: string;
49
+ more: string;
50
+ };
51
+ steps: {
52
+ cancel: string;
53
+ next: string;
54
+ prev: string;
55
+ finish: string;
56
+ };
57
+ };
58
+ };
59
+ export default _default;
@@ -0,0 +1,59 @@
1
+ declare const _default: {
2
+ name: string;
3
+ fu: {
4
+ filter_bar: {
5
+ filter: string;
6
+ results: string;
7
+ clear: string;
8
+ drawer_title: string;
9
+ cancel: string;
10
+ search: string;
11
+ select_all: string;
12
+ more: string;
13
+ };
14
+ search_bar: {
15
+ search: string;
16
+ adv_search: string;
17
+ ok: string;
18
+ cancel: string;
19
+ please_select: string;
20
+ please_input: string;
21
+ like: string;
22
+ not_like: string;
23
+ in: string;
24
+ not_in: string;
25
+ gt: string;
26
+ ge: string;
27
+ lt: string;
28
+ le: string;
29
+ eq: string;
30
+ ne: string;
31
+ between: string;
32
+ select_date: string;
33
+ start_date: string;
34
+ end_date: string;
35
+ select_date_time: string;
36
+ start_date_time: string;
37
+ end_date_time: string;
38
+ range_separator: string;
39
+ data_time_error: string;
40
+ clean: string;
41
+ refresh: string;
42
+ };
43
+ table: {
44
+ ok: string;
45
+ reset: string;
46
+ custom_table_fields: string;
47
+ custom_table_fields_desc: string;
48
+ custom_table_rows: string;
49
+ more: string;
50
+ };
51
+ steps: {
52
+ cancel: string;
53
+ next: string;
54
+ prev: string;
55
+ finish: string;
56
+ };
57
+ };
58
+ };
59
+ export default _default;
@@ -0,0 +1,59 @@
1
+ declare const _default: {
2
+ name: string;
3
+ fu: {
4
+ filter_bar: {
5
+ filter: string;
6
+ results: string;
7
+ clear: string;
8
+ drawer_title: string;
9
+ cancel: string;
10
+ search: string;
11
+ select_all: string;
12
+ more: string;
13
+ };
14
+ search_bar: {
15
+ search: string;
16
+ adv_search: string;
17
+ ok: string;
18
+ cancel: string;
19
+ please_select: string;
20
+ please_input: string;
21
+ like: string;
22
+ not_like: string;
23
+ in: string;
24
+ not_in: string;
25
+ gt: string;
26
+ ge: string;
27
+ lt: string;
28
+ le: string;
29
+ eq: string;
30
+ ne: string;
31
+ between: string;
32
+ select_date: string;
33
+ start_date: string;
34
+ end_date: string;
35
+ select_date_time: string;
36
+ start_date_time: string;
37
+ end_date_time: string;
38
+ range_separator: string;
39
+ data_time_error: string;
40
+ clean: string;
41
+ refresh: string;
42
+ };
43
+ table: {
44
+ ok: string;
45
+ reset: string;
46
+ custom_table_fields: string;
47
+ custom_table_fields_desc: string;
48
+ custom_table_rows: string;
49
+ more: string;
50
+ };
51
+ steps: {
52
+ cancel: string;
53
+ next: string;
54
+ prev: string;
55
+ finish: string;
56
+ };
57
+ };
58
+ };
59
+ export default _default;
@@ -0,0 +1,4 @@
1
+ declare const COMPONENTS_SIZE: string[];
2
+ export declare type ComponentSize = typeof COMPONENTS_SIZE[number];
3
+ export declare const validateSize: (val: string) => val is string;
4
+ export {};
@@ -0,0 +1 @@
1
+ export declare const validateType: (value: string) => boolean;
@@ -0,0 +1,2 @@
1
+ export declare const datetimeFormat: (timestamp: string) => string;
2
+ export declare const dateFormat: (timestamp: string) => string;
@@ -0,0 +1,8 @@
1
+ export interface DropdownProps {
2
+ icon?: string;
3
+ disabled?: boolean;
4
+ divided?: boolean;
5
+ command?: string | number | object;
6
+ label?: string | number;
7
+ [k: string]: any;
8
+ }
@@ -0,0 +1,2 @@
1
+ export declare const uuid: () => string;
2
+ export declare const randomId: () => number;
@@ -0,0 +1,9 @@
1
+ import type { VNode, VNodeNormalizedChildren } from 'vue';
2
+ export declare function isFragment(node: VNode): boolean;
3
+ export declare function isFragment(node: unknown): node is VNode;
4
+ export declare function isComment(node: VNode): boolean;
5
+ export declare function isComment(node: unknown): node is VNode;
6
+ export declare function isValidElementNode(node: VNode): boolean;
7
+ export declare function isValidElementNode(node: unknown): node is VNode;
8
+ export declare function isValidChildren(children: VNodeNormalizedChildren): children is VNodeNormalizedChildren;
9
+ export declare function getChildren(nodes: VNodeNormalizedChildren | VNode[], depth?: number): VNodeNormalizedChildren | VNode[];
@@ -1,108 +0,0 @@
1
- <template>
2
- <div class="fu-complex-search">
3
- <el-popover trigger="manual" v-model="active" :show-arrow="false" @hide="closePopover"
4
- popper-class="fu-complex-components">
5
-
6
- <div class="fu-complex-components__body">
7
- <slot>
8
- <!-- :size="configSize" -->
9
- <component v-for="(c, i) in components" :key="i" :is="c.component" v-bind="c" :ref="c.field" v-on="c" />
10
- </slot>
11
- </div>
12
- <div class="fu-complex-components__footer">
13
- <!-- :size="configSize" -->
14
- <el-button @click="active = false">{{ t('fu.search_bar.cancel') }}</el-button>
15
- <el-button type="primary" @click="ok">{{ t('fu.search_bar.ok') }}</el-button>
16
- </div>
17
- <template #reference>
18
- <!-- :size="configSize" -->
19
- <fu-search-bar-button icon="ArrowRight" @click="toggle"
20
- :class="['fu-complex-search__trigger', { 'is-active': active }]" :tooltip="t('fu.search_bar.adv_search')" />
21
- </template>
22
- </el-popover>
23
- </div>
24
- </template>
25
-
26
- <script setup lang="ts">
27
- import { ref, computed, useSlots, getCurrentInstance } from "vue";
28
- import FuSearchBarButton from "@/components/search-bar/FuSearchBarButton.vue";
29
- import { useLocale } from "@/hooks"
30
-
31
- const slots = useSlots()
32
- const instance = getCurrentInstance()
33
-
34
- const props = defineProps({
35
- components: Array,
36
- });
37
- const emit = defineEmits(["close", "change"])
38
- const { t } = useLocale()
39
- const active = ref(false)
40
-
41
-
42
- function closePopover() {
43
- emit("close")
44
- }
45
- function toggle() {
46
- active.value = !active.value
47
- refs.value.forEach((r: any) => {
48
- // *****r.init 有问题
49
- if (r?.init) {
50
- r.init()
51
- } else {
52
- console.warn("init undefined", r)
53
- }
54
- })
55
- }
56
-
57
- function close() {
58
- active.value = false
59
- }
60
- function ok() {
61
- active.value = false
62
- let conditions: any = [];
63
- refs.value.forEach((r: any) => {
64
- let condition
65
- if (r.getCondition) {
66
- condition = r.getCondition()
67
- } else {
68
- console.warn("getCondition undefined", r)
69
- }
70
- if (condition && condition.value !== undefined) {
71
- conditions.push(condition)
72
- }
73
- })
74
- emit("change", conditions)
75
- }
76
-
77
- function createConditions(conditions: any) {
78
- let result: any = []
79
- if (conditions) {
80
- Object.keys(conditions).forEach(key => {
81
- let c = conditions[key]
82
- refs.value.forEach((r: any) => {
83
- if (r.field === key) {
84
- result.push(r.createCondition(c.value, c.operator))
85
- }
86
- })
87
- })
88
- }
89
- return result
90
- }
91
- const refs = computed(() => {
92
- let refs: any = [];
93
- if (slots.default?.()[0].children.length) {
94
- // 使用slot
95
- slots.default?.().forEach((component: any) => {
96
- refs.push(component.componentInstance)
97
- })
98
- } else {
99
- // 使用components
100
- props.components.forEach((c: any) => {
101
- refs.push(instance.refs[c.field][0])
102
- })
103
- }
104
- return refs
105
- });
106
-
107
-
108
- </script>
@@ -1,43 +0,0 @@
1
- <template>
2
- <!-- , 'fu-quick-search--' + configSize -->
3
- <div :class="['fu-quick-search']">
4
- <el-icon v-if="useIcon">
5
- <Search />
6
- </el-icon>
7
- <label>
8
- <input :placeholder="placeholder" v-model="quick" @input="input" @blur="blur" @keydown="keydown" />
9
- </label>
10
- </div>
11
- </template>
12
-
13
- <script setup lang="ts">
14
- import { ref, watch } from "vue";
15
- defineOptions({ name: "FuQuickSearch" });
16
- const props = defineProps({
17
- value: String,
18
- placeholder: String,
19
- useIcon: {
20
- type: Boolean,
21
- default: true
22
- }
23
- })
24
-
25
- const emit = defineEmits(["input", "change"])
26
- const quick = ref("")
27
-
28
- watch(() => props.value, (val: any) => {
29
- quick.value = val
30
- })
31
- function input(e: Event) {
32
- emit("input", quick.value, e)
33
- }
34
- function blur(e: Event) {
35
- emit("change", quick.value, e)
36
- }
37
- function keydown(e: Event) {
38
- const event = e as KeyboardEvent
39
- if (event.key === "Enter") {
40
- emit("change", quick.value, e)
41
- }
42
- }
43
- </script>