@farris/ui-vue 1.0.0-beta.2 → 1.0.0-beta.4

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 (246) hide show
  1. package/accordion/index.esm.js +93 -0
  2. package/accordion/index.umd.js +1 -0
  3. package/accordion/package.json +8 -0
  4. package/accordion/style.css +1 -0
  5. package/avatar/index.esm.js +94 -0
  6. package/avatar/index.umd.js +1 -0
  7. package/avatar/package.json +8 -0
  8. package/avatar/style.css +1 -0
  9. package/button/index.esm.js +206 -0
  10. package/button/index.umd.js +1 -0
  11. package/button/package.json +8 -0
  12. package/button-edit/index.esm.js +300 -0
  13. package/button-edit/index.umd.js +1 -0
  14. package/button-edit/package.json +8 -0
  15. package/checkbox/index.esm.js +97 -0
  16. package/checkbox/index.umd.js +1 -0
  17. package/checkbox/package.json +8 -0
  18. package/combo-list/index.esm.js +457 -0
  19. package/combo-list/index.umd.js +1 -0
  20. package/combo-list/package.json +8 -0
  21. package/data-grid/index.esm.js +1535 -0
  22. package/data-grid/index.umd.js +1 -0
  23. package/data-grid/package.json +8 -0
  24. package/data-grid/style.css +1 -0
  25. package/date-picker/index.esm.js +1479 -0
  26. package/date-picker/index.umd.js +1 -0
  27. package/date-picker/package.json +8 -0
  28. package/date-picker/style.css +1 -0
  29. package/{src/index.esm.js → farris.all.esm.js} +1 -2
  30. package/farris.all.umd.js +1 -0
  31. package/list-view/index.esm.js +144 -0
  32. package/list-view/index.umd.js +1 -0
  33. package/list-view/package.json +8 -0
  34. package/list-view/style.css +1 -0
  35. package/message-box/index.esm.js +499 -0
  36. package/message-box/index.umd.js +1 -0
  37. package/message-box/package.json +8 -0
  38. package/modal/index.esm.js +165 -0
  39. package/modal/index.umd.js +1 -0
  40. package/modal/package.json +8 -0
  41. package/notify/index.esm.js +187 -0
  42. package/notify/index.umd.js +1 -0
  43. package/notify/package.json +8 -0
  44. package/notify/style.css +1 -0
  45. package/package.json +6 -5
  46. package/pagination/index.esm.js +334 -0
  47. package/pagination/index.umd.js +1 -0
  48. package/pagination/package.json +8 -0
  49. package/pagination/style.css +1 -0
  50. package/popover/index.esm.js +83 -0
  51. package/popover/index.umd.js +1 -0
  52. package/popover/package.json +8 -0
  53. package/popover/style.css +1 -0
  54. package/radio-group/index.esm.js +79 -0
  55. package/radio-group/index.umd.js +1 -0
  56. package/radio-group/package.json +8 -0
  57. package/section/index.esm.js +70 -0
  58. package/section/index.umd.js +1 -0
  59. package/section/package.json +8 -0
  60. package/switch/index.esm.js +78 -0
  61. package/switch/index.umd.js +1 -0
  62. package/switch/package.json +8 -0
  63. package/tabs/index.esm.js +385 -0
  64. package/tabs/index.umd.js +1 -0
  65. package/tabs/package.json +8 -0
  66. package/tabs/style.css +1 -0
  67. package/text/index.esm.js +33 -0
  68. package/text/index.umd.js +1 -0
  69. package/text/package.json +8 -0
  70. package/tooltip/index.esm.js +195 -0
  71. package/tooltip/index.umd.js +1 -0
  72. package/tooltip/package.json +8 -0
  73. package/tooltip/style.css +1 -0
  74. package/types/accordion/index.d.ts +25 -0
  75. package/types/accordion/src/accordion.component.d.ts +70 -0
  76. package/types/accordion/src/accordion.props.d.ts +50 -0
  77. package/types/accordion/src/components/accordion-item.component.d.ts +38 -0
  78. package/types/accordion/src/components/accordion-item.props.d.ts +34 -0
  79. package/types/avatar/index.d.ts +23 -0
  80. package/types/avatar/src/avatar.component.d.ts +109 -0
  81. package/types/avatar/src/avatar.props.d.ts +96 -0
  82. package/types/avatar/src/composition/types.d.ts +31 -0
  83. package/types/avatar/src/composition/use-image.d.ts +19 -0
  84. package/types/button/index.d.ts +24 -0
  85. package/types/button/src/button-group.component.d.ts +106 -0
  86. package/types/button/src/button-group.props.d.ts +106 -0
  87. package/types/button/src/button.component.d.ts +34 -0
  88. package/types/button/src/button.props.d.ts +47 -0
  89. package/types/button/src/composition/types-group.d.ts +24 -0
  90. package/types/button/src/composition/types.d.ts +24 -0
  91. package/types/button/src/composition/use-button-group.d.ts +19 -0
  92. package/types/button/src/composition/use-button.d.ts +19 -0
  93. package/types/button-edit/index.d.ts +23 -0
  94. package/types/button-edit/src/button-edit.props.d.ts +135 -0
  95. package/types/button-edit/src/composition/types.d.ts +118 -0
  96. package/types/button-edit/src/composition/use-button.d.ts +19 -0
  97. package/types/button-edit/src/composition/use-clear.d.ts +19 -0
  98. package/types/button-edit/src/composition/use-text-box.d.ts +19 -0
  99. package/types/checkbox/index.d.ts +23 -0
  100. package/types/checkbox/src/checkbox-group.component.d.ts +148 -0
  101. package/types/checkbox/src/checkbox-group.props.d.ts +123 -0
  102. package/types/checkbox/src/composition/types.d.ts +46 -0
  103. package/types/checkbox/src/composition/use-checkbox-group.d.ts +19 -0
  104. package/types/combo-list/index.d.ts +25 -0
  105. package/types/combo-list/src/combo-list.props.d.ts +290 -0
  106. package/types/combo-list/src/components/option.component.d.ts +39 -0
  107. package/types/combo-list/src/components/options.component.d.ts +10 -0
  108. package/types/combo-list/src/composition/index.d.ts +18 -0
  109. package/types/combo-list/src/composition/use-combo-list.d.ts +30 -0
  110. package/types/combo-list/src/composition/use-option.d.ts +19 -0
  111. package/types/combo-list/src/composition/use-options.d.ts +2 -0
  112. package/types/combo-list/src/composition/use-panel.d.ts +8 -0
  113. package/types/combo-list/src/const.d.ts +40 -0
  114. package/types/combo-list/src/types.d.ts +186 -0
  115. package/types/data-grid/index.d.ts +23 -0
  116. package/types/data-grid/src/components/data/data-area.component.d.ts +21 -0
  117. package/types/data-grid/src/components/editors/date-picker.component.d.ts +2 -0
  118. package/types/data-grid/src/components/editors/text-area-editor.component.d.ts +2 -0
  119. package/types/data-grid/src/components/editors/text-editor.component.d.ts +17 -0
  120. package/types/data-grid/src/components/header/data-grid-header.component.d.ts +22 -0
  121. package/types/data-grid/src/components/pagination/data-grid-pagination.component.d.ts +5 -0
  122. package/types/data-grid/src/components/scrollbar/horizontal-scrollbar.component.d.ts +21 -0
  123. package/types/data-grid/src/components/scrollbar/vertical-scrollbar.component.d.ts +21 -0
  124. package/types/data-grid/src/components/sidebar/data-grid-sidebar.component.d.ts +21 -0
  125. package/types/data-grid/src/components/summary/data-grid-summary.component.d.ts +5 -0
  126. package/types/data-grid/src/composition/types.d.ts +175 -0
  127. package/types/data-grid/src/composition/use-column.d.ts +17 -0
  128. package/types/data-grid/src/composition/use-data-view.d.ts +19 -0
  129. package/types/data-grid/src/composition/use-edit.d.ts +18 -0
  130. package/types/data-grid/src/composition/use-fit-column.d.ts +20 -0
  131. package/types/data-grid/src/composition/use-group-column.d.ts +22 -0
  132. package/types/data-grid/src/composition/use-group-data.d.ts +3 -0
  133. package/types/data-grid/src/composition/use-positon-style.d.ts +20 -0
  134. package/types/data-grid/src/composition/use-resize.d.ts +20 -0
  135. package/types/data-grid/src/composition/use-row.d.ts +3 -0
  136. package/types/data-grid/src/composition/use-sidebar.d.ts +3 -0
  137. package/types/data-grid/src/composition/use-virtual-scroll.d.ts +20 -0
  138. package/types/data-grid/src/composition/use-visual-data.d.ts +19 -0
  139. package/types/data-grid/src/data-grid.component.d.ts +278 -0
  140. package/types/data-grid/src/data-grid.props.d.ts +650 -0
  141. package/types/date-picker/index.d.ts +28 -0
  142. package/types/date-picker/src/components/calendar/calendar.component.d.ts +166 -0
  143. package/types/date-picker/src/components/calendar/calendar.props.d.ts +94 -0
  144. package/types/date-picker/src/components/calendar-navbar/calendar-navbar.component.d.ts +138 -0
  145. package/types/date-picker/src/components/calendar-navbar/calendar-navbar.props.d.ts +81 -0
  146. package/types/date-picker/src/components/date-picker-container/date-picker-container.component.d.ts +626 -0
  147. package/types/date-picker/src/components/date-picker-container/date-picker-container.props.d.ts +306 -0
  148. package/types/date-picker/src/components/month/month.component.d.ts +86 -0
  149. package/types/date-picker/src/components/month/month.props.d.ts +57 -0
  150. package/types/date-picker/src/components/year/year.component.d.ts +86 -0
  151. package/types/date-picker/src/components/year/year.props.d.ts +57 -0
  152. package/types/date-picker/src/composition/types.d.ts +102 -0
  153. package/types/date-picker/src/composition/use-calendar.d.ts +2 -0
  154. package/types/date-picker/src/composition/use-compare.d.ts +2 -0
  155. package/types/date-picker/src/composition/use-date.d.ts +2 -0
  156. package/types/date-picker/src/composition/use-disable-date.d.ts +18 -0
  157. package/types/date-picker/src/composition/use-disable-month.d.ts +2 -0
  158. package/types/date-picker/src/composition/use-event.d.ts +45 -0
  159. package/types/date-picker/src/composition/use-mark.d.ts +2 -0
  160. package/types/date-picker/src/composition/use-month.d.ts +2 -0
  161. package/types/date-picker/src/composition/use-number.d.ts +2 -0
  162. package/types/date-picker/src/composition/use-year.d.ts +2 -0
  163. package/types/date-picker/src/date-picker.props.d.ts +168 -0
  164. package/types/date-picker/src/types/calendar.d.ts +30 -0
  165. package/types/date-picker/src/types/common.d.ts +42 -0
  166. package/types/date-picker/src/types/date-model.d.ts +38 -0
  167. package/types/date-picker/src/types/month.d.ts +48 -0
  168. package/types/date-picker/src/types/year.d.ts +24 -0
  169. package/types/index.d.ts +20 -0
  170. package/types/list-view/index.d.ts +23 -0
  171. package/types/list-view/src/components/list-view-checkbox.component.d.ts +32 -0
  172. package/types/list-view/src/components/list-view-checkbox.props.d.ts +31 -0
  173. package/types/list-view/src/list-view.props.d.ts +44 -0
  174. package/types/message-box/index.d.ts +24 -0
  175. package/types/message-box/src/composition/types.d.ts +18 -0
  176. package/types/message-box/src/composition/use-copy.d.ts +18 -0
  177. package/types/message-box/src/message-box.component.d.ts +72 -0
  178. package/types/message-box/src/message-box.props.d.ts +52 -0
  179. package/types/modal/index.d.ts +23 -0
  180. package/types/modal/src/modal.component.d.ts +104 -0
  181. package/types/modal/src/modal.props.d.ts +72 -0
  182. package/types/notify/index.d.ts +26 -0
  183. package/types/notify/src/components/toast.component.d.ts +21 -0
  184. package/types/notify/src/components/toast.props.d.ts +27 -0
  185. package/types/notify/src/notify.props.d.ts +99 -0
  186. package/types/number-range/index.d.ts +23 -0
  187. package/types/number-range/src/composition/types.d.ts +52 -0
  188. package/types/number-range/src/composition/use-data.d.ts +19 -0
  189. package/types/number-range/src/composition/use-util.d.ts +19 -0
  190. package/types/number-range/src/number-range.component.d.ts +247 -0
  191. package/types/number-range/src/number-range.props.d.ts +216 -0
  192. package/types/number-spinner/index.d.ts +23 -0
  193. package/types/number-spinner/src/composition/types.d.ts +52 -0
  194. package/types/number-spinner/src/composition/use-data.d.ts +19 -0
  195. package/types/number-spinner/src/composition/use-util.d.ts +19 -0
  196. package/types/number-spinner/src/number-spinner.component.d.ts +202 -0
  197. package/types/number-spinner/src/number-spinner.props.d.ts +181 -0
  198. package/types/overlay/src/overlay.component.d.ts +20 -0
  199. package/types/overlay/src/overlay.props.d.ts +26 -0
  200. package/types/pagination/index.d.ts +23 -0
  201. package/types/pagination/src/components/buttons/goto-buttons.component.d.ts +19 -0
  202. package/types/pagination/src/components/buttons/next-buttons.component.d.ts +20 -0
  203. package/types/pagination/src/components/buttons/previous-buttons.component.d.ts +20 -0
  204. package/types/pagination/src/components/pages/page-info.component.d.ts +19 -0
  205. package/types/pagination/src/components/pages/page-list.component.d.ts +19 -0
  206. package/types/pagination/src/components/pages/page-number.component.d.ts +20 -0
  207. package/types/pagination/src/composition/types.d.ts +24 -0
  208. package/types/pagination/src/composition/use-pages.d.ts +18 -0
  209. package/types/pagination/src/pagination.components.d.ts +41 -0
  210. package/types/pagination/src/pagination.props.d.ts +36 -0
  211. package/types/popover/index.d.ts +24 -0
  212. package/types/popover/src/popover.component.d.ts +26 -0
  213. package/types/popover/src/popover.directive.d.ts +5 -0
  214. package/types/popover/src/popover.props.d.ts +30 -0
  215. package/types/radio-group/index.d.ts +23 -0
  216. package/types/radio-group/src/composition/change-radio.d.ts +19 -0
  217. package/types/radio-group/src/composition/types.d.ts +42 -0
  218. package/types/radio-group/src/radio-group.component.d.ts +91 -0
  219. package/types/radio-group/src/radio-group.props.d.ts +87 -0
  220. package/types/section/index.d.ts +23 -0
  221. package/types/section/src/section.component.d.ts +187 -0
  222. package/types/section/src/section.props.d.ts +117 -0
  223. package/types/switch/index.d.ts +23 -0
  224. package/types/switch/src/switch.component.d.ts +66 -0
  225. package/types/switch/src/switch.props.d.ts +52 -0
  226. package/types/tabs/index.d.ts +25 -0
  227. package/types/tabs/src/components/tab-page.component.d.ts +101 -0
  228. package/types/tabs/src/components/tab-page.props.d.ts +63 -0
  229. package/types/tabs/src/composition/types.d.ts +35 -0
  230. package/types/tabs/src/composition/use-tabs.d.ts +18 -0
  231. package/types/tabs/src/tabs.component.d.ts +149 -0
  232. package/types/tabs/src/tabs.props.d.ts +86 -0
  233. package/types/text/index.d.ts +23 -0
  234. package/types/text/src/text.component.d.ts +14 -0
  235. package/types/text/src/text.props.d.ts +26 -0
  236. package/types/tooltip/index.d.ts +24 -0
  237. package/types/tooltip/src/composition/types.d.ts +45 -0
  238. package/types/tooltip/src/composition/use-adjust-placement.d.ts +20 -0
  239. package/types/tooltip/src/composition/use-adjust-position.d.ts +6 -0
  240. package/types/tooltip/src/composition/use-calculate-position.d.ts +21 -0
  241. package/types/tooltip/src/composition/use-relative.d.ts +19 -0
  242. package/types/tooltip/src/composition/use-tooltip-position.d.ts +22 -0
  243. package/types/tooltip/src/tooltip.component.d.ts +56 -0
  244. package/types/tooltip/src/tooltip.props.d.ts +45 -0
  245. package/src/index.umd.js +0 -1
  246. /package/{src/style.css → style.css} +0 -0
@@ -0,0 +1,2 @@
1
+ import { VisualDataCell } from '../../composition/types';
2
+ export default function (cell: VisualDataCell): JSX.Element;
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { VisualDataCell } from '../../composition/types';
17
+ export default function (cell: VisualDataCell): JSX.Element;
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Ref } from 'vue';
17
+ import { UseColumn, UseFitColumn, UseSidebar, UseVirtualScroll } from '../../composition/types';
18
+ import { DataGridProps } from '../../data-grid.props';
19
+ export default function (props: DataGridProps, gridContentRef: Ref<any>, useColumnComposition: UseColumn, useFitColumnComposition: UseFitColumn, useSidebarComposition: UseSidebar, useVirtualScrollComposition: UseVirtualScroll, viewPortWidth: Ref<number>): {
20
+ renderGridHeader: () => JSX.Element;
21
+ renderGridColumnResizeOverlay: () => JSX.Element;
22
+ };
@@ -0,0 +1,5 @@
1
+ import { UseDataView } from '../../composition/types';
2
+ import { DataGridProps } from '../../data-grid.props';
3
+ export default function (props: DataGridProps, dataView: UseDataView): {
4
+ renderDataGridPagination: () => JSX.Element;
5
+ };
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Ref } from 'vue';
17
+ import { UseVirtualScroll } from '../../composition/types';
18
+ import { DataGridProps } from '../../data-grid.props';
19
+ export default function (props: DataGridProps, gridContentRef: Ref<any>, useVirtualScrollComposition: UseVirtualScroll): {
20
+ renderHorizontalScrollbar: () => JSX.Element;
21
+ };
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Ref } from 'vue';
17
+ import { UseVirtualScroll } from '../../composition/types';
18
+ import { DataGridProps } from '../../data-grid.props';
19
+ export default function (props: DataGridProps, gridContentRef: Ref<any>, useVirtualScrollComposition: UseVirtualScroll): {
20
+ renderVerticalScrollbar: () => JSX.Element;
21
+ };
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Ref } from 'vue';
17
+ import { UseRow, UseSidebar, UseVirtualScroll, VisualData } from '../../composition/types';
18
+ import { DataGridProps } from '../../data-grid.props';
19
+ export default function (props: DataGridProps, useRowComposition: UseRow, useSidebarComposition: UseSidebar, useVirtualScrollComposition: UseVirtualScroll): {
20
+ renderDataGridSidebar: (visibleDatas: Ref<VisualData[]>) => JSX.Element;
21
+ };
@@ -0,0 +1,5 @@
1
+ import { UseColumn, UseDataView } from '../../composition/types';
2
+ import { DataGridProps } from '../../data-grid.props';
3
+ export default function (props: DataGridProps, dataView: UseDataView, useColumnComposition: UseColumn): {
4
+ renderDataGridSummery: () => false | JSX.Element | undefined;
5
+ };
@@ -0,0 +1,175 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { ComputedRef, Ref } from 'vue';
17
+ import { DataGridColumn } from '../data-grid.props';
18
+ import { ColumnRenderContext } from './use-column';
19
+ import { DataViewFilter } from './use-data-view';
20
+ export interface DataGridHeaderCell {
21
+ actualWidth: number;
22
+ children: DataGridHeaderCell[];
23
+ depth: number;
24
+ layer: number;
25
+ left: number;
26
+ field: string;
27
+ parent: DataGridHeaderCell | null;
28
+ resizable: boolean;
29
+ title: string;
30
+ }
31
+ export declare enum CellMode {
32
+ readonly = 0,
33
+ editable = 1,
34
+ editing = 2
35
+ }
36
+ export declare enum VisualDataType {
37
+ data = 0,
38
+ group = 1,
39
+ summary = 2
40
+ }
41
+ export interface VisualDataCell {
42
+ actualHeight?: number;
43
+ cellHeight?: number;
44
+ colSpan: number;
45
+ data: any;
46
+ getEditor: (cell: VisualDataCell) => any;
47
+ field: string;
48
+ index: number;
49
+ mode: CellMode;
50
+ ref?: any;
51
+ rowSpan: number;
52
+ setRef: (vnode: any) => void;
53
+ spannedBy?: VisualDataCell;
54
+ spanned?: VisualDataCell[];
55
+ parent: any;
56
+ update: (value: any) => void;
57
+ }
58
+ export interface VisualData {
59
+ collapse?: boolean;
60
+ data: Record<string, VisualDataCell>;
61
+ details?: VisualData[];
62
+ groupField?: string;
63
+ groupValue?: any;
64
+ layer: number;
65
+ index: number;
66
+ dataIndex: number;
67
+ top: number;
68
+ type: VisualDataType;
69
+ ref?: any;
70
+ height?: number;
71
+ pre?: any;
72
+ refreshKey?: string;
73
+ setRef: (vnode: any) => void;
74
+ }
75
+ export interface UseVisualData {
76
+ getVisualData: (start: number, end: number, pre?: VisualData, forceToRefresh?: boolean) => VisualData[];
77
+ maxVisibleRowIndex: Ref<number>;
78
+ minVisibleRowIndex: Ref<number>;
79
+ toggleGroupRow: (status: 'collapse' | 'expand', groupRow: VisualData, visibleDatas: VisualData[]) => VisualData[];
80
+ }
81
+ export interface UseCellPosition {
82
+ calculateCellPositionInRow: (columns: DataGridColumn[]) => Record<string, {
83
+ left: number;
84
+ width: number;
85
+ }>;
86
+ cellKey: (dataItem: VisualData, columnIndex: number) => string;
87
+ cellPosition: (cell: VisualDataCell, cellPositionMap: Record<string, {
88
+ left: number;
89
+ width: number;
90
+ }>) => Record<string, any>;
91
+ rowKey: (dataItem: VisualData) => string;
92
+ rowPosition: (dataItem: VisualData) => Record<string, any>;
93
+ rowSpanCellPosition: (visualDataItem: VisualData, cell: VisualDataCell, cellPositionMap: Record<string, {
94
+ left: number;
95
+ width: number;
96
+ }>) => Record<string, any>;
97
+ groupCellPosition: (groupCell: VisualDataCell, cellPositionMap: Record<string, {
98
+ left: number;
99
+ width: number;
100
+ }>, layer: number) => Record<string, any>;
101
+ summaryCellPosition: (groupCell: VisualDataCell, cellPositionMap: Record<string, {
102
+ left: number;
103
+ width: number;
104
+ }>, layer: number) => Record<string, any>;
105
+ }
106
+ export interface UseVirtualScroll {
107
+ onMouseDownScrollThumb: ($event: MouseEvent, gridContentRef: Ref<any>, thumbType: 'vertical' | 'horizontal') => void;
108
+ onWheel: (payload: WheelEvent) => void;
109
+ dataGridWidth: Ref<number>;
110
+ gridDataStyle: ComputedRef<Record<string, any>>;
111
+ gridHeaderColumnsStyle: ComputedRef<Record<string, any>>;
112
+ gridMergedDataStyle: ComputedRef<Record<string, any>>;
113
+ gridSideStyle: ComputedRef<Record<string, any>>;
114
+ viewPortHeight: Ref<number>;
115
+ viewPortWidth: Ref<number>;
116
+ horizontalScrollThumbStyle: ComputedRef<Record<string, any>>;
117
+ leftFixedGridDataStyle: ComputedRef<Record<string, any>>;
118
+ leftFixedGridHeaderColumnsStyle: ComputedRef<Record<string, any>>;
119
+ leftFixedGridMergedDataStyle: ComputedRef<Record<string, any>>;
120
+ reCalculateVisualDataRows: (forceToRefresh?: boolean) => void;
121
+ rightFixedGridDataStyle: ComputedRef<Record<string, any>>;
122
+ rightFixedGridHeaderColumnsStyle: ComputedRef<Record<string, any>>;
123
+ rightFixedGridMergedDataStyle: ComputedRef<Record<string, any>>;
124
+ verticalScrollThumbStyle: ComputedRef<Record<string, any>>;
125
+ }
126
+ export interface UseRow {
127
+ gridRowClass(dataItem: VisualData): Record<string, any>;
128
+ sidebarRowClass(dataItem: VisualData): Record<string, any>;
129
+ onClickRow: ($event: MouseEvent, dataItem: VisualData) => any;
130
+ onMouseoverRow: ($event: MouseEvent, dataItem: VisualData) => any;
131
+ }
132
+ export interface UseColumn {
133
+ columnContext: Ref<ColumnRenderContext>;
134
+ hasLeftFixedColumn: ComputedRef<boolean>;
135
+ hasRightFixedColumn: ComputedRef<boolean>;
136
+ }
137
+ export interface UseFitColumn {
138
+ calculateColumnHeaders: (context: Ref<ColumnRenderContext>) => void;
139
+ calculateColumnsSize: (context: Ref<ColumnRenderContext>, gridContentElement: any, viewPortWidth: Ref<number>) => void;
140
+ calculateColumnsWidth: (context: Ref<ColumnRenderContext>) => void;
141
+ }
142
+ export interface UseSidebar {
143
+ showRowCheckbox: Ref<boolean>;
144
+ showRowNumer: Ref<boolean>;
145
+ sidebarWidth: ComputedRef<number>;
146
+ sidebarCellPosition: (dataItem: VisualData) => Record<string, any>;
147
+ sidebarCornerCellStyle: ComputedRef<Record<string, any>>;
148
+ }
149
+ export interface UseGroupData {
150
+ collpaseGroupIconClass: (groupRow: VisualData) => Record<string, boolean>;
151
+ renderGroupedData: (groupFields: string[], rawData: any[]) => any[];
152
+ renderGroupRow: (dataItem: any, preDataItem: any, rowIndex: number, top: number, columns: DataGridColumn[]) => VisualData;
153
+ renderSummaryRow: (dataItem: any, preDataItem: any, rowIndex: number, top: number, columns: DataGridColumn[]) => VisualData;
154
+ }
155
+ export interface UseDataView {
156
+ collapse: (collapseField: string, collapseValue: any) => any[];
157
+ dataView: Ref<any[]>;
158
+ expand: (expandField: string, expandValue: any) => any[];
159
+ getRange: (filters: DataViewFilter[], start: number, end: number) => any[];
160
+ navigatePageTo: (pageIndex: number) => void;
161
+ summaries: Map<string, number>;
162
+ totalItems: ComputedRef<number>;
163
+ }
164
+ export interface UseResize {
165
+ onClickColumnResizeBar: ($event: MouseEvent, columnField: string) => any;
166
+ resizeHandleStyle: Ref<Record<string, any>>;
167
+ resizeOverlayStyle: Ref<Record<string, any>>;
168
+ }
169
+ export interface UseEdit {
170
+ getEditor: (cell: VisualDataCell, column: DataGridColumn) => any;
171
+ onClickCell: ($event: MouseEvent, cell: VisualDataCell) => any;
172
+ }
173
+ export interface UseGroupColumn {
174
+ getGridHeaderCells: (columns: DataGridColumn[]) => Map<string, DataGridHeaderCell>;
175
+ }
@@ -0,0 +1,17 @@
1
+ import { DataGridColumn, DataGridProps } from '../data-grid.props';
2
+ import { DataGridHeaderCell, UseColumn } from './types';
3
+ export interface ColumnRenderContext {
4
+ defaultColumnWidth: number;
5
+ headerDepth: number;
6
+ leftColumns: DataGridColumn[];
7
+ leftColumnsWidth: number;
8
+ leftHeaderColumns: DataGridHeaderCell[];
9
+ primaryColumns: DataGridColumn[];
10
+ primaryColumnsWidth: number;
11
+ primaryHeaderColumns: DataGridHeaderCell[];
12
+ rightColumns: DataGridColumn[];
13
+ rightColumnsWidth: number;
14
+ rightHeaderColumns: DataGridHeaderCell[];
15
+ summaryColumns: DataGridColumn[];
16
+ }
17
+ export declare function useColumn(props: DataGridProps): UseColumn;
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { UseDataView } from './types';
17
+ import { DataGridProps } from '../data-grid.props';
18
+ export type DataViewFilter = (dataItem: any) => boolean;
19
+ export declare function useDataView(props: DataGridProps): UseDataView;
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { DataGridProps } from '../data-grid.props';
17
+ import { UseEdit } from './types';
18
+ export declare function useEdit(props: DataGridProps): UseEdit;
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Ref } from 'vue';
17
+ import { DataGridProps } from '../data-grid.props';
18
+ import { UseFitColumn } from './types';
19
+ import { ColumnRenderContext } from './use-column';
20
+ export declare function useFitColumn(props: DataGridProps, context: Ref<ColumnRenderContext>): UseFitColumn;
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { DataGridColumn, DataGridProps } from '../data-grid.props';
17
+ import { Ref } from 'vue';
18
+ import { DataGridHeaderCell } from './types';
19
+ import { ColumnRenderContext } from './use-column';
20
+ export declare function useGroupColumn(props: DataGridProps, columnRenderContext: Ref<ColumnRenderContext>): {
21
+ getGridHeaderCells: (columns: DataGridColumn[]) => Map<string, DataGridHeaderCell>;
22
+ };
@@ -0,0 +1,3 @@
1
+ import { DataGridProps } from '../data-grid.props';
2
+ import { UseGroupData } from './types';
3
+ export declare function useGroupData(props: DataGridProps): UseGroupData;
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { Ref } from 'vue';
17
+ import { DataGridProps } from '../data-grid.props';
18
+ import { UseCellPosition } from './types';
19
+ import { ColumnRenderContext } from './use-column';
20
+ export declare function useCellPosition(props: DataGridProps, context: Ref<ColumnRenderContext>): UseCellPosition;
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { DataGridProps } from '../data-grid.props';
17
+ import { Ref } from 'vue';
18
+ import { UseFitColumn, UseResize, UseVirtualScroll } from './types';
19
+ import { ColumnRenderContext } from './use-column';
20
+ export declare function useResize(props: DataGridProps, context: Ref<ColumnRenderContext>, useFitColumnComposition: UseFitColumn, useVirtualScrollComposition: UseVirtualScroll): UseResize;
@@ -0,0 +1,3 @@
1
+ import { DataGridProps } from '../data-grid.props';
2
+ import { UseRow } from './types';
3
+ export declare function useRow(props: DataGridProps): UseRow;
@@ -0,0 +1,3 @@
1
+ import { DataGridProps } from '../data-grid.props';
2
+ import { UseSidebar } from './types';
3
+ export declare function useSidebar(props: DataGridProps): UseSidebar;
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { DataGridProps } from '../data-grid.props';
17
+ import { UseDataView, UseVirtualScroll, UseVisualData, VisualData } from './types';
18
+ import { Ref } from 'vue';
19
+ import { ColumnRenderContext } from './use-column';
20
+ export declare function useVirtualScroll(props: DataGridProps, dataViewComposition: UseDataView, visibleDatas: Ref<VisualData[]>, columnContext: Ref<ColumnRenderContext>, visualDataComposition: UseVisualData, visibleCapacity: number, preloadCount: number, sidebarWidth: Ref<number>): UseVirtualScroll;
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import { DataGridColumn, DataGridProps } from '../data-grid.props';
17
+ import { Ref } from 'vue';
18
+ import { UseDataView, UseEdit, UseGroupData, UseVisualData } from './types';
19
+ export declare function useVisualData(props: DataGridProps, columns: Ref<DataGridColumn[]>, useGroupData: UseGroupData, dataViewComposition: UseDataView, visibleCapacity: number, preloadCount: number, useEditComposition: UseEdit): UseVisualData;