persagy-vant 0.0.23 → 0.0.25

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 (319) hide show
  1. package/es/action-sheet/index.css +1 -1
  2. package/es/action-sheet/index.d.ts +0 -63
  3. package/es/action-sheet/index.less +0 -96
  4. package/es/action-sheet/index.mjs +0 -3
  5. package/es/action-sheet/style/index.mjs +0 -8
  6. package/es/action-sheet/style/less.mjs +0 -8
  7. package/es/background/Background.d.ts +23 -0
  8. package/es/background/Background.mjs +23 -0
  9. package/es/background/assets/background-default.png +0 -0
  10. package/es/background/assets/background-light.png +0 -0
  11. package/es/background/assets/background-style-1.png +0 -0
  12. package/es/background/assets/background-style-2.png +0 -0
  13. package/es/background/assets/background-style-3.png +0 -0
  14. package/es/background/index.css +1 -0
  15. package/es/background/index.d.ts +21 -0
  16. package/es/background/index.less +41 -0
  17. package/es/background/index.mjs +8 -0
  18. package/es/background/style/index.d.ts +1 -0
  19. package/es/background/style/index.mjs +2 -0
  20. package/es/background/style/less.d.ts +1 -0
  21. package/es/background/style/less.mjs +2 -0
  22. package/es/background/types.d.ts +1 -0
  23. package/es/background/types.mjs +0 -0
  24. package/es/background/var.css +0 -0
  25. package/es/background/var.less +6 -0
  26. package/es/cascader/style/index.mjs +0 -8
  27. package/es/cascader/style/less.mjs +0 -8
  28. package/es/{action-sheet/ActionSheetPanel.d.ts → checkbox-panel/CheckboxPanel.d.ts} +11 -26
  29. package/es/checkbox-panel/CheckboxPanel.mjs +100 -0
  30. package/es/checkbox-panel/index.css +1 -0
  31. package/es/checkbox-panel/index.d.ts +58 -0
  32. package/es/checkbox-panel/index.less +26 -0
  33. package/es/checkbox-panel/index.mjs +8 -0
  34. package/es/checkbox-panel/style/index.d.ts +1 -0
  35. package/es/checkbox-panel/style/index.mjs +16 -0
  36. package/es/checkbox-panel/style/less.d.ts +1 -0
  37. package/es/checkbox-panel/style/less.mjs +16 -0
  38. package/es/coupon-list/style/index.mjs +1 -3
  39. package/es/coupon-list/style/less.mjs +1 -3
  40. package/es/datetime-picker/DatetimePicker.mjs +1 -3
  41. package/es/field/Field.d.ts +17 -4
  42. package/es/field/Field.mjs +1 -1
  43. package/es/field/index.d.ts +9 -2
  44. package/es/filter-tag/FilterTag.d.ts +14 -0
  45. package/es/filter-tag/FilterTag.mjs +6 -1
  46. package/es/filter-tag/index.css +1 -1
  47. package/es/filter-tag/index.d.ts +10 -1
  48. package/es/filter-tag/index.less +16 -0
  49. package/es/filter-tag/var.less +5 -0
  50. package/es/floor-select/FloorSelect.d.ts +38 -0
  51. package/es/floor-select/FloorSelect.mjs +234 -0
  52. package/es/floor-select/index.css +1 -0
  53. package/es/floor-select/index.d.ts +32 -0
  54. package/es/floor-select/index.less +57 -0
  55. package/es/floor-select/index.mjs +8 -0
  56. package/es/floor-select/style/index.d.ts +1 -0
  57. package/es/floor-select/style/index.mjs +20 -0
  58. package/es/floor-select/style/less.d.ts +1 -0
  59. package/es/floor-select/style/less.mjs +20 -0
  60. package/es/floor-select/types.d.ts +18 -0
  61. package/es/floor-select/types.mjs +0 -0
  62. package/es/fonts/meri-mobile-icon.ttf +0 -0
  63. package/es/fonts/meri-mobile-icon.woff +0 -0
  64. package/es/fonts/meri-mobile-icon.woff2 +0 -0
  65. package/es/form-panel/FormPanel.d.ts +32 -0
  66. package/es/form-panel/FormPanel.mjs +64 -0
  67. package/es/form-panel/index.css +1 -0
  68. package/es/form-panel/index.d.ts +28 -0
  69. package/es/form-panel/index.less +95 -0
  70. package/es/form-panel/index.mjs +8 -0
  71. package/es/form-panel/style/index.d.ts +1 -0
  72. package/es/form-panel/style/index.mjs +11 -0
  73. package/es/form-panel/style/less.d.ts +1 -0
  74. package/es/form-panel/style/less.mjs +11 -0
  75. package/es/friendly-tip/FriendlyTip.d.ts +86 -0
  76. package/es/friendly-tip/FriendlyTip.mjs +60 -0
  77. package/es/friendly-tip/index.css +1 -0
  78. package/es/friendly-tip/index.d.ts +64 -0
  79. package/es/friendly-tip/index.less +48 -0
  80. package/es/friendly-tip/index.mjs +8 -0
  81. package/es/friendly-tip/style/index.d.ts +1 -0
  82. package/es/friendly-tip/style/index.mjs +7 -0
  83. package/es/friendly-tip/style/less.d.ts +1 -0
  84. package/es/friendly-tip/style/less.mjs +7 -0
  85. package/es/friendly-tip/var.css +0 -0
  86. package/es/friendly-tip/var.less +10 -0
  87. package/es/index.d.ts +7 -1
  88. package/es/index.mjs +19 -1
  89. package/es/location-select/style/index.mjs +1 -1
  90. package/es/location-select/style/less.mjs +1 -1
  91. package/es/material-add/MaterialAdd.d.ts +14 -1
  92. package/es/material-add/MaterialAdd.mjs +98 -50
  93. package/es/material-add/index.d.ts +10 -1
  94. package/es/material-add/style/index.mjs +1 -1
  95. package/es/material-add/style/less.mjs +1 -1
  96. package/es/material-add/types.d.ts +9 -0
  97. package/es/multi-person-select/MultiPersonSelect.d.ts +1 -1
  98. package/es/multi-person-select/index.d.ts +1 -1
  99. package/es/multi-person-select/style/index.mjs +1 -1
  100. package/es/multi-person-select/style/less.mjs +1 -1
  101. package/es/notify/index.css +1 -1
  102. package/es/notify/index.less +10 -0
  103. package/es/notify/var.less +3 -0
  104. package/es/object-select/style/index.mjs +1 -1
  105. package/es/object-select/style/less.mjs +1 -1
  106. package/es/popover/Popover.mjs +5 -4
  107. package/es/popover/index.css +1 -1
  108. package/es/popover/index.less +12 -5
  109. package/es/popover/var.less +1 -1
  110. package/es/quantity-input/QuantityInput.d.ts +1 -1
  111. package/es/quantity-input/index.d.ts +2 -2
  112. package/es/radio-panel/RadioPanel.d.ts +41 -0
  113. package/es/radio-panel/RadioPanel.mjs +71 -0
  114. package/es/radio-panel/index.css +1 -0
  115. package/es/radio-panel/index.d.ts +31 -0
  116. package/es/radio-panel/index.less +26 -0
  117. package/es/radio-panel/index.mjs +8 -0
  118. package/es/radio-panel/style/index.d.ts +1 -0
  119. package/es/radio-panel/style/index.mjs +15 -0
  120. package/es/radio-panel/style/less.d.ts +1 -0
  121. package/es/radio-panel/style/less.mjs +15 -0
  122. package/es/rate/Rate.d.ts +1 -1
  123. package/es/rate/Rate.mjs +2 -1
  124. package/es/rate/RateCell.d.ts +196 -0
  125. package/es/rate/RateCell.mjs +60 -0
  126. package/es/rate/index.css +1 -1
  127. package/es/rate/index.d.ts +136 -0
  128. package/es/rate/index.less +35 -0
  129. package/es/rate/index.mjs +8 -0
  130. package/es/rate/style/index.mjs +5 -0
  131. package/es/rate/style/less.mjs +5 -0
  132. package/es/rate/var.less +1 -1
  133. package/es/search/Search.d.ts +13 -3
  134. package/es/search/index.d.ts +9 -2
  135. package/es/single-person-select/style/index.mjs +1 -2
  136. package/es/single-person-select/style/less.mjs +1 -2
  137. package/es/style/base.css +1 -1
  138. package/es/style/css-variables.css +1 -1
  139. package/es/style/css-variables.less +10 -0
  140. package/es/tab/style/index.mjs +0 -8
  141. package/es/tab/style/less.mjs +0 -8
  142. package/es/tabbar/index.css +1 -1
  143. package/es/tabbar/var.less +1 -1
  144. package/es/tabs/Tabs.mjs +5 -1
  145. package/es/tabs/index.css +1 -1
  146. package/es/tabs/index.less +4 -0
  147. package/es/tabs/style/index.mjs +0 -8
  148. package/es/tabs/style/less.mjs +0 -8
  149. package/es/tag/Tag.d.ts +13 -3
  150. package/es/tag/Tag.mjs +1 -1
  151. package/es/tag/index.d.ts +9 -2
  152. package/es/work-order-filter/style/index.mjs +1 -1
  153. package/es/work-order-filter/style/less.mjs +1 -1
  154. package/lib/action-sheet/index.css +1 -1
  155. package/lib/action-sheet/index.d.ts +0 -63
  156. package/lib/action-sheet/index.js +0 -3
  157. package/lib/action-sheet/index.less +0 -96
  158. package/lib/action-sheet/style/index.js +0 -8
  159. package/lib/action-sheet/style/less.js +0 -8
  160. package/lib/background/Background.d.ts +23 -0
  161. package/lib/background/Background.js +42 -0
  162. package/lib/background/assets/background-default.png +0 -0
  163. package/lib/background/assets/background-light.png +0 -0
  164. package/lib/background/assets/background-style-1.png +0 -0
  165. package/lib/background/assets/background-style-2.png +0 -0
  166. package/lib/background/assets/background-style-3.png +0 -0
  167. package/lib/background/index.css +1 -0
  168. package/lib/background/index.d.ts +21 -0
  169. package/lib/background/index.js +37 -0
  170. package/lib/background/index.less +41 -0
  171. package/lib/background/style/index.d.ts +1 -0
  172. package/lib/background/style/index.js +2 -0
  173. package/lib/background/style/less.d.ts +1 -0
  174. package/lib/background/style/less.js +2 -0
  175. package/lib/background/types.d.ts +1 -0
  176. package/lib/background/types.js +15 -0
  177. package/lib/background/var.css +0 -0
  178. package/lib/background/var.less +6 -0
  179. package/lib/cascader/style/index.js +0 -8
  180. package/lib/cascader/style/less.js +0 -8
  181. package/lib/{action-sheet/ActionSheetPanel.d.ts → checkbox-panel/CheckboxPanel.d.ts} +11 -26
  182. package/lib/checkbox-panel/CheckboxPanel.js +119 -0
  183. package/lib/checkbox-panel/index.css +1 -0
  184. package/lib/checkbox-panel/index.d.ts +58 -0
  185. package/lib/checkbox-panel/index.js +37 -0
  186. package/lib/checkbox-panel/index.less +26 -0
  187. package/lib/checkbox-panel/style/index.d.ts +1 -0
  188. package/lib/checkbox-panel/style/index.js +16 -0
  189. package/lib/checkbox-panel/style/less.d.ts +1 -0
  190. package/lib/checkbox-panel/style/less.js +16 -0
  191. package/lib/coupon-list/style/index.js +1 -3
  192. package/lib/coupon-list/style/less.js +1 -3
  193. package/lib/datetime-picker/DatetimePicker.js +1 -3
  194. package/lib/field/Field.d.ts +17 -4
  195. package/lib/field/Field.js +1 -1
  196. package/lib/field/index.d.ts +9 -2
  197. package/lib/filter-tag/FilterTag.d.ts +14 -0
  198. package/lib/filter-tag/FilterTag.js +6 -1
  199. package/lib/filter-tag/index.css +1 -1
  200. package/lib/filter-tag/index.d.ts +10 -1
  201. package/lib/filter-tag/index.less +16 -0
  202. package/lib/filter-tag/var.less +5 -0
  203. package/lib/floor-select/FloorSelect.d.ts +38 -0
  204. package/lib/floor-select/FloorSelect.js +253 -0
  205. package/lib/floor-select/index.css +1 -0
  206. package/lib/floor-select/index.d.ts +32 -0
  207. package/lib/floor-select/index.js +37 -0
  208. package/lib/floor-select/index.less +57 -0
  209. package/lib/floor-select/style/index.d.ts +1 -0
  210. package/lib/floor-select/style/index.js +20 -0
  211. package/lib/floor-select/style/less.d.ts +1 -0
  212. package/lib/floor-select/style/less.js +20 -0
  213. package/lib/floor-select/types.d.ts +18 -0
  214. package/lib/floor-select/types.js +15 -0
  215. package/lib/fonts/meri-mobile-icon.ttf +0 -0
  216. package/lib/fonts/meri-mobile-icon.woff +0 -0
  217. package/lib/fonts/meri-mobile-icon.woff2 +0 -0
  218. package/lib/form-panel/FormPanel.d.ts +32 -0
  219. package/lib/form-panel/FormPanel.js +83 -0
  220. package/lib/form-panel/index.css +1 -0
  221. package/lib/form-panel/index.d.ts +28 -0
  222. package/lib/form-panel/index.js +37 -0
  223. package/lib/form-panel/index.less +95 -0
  224. package/lib/form-panel/style/index.d.ts +1 -0
  225. package/lib/form-panel/style/index.js +11 -0
  226. package/lib/form-panel/style/less.d.ts +1 -0
  227. package/lib/form-panel/style/less.js +11 -0
  228. package/lib/friendly-tip/FriendlyTip.d.ts +86 -0
  229. package/lib/friendly-tip/FriendlyTip.js +79 -0
  230. package/lib/friendly-tip/index.css +1 -0
  231. package/lib/friendly-tip/index.d.ts +64 -0
  232. package/lib/friendly-tip/index.js +37 -0
  233. package/lib/friendly-tip/index.less +48 -0
  234. package/lib/friendly-tip/style/index.d.ts +1 -0
  235. package/lib/friendly-tip/style/index.js +7 -0
  236. package/lib/friendly-tip/style/less.d.ts +1 -0
  237. package/lib/friendly-tip/style/less.js +7 -0
  238. package/lib/friendly-tip/var.css +0 -0
  239. package/lib/friendly-tip/var.less +10 -0
  240. package/lib/index.css +1 -1
  241. package/lib/index.d.ts +7 -1
  242. package/lib/index.js +19 -1
  243. package/lib/index.less +15 -9
  244. package/lib/location-select/style/index.js +1 -1
  245. package/lib/location-select/style/less.js +1 -1
  246. package/lib/material-add/MaterialAdd.d.ts +14 -1
  247. package/lib/material-add/MaterialAdd.js +98 -50
  248. package/lib/material-add/index.d.ts +10 -1
  249. package/lib/material-add/style/index.js +1 -1
  250. package/lib/material-add/style/less.js +1 -1
  251. package/lib/material-add/types.d.ts +9 -0
  252. package/lib/multi-person-select/MultiPersonSelect.d.ts +1 -1
  253. package/lib/multi-person-select/index.d.ts +1 -1
  254. package/lib/multi-person-select/style/index.js +1 -1
  255. package/lib/multi-person-select/style/less.js +1 -1
  256. package/lib/notify/index.css +1 -1
  257. package/lib/notify/index.less +10 -0
  258. package/lib/notify/var.less +3 -0
  259. package/lib/object-select/style/index.js +1 -1
  260. package/lib/object-select/style/less.js +1 -1
  261. package/lib/popover/Popover.js +5 -4
  262. package/lib/popover/index.css +1 -1
  263. package/lib/popover/index.less +12 -5
  264. package/lib/popover/var.less +1 -1
  265. package/lib/quantity-input/QuantityInput.d.ts +1 -1
  266. package/lib/quantity-input/index.d.ts +2 -2
  267. package/lib/radio-panel/RadioPanel.d.ts +41 -0
  268. package/lib/radio-panel/RadioPanel.js +90 -0
  269. package/lib/radio-panel/index.css +1 -0
  270. package/lib/radio-panel/index.d.ts +31 -0
  271. package/lib/radio-panel/index.js +37 -0
  272. package/lib/radio-panel/index.less +26 -0
  273. package/lib/radio-panel/style/index.d.ts +1 -0
  274. package/lib/radio-panel/style/index.js +15 -0
  275. package/lib/radio-panel/style/less.d.ts +1 -0
  276. package/lib/radio-panel/style/less.js +15 -0
  277. package/lib/rate/Rate.d.ts +1 -1
  278. package/lib/rate/Rate.js +2 -1
  279. package/lib/rate/RateCell.d.ts +196 -0
  280. package/lib/rate/RateCell.js +89 -0
  281. package/lib/rate/index.css +1 -1
  282. package/lib/rate/index.d.ts +136 -0
  283. package/lib/rate/index.js +8 -0
  284. package/lib/rate/index.less +35 -0
  285. package/lib/rate/style/index.js +5 -0
  286. package/lib/rate/style/less.js +5 -0
  287. package/lib/rate/var.less +1 -1
  288. package/lib/search/Search.d.ts +13 -3
  289. package/lib/search/index.d.ts +9 -2
  290. package/lib/single-person-select/style/index.js +1 -2
  291. package/lib/single-person-select/style/less.js +1 -2
  292. package/lib/style/base.css +1 -1
  293. package/lib/style/css-variables.css +1 -1
  294. package/lib/style/css-variables.less +10 -0
  295. package/lib/tab/style/index.js +0 -8
  296. package/lib/tab/style/less.js +0 -8
  297. package/lib/tabbar/index.css +1 -1
  298. package/lib/tabbar/var.less +1 -1
  299. package/lib/tabs/Tabs.js +5 -1
  300. package/lib/tabs/index.css +1 -1
  301. package/lib/tabs/index.less +4 -0
  302. package/lib/tabs/style/index.js +0 -8
  303. package/lib/tabs/style/less.js +0 -8
  304. package/lib/tag/Tag.d.ts +13 -3
  305. package/lib/tag/Tag.js +1 -1
  306. package/lib/tag/index.d.ts +9 -2
  307. package/lib/vant.cjs.js +2919 -2420
  308. package/lib/vant.es.js +2920 -2421
  309. package/lib/vant.js +5375 -4876
  310. package/lib/vant.min.js +1 -1
  311. package/lib/web-types.json +1 -1
  312. package/lib/work-order-filter/style/index.js +1 -1
  313. package/lib/work-order-filter/style/less.js +1 -1
  314. package/package.json +1 -1
  315. package/skills/use-persagy-vant/SKILL.md +7 -6
  316. package/skills/use-persagy-vant/references/design-interaction-baseline.md +71 -0
  317. package/skills/use-persagy-vant/references/page-recipes.md +11 -4
  318. package/es/action-sheet/ActionSheetPanel.mjs +0 -145
  319. package/lib/action-sheet/ActionSheetPanel.js +0 -174
@@ -0,0 +1,234 @@
1
+ import { computed, defineComponent, ref, watch, createVNode as _createVNode } from "vue";
2
+ import { createNamespace } from "../utils/index.mjs";
3
+ import { Cell } from "../cell/index.mjs";
4
+ import { Sidebar } from "../sidebar/index.mjs";
5
+ import { SidebarItem } from "../sidebar-item/index.mjs";
6
+ import { Tab } from "../tab/index.mjs";
7
+ import { Tabs } from "../tabs/index.mjs";
8
+ const [name, bem] = createNamespace("floor-select");
9
+ const defaultBuildings = [{
10
+ id: "building-a",
11
+ text: "\u5EFA\u7B51A\u5EA7",
12
+ floors: [{
13
+ id: "a-b3",
14
+ text: "B3",
15
+ spaces: [{
16
+ id: "a-b3-01",
17
+ text: "B3 \u8BBE\u5907\u673A\u623F"
18
+ }, {
19
+ id: "a-b3-02",
20
+ text: "B3 \u914D\u7535\u5BA4"
21
+ }, {
22
+ id: "a-b3-03",
23
+ text: "B3 \u7269\u4E1A\u4ED3\u5E93"
24
+ }]
25
+ }, {
26
+ id: "a-b2",
27
+ text: "B2",
28
+ spaces: [{
29
+ id: "a-b2-01",
30
+ text: "B2 \u505C\u8F66\u533A"
31
+ }, {
32
+ id: "a-b2-02",
33
+ text: "B2 \u6C34\u6CF5\u623F"
34
+ }]
35
+ }, {
36
+ id: "a-b1",
37
+ text: "B1",
38
+ dot: true,
39
+ spaces: [{
40
+ id: "a-b1-01",
41
+ text: "B1 \u6D88\u9632\u63A7\u5236\u5BA4"
42
+ }, {
43
+ id: "a-b1-02",
44
+ text: "B1 \u8BBE\u5907\u95F4"
45
+ }, {
46
+ id: "a-b1-03",
47
+ text: "B1 \u5458\u5DE5\u9910\u5385"
48
+ }]
49
+ }, {
50
+ id: "a-f1",
51
+ text: "F1",
52
+ spaces: [{
53
+ id: "a-f1-01",
54
+ text: "F1 \u5927\u5802"
55
+ }, {
56
+ id: "a-f1-02",
57
+ text: "F1 \u7269\u4E1A\u670D\u52A1\u4E2D\u5FC3"
58
+ }, {
59
+ id: "a-f1-03",
60
+ text: "F1 \u4F1A\u8BAE\u5BA4"
61
+ }, {
62
+ id: "a-f1-04",
63
+ text: "F1 \u8BBE\u5907\u8D70\u5ECA"
64
+ }]
65
+ }]
66
+ }, {
67
+ id: "building-b",
68
+ text: "\u5EFA\u7B51B\u5EA7",
69
+ floors: [{
70
+ id: "b-b1",
71
+ text: "B1",
72
+ spaces: [{
73
+ id: "b-b1-01",
74
+ text: "B\u5EA7 B1 \u8BBE\u5907\u95F4"
75
+ }]
76
+ }, {
77
+ id: "b-f1",
78
+ text: "F1",
79
+ spaces: [{
80
+ id: "b-f1-01",
81
+ text: "B\u5EA7 F1 \u5927\u5802"
82
+ }]
83
+ }, {
84
+ id: "b-f2",
85
+ text: "F2",
86
+ spaces: [{
87
+ id: "b-f2-01",
88
+ text: "B\u5EA7 F2 \u529E\u516C\u533A"
89
+ }]
90
+ }]
91
+ }, {
92
+ id: "building-c",
93
+ text: "\u5EFA\u7B51C\u5EA7",
94
+ floors: [{
95
+ id: "c-f1",
96
+ text: "F1",
97
+ spaces: [{
98
+ id: "c-f1-01",
99
+ text: "C\u5EA7 F1 \u8BBE\u5907\u95F4"
100
+ }]
101
+ }]
102
+ }, {
103
+ id: "building-d",
104
+ text: "\u5EFA\u7B51D\u5EA7",
105
+ floors: [{
106
+ id: "d-f1",
107
+ text: "F1",
108
+ spaces: [{
109
+ id: "d-f1-01",
110
+ text: "D\u5EA7 F1 \u529E\u516C\u533A"
111
+ }]
112
+ }]
113
+ }];
114
+ const floorSelectProps = {
115
+ modelValue: [String, Number],
116
+ activeBuilding: [String, Number],
117
+ buildings: {
118
+ type: Array,
119
+ default: () => defaultBuildings
120
+ },
121
+ more: Boolean
122
+ };
123
+ var stdin_default = defineComponent({
124
+ name,
125
+ props: floorSelectProps,
126
+ emits: ["change", "update:activeBuilding", "update:modelValue"],
127
+ setup(props, {
128
+ emit,
129
+ slots
130
+ }) {
131
+ const activeBuilding = ref();
132
+ const activeFloor = ref(0);
133
+ const showMore = ref(false);
134
+ const currentBuilding = computed(() => props.buildings.find((building) => building.id === activeBuilding.value));
135
+ const floors = computed(() => {
136
+ var _a, _b;
137
+ return (_b = (_a = currentBuilding.value) == null ? void 0 : _a.floors) != null ? _b : [];
138
+ });
139
+ const spaces = computed(() => {
140
+ var _a, _b;
141
+ return (_b = (_a = floors.value[activeFloor.value]) == null ? void 0 : _a.spaces) != null ? _b : [];
142
+ });
143
+ const syncBuilding = () => {
144
+ var _a, _b, _c;
145
+ const selectedBuilding = props.buildings.find((building) => building.id === props.activeBuilding);
146
+ const containsSelectedSpace = props.buildings.find((building) => building.floors.some((floor) => floor.spaces.some((space) => space.id === props.modelValue)));
147
+ activeBuilding.value = (_c = (_a = selectedBuilding == null ? void 0 : selectedBuilding.id) != null ? _a : containsSelectedSpace == null ? void 0 : containsSelectedSpace.id) != null ? _c : (_b = props.buildings[0]) == null ? void 0 : _b.id;
148
+ };
149
+ watch(() => [props.activeBuilding, props.modelValue, props.buildings], () => {
150
+ syncBuilding();
151
+ }, {
152
+ immediate: true,
153
+ deep: true
154
+ });
155
+ watch([activeBuilding, floors], () => {
156
+ const selectedIndex = floors.value.findIndex((floor) => floor.spaces.some((space) => space.id === props.modelValue));
157
+ activeFloor.value = selectedIndex >= 0 ? selectedIndex : 0;
158
+ }, {
159
+ immediate: true
160
+ });
161
+ const selectBuilding = (id) => {
162
+ activeBuilding.value = id;
163
+ emit("update:activeBuilding", id);
164
+ };
165
+ const selectSpace = (item) => {
166
+ if (item.disabled) {
167
+ return;
168
+ }
169
+ emit("update:modelValue", item.id);
170
+ emit("change", item, activeBuilding.value);
171
+ };
172
+ const renderCell = (item, index) => {
173
+ var _a;
174
+ const selected = props.modelValue === item.id;
175
+ const cell = (_a = slots.cell) == null ? void 0 : _a.call(slots, {
176
+ item,
177
+ selected,
178
+ select: () => selectSpace(item)
179
+ });
180
+ return _createVNode("div", {
181
+ "key": item.id,
182
+ "class": bem("cell")
183
+ }, [cell || _createVNode(Cell, {
184
+ "title": item.text,
185
+ "border": index < spaces.value.length - 1,
186
+ "clickable": !item.disabled,
187
+ "rightSelect": selected,
188
+ "selectType": "radio",
189
+ "onClick": () => selectSpace(item),
190
+ "onUpdate:rightSelect": () => selectSpace(item)
191
+ }, null)]);
192
+ };
193
+ return () => _createVNode("div", {
194
+ "class": bem()
195
+ }, [_createVNode(Tabs, {
196
+ "active": activeBuilding.value,
197
+ "type": "filter",
198
+ "shrink": true,
199
+ "more": props.more,
200
+ "showMore": showMore.value,
201
+ "class": bem("tabs"),
202
+ "onUpdate:active": selectBuilding,
203
+ "onUpdate:showMore": (value) => {
204
+ showMore.value = value;
205
+ }
206
+ }, {
207
+ default: () => [props.buildings.map((building) => _createVNode(Tab, {
208
+ "key": building.id,
209
+ "name": building.id,
210
+ "title": building.text
211
+ }, null))]
212
+ }), _createVNode("div", {
213
+ "class": bem("content")
214
+ }, [_createVNode(Sidebar, {
215
+ "modelValue": activeFloor.value,
216
+ "class": bem("sidebar"),
217
+ "onUpdate:modelValue": (value) => {
218
+ activeFloor.value = +value;
219
+ }
220
+ }, {
221
+ default: () => [floors.value.map((floor) => _createVNode(SidebarItem, {
222
+ "key": floor.id,
223
+ "title": floor.text,
224
+ "dot": floor.dot,
225
+ "disabled": floor.disabled
226
+ }, null))]
227
+ }), _createVNode("div", {
228
+ "class": bem("cells")
229
+ }, [spaces.value.map(renderCell)])])]);
230
+ }
231
+ });
232
+ export {
233
+ stdin_default as default
234
+ };
@@ -0,0 +1 @@
1
+ .van-floor-select{display:flex;flex-direction:column;min-height:100vh;color:var(--van-text-color);background:var(--van-background-color-light)}.van-floor-select__tabs{flex:none;padding:var(--van-padding-xs) var(--van-padding-md);--van-tabs-line-height: 38px;--van-tabs-nav-background-color: transparent;--van-tabs-filter-background-color: var(--van-gray-2);--van-tabs-filter-active-background-color: var(--van-blue-1);--van-tabs-filter-border-radius: var(--van-border-radius-lg)}.van-floor-select__tabs .van-tabs__nav{gap:6px}.van-floor-select__tabs .van-tabs__more{z-index:3;width:40px;color:var(--van-gray-8);background:linear-gradient(90deg,transparent,var(--van-white) 36%)}.van-floor-select__content{display:flex;flex:1;min-height:0}.van-floor-select__sidebar{flex:none;height:auto;background:var(--van-gray-1);--van-sidebar-width: 80px;--van-sidebar-padding: var(--van-padding-sm);--van-sidebar-background-color: var(--van-gray-1);--van-sidebar-selected-background-color: var(--van-background-color-light);--van-sidebar-selected-text-color: var(--van-primary-color);--van-sidebar-selected-font-weight: var(--van-font-weight-bold)}.van-floor-select__cells{flex:1;min-width:0;overflow-y:auto;background:var(--van-background-color-light)}.van-floor-select__cell .van-cell{--van-cell-vertical-padding: var(--van-padding-sm)}
@@ -0,0 +1,32 @@
1
+ export declare const FloorSelect: import("../utils").WithInstall<import("vue").DefineComponent<{
2
+ modelValue: import("vue").PropType<import("../utils").Numeric | undefined>;
3
+ activeBuilding: import("vue").PropType<import("../utils").Numeric | undefined>;
4
+ buildings: {
5
+ type: import("vue").PropType<import("./types").FloorSelectBuilding[]>;
6
+ default: () => import("./types").FloorSelectBuilding[];
7
+ };
8
+ more: BooleanConstructor;
9
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "update:modelValue" | "update:activeBuilding")[], "change" | "update:modelValue" | "update:activeBuilding", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
10
+ modelValue: import("vue").PropType<import("../utils").Numeric | undefined>;
11
+ activeBuilding: import("vue").PropType<import("../utils").Numeric | undefined>;
12
+ buildings: {
13
+ type: import("vue").PropType<import("./types").FloorSelectBuilding[]>;
14
+ default: () => import("./types").FloorSelectBuilding[];
15
+ };
16
+ more: BooleanConstructor;
17
+ }>> & {
18
+ onChange?: ((...args: any[]) => any) | undefined;
19
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
20
+ "onUpdate:activeBuilding"?: ((...args: any[]) => any) | undefined;
21
+ }, {
22
+ more: boolean;
23
+ buildings: import("./types").FloorSelectBuilding[];
24
+ }>>;
25
+ export default FloorSelect;
26
+ export type { FloorSelectProps } from './FloorSelect';
27
+ export type { FloorSelectBuilding, FloorSelectItem, FloorSelectSpace } from './types';
28
+ declare module 'vue' {
29
+ interface GlobalComponents {
30
+ VanFloorSelect: typeof FloorSelect;
31
+ }
32
+ }
@@ -0,0 +1,57 @@
1
+ .van-floor-select {
2
+ display: flex;
3
+ flex-direction: column;
4
+ min-height: 100vh;
5
+ color: var(--van-text-color);
6
+ background: var(--van-background-color-light);
7
+
8
+ &__tabs {
9
+ flex: none;
10
+ padding: var(--van-padding-xs) var(--van-padding-md);
11
+ --van-tabs-line-height: 38px;
12
+ --van-tabs-nav-background-color: transparent;
13
+ --van-tabs-filter-background-color: var(--van-gray-2);
14
+ --van-tabs-filter-active-background-color: var(--van-blue-1);
15
+ --van-tabs-filter-border-radius: var(--van-border-radius-lg);
16
+
17
+ .van-tabs__nav { gap: 6px; }
18
+
19
+ .van-tabs__more {
20
+ z-index: 3;
21
+ width: 40px;
22
+ color: var(--van-gray-8);
23
+ background: linear-gradient(90deg, transparent, var(--van-white) 36%);
24
+ }
25
+ }
26
+
27
+ &__content {
28
+ display: flex;
29
+ flex: 1;
30
+ min-height: 0;
31
+ }
32
+
33
+ &__sidebar {
34
+ flex: none;
35
+ height: auto;
36
+ background: var(--van-gray-1);
37
+ --van-sidebar-width: 80px;
38
+ --van-sidebar-padding: var(--van-padding-sm);
39
+ --van-sidebar-background-color: var(--van-gray-1);
40
+ --van-sidebar-selected-background-color: var(--van-background-color-light);
41
+ --van-sidebar-selected-text-color: var(--van-primary-color);
42
+ --van-sidebar-selected-font-weight: var(--van-font-weight-bold);
43
+ }
44
+
45
+ &__cells {
46
+ flex: 1;
47
+ min-width: 0;
48
+ overflow-y: auto;
49
+ background: var(--van-background-color-light);
50
+ }
51
+
52
+ &__cell {
53
+ .van-cell {
54
+ --van-cell-vertical-padding: var(--van-padding-sm);
55
+ }
56
+ }
57
+ }
@@ -0,0 +1,8 @@
1
+ import { withInstall } from "../utils/index.mjs";
2
+ import _FloorSelect from "./FloorSelect.mjs";
3
+ const FloorSelect = withInstall(_FloorSelect);
4
+ var stdin_default = FloorSelect;
5
+ export {
6
+ FloorSelect,
7
+ stdin_default as default
8
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,20 @@
1
+ import "../../style/base.css";
2
+ import "../../badge/index.css";
3
+ import "../../icon/index.css";
4
+ import "../../loading/index.css";
5
+ import "../../overlay/index.css";
6
+ import "../../popup/index.css";
7
+ import "../../action-sheet/index.css";
8
+ import "../../checkbox-group/index.css";
9
+ import "../../checkbox/index.css";
10
+ import "../../radio-group/index.css";
11
+ import "../../radio/index.css";
12
+ import "../../cell/index.css";
13
+ import "../../sticky/index.css";
14
+ import "../../swipe/index.css";
15
+ import "../../swipe-item/index.css";
16
+ import "../../tabs/index.css";
17
+ import "../../tab/index.css";
18
+ import "../../sidebar/index.css";
19
+ import "../../sidebar-item/index.css";
20
+ import "../index.css";
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,20 @@
1
+ import "../../style/base.less";
2
+ import "../../badge/index.less";
3
+ import "../../icon/index.less";
4
+ import "../../loading/index.less";
5
+ import "../../overlay/index.less";
6
+ import "../../popup/index.less";
7
+ import "../../action-sheet/index.less";
8
+ import "../../checkbox-group/index.less";
9
+ import "../../checkbox/index.less";
10
+ import "../../radio-group/index.less";
11
+ import "../../radio/index.less";
12
+ import "../../cell/index.less";
13
+ import "../../sticky/index.less";
14
+ import "../../swipe/index.less";
15
+ import "../../swipe-item/index.less";
16
+ import "../../tabs/index.less";
17
+ import "../../tab/index.less";
18
+ import "../../sidebar/index.less";
19
+ import "../../sidebar-item/index.less";
20
+ import "../index.less";
@@ -0,0 +1,18 @@
1
+ import type { Numeric } from '../utils';
2
+ export declare type FloorSelectSpace = {
3
+ id: Numeric;
4
+ text: string;
5
+ disabled?: boolean;
6
+ };
7
+ export declare type FloorSelectItem = {
8
+ id: Numeric;
9
+ text: string;
10
+ dot?: boolean;
11
+ disabled?: boolean;
12
+ spaces: FloorSelectSpace[];
13
+ };
14
+ export declare type FloorSelectBuilding = {
15
+ id: Numeric;
16
+ text: string;
17
+ floors: FloorSelectItem[];
18
+ };
File without changes
Binary file
Binary file
Binary file
@@ -0,0 +1,32 @@
1
+ import { type ExtractPropTypes } from 'vue';
2
+ declare const formPanelProps: {
3
+ show: BooleanConstructor;
4
+ title: StringConstructor;
5
+ confirmText: {
6
+ type: import("vue").PropType<string>;
7
+ default: string;
8
+ };
9
+ };
10
+ export declare type FormPanelProps = ExtractPropTypes<typeof formPanelProps>;
11
+ declare const _default: import("vue").DefineComponent<{
12
+ show: BooleanConstructor;
13
+ title: StringConstructor;
14
+ confirmText: {
15
+ type: import("vue").PropType<string>;
16
+ default: string;
17
+ };
18
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:show" | "confirm")[], "update:show" | "confirm", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
19
+ show: BooleanConstructor;
20
+ title: StringConstructor;
21
+ confirmText: {
22
+ type: import("vue").PropType<string>;
23
+ default: string;
24
+ };
25
+ }>> & {
26
+ "onUpdate:show"?: ((...args: any[]) => any) | undefined;
27
+ onConfirm?: ((...args: any[]) => any) | undefined;
28
+ }, {
29
+ show: boolean;
30
+ confirmText: string;
31
+ }>;
32
+ export default _default;
@@ -0,0 +1,64 @@
1
+ import { defineComponent, createVNode as _createVNode } from "vue";
2
+ import { createNamespace, makeStringProp } from "../utils/index.mjs";
3
+ import { ActionSheet } from "../action-sheet/index.mjs";
4
+ import { NavBar } from "../nav-bar/index.mjs";
5
+ import { Icon } from "../icon/index.mjs";
6
+ import { Button } from "../button/index.mjs";
7
+ const [name, bem] = createNamespace("form-panel");
8
+ const formPanelProps = {
9
+ show: Boolean,
10
+ title: String,
11
+ confirmText: makeStringProp("\u786E\u5B9A")
12
+ };
13
+ var stdin_default = defineComponent({
14
+ name,
15
+ props: formPanelProps,
16
+ emits: ["update:show", "confirm"],
17
+ setup(props, {
18
+ emit,
19
+ slots
20
+ }) {
21
+ const close = () => emit("update:show", false);
22
+ const confirm = () => {
23
+ emit("confirm");
24
+ close();
25
+ };
26
+ return () => _createVNode(ActionSheet, {
27
+ "show": props.show,
28
+ "class": bem(),
29
+ "onUpdate:show": (show) => emit("update:show", show)
30
+ }, {
31
+ default: () => {
32
+ var _a;
33
+ return [_createVNode("div", {
34
+ "class": bem("content")
35
+ }, [_createVNode("div", {
36
+ "class": bem("nav-wrapper")
37
+ }, [_createVNode(NavBar, {
38
+ "title": props.title,
39
+ "border": false,
40
+ "class": bem("nav")
41
+ }, {
42
+ left: () => _createVNode(Icon, {
43
+ "name": "cross",
44
+ "size": "22",
45
+ "onClick": close
46
+ }, null)
47
+ })]), _createVNode("div", {
48
+ "class": bem("body")
49
+ }, [(_a = slots.default) == null ? void 0 : _a.call(slots)]), _createVNode("div", {
50
+ "class": bem("footer")
51
+ }, [_createVNode(Button, {
52
+ "block": true,
53
+ "type": "primary",
54
+ "onClick": confirm
55
+ }, {
56
+ default: () => [props.confirmText]
57
+ })])])];
58
+ }
59
+ });
60
+ }
61
+ });
62
+ export {
63
+ stdin_default as default
64
+ };
@@ -0,0 +1 @@
1
+ .van-form-panel{box-sizing:border-box;display:flex;height:calc(100% - 96px);max-height:calc(100% - 96px);overflow:hidden;background:var(--van-gray-1)}.van-form-panel .van-action-sheet__content{display:flex;flex:1;min-height:0;overflow:hidden}.van-form-panel__content{display:flex;flex:1;flex-direction:column;min-height:0;overflow:hidden;background:var(--van-gray-1)}.van-form-panel__nav-wrapper{flex:none;width:100%;min-width:0;max-width:100%;overflow:hidden}.van-form-panel__nav{box-sizing:border-box;width:100%;min-width:0;max-width:100%;overflow:hidden;--van-nav-bar-background-color: var(--van-gray-1)}.van-form-panel__nav .van-nav-bar__content{box-sizing:border-box;width:100%;overflow:hidden}.van-form-panel__nav .van-nav-bar__left--slot,.van-form-panel__nav .van-nav-bar__right--slot{padding:0}.van-form-panel__nav .van-nav-bar__left--slot{left:var(--van-padding-md)}.van-form-panel__nav .van-nav-bar__right--slot{right:var(--van-padding-md)}.van-form-panel__body{flex:1;min-height:0;padding:0 var(--van-padding-md);overflow-y:auto}.van-form-panel__card{overflow:hidden;background:var(--van-white);border-radius:var(--van-border-radius-lg)}.van-form-panel__footer{flex:none;padding:var(--van-padding-xs) 12px;background:var(--van-white);box-shadow:0 3px 12px rgba(27,33,41,.12),0 .5px 3px rgba(27,33,41,.08)}.van-form-panel__select-all{color:var(--van-primary-color);font-weight:var(--van-font-weight-bold);font-size:var(--van-font-size-md)}.van-form-panel .van-cell{min-height:44px}.van-form-panel .van-checkbox{margin:0}
@@ -0,0 +1,28 @@
1
+ export declare const FormPanel: import("../utils").WithInstall<import("vue").DefineComponent<{
2
+ show: BooleanConstructor;
3
+ title: StringConstructor;
4
+ confirmText: {
5
+ type: import("vue").PropType<string>;
6
+ default: string;
7
+ };
8
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:show" | "confirm")[], "update:show" | "confirm", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
9
+ show: BooleanConstructor;
10
+ title: StringConstructor;
11
+ confirmText: {
12
+ type: import("vue").PropType<string>;
13
+ default: string;
14
+ };
15
+ }>> & {
16
+ "onUpdate:show"?: ((...args: any[]) => any) | undefined;
17
+ onConfirm?: ((...args: any[]) => any) | undefined;
18
+ }, {
19
+ show: boolean;
20
+ confirmText: string;
21
+ }>>;
22
+ export default FormPanel;
23
+ export type { FormPanelProps } from './FormPanel';
24
+ declare module 'vue' {
25
+ interface GlobalComponents {
26
+ VanFormPanel: typeof FormPanel;
27
+ }
28
+ }
@@ -0,0 +1,95 @@
1
+ .van-form-panel {
2
+ box-sizing: border-box;
3
+ display: flex;
4
+ height: calc(100% - 96px);
5
+ max-height: calc(100% - 96px);
6
+ overflow: hidden;
7
+ background: var(--van-gray-1);
8
+
9
+ .van-action-sheet__content {
10
+ display: flex;
11
+ flex: 1;
12
+ min-height: 0;
13
+ overflow: hidden;
14
+ }
15
+
16
+ &__content {
17
+ display: flex;
18
+ flex: 1;
19
+ flex-direction: column;
20
+ min-height: 0;
21
+ overflow: hidden;
22
+ background: var(--van-gray-1);
23
+ }
24
+
25
+ &__nav-wrapper {
26
+ flex: none;
27
+ width: 100%;
28
+ min-width: 0;
29
+ max-width: 100%;
30
+ overflow: hidden;
31
+ }
32
+
33
+ &__nav {
34
+ box-sizing: border-box;
35
+ width: 100%;
36
+ min-width: 0;
37
+ max-width: 100%;
38
+ overflow: hidden;
39
+ --van-nav-bar-background-color: var(--van-gray-1);
40
+
41
+ .van-nav-bar__content {
42
+ box-sizing: border-box;
43
+ width: 100%;
44
+ overflow: hidden;
45
+ }
46
+
47
+ .van-nav-bar__left--slot,
48
+ .van-nav-bar__right--slot {
49
+ padding: 0;
50
+ }
51
+
52
+ .van-nav-bar__left--slot {
53
+ left: var(--van-padding-md);
54
+ }
55
+
56
+ .van-nav-bar__right--slot {
57
+ right: var(--van-padding-md);
58
+ }
59
+ }
60
+
61
+ &__body {
62
+ flex: 1;
63
+ min-height: 0;
64
+ padding: 0 var(--van-padding-md);
65
+ overflow-y: auto;
66
+ }
67
+
68
+ &__card {
69
+ overflow: hidden;
70
+ background: var(--van-white);
71
+ border-radius: var(--van-border-radius-lg);
72
+ }
73
+
74
+ &__footer {
75
+ flex: none;
76
+ padding: var(--van-padding-xs) 12px;
77
+ background: var(--van-white);
78
+ box-shadow: 0 3px 12px rgba(27, 33, 41, 0.12),
79
+ 0 0.5px 3px rgba(27, 33, 41, 0.08);
80
+ }
81
+
82
+ &__select-all {
83
+ color: var(--van-primary-color);
84
+ font-weight: var(--van-font-weight-bold);
85
+ font-size: var(--van-font-size-md);
86
+ }
87
+
88
+ .van-cell {
89
+ min-height: 44px;
90
+ }
91
+
92
+ .van-checkbox {
93
+ margin: 0;
94
+ }
95
+ }
@@ -0,0 +1,8 @@
1
+ import { withInstall } from "../utils/index.mjs";
2
+ import _FormPanel from "./FormPanel.mjs";
3
+ const FormPanel = withInstall(_FormPanel);
4
+ var stdin_default = FormPanel;
5
+ export {
6
+ FormPanel,
7
+ stdin_default as default
8
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,11 @@
1
+ import "../../style/base.css";
2
+ import "../../badge/index.css";
3
+ import "../../icon/index.css";
4
+ import "../../loading/index.css";
5
+ import "../../button/index.css";
6
+ import "../../overlay/index.css";
7
+ import "../../popup/index.css";
8
+ import "../../popover/index.css";
9
+ import "../../nav-bar/index.css";
10
+ import "../../action-sheet/index.css";
11
+ import "../index.css";
@@ -0,0 +1 @@
1
+ export {};