@pisell/materials 1.0.1059 → 1.0.1062

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 (374) hide show
  1. package/README.md +285 -285
  2. package/build/lowcode/assets-daily.json +11 -11
  3. package/build/lowcode/assets-dev.json +2 -2
  4. package/build/lowcode/assets-prod.json +11 -11
  5. package/build/lowcode/index.js +1 -1
  6. package/build/lowcode/meta.js +7 -7
  7. package/build/lowcode/preview.js +9 -9
  8. package/build/lowcode/render/default/view.css +1 -1
  9. package/build/lowcode/render/default/view.js +27 -27
  10. package/build/lowcode/view.css +1 -1
  11. package/build/lowcode/view.js +27 -27
  12. package/es/components/PisellLayouts/index.d.ts +2 -1
  13. package/es/components/PisellLayouts/index.js +17 -15
  14. package/es/components/cardMetricItem/index.js +2 -2
  15. package/es/components/pisellFilter/type.d.ts +4 -2
  16. package/es/components/pisellFloorMapLayout/PisellFloorMapLayout.d.ts +1 -1
  17. package/es/components/pisellFloorMapLayout/PisellFloorMapLayout.js +474 -202
  18. package/es/components/pisellFloorMapLayout/PisellFloorMapLayout.less +70 -0
  19. package/es/components/pisellFloorMapLayout/PisellFloorMapLayout.stories.d.ts +13 -0
  20. package/es/components/pisellFloorMapLayout/PisellFloorMapLayout.stories.js +469 -38
  21. package/es/components/pisellFloorMapLayout/components/CanvasTabs.d.ts +22 -0
  22. package/es/components/pisellFloorMapLayout/components/CanvasTabs.js +203 -0
  23. package/es/components/pisellFloorMapLayout/components/CanvasTabs.less +189 -0
  24. package/es/components/pisellFloorMapLayout/components/EditableItemLayer.d.ts +37 -0
  25. package/es/components/pisellFloorMapLayout/components/EditableItemLayer.js +341 -0
  26. package/es/components/pisellFloorMapLayout/components/EditableItemLayer.less +89 -0
  27. package/es/components/pisellFloorMapLayout/components/FigmaTableCard.d.ts +39 -0
  28. package/es/components/pisellFloorMapLayout/components/FigmaTableCard.js +432 -0
  29. package/es/components/pisellFloorMapLayout/components/FloorMapDataForm.d.ts +17 -0
  30. package/es/components/pisellFloorMapLayout/components/FloorMapDataForm.js +131 -0
  31. package/es/components/pisellFloorMapLayout/components/FloorMapDataForm.less +7 -0
  32. package/es/components/pisellFloorMapLayout/components/FloorMapEditPanel.d.ts +11 -0
  33. package/es/components/pisellFloorMapLayout/components/FloorMapEditPanel.js +497 -0
  34. package/es/components/pisellFloorMapLayout/components/FloorMapEditPanel.less +154 -0
  35. package/es/components/pisellFloorMapLayout/components/FloorMapEditTopBar.d.ts +34 -0
  36. package/es/components/pisellFloorMapLayout/components/FloorMapEditTopBar.js +130 -0
  37. package/es/components/pisellFloorMapLayout/components/FloorMapEditTopBar.less +131 -0
  38. package/es/components/pisellFloorMapLayout/components/FloorMapImageElement.d.ts +6 -0
  39. package/es/components/pisellFloorMapLayout/components/FloorMapImageElement.js +69 -0
  40. package/es/components/pisellFloorMapLayout/components/FloorMapToolbar.d.ts +35 -0
  41. package/es/components/pisellFloorMapLayout/components/FloorMapToolbar.js +361 -0
  42. package/es/components/pisellFloorMapLayout/components/FloorMapToolbar.less +237 -0
  43. package/es/components/pisellFloorMapLayout/components/ItemLayer.d.ts +7 -0
  44. package/es/components/pisellFloorMapLayout/components/ItemLayer.js +37 -11
  45. package/es/components/pisellFloorMapLayout/components/MapLayer.d.ts +4 -0
  46. package/es/components/pisellFloorMapLayout/components/MapLayer.js +11 -3
  47. package/es/components/pisellFloorMapLayout/components/ViewControls.js +2 -2
  48. package/es/components/pisellFloorMapLayout/components/ViewControls.less +3 -2
  49. package/es/components/pisellFloorMapLayout/components/ViewControlsWithZoom.d.ts +11 -0
  50. package/es/components/pisellFloorMapLayout/components/ViewControlsWithZoom.js +27 -0
  51. package/es/components/pisellFloorMapLayout/components/index.d.ts +14 -0
  52. package/es/components/pisellFloorMapLayout/components/index.js +8 -1
  53. package/es/components/pisellFloorMapLayout/context/FloorMapLayoutContext.d.ts +16 -0
  54. package/es/components/pisellFloorMapLayout/context/FloorMapLayoutContext.js +21 -0
  55. package/es/components/pisellFloorMapLayout/context/mergeFloorMapLayoutContext.d.ts +5 -0
  56. package/es/components/pisellFloorMapLayout/context/mergeFloorMapLayoutContext.js +28 -0
  57. package/es/components/pisellFloorMapLayout/hooks/useFloorMapEditState.d.ts +62 -0
  58. package/es/components/pisellFloorMapLayout/hooks/useFloorMapEditState.js +438 -0
  59. package/es/components/pisellFloorMapLayout/hooks/useFloorMapPaletteTouchDrag.d.ts +21 -0
  60. package/es/components/pisellFloorMapLayout/hooks/useFloorMapPaletteTouchDrag.js +122 -0
  61. package/es/components/pisellFloorMapLayout/hooks/useFloorMapTransformMetrics.d.ts +67 -0
  62. package/es/components/pisellFloorMapLayout/hooks/useFloorMapTransformMetrics.js +322 -0
  63. package/es/components/pisellFloorMapLayout/index.d.ts +9 -2
  64. package/es/components/pisellFloorMapLayout/index.js +7 -2
  65. package/es/components/pisellFloorMapLayout/locales.d.ts +186 -0
  66. package/es/components/pisellFloorMapLayout/locales.js +185 -0
  67. package/es/components/pisellFloorMapLayout/types.d.ts +362 -1
  68. package/es/components/pisellFloorMapLayout/types.js +148 -1
  69. package/es/components/pisellFloorMapLayout/utils/floorMapCanvasDisplay.d.ts +20 -0
  70. package/es/components/pisellFloorMapLayout/utils/floorMapCanvasDisplay.js +129 -0
  71. package/es/components/pisellFloorMapLayout/utils/floorMapConfigMerge.d.ts +8 -0
  72. package/es/components/pisellFloorMapLayout/utils/floorMapConfigMerge.js +87 -0
  73. package/es/components/pisellFloorMapLayout/utils/floorMapDropUtils.d.ts +26 -0
  74. package/es/components/pisellFloorMapLayout/utils/floorMapDropUtils.js +47 -0
  75. package/es/components/pisellFloorMapLayout/utils/floorMapElementKindUtils.d.ts +11 -0
  76. package/es/components/pisellFloorMapLayout/utils/floorMapElementKindUtils.js +69 -0
  77. package/es/components/pisellFloorMapLayout/utils/floorMapFallbackRender.d.ts +11 -0
  78. package/es/components/pisellFloorMapLayout/utils/floorMapFallbackRender.js +88 -0
  79. package/es/components/pisellFloorMapLayout/utils/floorMapStageDefaults.d.ts +8 -0
  80. package/es/components/pisellFloorMapLayout/utils/floorMapStageDefaults.js +8 -0
  81. package/es/components/pisellFloorMapLayout/utils/floorMapViewConfigDiff.d.ts +8 -0
  82. package/es/components/pisellFloorMapLayout/utils/floorMapViewConfigDiff.js +108 -0
  83. package/es/components/pisellFloorMapLayout/utils/layoutMeasurements.d.ts +30 -0
  84. package/es/components/pisellFloorMapLayout/utils/layoutMeasurements.js +125 -0
  85. package/es/components/pisellFloorMapLayout/utils/mergeCanvasesForTabs.d.ts +7 -0
  86. package/es/components/pisellFloorMapLayout/utils/mergeCanvasesForTabs.js +29 -0
  87. package/es/components/pisellFloorMapLayout/utils/snap.d.ts +10 -0
  88. package/es/components/pisellFloorMapLayout/utils/snap.js +21 -0
  89. package/es/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.d.ts +6 -0
  90. package/es/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.js +175 -0
  91. package/es/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.less +129 -0
  92. package/es/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.stories.d.ts +10 -0
  93. package/es/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.stories.js +237 -0
  94. package/es/components/pisellHierarchicalSummaryList/components/Row.d.ts +35 -0
  95. package/es/components/pisellHierarchicalSummaryList/components/Row.js +313 -0
  96. package/es/components/pisellHierarchicalSummaryList/components/index.d.ts +1 -0
  97. package/es/components/pisellHierarchicalSummaryList/components/index.js +1 -0
  98. package/es/components/pisellHierarchicalSummaryList/hooks/index.d.ts +2 -0
  99. package/es/components/pisellHierarchicalSummaryList/hooks/index.js +1 -0
  100. package/es/components/pisellHierarchicalSummaryList/hooks/useExpandedKeys.d.ts +15 -0
  101. package/es/components/pisellHierarchicalSummaryList/hooks/useExpandedKeys.js +34 -0
  102. package/es/components/pisellHierarchicalSummaryList/index.d.ts +5 -0
  103. package/es/components/pisellHierarchicalSummaryList/index.js +5 -0
  104. package/es/components/pisellHierarchicalSummaryList/types.d.ts +248 -0
  105. package/es/components/pisellHierarchicalSummaryList/types.js +1 -0
  106. package/es/components/pisellLookup/PisellLookup.js +82 -82
  107. package/es/components/pisellMultipleSelect/PisellMultipleSelect.stories.js +34 -34
  108. package/es/components/pisellRecordBoard/PisellRecordBoard.d.ts +2 -1
  109. package/es/components/pisellRecordBoard/PisellRecordBoard.js +95 -18
  110. package/es/components/pisellRecordBoard/PisellRecordBoard.stories.d.ts +4 -0
  111. package/es/components/pisellRecordBoard/PisellRecordBoard.stories.js +1315 -383
  112. package/es/components/pisellRecordBoard/index.d.ts +7 -2
  113. package/es/components/pisellRecordBoard/index.js +2 -1
  114. package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/index.js +1 -3
  115. package/es/components/pisellRecordBoard/shellFrame/FloorMap.d.ts +14 -0
  116. package/es/components/pisellRecordBoard/shellFrame/FloorMap.js +15 -0
  117. package/es/components/pisellRecordBoard/shellFrame/ShellBodyMetaContext.d.ts +16 -0
  118. package/es/components/pisellRecordBoard/shellFrame/ShellBodyMetaContext.js +11 -0
  119. package/es/components/pisellRecordBoard/shellFrame/ToolBar/ToolBarFilter.less +47 -0
  120. package/es/components/pisellRecordBoard/shellFrame/ToolBar/index.js +57 -10
  121. package/es/components/pisellRecordBoard/shellFrame/ToolBarReset/index.js +3 -3
  122. package/es/components/pisellRecordBoard/shellFrame/index.d.ts +4 -10
  123. package/es/components/pisellRecordBoard/shellFrame/index.js +101 -19
  124. package/es/components/pisellRecordBoard/types.d.ts +62 -2
  125. package/es/components/pisellRecordBoard/utils/partitionShellFrameChildren.d.ts +15 -0
  126. package/es/components/pisellRecordBoard/utils/partitionShellFrameChildren.js +57 -0
  127. package/es/components/pisellReservationSchedule/PisellReservationSchedule.d.ts +10 -0
  128. package/es/components/pisellReservationSchedule/PisellReservationSchedule.js +156 -0
  129. package/es/components/pisellReservationSchedule/PisellReservationSchedule.less +88 -0
  130. package/es/components/pisellReservationSchedule/PisellReservationSchedule.stories.d.ts +12 -0
  131. package/es/components/pisellReservationSchedule/PisellReservationSchedule.stories.js +105 -0
  132. package/es/components/pisellReservationSchedule/index.d.ts +2 -0
  133. package/es/components/pisellReservationSchedule/index.js +1 -0
  134. package/es/components/pisellReservationSchedule/locales.d.ts +25 -0
  135. package/es/components/pisellReservationSchedule/locales.js +24 -0
  136. package/es/components/pisellReservationSchedule/types.d.ts +42 -0
  137. package/es/components/pisellReservationSchedule/types.js +1 -0
  138. package/es/components/pisellReservationScheduleBand/PisellReservationScheduleBand.d.ts +10 -0
  139. package/es/components/pisellReservationScheduleBand/PisellReservationScheduleBand.js +91 -0
  140. package/es/components/pisellReservationScheduleBand/PisellReservationScheduleBand.less +49 -0
  141. package/es/components/pisellReservationScheduleBand/PisellReservationScheduleBand.stories.d.ts +16 -0
  142. package/es/components/pisellReservationScheduleBand/PisellReservationScheduleBand.stories.js +197 -0
  143. package/es/components/pisellReservationScheduleBand/index.d.ts +2 -0
  144. package/es/components/pisellReservationScheduleBand/index.js +1 -0
  145. package/es/components/pisellReservationScheduleBand/types.d.ts +45 -0
  146. package/es/components/pisellReservationScheduleBand/types.js +1 -0
  147. package/es/components/pisellRow/index.js +7 -7
  148. package/es/components/pisellTimeNavigator/PisellTimeNavigator.d.ts +10 -0
  149. package/es/components/pisellTimeNavigator/PisellTimeNavigator.js +609 -0
  150. package/es/components/pisellTimeNavigator/PisellTimeNavigator.less +412 -0
  151. package/es/components/pisellTimeNavigator/PisellTimeNavigator.stories.d.ts +79 -0
  152. package/es/components/pisellTimeNavigator/PisellTimeNavigator.stories.js +290 -0
  153. package/es/components/pisellTimeNavigator/components/BackgroundLayer.d.ts +14 -0
  154. package/es/components/pisellTimeNavigator/components/BackgroundLayer.js +30 -0
  155. package/es/components/pisellTimeNavigator/components/CursorLayer.d.ts +20 -0
  156. package/es/components/pisellTimeNavigator/components/CursorLayer.js +46 -0
  157. package/es/components/pisellTimeNavigator/components/GestureLayer.d.ts +31 -0
  158. package/es/components/pisellTimeNavigator/components/GestureLayer.js +82 -0
  159. package/es/components/pisellTimeNavigator/components/NowButton.d.ts +14 -0
  160. package/es/components/pisellTimeNavigator/components/NowButton.js +38 -0
  161. package/es/components/pisellTimeNavigator/components/ScaleLayer.d.ts +17 -0
  162. package/es/components/pisellTimeNavigator/components/ScaleLayer.js +51 -0
  163. package/es/components/pisellTimeNavigator/components/index.d.ts +5 -0
  164. package/es/components/pisellTimeNavigator/components/index.js +5 -0
  165. package/es/components/pisellTimeNavigator/hooks/index.d.ts +5 -0
  166. package/es/components/pisellTimeNavigator/hooks/index.js +3 -0
  167. package/es/components/pisellTimeNavigator/hooks/useDragInertia.d.ts +14 -0
  168. package/es/components/pisellTimeNavigator/hooks/useDragInertia.js +109 -0
  169. package/es/components/pisellTimeNavigator/hooks/useRealtime.d.ts +5 -0
  170. package/es/components/pisellTimeNavigator/hooks/useRealtime.js +16 -0
  171. package/es/components/pisellTimeNavigator/hooks/useTimeAxis.d.ts +27 -0
  172. package/es/components/pisellTimeNavigator/hooks/useTimeAxis.js +76 -0
  173. package/es/components/pisellTimeNavigator/index.d.ts +4 -0
  174. package/es/components/pisellTimeNavigator/index.js +3 -0
  175. package/es/components/pisellTimeNavigator/locales.d.ts +22 -0
  176. package/es/components/pisellTimeNavigator/locales.js +21 -0
  177. package/es/components/pisellTimeNavigator/types.d.ts +149 -0
  178. package/es/components/pisellTimeNavigator/types.js +1 -0
  179. package/es/components/pisellTimeNavigator/utils/index.d.ts +30 -0
  180. package/es/components/pisellTimeNavigator/utils/index.js +116 -0
  181. package/es/index.d.ts +15 -5
  182. package/es/index.js +7 -1
  183. package/es/locales/en-US.d.ts +2 -0
  184. package/es/locales/en-US.js +6 -4
  185. package/es/locales/zh-CN.d.ts +2 -0
  186. package/es/locales/zh-CN.js +6 -4
  187. package/es/locales/zh-TW.d.ts +2 -0
  188. package/es/locales/zh-TW.js +6 -4
  189. package/lib/components/PisellLayouts/index.d.ts +2 -1
  190. package/lib/components/PisellLayouts/index.js +13 -1
  191. package/lib/components/pisellFilter/type.d.ts +4 -2
  192. package/lib/components/pisellFloorMapLayout/PisellFloorMapLayout.d.ts +1 -1
  193. package/lib/components/pisellFloorMapLayout/PisellFloorMapLayout.js +566 -181
  194. package/lib/components/pisellFloorMapLayout/PisellFloorMapLayout.less +70 -0
  195. package/lib/components/pisellFloorMapLayout/PisellFloorMapLayout.stories.d.ts +13 -0
  196. package/lib/components/pisellFloorMapLayout/PisellFloorMapLayout.stories.js +682 -84
  197. package/lib/components/pisellFloorMapLayout/components/CanvasTabs.d.ts +22 -0
  198. package/lib/components/pisellFloorMapLayout/components/CanvasTabs.js +237 -0
  199. package/lib/components/pisellFloorMapLayout/components/CanvasTabs.less +189 -0
  200. package/lib/components/pisellFloorMapLayout/components/EditableItemLayer.d.ts +37 -0
  201. package/lib/components/pisellFloorMapLayout/components/EditableItemLayer.js +358 -0
  202. package/lib/components/pisellFloorMapLayout/components/EditableItemLayer.less +89 -0
  203. package/lib/components/pisellFloorMapLayout/components/FigmaTableCard.d.ts +39 -0
  204. package/lib/components/pisellFloorMapLayout/components/FigmaTableCard.js +482 -0
  205. package/lib/components/pisellFloorMapLayout/components/FloorMapDataForm.d.ts +17 -0
  206. package/lib/components/pisellFloorMapLayout/components/FloorMapDataForm.js +117 -0
  207. package/lib/components/pisellFloorMapLayout/components/FloorMapDataForm.less +7 -0
  208. package/lib/components/pisellFloorMapLayout/components/FloorMapEditPanel.d.ts +11 -0
  209. package/lib/components/pisellFloorMapLayout/components/FloorMapEditPanel.js +508 -0
  210. package/lib/components/pisellFloorMapLayout/components/FloorMapEditPanel.less +154 -0
  211. package/lib/components/pisellFloorMapLayout/components/FloorMapEditTopBar.d.ts +34 -0
  212. package/lib/components/pisellFloorMapLayout/components/FloorMapEditTopBar.js +188 -0
  213. package/lib/components/pisellFloorMapLayout/components/FloorMapEditTopBar.less +131 -0
  214. package/lib/components/pisellFloorMapLayout/components/FloorMapImageElement.d.ts +6 -0
  215. package/lib/components/pisellFloorMapLayout/components/FloorMapImageElement.js +94 -0
  216. package/lib/components/pisellFloorMapLayout/components/FloorMapToolbar.d.ts +35 -0
  217. package/lib/components/pisellFloorMapLayout/components/FloorMapToolbar.js +333 -0
  218. package/lib/components/pisellFloorMapLayout/components/FloorMapToolbar.less +237 -0
  219. package/lib/components/pisellFloorMapLayout/components/ItemLayer.d.ts +7 -0
  220. package/lib/components/pisellFloorMapLayout/components/ItemLayer.js +26 -5
  221. package/lib/components/pisellFloorMapLayout/components/MapLayer.d.ts +4 -0
  222. package/lib/components/pisellFloorMapLayout/components/MapLayer.js +7 -2
  223. package/lib/components/pisellFloorMapLayout/components/ViewControls.less +3 -2
  224. package/lib/components/pisellFloorMapLayout/components/ViewControlsWithZoom.d.ts +11 -0
  225. package/lib/components/pisellFloorMapLayout/components/ViewControlsWithZoom.js +63 -0
  226. package/lib/components/pisellFloorMapLayout/components/index.d.ts +14 -0
  227. package/lib/components/pisellFloorMapLayout/components/index.js +23 -2
  228. package/lib/components/pisellFloorMapLayout/context/FloorMapLayoutContext.d.ts +16 -0
  229. package/lib/components/pisellFloorMapLayout/context/FloorMapLayoutContext.js +54 -0
  230. package/lib/components/pisellFloorMapLayout/context/mergeFloorMapLayoutContext.d.ts +5 -0
  231. package/lib/components/pisellFloorMapLayout/context/mergeFloorMapLayoutContext.js +47 -0
  232. package/lib/components/pisellFloorMapLayout/hooks/useFloorMapEditState.d.ts +62 -0
  233. package/lib/components/pisellFloorMapLayout/hooks/useFloorMapEditState.js +431 -0
  234. package/lib/components/pisellFloorMapLayout/hooks/useFloorMapPaletteTouchDrag.d.ts +21 -0
  235. package/lib/components/pisellFloorMapLayout/hooks/useFloorMapPaletteTouchDrag.js +146 -0
  236. package/lib/components/pisellFloorMapLayout/hooks/useFloorMapTransformMetrics.d.ts +67 -0
  237. package/lib/components/pisellFloorMapLayout/hooks/useFloorMapTransformMetrics.js +309 -0
  238. package/lib/components/pisellFloorMapLayout/index.d.ts +9 -2
  239. package/lib/components/pisellFloorMapLayout/index.js +31 -2
  240. package/lib/components/pisellFloorMapLayout/locales.d.ts +186 -0
  241. package/lib/components/pisellFloorMapLayout/locales.js +206 -0
  242. package/lib/components/pisellFloorMapLayout/types.d.ts +362 -1
  243. package/lib/components/pisellFloorMapLayout/types.js +15 -0
  244. package/lib/components/pisellFloorMapLayout/utils/floorMapCanvasDisplay.d.ts +20 -0
  245. package/lib/components/pisellFloorMapLayout/utils/floorMapCanvasDisplay.js +126 -0
  246. package/lib/components/pisellFloorMapLayout/utils/floorMapConfigMerge.d.ts +8 -0
  247. package/lib/components/pisellFloorMapLayout/utils/floorMapConfigMerge.js +66 -0
  248. package/lib/components/pisellFloorMapLayout/utils/floorMapDropUtils.d.ts +26 -0
  249. package/lib/components/pisellFloorMapLayout/utils/floorMapDropUtils.js +61 -0
  250. package/lib/components/pisellFloorMapLayout/utils/floorMapElementKindUtils.d.ts +11 -0
  251. package/lib/components/pisellFloorMapLayout/utils/floorMapElementKindUtils.js +70 -0
  252. package/lib/components/pisellFloorMapLayout/utils/floorMapFallbackRender.d.ts +11 -0
  253. package/lib/components/pisellFloorMapLayout/utils/floorMapFallbackRender.js +135 -0
  254. package/lib/components/pisellFloorMapLayout/utils/floorMapStageDefaults.d.ts +8 -0
  255. package/lib/components/pisellFloorMapLayout/utils/floorMapStageDefaults.js +33 -0
  256. package/lib/components/pisellFloorMapLayout/utils/floorMapViewConfigDiff.d.ts +8 -0
  257. package/lib/components/pisellFloorMapLayout/utils/floorMapViewConfigDiff.js +128 -0
  258. package/lib/components/pisellFloorMapLayout/utils/layoutMeasurements.d.ts +30 -0
  259. package/lib/components/pisellFloorMapLayout/utils/layoutMeasurements.js +96 -0
  260. package/lib/components/pisellFloorMapLayout/utils/mergeCanvasesForTabs.d.ts +7 -0
  261. package/lib/components/pisellFloorMapLayout/utils/mergeCanvasesForTabs.js +41 -0
  262. package/lib/components/pisellFloorMapLayout/utils/snap.d.ts +10 -0
  263. package/lib/components/pisellFloorMapLayout/utils/snap.js +43 -0
  264. package/lib/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.d.ts +6 -0
  265. package/lib/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.js +179 -0
  266. package/lib/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.less +129 -0
  267. package/lib/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.stories.d.ts +10 -0
  268. package/lib/components/pisellHierarchicalSummaryList/PisellHierarchicalSummaryList.stories.js +218 -0
  269. package/lib/components/pisellHierarchicalSummaryList/components/Row.d.ts +35 -0
  270. package/lib/components/pisellHierarchicalSummaryList/components/Row.js +343 -0
  271. package/lib/components/pisellHierarchicalSummaryList/components/index.d.ts +1 -0
  272. package/lib/components/pisellHierarchicalSummaryList/components/index.js +29 -0
  273. package/lib/components/pisellHierarchicalSummaryList/hooks/index.d.ts +2 -0
  274. package/lib/components/pisellHierarchicalSummaryList/hooks/index.js +29 -0
  275. package/lib/components/pisellHierarchicalSummaryList/hooks/useExpandedKeys.d.ts +15 -0
  276. package/lib/components/pisellHierarchicalSummaryList/hooks/useExpandedKeys.js +51 -0
  277. package/lib/components/pisellHierarchicalSummaryList/index.d.ts +5 -0
  278. package/lib/components/pisellHierarchicalSummaryList/index.js +31 -0
  279. package/lib/components/pisellHierarchicalSummaryList/types.d.ts +248 -0
  280. package/lib/components/pisellHierarchicalSummaryList/types.js +17 -0
  281. package/lib/components/pisellRecordBoard/PisellRecordBoard.d.ts +2 -1
  282. package/lib/components/pisellRecordBoard/PisellRecordBoard.js +82 -8
  283. package/lib/components/pisellRecordBoard/PisellRecordBoard.stories.d.ts +4 -0
  284. package/lib/components/pisellRecordBoard/PisellRecordBoard.stories.js +915 -25
  285. package/lib/components/pisellRecordBoard/index.d.ts +7 -2
  286. package/lib/components/pisellRecordBoard/index.js +1 -0
  287. package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/index.js +8 -2
  288. package/lib/components/pisellRecordBoard/shellFrame/FloorMap.d.ts +14 -0
  289. package/lib/components/pisellRecordBoard/shellFrame/FloorMap.js +27 -0
  290. package/lib/components/pisellRecordBoard/shellFrame/ShellBodyMetaContext.d.ts +16 -0
  291. package/lib/components/pisellRecordBoard/shellFrame/ShellBodyMetaContext.js +45 -0
  292. package/lib/components/pisellRecordBoard/shellFrame/ToolBar/ToolBarFilter.less +47 -0
  293. package/lib/components/pisellRecordBoard/shellFrame/ToolBar/index.js +48 -4
  294. package/lib/components/pisellRecordBoard/shellFrame/index.d.ts +4 -10
  295. package/lib/components/pisellRecordBoard/shellFrame/index.js +88 -6
  296. package/lib/components/pisellRecordBoard/types.d.ts +62 -2
  297. package/lib/components/pisellRecordBoard/utils/partitionShellFrameChildren.d.ts +15 -0
  298. package/lib/components/pisellRecordBoard/utils/partitionShellFrameChildren.js +88 -0
  299. package/lib/components/pisellReservationSchedule/PisellReservationSchedule.d.ts +10 -0
  300. package/lib/components/pisellReservationSchedule/PisellReservationSchedule.js +200 -0
  301. package/lib/components/pisellReservationSchedule/PisellReservationSchedule.less +88 -0
  302. package/lib/components/pisellReservationSchedule/PisellReservationSchedule.stories.d.ts +12 -0
  303. package/lib/components/pisellReservationSchedule/PisellReservationSchedule.stories.js +116 -0
  304. package/lib/components/pisellReservationSchedule/index.d.ts +2 -0
  305. package/lib/components/pisellReservationSchedule/index.js +29 -0
  306. package/lib/components/pisellReservationSchedule/locales.d.ts +25 -0
  307. package/lib/components/pisellReservationSchedule/locales.js +47 -0
  308. package/lib/components/pisellReservationSchedule/types.d.ts +42 -0
  309. package/lib/components/pisellReservationSchedule/types.js +17 -0
  310. package/lib/components/pisellReservationScheduleBand/PisellReservationScheduleBand.d.ts +10 -0
  311. package/lib/components/pisellReservationScheduleBand/PisellReservationScheduleBand.js +127 -0
  312. package/lib/components/pisellReservationScheduleBand/PisellReservationScheduleBand.less +49 -0
  313. package/lib/components/pisellReservationScheduleBand/PisellReservationScheduleBand.stories.d.ts +16 -0
  314. package/lib/components/pisellReservationScheduleBand/PisellReservationScheduleBand.stories.js +181 -0
  315. package/lib/components/pisellReservationScheduleBand/index.d.ts +2 -0
  316. package/lib/components/pisellReservationScheduleBand/index.js +29 -0
  317. package/lib/components/pisellReservationScheduleBand/types.d.ts +45 -0
  318. package/lib/components/pisellReservationScheduleBand/types.js +17 -0
  319. package/lib/components/pisellTimeNavigator/PisellTimeNavigator.d.ts +10 -0
  320. package/lib/components/pisellTimeNavigator/PisellTimeNavigator.js +716 -0
  321. package/lib/components/pisellTimeNavigator/PisellTimeNavigator.less +412 -0
  322. package/lib/components/pisellTimeNavigator/PisellTimeNavigator.stories.d.ts +79 -0
  323. package/lib/components/pisellTimeNavigator/PisellTimeNavigator.stories.js +273 -0
  324. package/lib/components/pisellTimeNavigator/components/BackgroundLayer.d.ts +14 -0
  325. package/lib/components/pisellTimeNavigator/components/BackgroundLayer.js +81 -0
  326. package/lib/components/pisellTimeNavigator/components/CursorLayer.d.ts +20 -0
  327. package/lib/components/pisellTimeNavigator/components/CursorLayer.js +74 -0
  328. package/lib/components/pisellTimeNavigator/components/GestureLayer.d.ts +31 -0
  329. package/lib/components/pisellTimeNavigator/components/GestureLayer.js +159 -0
  330. package/lib/components/pisellTimeNavigator/components/NowButton.d.ts +14 -0
  331. package/lib/components/pisellTimeNavigator/components/NowButton.js +81 -0
  332. package/lib/components/pisellTimeNavigator/components/ScaleLayer.d.ts +17 -0
  333. package/lib/components/pisellTimeNavigator/components/ScaleLayer.js +95 -0
  334. package/lib/components/pisellTimeNavigator/components/index.d.ts +5 -0
  335. package/lib/components/pisellTimeNavigator/components/index.js +41 -0
  336. package/lib/components/pisellTimeNavigator/hooks/index.d.ts +5 -0
  337. package/lib/components/pisellTimeNavigator/hooks/index.js +35 -0
  338. package/lib/components/pisellTimeNavigator/hooks/useDragInertia.d.ts +14 -0
  339. package/lib/components/pisellTimeNavigator/hooks/useDragInertia.js +136 -0
  340. package/lib/components/pisellTimeNavigator/hooks/useRealtime.d.ts +5 -0
  341. package/lib/components/pisellTimeNavigator/hooks/useRealtime.js +49 -0
  342. package/lib/components/pisellTimeNavigator/hooks/useTimeAxis.d.ts +27 -0
  343. package/lib/components/pisellTimeNavigator/hooks/useTimeAxis.js +81 -0
  344. package/lib/components/pisellTimeNavigator/index.d.ts +4 -0
  345. package/lib/components/pisellTimeNavigator/index.js +42 -0
  346. package/lib/components/pisellTimeNavigator/locales.d.ts +22 -0
  347. package/lib/components/pisellTimeNavigator/locales.js +41 -0
  348. package/lib/components/pisellTimeNavigator/types.d.ts +149 -0
  349. package/lib/components/pisellTimeNavigator/types.js +17 -0
  350. package/lib/components/pisellTimeNavigator/utils/index.d.ts +30 -0
  351. package/lib/components/pisellTimeNavigator/utils/index.js +107 -0
  352. package/lib/index.d.ts +15 -5
  353. package/lib/index.js +35 -0
  354. package/lib/locales/en-US.d.ts +2 -0
  355. package/lib/locales/en-US.js +2 -0
  356. package/lib/locales/zh-CN.d.ts +2 -0
  357. package/lib/locales/zh-CN.js +2 -0
  358. package/lib/locales/zh-TW.d.ts +2 -0
  359. package/lib/locales/zh-TW.js +2 -0
  360. package/lowcode/floor-map-layout-provider/meta.ts +65 -0
  361. package/lowcode/pisell-floor-map-layout/meta.ts +3894 -1
  362. package/lowcode/pisell-hierarchical-summary-list/meta.ts +244 -0
  363. package/lowcode/pisell-reservation-schedule/index.ts +3 -0
  364. package/lowcode/pisell-reservation-schedule/meta.ts +69 -0
  365. package/lowcode/pisell-reservation-schedule/snippets.ts +1 -0
  366. package/lowcode/pisell-reservation-schedule-band/index.ts +3 -0
  367. package/lowcode/pisell-reservation-schedule-band/meta.ts +96 -0
  368. package/lowcode/pisell-reservation-schedule-band/snippets.ts +1 -0
  369. package/lowcode/pisell-time-navigator/index.ts +3 -0
  370. package/lowcode/pisell-time-navigator/meta.ts +298 -0
  371. package/lowcode/pisell-time-navigator/snippets.ts +1 -0
  372. package/lowcode/render-figma-style-round-table-card/meta.ts +589 -0
  373. package/lowcode/render-figma-style-table-card/meta.ts +589 -0
  374. package/package.json +3 -3
@@ -33,6 +33,7 @@ __export(PisellRecordBoard_stories_exports, {
33
33
  CustomComposition: () => CustomComposition,
34
34
  CustomFilterSortRender: () => CustomFilterSortRender,
35
35
  CustomQuickFilterAndColumnsRender: () => CustomQuickFilterAndColumnsRender,
36
+ Default: () => Default,
36
37
  GridLayoutFull: () => GridLayoutFull,
37
38
  GridLayoutToolBarSearchInput: () => GridLayoutToolBarSearchInput,
38
39
  GridLayoutToolBarSortAndFilter: () => GridLayoutToolBarSortAndFilter,
@@ -51,6 +52,9 @@ __export(PisellRecordBoard_stories_exports, {
51
52
  });
52
53
  module.exports = __toCommonJS(PisellRecordBoard_stories_exports);
53
54
  var import_react = __toESM(require("react"));
55
+ var import_antd = require("antd");
56
+ var import_types = require("../pisellFloorMapLayout/types");
57
+ var import_FigmaTableCard = require("../pisellFloorMapLayout/components/FigmaTableCard");
54
58
  var import_index = __toESM(require("./index"));
55
59
  var meta = {
56
60
  title: "Pro Components/PisellRecordBoard",
@@ -59,7 +63,7 @@ var meta = {
59
63
  layout: "padded",
60
64
  docs: {
61
65
  description: {
62
- component: "记录看板容器,提供统一的 data / 分页 / 搜索 / 多选上下文。ToolBar 左侧可放搜索(PisellFind)与内联快速筛选(toolBar.quickFilter);右侧为 Sort、PisellFilter、ToolBarReset。排序与筛选项可由列配置(columns)派生;quickFilter 为 true 时快速筛选项展示在左侧,Filter 弹层仅保留高级筛选。点击重置会清空筛选与排序。多选通过 grid.selectedKeys / grid.selectedRows / grid.onSelectionChange 传入;列显示隐藏由容器内部维护。grid 支持 antd Table 透传(onRow、onHeaderRow、expandable、rowClassName、summary 等),类型为 RecordBoardGridProps(基于 TableProps 省略 dataSource/loading/pagination/columns/scroll/size/rowSelection)。"
66
+ component: "记录看板容器,提供统一的 data / 分页 / 搜索 / 多选上下文。可选根级 **dataSources** + **gridDataSourceKey**:不传 **data** 时由容器从 `dataSources[key]` 客户端分页推导表格;平面图在 ShellFrame 内合并根级与 `FloorMap` 的 `dataSources` 后传入 PisellFloorMapLayout。ToolBar 左侧可放搜索(PisellFind)与内联快速筛选(toolBar.quickFilter);右侧为 Sort、PisellFilter、ToolBarReset。多选通过 grid.selectedKeys / grid.selectedRows / grid.onSelectionChange 传入。grid 支持 antd Table 透传(onRow、expandable 等)。**平面图**:`ShellFrame` 内与 `GridLayout` 并列声明 `PisellRecordBoard.FloorMap`。根级 `floorMap` 仍兼容。**平面图模式下底部分页隐藏**。详见 **Default** Story。"
63
67
  }
64
68
  }
65
69
  },
@@ -77,7 +81,13 @@ var meta = {
77
81
  }
78
82
  };
79
83
  var PisellRecordBoard_stories_default = meta;
80
- var orderStatusList = ["pending_pay", "paid", "shipped", "completed", "cancelled"];
84
+ var orderStatusList = [
85
+ "pending_pay",
86
+ "paid",
87
+ "shipped",
88
+ "completed",
89
+ "cancelled"
90
+ ];
81
91
  var payStatusList = ["unpaid", "paid", "refunded"];
82
92
  var mockData = Array.from({ length: 30 }, (_, i) => ({
83
93
  id: `order-${i + 1}`,
@@ -85,7 +95,9 @@ var mockData = Array.from({ length: 30 }, (_, i) => ({
85
95
  orderStatus: orderStatusList[i % orderStatusList.length],
86
96
  payStatus: payStatusList[i % payStatusList.length],
87
97
  amount: 99.9 + i % 15 * 88.5,
88
- createTime: `2024-01-${String(15 + i % 14).padStart(2, "0")} 10:${String(i % 60).padStart(2, "0")}`,
98
+ createTime: `2024-01-${String(15 + i % 14).padStart(2, "0")} 10:${String(
99
+ i % 60
100
+ ).padStart(2, "0")}`,
89
101
  buyerName: ["张三", "李四", "王五", "赵六", "钱七"][i % 5],
90
102
  buyerPhone: `138${String(1e7 + i).padStart(8, "0")}`,
91
103
  shipTo: ["北京市朝阳区", "上海市浦东新区", "广州市天河区", "深圳市南山区"][i % 4]
@@ -96,14 +108,21 @@ var mockDataMultiplePages = Array.from({ length: 250 }, (_, i) => ({
96
108
  orderStatus: orderStatusList[i % orderStatusList.length],
97
109
  payStatus: payStatusList[i % payStatusList.length],
98
110
  amount: 99.9 + i % 15 * 88.5,
99
- createTime: `2024-02-${String(1 + i % 28).padStart(2, "0")} 10:${String(i % 60).padStart(2, "0")}`,
111
+ createTime: `2024-02-${String(1 + i % 28).padStart(2, "0")} 10:${String(
112
+ i % 60
113
+ ).padStart(2, "0")}`,
100
114
  buyerName: ["张三", "李四", "王五", "赵六", "钱七"][i % 5],
101
115
  buyerPhone: `139${String(1e7 + i).padStart(8, "0")}`,
102
116
  shipTo: ["北京市朝阳区", "上海市浦东新区", "广州市天河区", "深圳市南山区"][i % 4]
103
117
  }));
104
118
  var columns = [
105
119
  { title: "订单号", dataIndex: "orderNo", key: "orderNo", width: 160 },
106
- { title: "订单状态", dataIndex: "orderStatus", key: "orderStatus", width: 140 },
120
+ {
121
+ title: "订单状态",
122
+ dataIndex: "orderStatus",
123
+ key: "orderStatus",
124
+ width: 140
125
+ },
107
126
  { title: "支付状态", dataIndex: "payStatus", key: "payStatus", width: 140 },
108
127
  { title: "订单金额", dataIndex: "amount", key: "amount", width: 110 },
109
128
  {
@@ -121,7 +140,13 @@ var columns = [
121
140
  { title: "收货地址", dataIndex: "shipTo", key: "shipTo", width: 200 }
122
141
  ];
123
142
  var columnsWithType = [
124
- { title: "订单号", dataIndex: "orderNo", key: "orderNo", width: 160, type: "singleLineText" },
143
+ {
144
+ title: "订单号",
145
+ dataIndex: "orderNo",
146
+ key: "orderNo",
147
+ width: 160,
148
+ type: "singleLineText"
149
+ },
125
150
  {
126
151
  title: "订单状态",
127
152
  dataIndex: "orderStatus",
@@ -178,9 +203,30 @@ var columnsWithType = [
178
203
  filterable: true,
179
204
  filter: { quickFilter: true }
180
205
  },
181
- { title: "买家", dataIndex: "buyerName", key: "buyerName", width: 100, type: "singleLineText", fieldProps: { placeholder: "买家" }, filterable: true, filter: { quickFilter: false } },
182
- { title: "手机号", dataIndex: "buyerPhone", key: "buyerPhone", width: 200, type: "phone" },
183
- { title: "收货地址", dataIndex: "shipTo", key: "shipTo", width: 200, type: "singleLineText" }
206
+ {
207
+ title: "买家",
208
+ dataIndex: "buyerName",
209
+ key: "buyerName",
210
+ width: 100,
211
+ type: "singleLineText",
212
+ fieldProps: { placeholder: "买家" },
213
+ filterable: true,
214
+ filter: { quickFilter: false }
215
+ },
216
+ {
217
+ title: "手机号",
218
+ dataIndex: "buyerPhone",
219
+ key: "buyerPhone",
220
+ width: 200,
221
+ type: "phone"
222
+ },
223
+ {
224
+ title: "收货地址",
225
+ dataIndex: "shipTo",
226
+ key: "shipTo",
227
+ width: 200,
228
+ type: "singleLineText"
229
+ }
184
230
  ];
185
231
  var customQuickFilterList = [
186
232
  {
@@ -251,7 +297,14 @@ var columnsWithCustomRender = [
251
297
  payStatusLabel[val] ?? val
252
298
  )
253
299
  },
254
- { title: "订单金额", dataIndex: "amount", key: "amount", width: 110, type: "currency", fieldProps: { precision: 2, currencySymbol: "¥" } },
300
+ {
301
+ title: "订单金额",
302
+ dataIndex: "amount",
303
+ key: "amount",
304
+ width: 110,
305
+ type: "currency",
306
+ fieldProps: { precision: 2, currencySymbol: "¥" }
307
+ },
255
308
  {
256
309
  title: "下单时间",
257
310
  dataIndex: "createTime",
@@ -361,7 +414,8 @@ var columnsWithCustomFilterSortRender = [
361
414
  function toTimestamp(v) {
362
415
  if (v == null) return null;
363
416
  if (typeof v === "number" && !Number.isNaN(v)) return v;
364
- if (v && typeof v.toDate === "function") return v.toDate().getTime();
417
+ if (v && typeof v.toDate === "function")
418
+ return v.toDate().getTime();
365
419
  const s = String(v).trim();
366
420
  if (!s) return null;
367
421
  const t = Date.parse(s);
@@ -380,7 +434,8 @@ function filterDataByCriteria(list, filterValues) {
380
434
  if (rowTime == null) return false;
381
435
  const start = toTimestamp(val[0]);
382
436
  const end = toTimestamp(val[1]);
383
- if (start != null && end != null) return rowTime >= start && rowTime <= end;
437
+ if (start != null && end != null)
438
+ return rowTime >= start && rowTime <= end;
384
439
  if (start != null) return rowTime >= start;
385
440
  if (end != null) return rowTime <= end;
386
441
  return true;
@@ -400,6 +455,23 @@ function filterDataByCriteria(list, filterValues) {
400
455
  });
401
456
  });
402
457
  }
458
+ var FLOOR_MAP_DIM_OPACITY = 0.2;
459
+ function recordBoardStoryRowMatchesToolbar(row, searchParams) {
460
+ var _a;
461
+ if (!searchParams) return true;
462
+ const filterValues = (_a = searchParams.filter) == null ? void 0 : _a.values;
463
+ const afterFilter = filterDataByCriteria(
464
+ [row],
465
+ filterValues
466
+ );
467
+ if (afterFilter.length === 0) return false;
468
+ const kw = String(searchParams.keyword ?? "").trim().toLowerCase();
469
+ if (!kw) return true;
470
+ const parts = Object.values(row).filter(
471
+ (v) => v != null && typeof v !== "object"
472
+ );
473
+ return parts.some((v) => String(v).toLowerCase().includes(kw));
474
+ }
403
475
  function sortDataBySortKey(list, sortKey) {
404
476
  if (!sortKey || typeof sortKey !== "string") return list;
405
477
  const match = sortKey.match(/^([^:]+):(asc|desc)/);
@@ -412,9 +484,788 @@ function sortDataBySortKey(list, sortKey) {
412
484
  return order === "asc" ? cmp : -cmp;
413
485
  });
414
486
  }
487
+ var RESTAURANT_DS_KEY = "tables";
488
+ var CONDIMENT_STATION_DS_KEY = "condimentStations";
489
+ function createInitialCondimentStations() {
490
+ return [
491
+ {
492
+ id: "cs1",
493
+ name: "大厅·自助蘸料区",
494
+ status: "正常",
495
+ flavorCount: 12,
496
+ area: "大厅"
497
+ },
498
+ {
499
+ id: "cs2",
500
+ name: "包厢走道补料台",
501
+ status: "需补货",
502
+ flavorCount: 6,
503
+ area: "包厢A",
504
+ note: "辣椒油低于 30%"
505
+ },
506
+ {
507
+ id: "cs3",
508
+ name: "露台·酱料小推位",
509
+ status: "正常",
510
+ flavorCount: 8,
511
+ area: "露台"
512
+ },
513
+ /**
514
+ * 以下记录在初始平面图**无落位**,用于编辑态「蘸料摆台」新建时可选绑定;
515
+ * 若列表与落位一一占满是,工具栏会提示「均已落位,或列表为空」。
516
+ */
517
+ {
518
+ id: "cs4",
519
+ name: "后厨·备用蘸料车",
520
+ status: "正常",
521
+ flavorCount: 4,
522
+ area: "后厨",
523
+ note: "待摆到平面图"
524
+ },
525
+ {
526
+ id: "cs5",
527
+ name: "入口处试味台(筹建)",
528
+ status: "维护中",
529
+ flavorCount: 0,
530
+ area: "门厅"
531
+ }
532
+ ];
533
+ }
534
+ function getRenderItemByKindCondimentStation(dataSources) {
535
+ return (item) => {
536
+ const merged = item;
537
+ const el = merged._sceneElement;
538
+ const b = el == null ? void 0 : el.dataBinding;
539
+ const titleFromElement = (el == null ? void 0 : el.name) != null && String(el.name).trim() ? String(el.name).trim() : "蘸料摆台";
540
+ const hasCondimentDs = (b == null ? void 0 : b.dataSourceKey) === CONDIMENT_STATION_DS_KEY;
541
+ const condimentRid = (b == null ? void 0 : b.recordId) != null ? String(b.recordId).trim() : "";
542
+ const boundToCondiment = hasCondimentDs && Boolean(condimentRid);
543
+ const list = dataSources[CONDIMENT_STATION_DS_KEY];
544
+ const row = boundToCondiment && list ? list.find((r) => r.id === condimentRid) : void 0;
545
+ const hasLiveRow = Boolean(row);
546
+ const borderColor = hasLiveRow ? row.status === "需补货" ? "#fa8c16" : row.status === "维护中" ? "#8c8c8c" : "#52c41a" : "#bfbfbf";
547
+ const isPlaceholder = !boundToCondiment || !hasLiveRow;
548
+ return /* @__PURE__ */ import_react.default.createElement(
549
+ "div",
550
+ {
551
+ style: {
552
+ width: "100%",
553
+ height: "100%",
554
+ boxSizing: "border-box",
555
+ padding: "8px 10px",
556
+ display: "flex",
557
+ flexDirection: "column",
558
+ justifyContent: "center",
559
+ minHeight: 0,
560
+ fontSize: 11,
561
+ lineHeight: 1.35,
562
+ background: isPlaceholder ? "#fafafa" : "#fff",
563
+ borderRadius: 8,
564
+ border: isPlaceholder ? `2px dashed ${borderColor}` : `2px solid ${borderColor}`,
565
+ boxShadow: isPlaceholder ? "none" : "0 2px 8px rgba(0,0,0,.08)",
566
+ overflow: "hidden"
567
+ }
568
+ },
569
+ /* @__PURE__ */ import_react.default.createElement(
570
+ "div",
571
+ {
572
+ style: {
573
+ fontWeight: 600,
574
+ color: isPlaceholder ? "#595959" : "#262626",
575
+ overflow: "hidden",
576
+ textOverflow: "ellipsis",
577
+ whiteSpace: "nowrap"
578
+ }
579
+ },
580
+ hasLiveRow ? row.name : titleFromElement
581
+ ),
582
+ hasLiveRow ? /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement("div", { style: { color: "#595959", marginTop: 4, flexShrink: 0 } }, row.status), /* @__PURE__ */ import_react.default.createElement("div", { style: { color: "#8c8c8c", marginTop: 4, flexShrink: 0 } }, row.flavorCount ?? "—", " 种蘸料")) : /* @__PURE__ */ import_react.default.createElement(
583
+ "div",
584
+ {
585
+ style: {
586
+ color: "#8c8c8c",
587
+ marginTop: 6,
588
+ flexShrink: 0,
589
+ fontSize: 10
590
+ }
591
+ },
592
+ !hasCondimentDs || !condimentRid ? hasCondimentDs && !condimentRid ? "已选择数据源,请在侧栏选择数据行" : "未绑定数据行:请在侧栏选择数据源与记录" : condimentRid.startsWith("new_") ? "新摆台占位,可在侧栏绑定具体记录" : "未找到对应记录:请检查绑定或数据列表"
593
+ )
594
+ );
595
+ };
596
+ }
597
+ function createInitialRestaurantTables() {
598
+ return [
599
+ { id: "t1", name: "1号桌", status: "空闲", capacity: 4, area: "大厅" },
600
+ {
601
+ id: "t2",
602
+ name: "2号桌",
603
+ status: "用餐中",
604
+ capacity: 4,
605
+ area: "大厅",
606
+ guests: 3,
607
+ customerName: "王女士"
608
+ },
609
+ {
610
+ id: "t3",
611
+ name: "3号桌",
612
+ status: "已预订",
613
+ capacity: 6,
614
+ area: "大厅",
615
+ reserveTime: "18:30"
616
+ },
617
+ { id: "t4", name: "4号桌", status: "空闲", capacity: 2, area: "露台" },
618
+ {
619
+ id: "t5",
620
+ name: "5号桌",
621
+ status: "用餐中",
622
+ capacity: 8,
623
+ area: "包厢A",
624
+ guests: 6
625
+ },
626
+ { id: "t6", name: "6号桌", status: "空闲", capacity: 4, area: "大厅" },
627
+ { id: "t7", name: "7号桌", status: "已预订", capacity: 2, area: "大厅" },
628
+ { id: "t8", name: "8号桌", status: "空闲", capacity: 4, area: "露台" },
629
+ { id: "r1", name: "圆桌1", status: "空闲", capacity: 6, area: "大厅" }
630
+ ];
631
+ }
632
+ function createInitialRestaurantFloorMapConfig() {
633
+ return {
634
+ canvases: [{ id: "main", name: "大厅平面图", order: 0, enabled: true }],
635
+ canvasUi: { canCreate: true, canEdit: true },
636
+ elementKindCategories: [
637
+ { id: "background", label: "底图", order: 0 },
638
+ { id: "dining", label: "餐桌", order: 1 },
639
+ { id: "station", label: "摆台", order: 2 },
640
+ { id: "area", label: "区域", order: 3 }
641
+ ],
642
+ elementKinds: [
643
+ {
644
+ value: import_types.FLOOR_MAP_IMAGE_ELEMENT_KIND,
645
+ label: "图片(底图)",
646
+ categoryId: "background",
647
+ dataBindingPolicy: "none",
648
+ showInPalette: true
649
+ },
650
+ {
651
+ value: "table",
652
+ label: "方桌",
653
+ categoryId: "dining",
654
+ dataBindingPolicy: "optional",
655
+ showInPalette: true
656
+ },
657
+ {
658
+ value: "roundTable",
659
+ label: "圆桌",
660
+ categoryId: "dining",
661
+ dataBindingPolicy: "optional",
662
+ defaultShape: "circle",
663
+ showInPalette: true
664
+ },
665
+ {
666
+ value: "condimentStation",
667
+ label: "蘸料摆台",
668
+ categoryId: "station",
669
+ dataBindingPolicy: "optional",
670
+ showInPalette: true
671
+ },
672
+ {
673
+ value: "stage",
674
+ label: "舞台/区域",
675
+ categoryId: "area",
676
+ dataBindingPolicy: "none",
677
+ showInPalette: true
678
+ }
679
+ ],
680
+ /**
681
+ * 四列栅格(同原 dataSourcePlacements 布局),现统一为 sceneElements + dataBinding
682
+ */
683
+ sceneElements: [
684
+ {
685
+ instanceId: "elm_t1",
686
+ canvasId: "main",
687
+ x: 80,
688
+ y: 80,
689
+ name: "1号桌",
690
+ width: 180,
691
+ height: 120,
692
+ zIndex: 0,
693
+ elementKind: "table",
694
+ dataBinding: {
695
+ dataSourceKey: RESTAURANT_DS_KEY,
696
+ recordId: "t1"
697
+ }
698
+ },
699
+ {
700
+ instanceId: "elm_t2",
701
+ canvasId: "main",
702
+ x: 280,
703
+ y: 80,
704
+ name: "2号桌",
705
+ width: 180,
706
+ height: 160,
707
+ zIndex: 0,
708
+ elementKind: "table",
709
+ dataBinding: {
710
+ dataSourceKey: RESTAURANT_DS_KEY,
711
+ recordId: "t2"
712
+ }
713
+ },
714
+ {
715
+ instanceId: "elm_t3",
716
+ canvasId: "main",
717
+ x: 480,
718
+ y: 80,
719
+ name: "3号桌",
720
+ width: 180,
721
+ height: 160,
722
+ zIndex: 0,
723
+ elementKind: "table",
724
+ dataBinding: {
725
+ dataSourceKey: RESTAURANT_DS_KEY,
726
+ recordId: "t3"
727
+ }
728
+ },
729
+ {
730
+ instanceId: "elm_cs1",
731
+ canvasId: "main",
732
+ x: 680,
733
+ y: 80,
734
+ name: "大厅·自助蘸料区",
735
+ width: 108,
736
+ height: 88,
737
+ zIndex: 0,
738
+ elementKind: "condimentStation",
739
+ dataBinding: {
740
+ dataSourceKey: CONDIMENT_STATION_DS_KEY,
741
+ recordId: "cs1"
742
+ }
743
+ },
744
+ {
745
+ instanceId: "elm_cs2",
746
+ canvasId: "main",
747
+ x: 80,
748
+ y: 264,
749
+ name: "包厢走道补料台",
750
+ width: 108,
751
+ height: 88,
752
+ zIndex: 0,
753
+ elementKind: "condimentStation",
754
+ dataBinding: {
755
+ dataSourceKey: CONDIMENT_STATION_DS_KEY,
756
+ recordId: "cs2"
757
+ }
758
+ },
759
+ {
760
+ instanceId: "elm_t4",
761
+ canvasId: "main",
762
+ x: 280,
763
+ y: 264,
764
+ name: "4号桌",
765
+ width: 180,
766
+ height: 120,
767
+ zIndex: 0,
768
+ elementKind: "table",
769
+ dataBinding: {
770
+ dataSourceKey: RESTAURANT_DS_KEY,
771
+ recordId: "t4"
772
+ }
773
+ },
774
+ {
775
+ instanceId: "elm_t5",
776
+ canvasId: "main",
777
+ x: 480,
778
+ y: 264,
779
+ name: "5号桌",
780
+ width: 180,
781
+ height: 160,
782
+ zIndex: 0,
783
+ elementKind: "table",
784
+ dataBinding: {
785
+ dataSourceKey: RESTAURANT_DS_KEY,
786
+ recordId: "t5"
787
+ }
788
+ },
789
+ {
790
+ instanceId: "elm_t6",
791
+ canvasId: "main",
792
+ x: 680,
793
+ y: 264,
794
+ name: "6号桌",
795
+ width: 180,
796
+ height: 120,
797
+ zIndex: 0,
798
+ elementKind: "table",
799
+ dataBinding: {
800
+ dataSourceKey: RESTAURANT_DS_KEY,
801
+ recordId: "t6"
802
+ }
803
+ },
804
+ {
805
+ instanceId: "elm_r1",
806
+ canvasId: "main",
807
+ x: 80,
808
+ y: 448,
809
+ name: "圆桌1",
810
+ width: 120,
811
+ height: 120,
812
+ zIndex: 0,
813
+ elementKind: "roundTable",
814
+ dataBinding: {
815
+ dataSourceKey: RESTAURANT_DS_KEY,
816
+ recordId: "r1"
817
+ }
818
+ },
819
+ {
820
+ instanceId: "elm_cs3",
821
+ canvasId: "main",
822
+ x: 220,
823
+ y: 448,
824
+ name: "露台·酱料小推位",
825
+ width: 108,
826
+ height: 88,
827
+ zIndex: 0,
828
+ elementKind: "condimentStation",
829
+ dataBinding: {
830
+ dataSourceKey: CONDIMENT_STATION_DS_KEY,
831
+ recordId: "cs3"
832
+ }
833
+ },
834
+ {
835
+ instanceId: "elm_t7",
836
+ canvasId: "main",
837
+ x: 480,
838
+ y: 448,
839
+ name: "7号桌",
840
+ width: 180,
841
+ height: 120,
842
+ zIndex: 0,
843
+ elementKind: "table",
844
+ dataBinding: {
845
+ dataSourceKey: RESTAURANT_DS_KEY,
846
+ recordId: "t7"
847
+ }
848
+ },
849
+ {
850
+ instanceId: "elm_t8",
851
+ canvasId: "main",
852
+ x: 680,
853
+ y: 448,
854
+ name: "8号桌",
855
+ width: 180,
856
+ height: 120,
857
+ zIndex: 0,
858
+ elementKind: "table",
859
+ dataBinding: {
860
+ dataSourceKey: RESTAURANT_DS_KEY,
861
+ recordId: "t8"
862
+ }
863
+ }
864
+ ]
865
+ };
866
+ }
867
+ var restaurantTableColumns = [
868
+ {
869
+ title: "桌号",
870
+ dataIndex: "name",
871
+ key: "name",
872
+ width: 120,
873
+ type: "singleLineText"
874
+ },
875
+ {
876
+ title: "状态",
877
+ dataIndex: "status",
878
+ key: "status",
879
+ width: 120,
880
+ type: "singleSelect",
881
+ fieldProps: {
882
+ options: [
883
+ { label: "全部", value: "all" },
884
+ { label: "空闲", value: "空闲" },
885
+ { label: "已预订", value: "已预订" },
886
+ { label: "用餐中", value: "用餐中" },
887
+ { label: "等待", value: "等待" },
888
+ { label: "已结账", value: "已结账" }
889
+ ]
890
+ },
891
+ filterable: true,
892
+ filter: { quickFilter: true }
893
+ },
894
+ {
895
+ title: "可坐人数",
896
+ dataIndex: "capacity",
897
+ key: "capacity",
898
+ width: 110,
899
+ type: "number"
900
+ },
901
+ {
902
+ title: "区域",
903
+ dataIndex: "area",
904
+ key: "area",
905
+ width: 140,
906
+ type: "singleLineText"
907
+ },
908
+ {
909
+ title: "当前用餐人数",
910
+ dataIndex: "guests",
911
+ key: "guests",
912
+ width: 130,
913
+ type: "number"
914
+ },
915
+ {
916
+ title: "顾客",
917
+ dataIndex: "customerName",
918
+ key: "customerName",
919
+ width: 120,
920
+ type: "singleLineText"
921
+ },
922
+ {
923
+ title: "预订时间",
924
+ dataIndex: "reserveTime",
925
+ key: "reserveTime",
926
+ width: 120,
927
+ type: "singleLineText"
928
+ }
929
+ ];
930
+ var condimentRecordFormColumns = [
931
+ { key: "name", label: "摆台名称", type: "string" },
932
+ {
933
+ key: "status",
934
+ label: "状态",
935
+ type: "select",
936
+ options: [
937
+ { label: "正常", value: "正常" },
938
+ { label: "需补货", value: "需补货" },
939
+ { label: "维护中", value: "维护中" }
940
+ ]
941
+ },
942
+ { key: "flavorCount", label: "蘸料种类数", type: "number" },
943
+ { key: "area", label: "区域", type: "string" },
944
+ { key: "note", label: "备注", type: "string" }
945
+ ];
946
+ function RestaurantTableRecordCustomForm(props) {
947
+ const { ctx } = props;
948
+ const [form] = import_antd.Form.useForm();
949
+ (0, import_react.useEffect)(() => {
950
+ form.setFieldsValue(ctx.record);
951
+ }, [ctx.recordId, ctx.record, form]);
952
+ return /* @__PURE__ */ import_react.default.createElement(
953
+ import_antd.Form,
954
+ {
955
+ form,
956
+ layout: "vertical",
957
+ size: "small",
958
+ onFinish: (values) => {
959
+ var _a;
960
+ (_a = ctx.onSaveRecord) == null ? void 0 : _a.call(ctx, values);
961
+ }
962
+ },
963
+ /* @__PURE__ */ import_react.default.createElement("p", { style: { margin: "0 0 8px", fontSize: 12, color: "#8c8c8c" } }, "以下为自定义 React 表单示例(仍可 `ctx.onSaveRecord` 写回与内置 FloorMapDataForm 相同的数据通道)。"),
964
+ /* @__PURE__ */ import_react.default.createElement(import_antd.Form.Item, { name: "guests", label: "当前用餐人数" }, /* @__PURE__ */ import_react.default.createElement(import_antd.InputNumber, { min: 0, style: { width: "100%" } })),
965
+ /* @__PURE__ */ import_react.default.createElement(import_antd.Form.Item, { name: "customerName", label: "顾客" }, /* @__PURE__ */ import_react.default.createElement(import_antd.Input, { allowClear: true })),
966
+ /* @__PURE__ */ import_react.default.createElement(import_antd.Form.Item, { name: "reserveTime", label: "预订时间" }, /* @__PURE__ */ import_react.default.createElement(import_antd.Input, { placeholder: "如 18:30", allowClear: true })),
967
+ /* @__PURE__ */ import_react.default.createElement(
968
+ import_antd.Button,
969
+ {
970
+ type: "primary",
971
+ htmlType: "submit",
972
+ loading: ctx.savingRecord,
973
+ block: true,
974
+ size: "small"
975
+ },
976
+ "保存记录"
977
+ )
978
+ );
979
+ }
980
+ var restaurantRecordFormColumns = [
981
+ { key: "name", label: "桌号", type: "string" },
982
+ {
983
+ key: "status",
984
+ label: "状态",
985
+ type: "select",
986
+ options: [
987
+ { label: "空闲", value: "空闲" },
988
+ { label: "已预订", value: "已预订" },
989
+ { label: "用餐中", value: "用餐中" },
990
+ { label: "等待", value: "等待" },
991
+ { label: "已结账", value: "已结账" }
992
+ ]
993
+ },
994
+ { key: "capacity", label: "可坐人数", type: "number" },
995
+ { key: "area", label: "区域", type: "string" },
996
+ { key: "guests", label: "当前用餐人数", type: "number" },
997
+ { key: "customerName", label: "顾客", type: "string" },
998
+ { key: "reserveTime", label: "预订时间", type: "string" }
999
+ ];
1000
+ var Default = {
1001
+ parameters: {
1002
+ layout: "fullscreen",
1003
+ docs: {
1004
+ description: {
1005
+ story: [
1006
+ "### 多数据源:餐桌 + 蘸料摆台(表格 ⇄ 平面图)",
1007
+ "",
1008
+ "- **`dataSources`**(根级):`{ tables, condimentStations }`,与 `dataSourceKey` 一致;ShellFrame 与 `FloorMap` props 合并后传入平面图。",
1009
+ "- **`floorMapLayoutContext`**:本 Story 将 `floorMapConfig` / `onSave` / 侧栏表单等放在根级 Context,`FloorMap` 仅保留 `mode`、`renderItemByKind`、`mapLayer` 等展示向 props。",
1010
+ "- **表格**:传根级 `data`(快筛 + 关键词过滤后分页);`dataSources.tables` 为**全量排序**餐桌,供平面图绑定。",
1011
+ "- **平面图**:始终渲染全部落位;未命中快筛/搜索的绑定行 **opacity=0.2**(`getMergedItemWrapperStyle`)。",
1012
+ "- **侧栏保存**:`onDataSourceRecordSave(key, id, patch)` 按 `key` 写回 `tables` 或 `condimentStations`。",
1013
+ "- **自定义表单开关**仍仅作用于 **餐桌** 数据源侧栏。",
1014
+ "",
1015
+ "```tsx",
1016
+ "<PisellRecordBoard data={...} dataSources={全量} floorMap={{ getMergedItemWrapperStyle: ... }} />",
1017
+ "```"
1018
+ ].join("\n")
1019
+ }
1020
+ }
1021
+ },
1022
+ render: function DefaultRender() {
1023
+ const [pageNumber, setPageNumber] = (0, import_react.useState)(1);
1024
+ const [pageSize, setPageSize] = (0, import_react.useState)(10);
1025
+ const [loading] = (0, import_react.useState)(false);
1026
+ const [searchParams, setSearchParams] = (0, import_react.useState)({});
1027
+ const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
1028
+ const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
1029
+ const [tables, setTables] = (0, import_react.useState)(
1030
+ createInitialRestaurantTables
1031
+ );
1032
+ const [condimentStations, setCondimentStations] = (0, import_react.useState)(createInitialCondimentStations);
1033
+ const [floorMapConfig, setFloorMapConfig] = (0, import_react.useState)(
1034
+ createInitialRestaurantFloorMapConfig
1035
+ );
1036
+ const [mapEditMode, setMapEditMode] = (0, import_react.useState)(false);
1037
+ const [useCustomRecordForm, setUseCustomRecordForm] = (0, import_react.useState)(false);
1038
+ const sortedAllTables = (0, import_react.useMemo)(
1039
+ () => sortDataBySortKey(tables, searchParams == null ? void 0 : searchParams.sort),
1040
+ [tables, searchParams == null ? void 0 : searchParams.sort]
1041
+ );
1042
+ const filteredSortedTables = (0, import_react.useMemo)(
1043
+ () => sortedAllTables.filter(
1044
+ (row) => recordBoardStoryRowMatchesToolbar(
1045
+ row,
1046
+ searchParams
1047
+ )
1048
+ ),
1049
+ [sortedAllTables, searchParams]
1050
+ );
1051
+ const total = filteredSortedTables.length;
1052
+ const data = (0, import_react.useMemo)(() => {
1053
+ const start = (pageNumber - 1) * pageSize;
1054
+ return filteredSortedTables.slice(start, start + pageSize);
1055
+ }, [pageNumber, pageSize, filteredSortedTables]);
1056
+ const value = (0, import_react.useMemo)(
1057
+ () => ({
1058
+ data,
1059
+ loading,
1060
+ total,
1061
+ pagination: { pageNumber, pageSize },
1062
+ onPageChange: (num, size) => {
1063
+ setPageNumber(num);
1064
+ setPageSize(size);
1065
+ },
1066
+ searchParams,
1067
+ onSearch: (params) => {
1068
+ setSearchParams(params);
1069
+ setPageNumber(1);
1070
+ },
1071
+ onReset: () => {
1072
+ setSearchParams({});
1073
+ setPageNumber(1);
1074
+ },
1075
+ layoutType: "grid",
1076
+ rowKey: "id"
1077
+ }),
1078
+ [data, loading, total, pageNumber, pageSize, searchParams]
1079
+ );
1080
+ const dataSources = (0, import_react.useMemo)(
1081
+ () => ({
1082
+ [RESTAURANT_DS_KEY]: sortedAllTables,
1083
+ [CONDIMENT_STATION_DS_KEY]: condimentStations
1084
+ }),
1085
+ [sortedAllTables, condimentStations]
1086
+ );
1087
+ const handleFloorMapSave = (0, import_react.useCallback)((config) => {
1088
+ setFloorMapConfig(config);
1089
+ console.log("[PisellRecordBoard Restaurant] floorMap onSave", config);
1090
+ }, []);
1091
+ const handleDataSourceRecordSave = (0, import_react.useCallback)(
1092
+ (dataSourceKey, id, newData) => {
1093
+ if (dataSourceKey === RESTAURANT_DS_KEY) {
1094
+ setTables(
1095
+ (prev) => prev.map((row) => row.id === id ? { ...row, ...newData } : row)
1096
+ );
1097
+ } else if (dataSourceKey === CONDIMENT_STATION_DS_KEY) {
1098
+ setCondimentStations(
1099
+ (prev) => prev.map((row) => row.id === id ? { ...row, ...newData } : row)
1100
+ );
1101
+ }
1102
+ console.log("[PisellRecordBoard Restaurant] onDataSourceRecordSave", {
1103
+ dataSourceKey,
1104
+ id,
1105
+ newData
1106
+ });
1107
+ },
1108
+ []
1109
+ );
1110
+ const floorMapLayoutContext = (0, import_react.useMemo)(
1111
+ () => ({
1112
+ floorMapConfig,
1113
+ onSave: handleFloorMapSave,
1114
+ onDataSourceRecordSave: handleDataSourceRecordSave,
1115
+ dataSourceLabels: {
1116
+ [RESTAURANT_DS_KEY]: "餐桌",
1117
+ [CONDIMENT_STATION_DS_KEY]: "蘸料摆台"
1118
+ },
1119
+ dataSourceFormColumns: {
1120
+ [RESTAURANT_DS_KEY]: restaurantRecordFormColumns,
1121
+ [CONDIMENT_STATION_DS_KEY]: condimentRecordFormColumns
1122
+ },
1123
+ ...useCustomRecordForm ? {
1124
+ dataSourceRecordForm: {
1125
+ [RESTAURANT_DS_KEY]: (ctx) => /* @__PURE__ */ import_react.default.createElement(RestaurantTableRecordCustomForm, { ctx })
1126
+ }
1127
+ } : {}
1128
+ }),
1129
+ [
1130
+ floorMapConfig,
1131
+ handleFloorMapSave,
1132
+ handleDataSourceRecordSave,
1133
+ useCustomRecordForm
1134
+ ]
1135
+ );
1136
+ const floorMap = (0, import_react.useMemo)(
1137
+ () => ({
1138
+ mode: mapEditMode ? "edit" : "read",
1139
+ renderItemByKind: {
1140
+ table: (0, import_FigmaTableCard.getRenderItemByKindTable)(dataSources),
1141
+ roundTable: (0, import_FigmaTableCard.getRenderItemByKindRoundTable)(dataSources),
1142
+ condimentStation: getRenderItemByKindCondimentStation(dataSources)
1143
+ },
1144
+ mapLayer: {
1145
+ backgroundType: "color",
1146
+ backgroundColor: "#f5f5f5",
1147
+ padding: 24
1148
+ },
1149
+ zoom: { defaultScale: 1, min: 0.4, max: 2.2, step: 0.1 },
1150
+ pan: { enabled: true, boundary: "clamp" },
1151
+ controls: {
1152
+ showZoom: true,
1153
+ showReset: true,
1154
+ showFitBounds: true
1155
+ },
1156
+ enableHover: true,
1157
+ getMergedItemWrapperStyle: (item) => {
1158
+ var _a;
1159
+ const m = item;
1160
+ const b = (_a = m._sceneElement) == null ? void 0 : _a.dataBinding;
1161
+ if (!(b == null ? void 0 : b.dataSourceKey)) return void 0;
1162
+ const recordId = b.recordId != null ? String(b.recordId).trim() : "";
1163
+ if (!recordId || recordId.startsWith("new_")) return void 0;
1164
+ const rows = dataSources[b.dataSourceKey];
1165
+ const row = rows == null ? void 0 : rows.find((r) => r.id === recordId);
1166
+ if (!row) return void 0;
1167
+ if (recordBoardStoryRowMatchesToolbar(
1168
+ row,
1169
+ searchParams
1170
+ ))
1171
+ return void 0;
1172
+ return { opacity: FLOOR_MAP_DIM_OPACITY };
1173
+ }
1174
+ }),
1175
+ [dataSources, mapEditMode, searchParams]
1176
+ );
1177
+ return /* @__PURE__ */ import_react.default.createElement(
1178
+ "div",
1179
+ {
1180
+ style: {
1181
+ boxSizing: "border-box",
1182
+ height: "100vh",
1183
+ minHeight: "100vh",
1184
+ padding: 16,
1185
+ background: "#f5f5f5",
1186
+ display: "flex",
1187
+ flexDirection: "column",
1188
+ overflow: "hidden"
1189
+ }
1190
+ },
1191
+ /* @__PURE__ */ import_react.default.createElement(
1192
+ "div",
1193
+ {
1194
+ style: {
1195
+ flexShrink: 0,
1196
+ marginBottom: 12,
1197
+ padding: "10px 12px",
1198
+ background: "#e6f4ff",
1199
+ border: "1px solid #91caff",
1200
+ borderRadius: 8,
1201
+ fontSize: 13,
1202
+ lineHeight: 1.65,
1203
+ color: "#0958d9"
1204
+ }
1205
+ },
1206
+ /* @__PURE__ */ import_react.default.createElement(import_antd.Space, { size: "large", wrap: true, align: "center" }, /* @__PURE__ */ import_react.default.createElement("span", null, /* @__PURE__ */ import_react.default.createElement("strong", null, "表格:"), "快筛 + 搜索过滤 + 分页;平面图为全量落位,未命中行半透明显示。"), /* @__PURE__ */ import_react.default.createElement("span", null, /* @__PURE__ */ import_react.default.createElement("strong", null, "平面图:"), "`tables` + `condimentStations` 同时渲染;工具栏「表格 / 平面图」切换视图。"), /* @__PURE__ */ import_react.default.createElement("span", null, /* @__PURE__ */ import_react.default.createElement(import_antd.Switch, { checked: mapEditMode, onChange: setMapEditMode }), /* @__PURE__ */ import_react.default.createElement("span", { style: { marginLeft: 8 } }, "平面图编辑模式(关=只读,开=可拖桌位、侧栏改记录并写回对应数据源)")), /* @__PURE__ */ import_react.default.createElement("span", null, /* @__PURE__ */ import_react.default.createElement(
1207
+ import_antd.Switch,
1208
+ {
1209
+ checked: useCustomRecordForm,
1210
+ onChange: setUseCustomRecordForm
1211
+ }
1212
+ ), /* @__PURE__ */ import_react.default.createElement("span", { style: { marginLeft: 8 } }, "侧栏自定义表单(仅", /* @__PURE__ */ import_react.default.createElement("strong", null, "餐桌"), "数据源;蘸料台仍用列配置表单)"))),
1213
+ /* @__PURE__ */ import_react.default.createElement("div", { style: { marginTop: 8, fontSize: 12, color: "#1677ff" } }, "提示:平面图为全量落位;仅当", /* @__PURE__ */ import_react.default.createElement("strong", null, "已绑定有效数据行"), "且该行未命中快筛/搜索时透明度", " ", Math.round(FLOOR_MAP_DIM_OPACITY * 100), "%(未选行、new_ 占位、行已删不参与淡化)。保存布局仍会输出 `onSave` 日志。")
1214
+ ),
1215
+ /* @__PURE__ */ import_react.default.createElement(
1216
+ "div",
1217
+ {
1218
+ style: {
1219
+ flex: 1,
1220
+ minHeight: 0,
1221
+ minWidth: 0,
1222
+ display: "flex",
1223
+ flexDirection: "column"
1224
+ }
1225
+ },
1226
+ /* @__PURE__ */ import_react.default.createElement(
1227
+ import_index.default,
1228
+ {
1229
+ rowKey: "id",
1230
+ ...value,
1231
+ dataSources,
1232
+ floorMapLayoutContext,
1233
+ defaultBodyView: "grid",
1234
+ style: { height: "100%", minHeight: 0, flex: 1 },
1235
+ grid: {
1236
+ columns: restaurantTableColumns,
1237
+ scroll: { x: 1460 },
1238
+ selectedKeys,
1239
+ selectedRows,
1240
+ onSelectionChange: (keys, rows) => {
1241
+ setSelectedKeys(keys);
1242
+ setSelectedRows(rows);
1243
+ }
1244
+ },
1245
+ toolBar: {
1246
+ search: true,
1247
+ quickFilter: true,
1248
+ filter: { hiddenQuickFilter: true }
1249
+ }
1250
+ },
1251
+ /* @__PURE__ */ import_react.default.createElement(import_index.default.ShellFrame, null, /* @__PURE__ */ import_react.default.createElement(import_index.default.GridLayout, null), /* @__PURE__ */ import_react.default.createElement(
1252
+ import_index.default.FloorMap,
1253
+ {
1254
+ ...floorMap
1255
+ }
1256
+ ))
1257
+ )
1258
+ )
1259
+ );
1260
+ }
1261
+ };
415
1262
  var GridLayoutWithTable = {
416
1263
  parameters: {
417
- docs: { description: { story: "列配置 type + fieldProps,筛选项与排序由 columns 派生;快速筛选在右侧「筛选」弹层内。" } }
1264
+ docs: {
1265
+ description: {
1266
+ story: "列配置 type + fieldProps,筛选项与排序由 columns 派生;快速筛选在右侧「筛选」弹层内。"
1267
+ }
1268
+ }
418
1269
  },
419
1270
  render: function GridLayoutWithTableRender() {
420
1271
  var _a;
@@ -425,7 +1276,10 @@ var GridLayoutWithTable = {
425
1276
  const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
426
1277
  const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
427
1278
  const filterValues = (_a = searchParams == null ? void 0 : searchParams.filter) == null ? void 0 : _a.values;
428
- const filteredList = (0, import_react.useMemo)(() => filterDataByCriteria(mockData, filterValues), [searchParams]);
1279
+ const filteredList = (0, import_react.useMemo)(
1280
+ () => filterDataByCriteria(mockData, filterValues),
1281
+ [searchParams]
1282
+ );
429
1283
  const sortedList = (0, import_react.useMemo)(
430
1284
  () => sortDataBySortKey(filteredList, searchParams == null ? void 0 : searchParams.sort),
431
1285
  [filteredList, searchParams == null ? void 0 : searchParams.sort]
@@ -574,7 +1428,12 @@ var GridLayoutWithCollapseUniformColumns = {
574
1428
  }, [pageNumber, pageSize, uniformData]);
575
1429
  const columnsUniform = [
576
1430
  { title: "订单号", dataIndex: "orderNo", key: "orderNo", width: 140 },
577
- { title: "支付状态", dataIndex: "payStatus", key: "payStatus", width: 120 },
1431
+ {
1432
+ title: "支付状态",
1433
+ dataIndex: "payStatus",
1434
+ key: "payStatus",
1435
+ width: 120
1436
+ },
578
1437
  { title: "订单金额", dataIndex: "amount", key: "amount", width: 120 },
579
1438
  { title: "备注", dataIndex: "note", key: "note", width: 160 }
580
1439
  ];
@@ -715,7 +1574,10 @@ var GridWithOnRow = {
715
1574
  const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
716
1575
  const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
717
1576
  const filterValues = (_a = searchParams == null ? void 0 : searchParams.filter) == null ? void 0 : _a.values;
718
- const filteredList = (0, import_react.useMemo)(() => filterDataByCriteria(mockData, filterValues), [searchParams]);
1577
+ const filteredList = (0, import_react.useMemo)(
1578
+ () => filterDataByCriteria(mockData, filterValues),
1579
+ [searchParams]
1580
+ );
719
1581
  const sortedList = (0, import_react.useMemo)(
720
1582
  () => sortDataBySortKey(filteredList, searchParams == null ? void 0 : searchParams.sort),
721
1583
  [filteredList, searchParams == null ? void 0 : searchParams.sort]
@@ -765,8 +1627,9 @@ var GridWithOnRow = {
765
1627
  },
766
1628
  onRow: (record) => ({
767
1629
  onClick: () => {
768
- console.log("行点击", record.orderNo, record);
769
- alert(`点击订单:${record.orderNo}`);
1630
+ const r = record;
1631
+ console.log("行点击", r.orderNo, r);
1632
+ alert(`点击订单:${r.orderNo}`);
770
1633
  }
771
1634
  }),
772
1635
  rowClassName: (record) => record.orderStatus === "cancelled" ? "pisell-record-board-row-cancelled" : ""
@@ -779,7 +1642,11 @@ var GridWithOnRow = {
779
1642
  };
780
1643
  var GridLayoutWithColumnType = {
781
1644
  parameters: {
782
- docs: { description: { story: "与 GridLayoutWithTable 相同能力,可点排序、筛选、重置验证行为。" } }
1645
+ docs: {
1646
+ description: {
1647
+ story: "与 GridLayoutWithTable 相同能力,可点排序、筛选、重置验证行为。"
1648
+ }
1649
+ }
783
1650
  },
784
1651
  render: function GridLayoutWithColumnTypeRender() {
785
1652
  var _a;
@@ -790,7 +1657,10 @@ var GridLayoutWithColumnType = {
790
1657
  const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
791
1658
  const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
792
1659
  const filterValues = (_a = searchParams == null ? void 0 : searchParams.filter) == null ? void 0 : _a.values;
793
- const filteredList = (0, import_react.useMemo)(() => filterDataByCriteria(mockData, filterValues), [searchParams]);
1660
+ const filteredList = (0, import_react.useMemo)(
1661
+ () => filterDataByCriteria(mockData, filterValues),
1662
+ [searchParams]
1663
+ );
794
1664
  const sortedList = (0, import_react.useMemo)(
795
1665
  () => sortDataBySortKey(filteredList, searchParams == null ? void 0 : searchParams.sort),
796
1666
  [filteredList, searchParams == null ? void 0 : searchParams.sort]
@@ -1028,7 +1898,10 @@ var GridLayoutWithQuickFilterOnLeft = {
1028
1898
  const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
1029
1899
  const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
1030
1900
  const filterValues = (_a = searchParams == null ? void 0 : searchParams.filter) == null ? void 0 : _a.values;
1031
- const filteredList = (0, import_react.useMemo)(() => filterDataByCriteria(mockData, filterValues), [searchParams]);
1901
+ const filteredList = (0, import_react.useMemo)(
1902
+ () => filterDataByCriteria(mockData, filterValues),
1903
+ [searchParams]
1904
+ );
1032
1905
  const sortedList = (0, import_react.useMemo)(
1033
1906
  () => sortDataBySortKey(filteredList, searchParams == null ? void 0 : searchParams.sort),
1034
1907
  [filteredList, searchParams == null ? void 0 : searchParams.sort]
@@ -1319,7 +2192,11 @@ var GridLayoutWithPisellFindInToolBar = {
1319
2192
  {
1320
2193
  rowKey: "id",
1321
2194
  ...value,
1322
- toolBar: { search: true, quickFilter: true, filter: { hiddenQuickFilter: true } },
2195
+ toolBar: {
2196
+ search: true,
2197
+ quickFilter: true,
2198
+ filter: { hiddenQuickFilter: true }
2199
+ },
1323
2200
  grid: {
1324
2201
  columns,
1325
2202
  size: "small",
@@ -1395,7 +2272,11 @@ var GridLayoutToolBarSearchInput = {
1395
2272
  };
1396
2273
  var GridLayoutFull = {
1397
2274
  parameters: {
1398
- docs: { description: { story: "勾选行后显示批量操作栏,可配置 onDelete 等;含搜索、筛选、排序、重置。" } }
2275
+ docs: {
2276
+ description: {
2277
+ story: "勾选行后显示批量操作栏,可配置 onDelete 等;含搜索、筛选、排序、重置。"
2278
+ }
2279
+ }
1399
2280
  },
1400
2281
  render: function GridLayoutFullRender() {
1401
2282
  const [pageNumber, setPageNumber] = (0, import_react.useState)(1);
@@ -1463,7 +2344,11 @@ var GridLayoutFull = {
1463
2344
  };
1464
2345
  var Placeholder = {
1465
2346
  parameters: {
1466
- docs: { description: { story: "不传 value 时的占位态,用于设计态或未接数据源时。" } }
2347
+ docs: {
2348
+ description: {
2349
+ story: "不传 value 时的占位态,用于设计态或未接数据源时。"
2350
+ }
2351
+ }
1467
2352
  },
1468
2353
  args: {
1469
2354
  rowKey: "id"
@@ -1482,7 +2367,11 @@ var CardLayoutPlaceholder = {
1482
2367
  };
1483
2368
  var CustomComposition = {
1484
2369
  parameters: {
1485
- docs: { description: { story: "未用 ShellFrame,手动组合 ToolBar、BatchActionBar、Grid、Pagination。" } }
2370
+ docs: {
2371
+ description: {
2372
+ story: "未用 ShellFrame,手动组合 ToolBar、BatchActionBar、Grid、Pagination。"
2373
+ }
2374
+ }
1486
2375
  },
1487
2376
  render: function CustomCompositionRender() {
1488
2377
  const [pageNumber, setPageNumber] = (0, import_react.useState)(1);
@@ -1656,6 +2545,7 @@ var SearchAndGridOnly = {
1656
2545
  CustomComposition,
1657
2546
  CustomFilterSortRender,
1658
2547
  CustomQuickFilterAndColumnsRender,
2548
+ Default,
1659
2549
  GridLayoutFull,
1660
2550
  GridLayoutToolBarSearchInput,
1661
2551
  GridLayoutToolBarSortAndFilter,