orion-design 0.1.30 → 0.1.31

Sign up to get free protection for your applications and to get access to all the features.
Files changed (199) hide show
  1. package/README.md +5 -5
  2. package/dist/Throne/index.js +30 -14
  3. package/dist/Throne/index.js.map +1 -1
  4. package/dist/_commonjsHelpers-DWwsNxpa.js +9 -0
  5. package/dist/_commonjsHelpers-DWwsNxpa.js.map +1 -0
  6. package/dist/components/Button/index.js +40 -33
  7. package/dist/components/Button/index.js.map +1 -1
  8. package/dist/components/Flex/index.js +122 -89
  9. package/dist/components/Flex/index.js.map +1 -1
  10. package/dist/components/Form/Form.js +2 -2
  11. package/dist/components/Form/Form.js.map +1 -1
  12. package/dist/components/Form/LovInput/LovInput.js +2 -2
  13. package/dist/components/Form/LovInput/LovInput.js.map +1 -1
  14. package/dist/components/Form/LovInput/hooks/useLov.js +5 -5
  15. package/dist/components/Form/LovInput/hooks/useLov.js.map +1 -1
  16. package/dist/components/Form/LovInput/index.js +4 -4
  17. package/dist/components/Form/hooks/FormItemValidateTrigger.js +2 -2
  18. package/dist/components/Form/hooks/FormItemValidateTrigger.js.map +1 -1
  19. package/dist/components/Form/hooks/index.js +128 -66
  20. package/dist/components/Form/hooks/index.js.map +1 -1
  21. package/dist/components/Form/index.js +836 -656
  22. package/dist/components/Form/index.js.map +1 -1
  23. package/dist/components/Form/utils/index.js +30 -18
  24. package/dist/components/Form/utils/index.js.map +1 -1
  25. package/dist/components/LovTable/index.js +179 -105
  26. package/dist/components/LovTable/index.js.map +1 -1
  27. package/dist/components/Modal/index.js +111 -56
  28. package/dist/components/Modal/index.js.map +1 -1
  29. package/dist/components/Modal/types.js +4 -3
  30. package/dist/components/Modal/types.js.map +1 -1
  31. package/dist/components/Modal/useModal.js +5 -5
  32. package/dist/components/Modal/useModal.js.map +1 -1
  33. package/dist/components/Pagetable/hooks/useColumns.js +88 -80
  34. package/dist/components/Pagetable/hooks/useColumns.js.map +1 -1
  35. package/dist/components/Pagetable/index.js +687 -542
  36. package/dist/components/Pagetable/index.js.map +1 -1
  37. package/dist/components/Pagetable/utils/index.js +92 -54
  38. package/dist/components/Pagetable/utils/index.js.map +1 -1
  39. package/dist/components/Querytable/hooks/useColumns.js +82 -74
  40. package/dist/components/Querytable/hooks/useColumns.js.map +1 -1
  41. package/dist/components/Querytable/index.js +579 -469
  42. package/dist/components/Querytable/index.js.map +1 -1
  43. package/dist/components/Querytable/utils/index.js +92 -54
  44. package/dist/components/Querytable/utils/index.js.map +1 -1
  45. package/dist/components/RichTextEditor/index.js +100 -74
  46. package/dist/components/RichTextEditor/index.js.map +1 -1
  47. package/dist/components/Tabs/constants.js +2 -2
  48. package/dist/components/Tabs/constants.js.map +1 -1
  49. package/dist/components/Tabs/index.js +603 -358
  50. package/dist/components/Tabs/index.js.map +1 -1
  51. package/dist/components/Tabs/tab-bar.js +6 -6
  52. package/dist/components/Tabs/tab-bar.js.map +1 -1
  53. package/dist/components/Tabs/tab-pane.js +3 -3
  54. package/dist/components/Tabs/tab-pane.js.map +1 -1
  55. package/dist/components/_constants/aria.js +2 -2
  56. package/dist/components/_constants/aria.js.map +1 -1
  57. package/dist/components/_constants/event.js +6 -4
  58. package/dist/components/_constants/event.js.map +1 -1
  59. package/dist/components/_constants/index.js +6 -6
  60. package/dist/components/_hooks/index.js +7 -7
  61. package/dist/components/_hooks/use-namespace/index.js +74 -39
  62. package/dist/components/_hooks/use-namespace/index.js.map +1 -1
  63. package/dist/components/_hooks/use-ordered-children/index.js +29 -19
  64. package/dist/components/_hooks/use-ordered-children/index.js.map +1 -1
  65. package/dist/components/_util/arrays.js +9 -5
  66. package/dist/components/_util/arrays.js.map +1 -1
  67. package/dist/components/_util/browser.js +6 -6
  68. package/dist/components/_util/browser.js.map +1 -1
  69. package/dist/components/_util/classNames.js +22 -17
  70. package/dist/components/_util/classNames.js.map +1 -1
  71. package/dist/components/_util/dom/aria.js +74 -39
  72. package/dist/components/_util/dom/aria.js.map +1 -1
  73. package/dist/components/_util/dom/element.js +9 -8
  74. package/dist/components/_util/dom/element.js.map +1 -1
  75. package/dist/components/_util/dom/event.js +14 -7
  76. package/dist/components/_util/dom/event.js.map +1 -1
  77. package/dist/components/_util/dom/index.js +36 -36
  78. package/dist/components/_util/dom/position.js +49 -25
  79. package/dist/components/_util/dom/position.js.map +1 -1
  80. package/dist/components/_util/dom/scroll.js +103 -61
  81. package/dist/components/_util/dom/scroll.js.map +1 -1
  82. package/dist/components/_util/dom/style.js +65 -50
  83. package/dist/components/_util/dom/style.js.map +1 -1
  84. package/dist/components/_util/easings.js +8 -4
  85. package/dist/components/_util/easings.js.map +1 -1
  86. package/dist/components/_util/error.js +12 -11
  87. package/dist/components/_util/error.js.map +1 -1
  88. package/dist/components/_util/functions.js +3 -3
  89. package/dist/components/_util/i18n.js +2 -2
  90. package/dist/components/_util/i18n.js.map +1 -1
  91. package/dist/components/_util/index.js +137 -137
  92. package/dist/components/_util/isValid.js +4 -2
  93. package/dist/components/_util/isValid.js.map +1 -1
  94. package/dist/components/_util/objects.js +18 -14
  95. package/dist/components/_util/objects.js.map +1 -1
  96. package/dist/components/_util/props-util/index.js +46 -20
  97. package/dist/components/_util/props-util/index.js.map +1 -1
  98. package/dist/components/_util/props-util/initDefaultProps.js +18 -10
  99. package/dist/components/_util/props-util/initDefaultProps.js.map +1 -1
  100. package/dist/components/_util/raf.js +5 -4
  101. package/dist/components/_util/raf.js.map +1 -1
  102. package/dist/components/_util/rand.js +4 -3
  103. package/dist/components/_util/rand.js.map +1 -1
  104. package/dist/components/_util/strings.js +9 -8
  105. package/dist/components/_util/strings.js.map +1 -1
  106. package/dist/components/_util/throttleByRaf.js +16 -10
  107. package/dist/components/_util/throttleByRaf.js.map +1 -1
  108. package/dist/components/_util/type.js +41 -38
  109. package/dist/components/_util/type.js.map +1 -1
  110. package/dist/components/_util/types.js +41 -22
  111. package/dist/components/_util/types.js.map +1 -1
  112. package/dist/components/_util/typescript.js +2 -2
  113. package/dist/components/_util/typescript.js.map +1 -1
  114. package/dist/components/_util/util.js +85 -43
  115. package/dist/components/_util/util.js.map +1 -1
  116. package/dist/components/_util/vue/global-node.js +27 -15
  117. package/dist/components/_util/vue/global-node.js.map +1 -1
  118. package/dist/components/_util/vue/icon.js +29 -25
  119. package/dist/components/_util/vue/icon.js.map +1 -1
  120. package/dist/components/_util/vue/index.js +41 -41
  121. package/dist/components/_util/vue/install.js +35 -18
  122. package/dist/components/_util/vue/install.js.map +1 -1
  123. package/dist/components/_util/vue/props/index.js +6 -6
  124. package/dist/components/_util/vue/props/runtime.js +46 -30
  125. package/dist/components/_util/vue/props/runtime.js.map +1 -1
  126. package/dist/components/_util/vue/refs.js +12 -6
  127. package/dist/components/_util/vue/refs.js.map +1 -1
  128. package/dist/components/_util/vue/size.js +5 -3
  129. package/dist/components/_util/vue/size.js.map +1 -1
  130. package/dist/components/_util/vue/validator.js +5 -4
  131. package/dist/components/_util/vue/validator.js.map +1 -1
  132. package/dist/components/_util/vue/vnode.js +100 -54
  133. package/dist/components/_util/vue/vnode.js.map +1 -1
  134. package/dist/components/_util/vue-types/index.js +231 -220
  135. package/dist/components/_util/vue-types/index.js.map +1 -1
  136. package/dist/components/components.js +20 -20
  137. package/dist/components/index.js +38 -35
  138. package/dist/components/index.js.map +1 -1
  139. package/dist/components-B3d9m_tn.js +27 -0
  140. package/dist/components-B3d9m_tn.js.map +1 -0
  141. package/dist/error/OrionError.js +8 -4
  142. package/dist/error/OrionError.js.map +1 -1
  143. package/dist/functions-BeMkokbY.js +63 -0
  144. package/dist/functions-BeMkokbY.js.map +1 -0
  145. package/dist/index-BOKLZnqH.js +54 -0
  146. package/dist/index-BOKLZnqH.js.map +1 -0
  147. package/dist/index-D1m0KTpK.js +69 -0
  148. package/dist/index-D1m0KTpK.js.map +1 -0
  149. package/dist/index-DR5ZP7mD.js +160 -0
  150. package/dist/index-DR5ZP7mD.js.map +1 -0
  151. package/dist/index-DkwIULcN.js +200 -0
  152. package/dist/index-DkwIULcN.js.map +1 -0
  153. package/dist/index.css +797 -1
  154. package/dist/index.js +36 -36
  155. package/dist/print/LodopFuncs.js +101 -43
  156. package/dist/print/LodopFuncs.js.map +1 -1
  157. package/dist/print/index.js +200 -108
  158. package/dist/print/index.js.map +1 -1
  159. package/dist/request/ErrorHandlerChain.js +17 -14
  160. package/dist/request/ErrorHandlerChain.js.map +1 -1
  161. package/dist/request/RequestFilterChain.js +16 -13
  162. package/dist/request/RequestFilterChain.js.map +1 -1
  163. package/dist/request/ResponseParserChain.js +17 -14
  164. package/dist/request/ResponseParserChain.js.map +1 -1
  165. package/dist/request/disivion/DateSerializer.js +47 -22
  166. package/dist/request/disivion/DateSerializer.js.map +1 -1
  167. package/dist/request/disivion/DivisionErrorHandler.js +40 -25
  168. package/dist/request/disivion/DivisionErrorHandler.js.map +1 -1
  169. package/dist/request/disivion/DivisionResponseParser.js +16 -10
  170. package/dist/request/disivion/DivisionResponseParser.js.map +1 -1
  171. package/dist/request/disivion/index.js +305 -201
  172. package/dist/request/disivion/index.js.map +1 -1
  173. package/dist/request/error/BizExceptionResponseError.js +11 -5
  174. package/dist/request/error/BizExceptionResponseError.js.map +1 -1
  175. package/dist/request/error/ExceptionResponseError.js +11 -5
  176. package/dist/request/error/ExceptionResponseError.js.map +1 -1
  177. package/dist/request/error/ResponseError.js +9 -4
  178. package/dist/request/error/ResponseError.js.map +1 -1
  179. package/dist/request/error/SessionExceptionResponseError.js +11 -5
  180. package/dist/request/error/SessionExceptionResponseError.js.map +1 -1
  181. package/dist/request/index.js +11 -11
  182. package/dist/utils/DateUtil.js +48 -33
  183. package/dist/utils/DateUtil.js.map +1 -1
  184. package/dist/utils/NumberUtil.js +6 -6
  185. package/dist/utils/NumberUtil.js.map +1 -1
  186. package/dist/utils/cloneDeep.js +2 -2
  187. package/dist/utils/delay.js +3 -3
  188. package/dist/utils/delay.js.map +1 -1
  189. package/dist/utils/functions.js +3 -3
  190. package/dist/utils/index.js +12 -12
  191. package/dist/utils/md5.js +191 -93
  192. package/dist/utils/md5.js.map +1 -1
  193. package/dist/utils/uuid.js +35 -25
  194. package/dist/utils/uuid.js.map +1 -1
  195. package/dist/version/index.js +2 -2
  196. package/dist/version/version.d.ts +1 -1
  197. package/dist/version/version.js +2 -2
  198. package/dist/version/version.js.map +1 -1
  199. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/LovTable/LovQuerytable.vue","../../../src/components/LovTable/LovPagetable.vue","../../../src/components/LovTable/index.ts"],"sourcesContent":["<template>\r\n <querytable ref=\"table\" :data=\"data\" @row-click=\"onRowClick\" current-row-mode @current-row-change=\"handleCurrentRowChange\" size=\"small\">\r\n <slot></slot>\r\n </querytable>\r\n</template>\r\n<script setup lang=\"ts\">\r\nimport { ref, useTemplateRef, watch } from 'vue'\r\nimport Querytable from '../Querytable'\r\nimport { useLov } from '../Form'\r\nimport { findIndex } from 'lodash-es'\r\n\r\ndefineOptions({ name: 'OLovQuerytable', inheritAttrs: true })\r\n\r\nconst { data } = defineProps<{ data: any[] }>()\r\nconst tableRef = useTemplateRef('table')\r\nconst currentRowIndex = ref()\r\nconst currentRowData = ref()\r\n\r\nconst lov = useLov()\r\nlov?.registerKeydownHandler((code) => {\r\n if (code == 'ArrowUp') {\r\n let nextRow: any\r\n if (currentRowIndex.value == 0) {\r\n nextRow = data[data.length - 1]\r\n } else {\r\n nextRow = data[currentRowIndex.value - 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'ArrowDown') {\r\n let nextRow: any\r\n if (currentRowIndex.value == data.length - 1) {\r\n nextRow = data[0]\r\n } else {\r\n nextRow = data[currentRowIndex.value + 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'Enter') {\r\n currentRowData.value && lov?.backfill(currentRowData.value)\r\n }\r\n})\r\n\r\nconst scrollToRow = (index: number) => {\r\n const $table = tableRef.value?.$el\r\n const $row = $table.querySelectorAll('.el-table__row')[index]\r\n $row.scrollIntoViewIfNeeded()\r\n}\r\n\r\nconst onRowClick = (row: any) => {\r\n lov?.backfill(row)\r\n}\r\n\r\nconst handleCurrentRowChange = (row: any) => {\r\n const index = findIndex(data, row)\r\n if (index == -1) {\r\n currentRowIndex.value = 0\r\n currentRowData.value = data[0]\r\n } else {\r\n currentRowIndex.value = index\r\n currentRowData.value = row\r\n }\r\n}\r\n\r\nwatch(\r\n () => data,\r\n () => {\r\n if (data.length > 0) {\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(data[0])\r\n }\r\n }\r\n)\r\n</script>\r\n","<template>\r\n <pagetable\r\n ref=\"table\"\r\n :data=\"data\"\r\n @row-click=\"onRowClick\"\r\n current-row-mode\r\n @current-row-change=\"handleCurrentRowChange\"\r\n :pagination=\"pagination\"\r\n @update:pagination=\"onUpdatePagination\"\r\n size=\"small\"\r\n >\r\n <slot></slot>\r\n </pagetable>\r\n</template>\r\n<script setup lang=\"ts\">\r\nimport Pagetable from '../Pagetable'\r\nimport { useLov } from '../Form'\r\nimport { ref, useTemplateRef, watch } from 'vue'\r\nimport { findIndex } from 'lodash-es'\r\n\r\ndefineOptions({ name: 'OLovPagetable', inheritAttrs: true })\r\n\r\nconst { data, pagination } = defineProps<{\r\n data: any[]\r\n pagination: {\r\n currentPage?: number\r\n pageSize?: number\r\n total?: number\r\n }\r\n}>()\r\n\r\nconst emits = defineEmits(['update:pagination'])\r\nconst onUpdatePagination = (data: any) => {\r\n emits('update:pagination', data)\r\n}\r\n\r\nconst tableRef = useTemplateRef('table')\r\nconst currentRowIndex = ref()\r\nconst currentRowData = ref()\r\n\r\nconst lov = useLov()\r\nlov?.registerKeydownHandler((code) => {\r\n if (code == 'ArrowUp') {\r\n let nextRow: any\r\n if (currentRowIndex.value == 0) {\r\n nextRow = data[data.length - 1]\r\n } else {\r\n nextRow = data[currentRowIndex.value - 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'ArrowDown') {\r\n let nextRow: any\r\n if (currentRowIndex.value == data.length - 1) {\r\n nextRow = data[0]\r\n } else {\r\n nextRow = data[currentRowIndex.value + 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'Enter') {\r\n currentRowData.value && lov?.backfill(currentRowData.value)\r\n } else if (code == 'ArrowLeft') {\r\n const currentPage = pagination?.currentPage\r\n const pageSize = pagination?.pageSize\r\n const total = pagination?.total\r\n if (!currentPage || !pageSize || !total) {\r\n return\r\n }\r\n if (currentPage > 1) {\r\n emits('update:pagination', {\r\n ...pagination,\r\n currentPage: currentPage - 1,\r\n })\r\n }\r\n } else if (code == 'ArrowRight') {\r\n const currentPage = pagination?.currentPage\r\n const pageSize = pagination?.pageSize\r\n const total = pagination?.total\r\n if (!currentPage || !pageSize || !total) {\r\n return\r\n }\r\n const totalPage = Math.ceil(total / pageSize)\r\n if (currentPage < totalPage) {\r\n emits('update:pagination', {\r\n ...pagination,\r\n currentPage: currentPage + 1,\r\n })\r\n }\r\n }\r\n})\r\n\r\nconst scrollToRow = (index: number) => {\r\n const $table = tableRef.value?.$el\r\n const $row = $table.querySelectorAll('.el-table__row')[index]\r\n $row.scrollIntoViewIfNeeded()\r\n}\r\n\r\nconst onRowClick = (row: any) => {\r\n lov?.backfill(row)\r\n}\r\n\r\nconst handleCurrentRowChange = (row: any) => {\r\n const index = findIndex(data, row)\r\n if (index == -1) {\r\n currentRowIndex.value = 0\r\n currentRowData.value = data[0]\r\n } else {\r\n currentRowIndex.value = index\r\n currentRowData.value = row\r\n }\r\n}\r\n\r\nwatch(\r\n () => data,\r\n () => {\r\n if (data.length > 0) {\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(data[0])\r\n }\r\n }\r\n)\r\n</script>\r\n","import { withInstall } from '../_util'\r\n\r\nimport LovQuerytable from './LovQuerytable.vue'\r\nimport LovPagetable from './LovPagetable.vue'\r\n\r\nexport default withInstall(\r\n {},\r\n {\r\n LovQuerytable,\r\n LovPagetable,\r\n }\r\n)\r\n"],"names":["tableRef","useTemplateRef","currentRowIndex","ref","currentRowData","lov","useLov","code","nextRow","__props","scrollToRow","index","_a","onRowClick","row","handleCurrentRowChange","findIndex","watch","emits","__emit","onUpdatePagination","data","currentPage","pageSize","_b","total","_c","_d","_e","_f","totalPage","withInstall","LovQuerytable","LovPagetable"],"mappings":";;;;;;;;;;;;;;;;AAcM,UAAAA,IAAWC,EAAe,OAAO,GACjCC,IAAkBC,KAClBC,IAAiBD,KAEjBE,IAAMC;AACP,IAAAD,KAAA,QAAAA,EAAA,uBAAuB,CAACE,MAAS;AACpC,UAAIA,KAAQ,WAAW;AACjB,YAAAC;AACA,QAAAN,EAAgB,SAAS,IAC3BM,IAAUC,EAAI,KAACA,EAAI,KAAC,SAAS,CAAC,IAE9BD,IAAUC,OAAKP,EAAgB,QAAQ,CAAC,GAGjCF,EAAA,MAAM,cAAcQ,CAAO,GACpCE,EAAYR,EAAgB,KAAK;AAAA,MAAA,WACxBK,KAAQ,aAAa;AAC1B,YAAAC;AACJ,QAAIN,EAAgB,SAASO,EAAI,KAAC,SAAS,IAC/BD,IAAAC,OAAK,CAAC,IAEhBD,IAAUC,OAAKP,EAAgB,QAAQ,CAAC,GAGjCF,EAAA,MAAM,cAAcQ,CAAO,GACpCE,EAAYR,EAAgB,KAAK;AAAA,MAAA,MACnC,CAAWK,KAAQ,WACjBH,EAAe,UAASC,KAAA,QAAAA,EAAK,SAASD,EAAe;AAAA,IACvD;AAGI,UAAAM,IAAc,CAACC,MAAkB;;AAGrC,QAFeC,IAAAZ,EAAS,UAAT,gBAAAY,EAAgB,KACX,iBAAiB,gBAAgB,EAAED,CAAK,EACvD,uBAAuB;AAAA,IAAA,GAGxBE,IAAa,CAACC,MAAa;AAC/B,MAAAT,KAAA,QAAAA,EAAK,SAASS;AAAA,IAAG,GAGbC,IAAyB,CAACD,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,MAExC;AAAA,IAAA;;;;;;;;;;;;;;;;ICrHFE,IAAeoB;AAAA,EACb,CAAC;AAAA,EACD;AAAA,IAAA,eACEC;AAAAA,IAAA,cACAC;AAAAA,EACF;AACF;"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/LovTable/LovQuerytable.vue","../../../src/components/LovTable/LovPagetable.vue","../../../src/components/LovTable/index.ts"],"sourcesContent":["<template>\r\n <querytable ref=\"table\" :data=\"data\" @row-click=\"onRowClick\" current-row-mode @current-row-change=\"handleCurrentRowChange\" size=\"small\">\r\n <slot></slot>\r\n </querytable>\r\n</template>\r\n<script setup lang=\"ts\">\r\nimport { ref, useTemplateRef, watch } from 'vue'\r\nimport Querytable from '../Querytable'\r\nimport { useLov } from '../Form'\r\nimport { findIndex } from 'lodash-es'\r\n\r\ndefineOptions({ name: 'OLovQuerytable', inheritAttrs: true })\r\n\r\nconst { data } = defineProps<{ data: any[] }>()\r\nconst tableRef = useTemplateRef('table')\r\nconst currentRowIndex = ref()\r\nconst currentRowData = ref()\r\n\r\nconst lov = useLov()\r\nlov?.registerKeydownHandler((code) => {\r\n if (code == 'ArrowUp') {\r\n let nextRow: any\r\n if (currentRowIndex.value == 0) {\r\n nextRow = data[data.length - 1]\r\n } else {\r\n nextRow = data[currentRowIndex.value - 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'ArrowDown') {\r\n let nextRow: any\r\n if (currentRowIndex.value == data.length - 1) {\r\n nextRow = data[0]\r\n } else {\r\n nextRow = data[currentRowIndex.value + 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'Enter') {\r\n currentRowData.value && lov?.backfill(currentRowData.value)\r\n }\r\n})\r\n\r\nconst scrollToRow = (index: number) => {\r\n const $table = tableRef.value?.$el\r\n const $row = $table.querySelectorAll('.el-table__row')[index]\r\n $row.scrollIntoViewIfNeeded()\r\n}\r\n\r\nconst onRowClick = (row: any) => {\r\n lov?.backfill(row)\r\n}\r\n\r\nconst handleCurrentRowChange = (row: any) => {\r\n const index = findIndex(data, row)\r\n if (index == -1) {\r\n currentRowIndex.value = 0\r\n currentRowData.value = data[0]\r\n } else {\r\n currentRowIndex.value = index\r\n currentRowData.value = row\r\n }\r\n}\r\n\r\nwatch(\r\n () => data,\r\n () => {\r\n if (data.length > 0) {\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(data[0])\r\n }\r\n }\r\n)\r\n</script>\r\n","<template>\r\n <pagetable\r\n ref=\"table\"\r\n :data=\"data\"\r\n @row-click=\"onRowClick\"\r\n current-row-mode\r\n @current-row-change=\"handleCurrentRowChange\"\r\n :pagination=\"pagination\"\r\n @update:pagination=\"onUpdatePagination\"\r\n size=\"small\"\r\n >\r\n <slot></slot>\r\n </pagetable>\r\n</template>\r\n<script setup lang=\"ts\">\r\nimport Pagetable from '../Pagetable'\r\nimport { useLov } from '../Form'\r\nimport { ref, useTemplateRef, watch } from 'vue'\r\nimport { findIndex } from 'lodash-es'\r\n\r\ndefineOptions({ name: 'OLovPagetable', inheritAttrs: true })\r\n\r\nconst { data, pagination } = defineProps<{\r\n data: any[]\r\n pagination: {\r\n currentPage?: number\r\n pageSize?: number\r\n total?: number\r\n }\r\n}>()\r\n\r\nconst emits = defineEmits(['update:pagination'])\r\nconst onUpdatePagination = (data: any) => {\r\n emits('update:pagination', data)\r\n}\r\n\r\nconst tableRef = useTemplateRef('table')\r\nconst currentRowIndex = ref()\r\nconst currentRowData = ref()\r\n\r\nconst lov = useLov()\r\nlov?.registerKeydownHandler((code) => {\r\n if (code == 'ArrowUp') {\r\n let nextRow: any\r\n if (currentRowIndex.value == 0) {\r\n nextRow = data[data.length - 1]\r\n } else {\r\n nextRow = data[currentRowIndex.value - 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'ArrowDown') {\r\n let nextRow: any\r\n if (currentRowIndex.value == data.length - 1) {\r\n nextRow = data[0]\r\n } else {\r\n nextRow = data[currentRowIndex.value + 1]\r\n }\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(nextRow)\r\n scrollToRow(currentRowIndex.value)\r\n } else if (code == 'Enter') {\r\n currentRowData.value && lov?.backfill(currentRowData.value)\r\n } else if (code == 'ArrowLeft') {\r\n const currentPage = pagination?.currentPage\r\n const pageSize = pagination?.pageSize\r\n const total = pagination?.total\r\n if (!currentPage || !pageSize || !total) {\r\n return\r\n }\r\n if (currentPage > 1) {\r\n emits('update:pagination', {\r\n ...pagination,\r\n currentPage: currentPage - 1,\r\n })\r\n }\r\n } else if (code == 'ArrowRight') {\r\n const currentPage = pagination?.currentPage\r\n const pageSize = pagination?.pageSize\r\n const total = pagination?.total\r\n if (!currentPage || !pageSize || !total) {\r\n return\r\n }\r\n const totalPage = Math.ceil(total / pageSize)\r\n if (currentPage < totalPage) {\r\n emits('update:pagination', {\r\n ...pagination,\r\n currentPage: currentPage + 1,\r\n })\r\n }\r\n }\r\n})\r\n\r\nconst scrollToRow = (index: number) => {\r\n const $table = tableRef.value?.$el\r\n const $row = $table.querySelectorAll('.el-table__row')[index]\r\n $row.scrollIntoViewIfNeeded()\r\n}\r\n\r\nconst onRowClick = (row: any) => {\r\n lov?.backfill(row)\r\n}\r\n\r\nconst handleCurrentRowChange = (row: any) => {\r\n const index = findIndex(data, row)\r\n if (index == -1) {\r\n currentRowIndex.value = 0\r\n currentRowData.value = data[0]\r\n } else {\r\n currentRowIndex.value = index\r\n currentRowData.value = row\r\n }\r\n}\r\n\r\nwatch(\r\n () => data,\r\n () => {\r\n if (data.length > 0) {\r\n //@ts-ignore\r\n tableRef.value.setCurrentRow(data[0])\r\n }\r\n }\r\n)\r\n</script>\r\n","import { withInstall } from '../_util'\r\n\r\nimport LovQuerytable from './LovQuerytable.vue'\r\nimport LovPagetable from './LovPagetable.vue'\r\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AAe;AAAA,EACb,CAAC;AAAA,EACD;AAAA,IAAA,eACEC;AAAAA,IAAA,cACAC;AAAAA,EACF;AACF;"}
@@ -1,72 +1,127 @@
1
1
  import "lodash-es";
2
- import { defineComponent as g, inject as L, ref as o, shallowRef as O, provide as M, createVNode as w, Fragment as P, useTemplateRef as k, openBlock as E, createElementBlock as T, renderSlot as b } from "vue";
3
- import { withInstall as j } from "../_util/vue/install.js";
4
- import { ElDialog as B } from "element-plus";
5
- import { addUnit as I } from "../_util/dom/style.js";
6
- import { modalLocatorContextKey as x, modalContextKey as K } from "./types.js";
7
- const R = /* @__PURE__ */ g({
2
+ import { defineComponent, inject, ref, shallowRef, provide, createVNode, Fragment, useTemplateRef, openBlock, createElementBlock, renderSlot } from "vue";
3
+ import { withInstall } from "../_util/vue/install.js";
4
+ import { ElDialog } from "element-plus";
5
+ import { addUnit } from "../_util/dom/style.js";
6
+ import { modalLocatorContextKey, modalContextKey } from "./types.js";
7
+ const Modal = /* @__PURE__ */ defineComponent({
8
8
  name: "OModal",
9
- setup(l, {
10
- slots: a,
11
- attrs: t,
12
- emit: u,
13
- expose: c
9
+ setup(props, {
10
+ slots,
11
+ attrs,
12
+ emit,
13
+ expose
14
14
  }) {
15
- const d = L(x), n = o(!1), i = o(), v = O(), r = o(), f = o(), m = o(), h = o(), p = o(!0), s = o();
16
- c({
17
- open: async (e) => (n.value = !0, i.value = e.title, v.value = e.content, e.contentProps ? r.value = e.contentProps : r.value = {}, e.width && (f.value = e.width), e.height && (m.value = I(e.height)), e.showClose != null && e.showClose == !1 && (p.value = !1), e.locator ? s.value = e.locator : d && d.locator.value && (s.value = d.locator.value), new Promise((y, S) => {
18
- h.value = y;
19
- }))
15
+ const modalLocator = inject(modalLocatorContextKey);
16
+ const show = ref(false);
17
+ const title = ref();
18
+ const content = shallowRef();
19
+ const contentProps = ref();
20
+ const width = ref();
21
+ const height = ref();
22
+ const __resolve = ref();
23
+ const showClose = ref(true);
24
+ const appendTo = ref();
25
+ const _open = async (options) => {
26
+ show.value = true;
27
+ title.value = options.title;
28
+ content.value = options.content;
29
+ if (options.contentProps) {
30
+ contentProps.value = options.contentProps;
31
+ } else {
32
+ contentProps.value = {};
33
+ }
34
+ if (options.width) {
35
+ width.value = options.width;
36
+ }
37
+ if (options.height) {
38
+ height.value = addUnit(options.height);
39
+ }
40
+ if (options.showClose != void 0 && options.showClose == false) {
41
+ showClose.value = false;
42
+ }
43
+ if (options.locator) {
44
+ appendTo.value = options.locator;
45
+ } else {
46
+ if (modalLocator && modalLocator.locator.value) {
47
+ appendTo.value = modalLocator.locator.value;
48
+ }
49
+ }
50
+ const promise = new Promise((resolve, reject) => {
51
+ __resolve.value = resolve;
52
+ });
53
+ return promise;
54
+ };
55
+ expose({
56
+ open: _open
20
57
  });
21
- const C = (e) => {
22
- const _ = h.value;
23
- n.value = !1, i.value = void 0, v.value = void 0, r.value = void 0, f.value = void 0, m.value = void 0, h.value = void 0, p.value = !0, s.value = void 0, _ && _(e);
58
+ const _close = (options) => {
59
+ const resolve = __resolve.value;
60
+ show.value = false;
61
+ title.value = void 0;
62
+ content.value = void 0;
63
+ contentProps.value = void 0;
64
+ width.value = void 0;
65
+ height.value = void 0;
66
+ __resolve.value = void 0;
67
+ showClose.value = true;
68
+ appendTo.value = void 0;
69
+ resolve && resolve(options);
24
70
  };
25
- return M(K, {
26
- close: C
27
- }), () => {
28
- const e = v.value;
29
- return n.value ? w(B, {
30
- title: i.value,
31
- width: f.value,
32
- modelValue: n.value,
33
- beforeClose: C,
34
- draggable: !0,
35
- closeOnClickModal: !1,
36
- closeOnPressEscape: !1,
37
- showClose: p.value,
38
- alignCenter: !0,
39
- style: {
40
- height: m.value
71
+ provide(modalContextKey, {
72
+ close: _close
73
+ });
74
+ return () => {
75
+ const Children = content.value;
76
+ return show.value ? createVNode(ElDialog, {
77
+ "title": title.value,
78
+ "width": width.value,
79
+ "modelValue": show.value,
80
+ "beforeClose": _close,
81
+ "draggable": true,
82
+ "closeOnClickModal": false,
83
+ "closeOnPressEscape": false,
84
+ "showClose": showClose.value,
85
+ "alignCenter": true,
86
+ "style": {
87
+ height: height.value
41
88
  },
42
- appendTo: s.value
89
+ "appendTo": appendTo.value
43
90
  }, {
44
- default: () => [w(e, r.value, null)]
45
- }) : w(P, null, null);
91
+ default: () => [createVNode(Children, contentProps.value, null)]
92
+ }) : createVNode(Fragment, null, null);
46
93
  };
47
94
  }
48
- }), V = {
95
+ });
96
+ const _hoisted_1 = {
49
97
  ref: "modal-locator",
50
98
  class: "orion-modal-locator"
51
- }, A = /* @__PURE__ */ g({
52
- name: "OModalLocator",
53
- inheritAttrs: !0,
99
+ };
100
+ const _sfc_main = /* @__PURE__ */ defineComponent({
101
+ ...{ name: "OModalLocator", inheritAttrs: true },
54
102
  __name: "ModalLocator",
55
- setup(l) {
56
- const a = k("modal-locator");
57
- return M(x, {
58
- locator: a
59
- }), (t, u) => (E(), T("div", V, [
60
- b(t.$slots, "default", {}, void 0, !0)
61
- ], 512));
103
+ setup(__props) {
104
+ const locator = useTemplateRef("modal-locator");
105
+ provide(modalLocatorContextKey, {
106
+ locator
107
+ });
108
+ return (_ctx, _cache) => {
109
+ return openBlock(), createElementBlock("div", _hoisted_1, [
110
+ renderSlot(_ctx.$slots, "default", {}, void 0, true)
111
+ ], 512);
112
+ };
113
+ }
114
+ });
115
+ const _export_sfc = (sfc, props) => {
116
+ const target = sfc.__vccOpts || sfc;
117
+ for (const [key, val] of props) {
118
+ target[key] = val;
62
119
  }
63
- }), D = (l, a) => {
64
- const t = l.__vccOpts || l;
65
- for (const [u, c] of a)
66
- t[u] = c;
67
- return t;
68
- }, F = /* @__PURE__ */ D(A, [["__scopeId", "data-v-0fd5a1a9"]]), J = j(R, { ModalLocator: F });
120
+ return target;
121
+ };
122
+ const ModalLocator = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-0fd5a1a9"]]);
123
+ const index = withInstall(Modal, { ModalLocator });
69
124
  export {
70
- J as default
125
+ index as default
71
126
  };
72
127
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../src/components/Modal/Modal.tsx","../../../src/components/Modal/ModalLocator.vue","../../../src/components/Modal/index.ts"],"sourcesContent":["import { defineComponent, inject, provide, ref, shallowRef } from 'vue'\r\nimport { ElDialog } from 'element-plus'\r\nimport { addUnit } from '../_util'\r\nimport { modalContextKey, modalLocatorContextKey, ModalOptions } from './types'\r\n\r\nconst Modal = defineComponent({\r\n name: 'OModal',\r\n setup(props, { slots, attrs, emit, expose }) {\r\n const modalLocator = inject(modalLocatorContextKey)\r\n\r\n const show = ref(false)\r\n const title = ref<string>()\r\n const content = shallowRef()\r\n const contentProps = ref<Record<string, any>>()\r\n const width = ref<number | string>()\r\n const height = ref<number | string>()\r\n const __resolve = ref<(value: Record<string, any> | PromiseLike<Record<string, any>>) => void>()\r\n const showClose = ref(true)\r\n const appendTo = ref<string | HTMLElement>()\r\n\r\n const _open: (options: ModalOptions) => Promise<Record<string, any>> = async (options) => {\r\n show.value = true\r\n title.value = options.title\r\n content.value = options.content\r\n if (options.contentProps) {\r\n contentProps.value = options.contentProps\r\n } else {\r\n contentProps.value = {}\r\n }\r\n if (options.width) {\r\n width.value = options.width\r\n }\r\n if (options.height) {\r\n height.value = addUnit(options.height)\r\n }\r\n if (options.showClose != undefined && options.showClose == false) {\r\n showClose.value = false\r\n }\r\n if (options.locator) {\r\n appendTo.value = options.locator\r\n } else {\r\n if (modalLocator && modalLocator.locator.value) {\r\n appendTo.value = modalLocator.locator.value\r\n }\r\n }\r\n\r\n const promise = new Promise<Record<string, any>>((resolve, reject) => {\r\n __resolve.value = resolve\r\n })\r\n\r\n return promise\r\n }\r\n expose({\r\n open: _open,\r\n })\r\n\r\n const _close: (options: Record<string, any>) => void = (options) => {\r\n const resolve = __resolve.value\r\n\r\n show.value = false\r\n title.value = undefined\r\n content.value = undefined\r\n contentProps.value = undefined\r\n width.value = undefined\r\n height.value = undefined\r\n __resolve.value = undefined\r\n showClose.value = true\r\n appendTo.value = undefined\r\n\r\n resolve && resolve(options)\r\n }\r\n provide(modalContextKey, { close: _close })\r\n\r\n return () => {\r\n const Children = content.value\r\n return show.value ? (\r\n <ElDialog\r\n title={title.value}\r\n width={width.value}\r\n modelValue={show.value}\r\n beforeClose={_close}\r\n draggable={true}\r\n closeOnClickModal={false}\r\n closeOnPressEscape={false}\r\n showClose={showClose.value}\r\n alignCenter={true}\r\n style={{ height: height.value }}\r\n appendTo={appendTo.value}\r\n >\r\n <Children {...contentProps.value}></Children>\r\n </ElDialog>\r\n ) : (\r\n <></>\r\n )\r\n }\r\n },\r\n})\r\n\r\nexport default Modal\r\n","<template>\r\n <div ref=\"modal-locator\" class=\"orion-modal-locator\"><slot></slot></div>\r\n</template>\r\n<script setup lang=\"ts\">\r\nimport { provide, useTemplateRef } from 'vue'\r\nimport { modalLocatorContextKey } from './types'\r\n\r\ndefineOptions({ name: 'OModalLocator', inheritAttrs: true })\r\nconst locator = useTemplateRef('modal-locator')\r\n\r\nprovide(modalLocatorContextKey, {\r\n locator,\r\n})\r\n</script>\r\n<style lang=\"scss\" scoped>\r\n.orion-modal-locator {\r\n width: 100%;\r\n height: 100%;\r\n overflow: auto;\r\n box-sizing: border-box;\r\n position: relative;\r\n\r\n :deep(> .el-overlay) {\r\n position: absolute;\r\n\r\n > .el-overlay-dialog {\r\n position: absolute;\r\n }\r\n }\r\n}\r\n</style>\r\n","import { withInstall } from '../_util'\r\n\r\nimport Modal from './Modal'\r\nimport ModalLocator from './ModalLocator.vue'\r\n\r\nexport default withInstall<typeof Modal, { ModalLocator: typeof ModalLocator }>(Modal, { ModalLocator })\r\n"],"names":["Modal","defineComponent","name","setup","props","slots","attrs","emit","expose","modalLocator","inject","modalLocatorContextKey","show","ref","title","content","shallowRef","contentProps","width","height","__resolve","showClose","appendTo","open","options","value","addUnit","undefined","locator","Promise","resolve","reject","_close","provide","modalContextKey","close","Children","_createVNode","ElDialog","default","_Fragment","useTemplate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EAASG,QAAQE,QAEjBG,KAAWA,EAAQN,CAAO;AAAA;AAE5BS,WAAAA,EAAQC,GAAiB;AAAA,MAAEC,OAAOH;AAAAA,IAAO,CAAC,GAEnC,MAAM;AACX,YAAMI,IAAWrB,EAAQU;AACzB,aAAOb,EAAKa,QAAKY,EAAAC,GAAA;AAAA,QAAA,OAENxB,EAAMW;AAAAA,QAAK,OACXP,EAAMO;AAAAA,QAAK,YACNb,EAAKa;AAAAA,QAAK,aACTO;AAAAA,QAAM,WACR;AAAA,QAAI,mBACI;AAAA,QAAK,oBACJ;AAAA,QAAK,WACdX,EAAUI;AAAAA,QAAK,aACb;AAAA,QAAI,OACV;AAAA,UAAEN,QAAQA,EAAOM;AAAAA,QAAO;AAAA,QAAA,UACrBH,EAASG;AAAAA,MAAK,GAAA;AAAA,QAAAc,SAAAA,MAAAF,CAAAA,EAAAD,GAEVnB,EAAaQ,OAAK,IAAA,CAAA;AAAA,MAAAY,CAAAA,IAAAA,EAAAG,GAInC,MAAA,IAAA;AAAA;EAEL;AACF,CAAC;;;;;;;;ACxFK,UAAAZ,IAAUa,EAAe,eAAe;AAE9C,WAAAR,EAAQtB,GAAwB;AAAA,MAC9B,SAAAiB;AAAA,IAAA,CACD;;;;;;;;;iECPDc,IAAeC,EAAiE3C,GAAO,EAAE,cAAA4C,GAAc;"}
1
+ {"version":3,"file":"index.js","sources":["../../../src/components/Modal/Modal.tsx","../../../src/components/Modal/ModalLocator.vue","../../../src/components/Modal/index.ts"],"sourcesContent":["import { defineComponent, inject, provide, ref, shallowRef } from 'vue'\r\nimport { ElDialog } from 'element-plus'\r\nimport { addUnit } from '../_util'\r\nimport { modalContextKey, modalLocatorContextKey, ModalOptions } from './types'\r\n\r\nconst Modal = defineComponent({\r\n name: 'OModal',\r\n setup(props, { slots, attrs, emit, expose }) {\r\n const modalLocator = inject(modalLocatorContextKey)\r\n\r\n const show = ref(false)\r\n const title = ref<string>()\r\n const content = shallowRef()\r\n const contentProps = ref<Record<string, any>>()\r\n const width = ref<number | string>()\r\n const height = ref<number | string>()\r\n const __resolve = ref<(value: Record<string, any> | PromiseLike<Record<string, any>>) => void>()\r\n const showClose = ref(true)\r\n const appendTo = ref<string | HTMLElement>()\r\n\r\n const _open: (options: ModalOptions) => Promise<Record<string, any>> = async (options) => {\r\n show.value = true\r\n title.value = options.title\r\n content.value = options.content\r\n if (options.contentProps) {\r\n contentProps.value = options.contentProps\r\n } else {\r\n contentProps.value = {}\r\n }\r\n if (options.width) {\r\n width.value = options.width\r\n }\r\n if (options.height) {\r\n height.value = addUnit(options.height)\r\n }\r\n if (options.showClose != undefined && options.showClose == false) {\r\n showClose.value = false\r\n }\r\n if (options.locator) {\r\n appendTo.value = options.locator\r\n } else {\r\n if (modalLocator && modalLocator.locator.value) {\r\n appendTo.value = modalLocator.locator.value\r\n }\r\n }\r\n\r\n const promise = new Promise<Record<string, any>>((resolve, reject) => {\r\n __resolve.value = resolve\r\n })\r\n\r\n return promise\r\n }\r\n expose({\r\n open: _open,\r\n })\r\n\r\n const _close: (options: Record<string, any>) => void = (options) => {\r\n const resolve = __resolve.value\r\n\r\n show.value = false\r\n title.value = undefined\r\n content.value = undefined\r\n contentProps.value = undefined\r\n width.value = undefined\r\n height.value = undefined\r\n __resolve.value = undefined\r\n showClose.value = true\r\n appendTo.value = undefined\r\n\r\n resolve && resolve(options)\r\n }\r\n provide(modalContextKey, { close: _close })\r\n\r\n return () => {\r\n const Children = content.value\r\n return show.value ? (\r\n <ElDialog\r\n title={title.value}\r\n width={width.value}\r\n modelValue={show.value}\r\n beforeClose={_close}\r\n draggable={true}\r\n closeOnClickModal={false}\r\n closeOnPressEscape={false}\r\n showClose={showClose.value}\r\n alignCenter={true}\r\n style={{ height: height.value }}\r\n appendTo={appendTo.value}\r\n >\r\n <Children {...contentProps.value}></Children>\r\n </ElDialog>\r\n ) : (\r\n <></>\r\n )\r\n }\r\n },\r\n})\r\n\r\nexport default Modal\r\n","<template>\r\n <div ref=\"modal-locator\" class=\"orion-modal-locator\"><slot></slot></div>\r\n</template>\r\n<script setup lang=\"ts\">\r\nimport { provide, useTemplateRef } from 'vue'\r\nimport { modalLocatorContextKey } from './types'\r\n\r\ndefineOptions({ name: 'OModalLocator', inheritAttrs: true })\r\nconst locator = useTemplateRef('modal-locator')\r\n\r\nprovide(modalLocatorContextKey, {\r\n locator,\r\n})\r\n</script>\r\n<style lang=\"scss\" scoped>\r\n.orion-modal-locator {\r\n width: 100%;\r\n height: 100%;\r\n overflow: auto;\r\n box-sizing: border-box;\r\n position: relative;\r\n\r\n :deep(> .el-overlay) {\r\n position: absolute;\r\n\r\n > .el-overlay-dialog {\r\n position: absolute;\r\n }\r\n }\r\n}\r\n</style>\r\n","import { withInstall } from '../_util'\r\n\r\nimport Modal from './Modal'\r\nimport ModalLocator from './ModalLocator.vue'\r\n\r\nexport default withInstall<typeof Modal, { ModalLocator: typeof ModalLocator }>(Modal, { ModalLocator })\r\n"],"names":["Modal","defineComponent","name","setup","props","slots","attrs","emit","expose","modalLocator","inject","modalLocatorContextKey","show","ref","title","content","shallowRef","contentProps","width","height","__resolve","showClose","appendTo","_open","options","value","addUnit","undefined","locator","promise","Promise","resolve","reject","open","_close","provide","modalContextKey","close","Children","_createVNode","ElDialog","default","_Fragment"],"mappings":";;;;;;AAKA,MAAMA,QAAQC,gCAAgB;AAAA,EAC5BC,MAAM;AAAA,EACNC,MAAMC,OAAO;AAAA,IAAEC;AAAAA,IAAOC;AAAAA,IAAOC;AAAAA,IAAMC;AAAAA,EAAO,GAAG;AAC3C,UAAMC,eAAeC,OAAOC,sBAAsB;AAElD,UAAMC,OAAOC,IAAI,KAAK;AACtB,UAAMC,QAAQD;AACd,UAAME,UAAUC;AAChB,UAAMC,eAAeJ;AACrB,UAAMK,QAAQL;AACd,UAAMM,SAASN;AACf,UAAMO,YAAYP;AAClB,UAAMQ,YAAYR,IAAI,IAAI;AAC1B,UAAMS,WAAWT;AAEjB,UAAMU,QAAiE,OAAOC,YAAY;AACxFZ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QAAK,SACXP,MAAMO;AAAAA,QAAK,cACNb,KAAKa;AAAAA,QAAK,eACTS;AAAAA,QAAM,aACR;AAAA,QAAI,qBACI;AAAA,QAAK,sBACJ;AAAA,QAAK,aACdb,UAAUI;AAAAA,QAAK,eACb;AAAA,QAAI,SACV;AAAA,UAAEN,QAAQA,OAAOM;AAAAA,QAAO;AAAA,QAAA,YACrBH,SAASG;AAAAA,MAAK,GAAA;AAAA,QAAAgB,SAAAA,MAAAF,CAAAA,YAAAD,UAEVrB,aAAaQ,OAAK,IAAA,CAAA;AAAA,MAAAc,CAAAA,IAAAA,YAAAG,UAInC,MAAA,IAAA;AAAA;EAEL;AACF,CAAC;;;;;;;;;ACxFK,UAAA,UAAU,eAAe,eAAe;AAE9C,YAAQ,wBAAwB;AAAA,MAC9B;AAAA,IAAA,CACD;;;;;;;;;;;;;;;;ACPD,MAAA,QAAe,YAAiE,OAAO,EAAE,cAAc;"}
@@ -1,6 +1,7 @@
1
- const o = Symbol("modalContextKey"), t = Symbol("modalLocatorContextKey");
1
+ const modalContextKey = Symbol("modalContextKey");
2
+ const modalLocatorContextKey = Symbol("modalLocatorContextKey");
2
3
  export {
3
- o as modalContextKey,
4
- t as modalLocatorContextKey
4
+ modalContextKey,
5
+ modalLocatorContextKey
5
6
  };
6
7
  //# sourceMappingURL=types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sources":["../../../src/components/Modal/types.ts"],"sourcesContent":["import { InjectionKey, ShallowRef, VNode } from 'vue'\r\n\r\nexport interface ModalOptions {\r\n title: string\r\n content: VNode\r\n contentProps?: Record<string, any>\r\n width?: number | string\r\n height?: number | string\r\n showClose?: boolean\r\n locator?: string | HTMLElement\r\n}\r\n\r\nexport interface ModalContext {\r\n close: (options: Record<string, any>) => void\r\n}\r\n\r\nexport const modalContextKey: InjectionKey<ModalContext> = Symbol('modalContextKey')\r\n\r\nexport interface ModalLocatorContext {\r\n locator: ShallowRef<HTMLElement | null>\r\n}\r\n\r\nexport const modalLocatorContextKey: InjectionKey<ModalLocatorContext> = Symbol('modalLocatorContextKey')\r\n"],"names":["modalContextKey","modalLocatorContextKey"],"mappings":"AAgBa,MAAAA,IAA8C,OAAO,iBAAiB,GAMtEC,IAA4D,OAAO,wBAAwB;"}
1
+ {"version":3,"file":"types.js","sources":["../../../src/components/Modal/types.ts"],"sourcesContent":["import { InjectionKey, ShallowRef, VNode } from 'vue'\r\n\r\nexport interface ModalOptions {\r\n title: string\r\n content: VNode\r\n contentProps?: Record<string, any>\r\n width?: number | string\r\n height?: number | string\r\n showClose?: boolean\r\n locator?: string | HTMLElement\r\n}\r\n\r\nexport interface ModalContext {\r\n close: (options: Record<string, any>) => void\r\n}\r\n\r\nexport const modalContextKey: InjectionKey<ModalContext> = Symbol('modalContextKey')\r\n\r\nexport interface ModalLocatorContext {\r\n locator: ShallowRef<HTMLElement | null>\r\n}\r\n\r\nexport const modalLocatorContextKey: InjectionKey<ModalLocatorContext> = Symbol('modalLocatorContextKey')\r\n"],"names":[],"mappings":"AAgBa,MAAA,kBAA8C,OAAO,iBAAiB;AAMtE,MAAA,yBAA4D,OAAO,wBAAwB;"}
@@ -1,9 +1,9 @@
1
- import { inject as o } from "vue";
2
- import { modalContextKey as t } from "./types.js";
3
- function m() {
4
- return o(t);
1
+ import { inject } from "vue";
2
+ import { modalContextKey } from "./types.js";
3
+ function useModal() {
4
+ return inject(modalContextKey);
5
5
  }
6
6
  export {
7
- m as default
7
+ useModal as default
8
8
  };
9
9
  //# sourceMappingURL=useModal.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"useModal.js","sources":["../../../src/components/Modal/useModal.ts"],"sourcesContent":["import { inject } from 'vue'\r\nimport { modalContextKey } from './types'\r\n\r\nexport default function useModal() {\r\n return inject(modalContextKey)\r\n}\r\n"],"names":["useModal","inject","modalContextKey"],"mappings":";;AAGA,SAAwBA,IAAW;AACjC,SAAOC,EAAOC,CAAe;AAC/B;"}
1
+ {"version":3,"file":"useModal.js","sources":["../../../src/components/Modal/useModal.ts"],"sourcesContent":["import { inject } from 'vue'\r\nimport { modalContextKey } from './types'\r\n\r\nexport default function useModal() {\r\n return inject(modalContextKey)\r\n}\r\n"],"names":[],"mappings":";;AAGA,SAAwB,WAAW;AACjC,SAAO,OAAO,eAAe;AAC/B;"}
@@ -1,103 +1,111 @@
1
- import { computed as f } from "vue";
2
- import g from "../../../error/OrionError.js";
3
- import { camelize as y } from "../../_util/util.js";
4
- import { filterEmpty as m } from "../../_util/props-util/index.js";
5
- function d(t) {
6
- return t == null ? void 0 : t.map((a) => {
7
- var n, i;
8
- const e = { ...a.props || {} };
9
- for (const [l, u] of Object.entries(e))
10
- delete e[l], e[y(l)] = u;
11
- if (a.type.name === "OPagetableColumnIndex")
1
+ import { computed } from "vue";
2
+ import OrionError from "../../../error/OrionError.js";
3
+ import { camelize } from "../../_util/util.js";
4
+ import { filterEmpty } from "../../_util/props-util/index.js";
5
+ function genColumns(children) {
6
+ const tableColumns = children == null ? void 0 : children.map((c) => {
7
+ var _a, _b;
8
+ const props = { ...c.props || {} };
9
+ for (const [k, v] of Object.entries(props)) {
10
+ delete props[k];
11
+ props[camelize(k)] = v;
12
+ }
13
+ if (c.type.name === "OPagetableColumnIndex") {
12
14
  return {
13
- type: a.type.name
15
+ type: c.type.name
14
16
  };
15
- if (a.type.name === "OPagetableColumnString" || a.type.name === "OPagetableColumnLink")
17
+ } else if (c.type.name === "OPagetableColumnString" || c.type.name === "OPagetableColumnLink") {
16
18
  return {
17
- type: a.type.name,
18
- head: e == null ? void 0 : e.head,
19
- headAlign: e == null ? void 0 : e.headAlign,
20
- name: e == null ? void 0 : e.name,
21
- width: e == null ? void 0 : e.width,
22
- fixed: e == null ? void 0 : e.fixed,
23
- tail: e == null ? void 0 : e.tail
19
+ type: c.type.name,
20
+ head: props == null ? void 0 : props.head,
21
+ headAlign: props == null ? void 0 : props.headAlign,
22
+ name: props == null ? void 0 : props.name,
23
+ width: props == null ? void 0 : props.width,
24
+ fixed: props == null ? void 0 : props.fixed,
25
+ tail: props == null ? void 0 : props.tail
24
26
  };
25
- if (a.type.name === "OPagetableColumnNumber")
27
+ } else if (c.type.name === "OPagetableColumnNumber") {
26
28
  return {
27
- type: a.type.name,
28
- head: e == null ? void 0 : e.head,
29
- headAlign: e == null ? void 0 : e.headAlign,
30
- name: e == null ? void 0 : e.name,
31
- width: e == null ? void 0 : e.width,
32
- fixed: e == null ? void 0 : e.fixed,
33
- tail: e == null ? void 0 : e.tail,
34
- thousandsSeparator: e == null ? void 0 : e.thousandsSeparator,
35
- precision: Number(e == null ? void 0 : e.precision),
36
- percentage: e == null ? void 0 : e.percentage
29
+ type: c.type.name,
30
+ head: props == null ? void 0 : props.head,
31
+ headAlign: props == null ? void 0 : props.headAlign,
32
+ name: props == null ? void 0 : props.name,
33
+ width: props == null ? void 0 : props.width,
34
+ fixed: props == null ? void 0 : props.fixed,
35
+ tail: props == null ? void 0 : props.tail,
36
+ thousandsSeparator: props == null ? void 0 : props.thousandsSeparator,
37
+ precision: Number(props == null ? void 0 : props.precision),
38
+ percentage: props == null ? void 0 : props.percentage
37
39
  };
38
- if (a.type.name === "OPagetableColumnDate")
40
+ } else if (c.type.name === "OPagetableColumnDate") {
39
41
  return {
40
- type: a.type.name,
41
- head: e == null ? void 0 : e.head,
42
- headAlign: e == null ? void 0 : e.headAlign,
43
- name: e == null ? void 0 : e.name,
44
- width: e == null ? void 0 : e.width,
45
- fixed: e == null ? void 0 : e.fixed,
46
- tail: e == null ? void 0 : e.tail,
47
- format: e == null ? void 0 : e.format,
48
- sourceFormat: e == null ? void 0 : e.sourceFormat
42
+ type: c.type.name,
43
+ head: props == null ? void 0 : props.head,
44
+ headAlign: props == null ? void 0 : props.headAlign,
45
+ name: props == null ? void 0 : props.name,
46
+ width: props == null ? void 0 : props.width,
47
+ fixed: props == null ? void 0 : props.fixed,
48
+ tail: props == null ? void 0 : props.tail,
49
+ format: props == null ? void 0 : props.format,
50
+ sourceFormat: props == null ? void 0 : props.sourceFormat
49
51
  };
50
- if (a.type.name === "OPagetableColumnSingleselect" || a.type.name === "OPagetableColumnMultiselect")
52
+ } else if (c.type.name === "OPagetableColumnSingleselect" || c.type.name === "OPagetableColumnMultiselect") {
51
53
  return {
52
- type: a.type.name,
53
- head: e == null ? void 0 : e.head,
54
- headAlign: e == null ? void 0 : e.headAlign,
55
- name: e == null ? void 0 : e.name,
56
- width: e == null ? void 0 : e.width,
57
- fixed: e == null ? void 0 : e.fixed,
58
- tail: e == null ? void 0 : e.tail,
59
- code: e == null ? void 0 : e.code
54
+ type: c.type.name,
55
+ head: props == null ? void 0 : props.head,
56
+ headAlign: props == null ? void 0 : props.headAlign,
57
+ name: props == null ? void 0 : props.name,
58
+ width: props == null ? void 0 : props.width,
59
+ fixed: props == null ? void 0 : props.fixed,
60
+ tail: props == null ? void 0 : props.tail,
61
+ code: props == null ? void 0 : props.code
60
62
  };
61
- if (a.type.name === "OPagetableColumnButtongroup")
63
+ } else if (c.type.name === "OPagetableColumnButtongroup") {
62
64
  return {
63
- type: a.type.name,
64
- head: e == null ? void 0 : e.head,
65
- headAlign: e == null ? void 0 : e.headAlign,
66
- name: e == null ? void 0 : e.name,
67
- width: e == null ? void 0 : e.width,
68
- fixed: e == null ? void 0 : e.fixed,
69
- tail: e == null ? void 0 : e.tail,
70
- children: a.children
65
+ type: c.type.name,
66
+ head: props == null ? void 0 : props.head,
67
+ headAlign: props == null ? void 0 : props.headAlign,
68
+ name: props == null ? void 0 : props.name,
69
+ width: props == null ? void 0 : props.width,
70
+ fixed: props == null ? void 0 : props.fixed,
71
+ tail: props == null ? void 0 : props.tail,
72
+ children: c.children
71
73
  };
72
- if (a.type.name === "OPagetableColumngroup")
74
+ } else if (c.type.name === "OPagetableColumngroup") {
73
75
  return {
74
- type: a.type.name,
75
- head: e == null ? void 0 : e.head,
76
- headAlign: e == null ? void 0 : e.headAlign,
77
- children: d(m((i = (n = a.children) == null ? void 0 : n.default) == null ? void 0 : i.call(n)))
76
+ type: c.type.name,
77
+ head: props == null ? void 0 : props.head,
78
+ headAlign: props == null ? void 0 : props.headAlign,
79
+ children: genColumns(filterEmpty((_b = (_a = c.children) == null ? void 0 : _a.default) == null ? void 0 : _b.call(_a)))
78
80
  };
79
- if (a.type.name === "OPagetableColumnDiy")
81
+ } else if (c.type.name === "OPagetableColumnDiy") {
80
82
  return {
81
- type: a.type.name,
82
- head: e == null ? void 0 : e.head,
83
- headAlign: e == null ? void 0 : e.headAlign,
84
- name: e == null ? void 0 : e.name,
85
- width: e == null ? void 0 : e.width,
86
- fixed: e == null ? void 0 : e.fixed,
87
- tail: e == null ? void 0 : e.tail,
88
- children: a.children
83
+ type: c.type.name,
84
+ head: props == null ? void 0 : props.head,
85
+ headAlign: props == null ? void 0 : props.headAlign,
86
+ name: props == null ? void 0 : props.name,
87
+ width: props == null ? void 0 : props.width,
88
+ fixed: props == null ? void 0 : props.fixed,
89
+ tail: props == null ? void 0 : props.tail,
90
+ children: c.children
89
91
  };
90
- throw new g(`OPagetable不能正确解析'${a.type.name}'子组件。`);
92
+ } else {
93
+ throw new OrionError(`OPagetable不能正确解析'${c.type.name}'子组件。`);
94
+ }
91
95
  });
96
+ return tableColumns;
92
97
  }
93
- function A(t) {
94
- return f(() => {
95
- var i;
96
- const a = (i = t.default) == null ? void 0 : i.call(t), e = m(a);
97
- return d(e);
98
+ function useColumns(slots) {
99
+ const columns = computed(() => {
100
+ var _a;
101
+ const children = (_a = slots.default) == null ? void 0 : _a.call(slots);
102
+ const non_empty_children = filterEmpty(children);
103
+ const tableColumns = genColumns(non_empty_children);
104
+ return tableColumns;
98
105
  });
106
+ return columns;
99
107
  }
100
108
  export {
101
- A as default
109
+ useColumns as default
102
110
  };
103
111
  //# sourceMappingURL=useColumns.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"useColumns.js","sources":["../../../../src/components/Pagetable/hooks/useColumns.ts"],"sourcesContent":["import { computed } from 'vue'\r\nimport OrionError from '../../../error/OrionError'\r\n\r\nimport { camelize } from '../../../components/_util/util'\r\nimport { filterEmpty } from '../../_util/props-util'\r\n\r\nfunction genColumns(children) {\r\n const tableColumns = children?.map((c) => {\r\n const props = { ...(c.props || {}) }\r\n for (const [k, v] of Object.entries(props)) {\r\n delete props[k]\r\n props[camelize(k)] = v\r\n }\r\n\r\n if (c.type.name === 'OPagetableColumnIndex') {\r\n return {\r\n type: c.type.name,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnString' || c.type.name === 'OPagetableColumnLink') {\r\n return {\r\n type: c.type.name,\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnNumber') {\r\n return {\r\n type: c.type.name,\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n thousandsSeparator: props?.thousandsSeparator,\r\n precision: Number(props?.precision),\r\n percentage: props?.percentage,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnDate') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n format: props?.format,\r\n sourceFormat: props?.sourceFormat,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnSingleselect' || c.type.name === 'OPagetableColumnMultiselect') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n code: props?.code,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnButtongroup') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n children: c.children,\r\n }\r\n } else if (c.type.name === 'OPagetableColumngroup') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n\r\n children: genColumns(filterEmpty(c.children?.default?.())),\r\n }\r\n } else if (c.type.name === 'OPagetableColumnDiy') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n children: c.children,\r\n }\r\n } else {\r\n throw new OrionError(`OPagetable不能正确解析'${c.type.name}'子组件。`)\r\n }\r\n })\r\n\r\n return tableColumns\r\n}\r\n\r\nexport default function useColumns(slots) {\r\n const columns = computed(() => {\r\n const children = slots.default?.()\r\n\r\n const non_empty_children = filterEmpty(children)\r\n\r\n const tableColumns = genColumns(non_empty_children)\r\n\r\n return tableColumns\r\n })\r\n\r\n return columns\r\n}\r\n"],"names":["genColumns","children","c","props","k","v","camelize","filterEmpty","_b","_a","OrionError","useColumns","slots","computed","non_empty_children"],"mappings":";;;;AAMA,SAASA,EAAWC,GAAU;AAuGrB,SAtGcA,KAAA,gBAAAA,EAAU,IAAI,CAACC,MAAM;;AACxC,UAAMC,IAAQ,EAAE,GAAID,EAAE,SAAS,CAAI,EAAA;AACnC,eAAW,CAACE,GAAGC,CAAC,KAAK,OAAO,QAAQF,CAAK;AACvC,aAAOA,EAAMC,CAAC,GACRD,EAAAG,EAASF,CAAC,CAAC,IAAIC;AAGnB,QAAAH,EAAE,KAAK,SAAS;AACX,aAAA;AAAA,QACL,MAAMA,EAAE,KAAK;AAAA,MAAA;AAEjB,QAAWA,EAAE,KAAK,SAAS,4BAA4BA,EAAE,KAAK,SAAS;AAC9D,aAAA;AAAA,QACL,MAAMA,EAAE,KAAK;AAAA,QACb,MAAMC,KAAA,gBAAAA,EAAO;AAAA,QACb,WAAWA,KAAA,gBAAAA,EAAO;AAAA,QAClB,MAAMA,KAAA,gBAAAA,EAAO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MAAM;;AACvB,UAAAZ,KAAWQ,IAAAG,EAAM,YAAN,gBAAAH,EAAA,KAAAG,IAEXE,IAAqBP,EAAYN,CAAQ;AAIxC,WAFcD,EAAWc,CAAkB;AAAA,EAE3C,CACR;AAGH;"}
1
+ {"version":3,"file":"useColumns.js","sources":["../../../../src/components/Pagetable/hooks/useColumns.ts"],"sourcesContent":["import { computed } from 'vue'\r\nimport OrionError from '../../../error/OrionError'\r\n\r\nimport { camelize } from '../../../components/_util/util'\r\nimport { filterEmpty } from '../../_util/props-util'\r\n\r\nfunction genColumns(children) {\r\n const tableColumns = children?.map((c) => {\r\n const props = { ...(c.props || {}) }\r\n for (const [k, v] of Object.entries(props)) {\r\n delete props[k]\r\n props[camelize(k)] = v\r\n }\r\n\r\n if (c.type.name === 'OPagetableColumnIndex') {\r\n return {\r\n type: c.type.name,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnString' || c.type.name === 'OPagetableColumnLink') {\r\n return {\r\n type: c.type.name,\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnNumber') {\r\n return {\r\n type: c.type.name,\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n thousandsSeparator: props?.thousandsSeparator,\r\n precision: Number(props?.precision),\r\n percentage: props?.percentage,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnDate') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n format: props?.format,\r\n sourceFormat: props?.sourceFormat,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnSingleselect' || c.type.name === 'OPagetableColumnMultiselect') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n code: props?.code,\r\n }\r\n } else if (c.type.name === 'OPagetableColumnButtongroup') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n children: c.children,\r\n }\r\n } else if (c.type.name === 'OPagetableColumngroup') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n\r\n children: genColumns(filterEmpty(c.children?.default?.())),\r\n }\r\n } else if (c.type.name === 'OPagetableColumnDiy') {\r\n return {\r\n type: c.type.name,\r\n\r\n head: props?.head,\r\n headAlign: props?.headAlign,\r\n name: props?.name,\r\n width: props?.width,\r\n fixed: props?.fixed,\r\n tail: props?.tail,\r\n\r\n children: c.children,\r\n }\r\n } else {\r\n throw new OrionError(`OPagetable不能正确解析'${c.type.name}'子组件。`)\r\n }\r\n })\r\n\r\n return tableColumns\r\n}\r\n\r\nexport default function useColumns(slots) {\r\n const columns = computed(() => {\r\n const children = slots.default?.()\r\n\r\n const non_empty_children = filterEmpty(children)\r\n\r\n const tableColumns = genColumns(non_empty_children)\r\n\r\n return tableColumns\r\n })\r\n\r\n return columns\r\n}\r\n"],"names":[],"mappings":";;;;AAMA,SAAS,WAAW,UAAU;AAC5B,QAAM,eAAe,qCAAU,IAAI,CAAC,MAAM;;AACxC,UAAM,QAAQ,EAAE,GAAI,EAAE,SAAS,CAAI,EAAA;AACnC,eAAW,CAAC,GAAG,CAAC,KAAK,OAAO,QAAQ,KAAK,GAAG;AAC1C,aAAO,MAAM,CAAC;AACR,YAAA,SAAS,CAAC,CAAC,IAAI;AAAA,IACvB;AAEI,QAAA,EAAE,KAAK,SAAS,yBAAyB;AACpC,aAAA;AAAA,QACL,MAAM,EAAE,KAAK;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