@shwfed/config 2.4.0 → 2.5.0

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 (315) hide show
  1. package/dist/mcp.mjs +128 -27
  2. package/dist/module.json +1 -1
  3. package/dist/preview/assets/{config-Bxkq2ZRm.js → config-BkytEQN5.js} +1 -1
  4. package/dist/preview/assets/{config-BdFIFUa_.js → config-CK011_jJ.js} +1 -1
  5. package/dist/preview/assets/{config-BcQQl4v6.js → config-C_bBX0wD.js} +1 -1
  6. package/dist/preview/assets/{config-CHHX7vhb.js → config-Cbn8o9BY.js} +1 -1
  7. package/dist/preview/assets/{config-CZ0f5xdI.js → config-DYL6kHr3.js} +1 -1
  8. package/dist/preview/assets/{config-Ddh8pxIi.js → config-Dx0zHfGt.js} +1 -1
  9. package/dist/preview/assets/{config-D9xGgFnF.js → config-E-DM6b5t.js} +1 -1
  10. package/dist/preview/assets/{config-C32yfrlg.js → config-PjseWUbC.js} +1 -1
  11. package/dist/preview/assets/{config-Bi9F-Jdh.js → config-dwcdYHd4.js} +1 -1
  12. package/dist/preview/assets/{definition.vue_vue_type_script_setup_true_lang-C_cjxvm1.js → definition.vue_vue_type_script_setup_true_lang-uJFJXxli.js} +1 -1
  13. package/dist/preview/assets/index-7MVXgV5n.css +1 -0
  14. package/dist/preview/assets/index-CmPiZG_4.js +1 -0
  15. package/dist/preview/assets/index-x-77enex.js +668 -0
  16. package/dist/preview/assets/runtime-BRMGkqSr.js +1 -0
  17. package/dist/preview/assets/runtime-CHLboM_z.js +1 -0
  18. package/dist/preview/assets/runtime-CeHdesjP.js +1 -0
  19. package/dist/preview/assets/runtime-D4_9FCLy.js +1 -0
  20. package/dist/preview/assets/runtime-DHBTDws7.js +1 -0
  21. package/dist/preview/assets/runtime-DJHpCLnr.js +1 -0
  22. package/dist/preview/assets/runtime-DKq86fZU.js +1 -0
  23. package/dist/preview/assets/runtime-DjpjaNec.js +1 -0
  24. package/dist/preview/assets/runtime-ZQryOEKm.js +1 -0
  25. package/dist/preview/index.html +2 -2
  26. package/dist/runtime/components/actions/buttons/2026-04-18/com.shwfed.actions.button.http.request.json/runtime.vue +7 -4
  27. package/dist/runtime/components/actions/buttons/2026-04-18/com.shwfed.actions.button.http.request.json.confirm/runtime.vue +6 -0
  28. package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/schema.d.ts +1 -1
  29. package/dist/runtime/components/form/ValidationRulesField.d.vue.ts +16 -0
  30. package/dist/runtime/components/form/ValidationRulesField.vue +207 -0
  31. package/dist/runtime/components/form/ValidationRulesField.vue.d.ts +16 -0
  32. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.markdown/config.d.vue.ts +24 -0
  33. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.markdown/config.vue.d.ts +24 -0
  34. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.markdown/schema.d.ts +18 -0
  35. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.text/config.d.vue.ts +24 -0
  36. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.text/config.vue +38 -0
  37. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.text/config.vue.d.ts +24 -0
  38. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.text/runtime.vue +18 -2
  39. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.text/schema.d.ts +18 -0
  40. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.textarea/config.d.vue.ts +24 -0
  41. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.textarea/config.vue +38 -0
  42. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.textarea/config.vue.d.ts +24 -0
  43. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.textarea/runtime.vue +18 -2
  44. package/dist/runtime/components/form/fields/2026-04-22/com.shwfed.form.field.textarea/schema.d.ts +18 -0
  45. package/dist/runtime/components/form/fields/2026-04-24/com.shwfed.form.field.actions/config.d.vue.ts +24 -0
  46. package/dist/runtime/components/form/fields/2026-04-24/com.shwfed.form.field.actions/config.vue.d.ts +24 -0
  47. package/dist/runtime/components/form/fields/2026-04-24/com.shwfed.form.field.actions/schema.d.ts +18 -0
  48. package/dist/runtime/components/form/fields/2026-04-24/com.shwfed.form.field.combobox.single/config.d.vue.ts +24 -0
  49. package/dist/runtime/components/form/fields/2026-04-24/com.shwfed.form.field.combobox.single/config.vue.d.ts +24 -0
  50. package/dist/runtime/components/form/fields/2026-04-24/com.shwfed.form.field.combobox.single/schema.d.ts +18 -0
  51. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.date/config.d.vue.ts +24 -0
  52. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.date/config.vue +38 -0
  53. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.date/config.vue.d.ts +24 -0
  54. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.date/runtime.vue +18 -2
  55. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.date/schema.d.ts +18 -0
  56. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.daterange/config.d.vue.ts +24 -0
  57. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.daterange/config.vue +38 -0
  58. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.daterange/config.vue.d.ts +24 -0
  59. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.daterange/runtime.vue +18 -2
  60. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.daterange/schema.d.ts +18 -0
  61. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetime/config.d.vue.ts +24 -0
  62. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetime/config.vue +38 -0
  63. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetime/config.vue.d.ts +24 -0
  64. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetime/runtime.vue +18 -2
  65. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetime/schema.d.ts +18 -0
  66. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetimerange/config.d.vue.ts +24 -0
  67. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetimerange/config.vue +38 -0
  68. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetimerange/config.vue.d.ts +24 -0
  69. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetimerange/runtime.vue +18 -2
  70. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.datetimerange/schema.d.ts +18 -0
  71. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.time/config.d.vue.ts +24 -0
  72. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.time/config.vue +38 -0
  73. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.time/config.vue.d.ts +24 -0
  74. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.time/runtime.vue +18 -2
  75. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.time/schema.d.ts +18 -0
  76. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.timerange/config.d.vue.ts +24 -0
  77. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.timerange/config.vue +38 -0
  78. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.timerange/config.vue.d.ts +24 -0
  79. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.timerange/runtime.vue +18 -2
  80. package/dist/runtime/components/form/fields/2026-04-27/com.shwfed.form.field.timerange/schema.d.ts +18 -0
  81. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.number/config.d.vue.ts +24 -0
  82. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.number/config.vue +38 -0
  83. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.number/config.vue.d.ts +24 -0
  84. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.number/runtime.vue +18 -2
  85. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.number/schema.d.ts +18 -0
  86. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.numberrange/config.d.vue.ts +24 -0
  87. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.numberrange/config.vue +38 -0
  88. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.numberrange/config.vue.d.ts +24 -0
  89. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.numberrange/runtime.vue +18 -2
  90. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.numberrange/schema.d.ts +18 -0
  91. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.switch/config.d.vue.ts +24 -0
  92. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.switch/config.vue +38 -0
  93. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.switch/config.vue.d.ts +24 -0
  94. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.switch/runtime.vue +18 -2
  95. package/dist/runtime/components/form/fields/2026-04-28/com.shwfed.form.field.switch/schema.d.ts +18 -0
  96. package/dist/runtime/components/form/fields/2026-04-29/com.shwfed.form.field.combobox.single/config.d.vue.ts +24 -0
  97. package/dist/runtime/components/form/fields/2026-04-29/com.shwfed.form.field.combobox.single/config.vue.d.ts +24 -0
  98. package/dist/runtime/components/form/fields/2026-04-29/com.shwfed.form.field.combobox.single/schema.d.ts +18 -0
  99. package/dist/runtime/components/form/fields/2026-05-12/com.shwfed.form.field.upload/config.d.vue.ts +24 -0
  100. package/dist/runtime/components/form/fields/2026-05-12/com.shwfed.form.field.upload/config.vue +38 -0
  101. package/dist/runtime/components/form/fields/2026-05-12/com.shwfed.form.field.upload/config.vue.d.ts +24 -0
  102. package/dist/runtime/components/form/fields/2026-05-12/com.shwfed.form.field.upload/runtime.vue +18 -2
  103. package/dist/runtime/components/form/fields/2026-05-12/com.shwfed.form.field.upload/schema.d.ts +18 -0
  104. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.combobox.single.remote/config.d.vue.ts +24 -0
  105. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.combobox.single.remote/config.vue +38 -0
  106. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.combobox.single.remote/config.vue.d.ts +24 -0
  107. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.combobox.single.remote/runtime.vue +18 -2
  108. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.combobox.single.remote/schema.d.ts +18 -0
  109. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.list/config.d.vue.ts +24 -0
  110. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.list/config.vue +38 -0
  111. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.list/config.vue.d.ts +24 -0
  112. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.list/runtime.vue +18 -2
  113. package/dist/runtime/components/form/fields/2026-05-13/com.shwfed.form.field.list/schema.d.ts +30 -0
  114. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.checkbox.group/config.d.vue.ts +24 -0
  115. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.checkbox.group/config.vue +38 -0
  116. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.checkbox.group/config.vue.d.ts +24 -0
  117. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.checkbox.group/runtime.vue +18 -2
  118. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.checkbox.group/schema.d.ts +18 -0
  119. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.radio.group/config.d.vue.ts +24 -0
  120. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.radio.group/config.vue +38 -0
  121. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.radio.group/config.vue.d.ts +24 -0
  122. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.radio.group/runtime.vue +18 -2
  123. package/dist/runtime/components/form/fields/2026-05-17/com.shwfed.form.field.radio.group/schema.d.ts +18 -0
  124. package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/config.d.vue.ts +24 -0
  125. package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/config.vue +51 -9
  126. package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/config.vue.d.ts +24 -0
  127. package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/runtime.vue +22 -2
  128. package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/schema.d.ts +18 -0
  129. package/dist/runtime/components/form/fields/2026-05-20/com.shwfed.form.field.collapsible/runtime.vue +26 -0
  130. package/dist/runtime/components/form/fields/2026-05-23/com.shwfed.form.field.tree.multi/config.d.vue.ts +24 -0
  131. package/dist/runtime/components/form/fields/2026-05-23/com.shwfed.form.field.tree.multi/config.vue.d.ts +24 -0
  132. package/dist/runtime/components/form/fields/2026-05-23/com.shwfed.form.field.tree.multi/schema.d.ts +18 -0
  133. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.month/config.d.vue.ts +24 -0
  134. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.month/config.vue +38 -0
  135. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.month/config.vue.d.ts +24 -0
  136. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.month/runtime.vue +18 -2
  137. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.month/schema.d.ts +18 -0
  138. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.monthrange/config.d.vue.ts +24 -0
  139. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.monthrange/config.vue +38 -0
  140. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.monthrange/config.vue.d.ts +24 -0
  141. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.monthrange/runtime.vue +18 -2
  142. package/dist/runtime/components/form/fields/2026-05-24/com.shwfed.form.field.monthrange/schema.d.ts +18 -0
  143. package/dist/runtime/components/form/fields/2026-05-25/com.shwfed.form.field.combobox.multi/config.d.vue.ts +24 -0
  144. package/dist/runtime/components/form/fields/2026-05-25/com.shwfed.form.field.combobox.multi/config.vue.d.ts +24 -0
  145. package/dist/runtime/components/form/fields/2026-05-25/com.shwfed.form.field.combobox.multi/schema.d.ts +18 -0
  146. package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/config.d.vue.ts +24 -0
  147. package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/config.vue.d.ts +24 -0
  148. package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/schema.d.ts +18 -0
  149. package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/config.d.vue.ts +24 -0
  150. package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/config.vue.d.ts +24 -0
  151. package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/schema.d.ts +18 -0
  152. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/config.d.vue.ts +24 -0
  153. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/config.vue +38 -0
  154. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/config.vue.d.ts +24 -0
  155. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/runtime.vue +18 -2
  156. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/schema.d.ts +18 -0
  157. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/config.d.vue.ts +24 -0
  158. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/config.vue +38 -0
  159. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/config.vue.d.ts +24 -0
  160. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/runtime.vue +18 -2
  161. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/schema.d.ts +18 -0
  162. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/config.d.vue.ts +24 -0
  163. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/config.vue +38 -0
  164. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/config.vue.d.ts +24 -0
  165. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/runtime.vue +18 -2
  166. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/schema.d.ts +18 -0
  167. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/config.d.vue.ts +24 -0
  168. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/config.vue +38 -0
  169. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/config.vue.d.ts +24 -0
  170. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/runtime.vue +18 -2
  171. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/schema.d.ts +18 -0
  172. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/config.d.vue.ts +24 -0
  173. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/config.vue +38 -0
  174. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/config.vue.d.ts +24 -0
  175. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/runtime.vue +18 -2
  176. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/schema.d.ts +18 -0
  177. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/config.d.vue.ts +24 -0
  178. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/config.vue +38 -0
  179. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/config.vue.d.ts +24 -0
  180. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/runtime.vue +18 -2
  181. package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/schema.d.ts +18 -0
  182. package/dist/runtime/components/form/index.d.vue.ts +1 -0
  183. package/dist/runtime/components/form/index.vue +14 -18
  184. package/dist/runtime/components/form/index.vue.d.ts +1 -0
  185. package/dist/runtime/components/form/schema.d.ts +2 -10
  186. package/dist/runtime/components/form/schema.js +2 -5
  187. package/dist/runtime/components/form/utils/cel-scope.d.ts +12 -3
  188. package/dist/runtime/components/form/utils/cel-scope.js +17 -18
  189. package/dist/runtime/components/form/utils/common.d.ts +42 -0
  190. package/dist/runtime/components/form/utils/common.js +40 -2
  191. package/dist/runtime/components/form/utils/form-vars.d.ts +19 -0
  192. package/dist/runtime/components/form/utils/form-vars.js +5 -0
  193. package/dist/runtime/components/form/utils/validation.d.ts +85 -0
  194. package/dist/runtime/components/form/utils/validation.js +113 -0
  195. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.date/config.vue +20 -8
  196. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.date/schema.d.ts +1 -0
  197. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.icon/config.vue +20 -8
  198. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.icon/schema.d.ts +1 -0
  199. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.number/config.vue +20 -8
  200. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.number/schema.d.ts +1 -0
  201. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.text/config.vue +20 -8
  202. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.text/schema.d.ts +1 -0
  203. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch/config.vue +20 -8
  204. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch/schema.d.ts +1 -0
  205. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch.remote/config.vue +20 -8
  206. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch.remote/schema.d.ts +1 -0
  207. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -0
  208. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/config.vue +20 -8
  209. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -0
  210. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/schema.d.ts +1 -0
  211. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.number-input/config.vue +20 -7
  212. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.number-input/schema.d.ts +1 -0
  213. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch/config.vue +20 -8
  214. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch/schema.d.ts +1 -0
  215. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch.local/config.vue +20 -8
  216. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch.local/schema.d.ts +1 -0
  217. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.text-input/config.vue +20 -8
  218. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.text-input/schema.d.ts +1 -0
  219. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.d.vue.ts +2 -0
  220. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.vue +20 -8
  221. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.vue.d.ts +2 -0
  222. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/schema.d.ts +1 -0
  223. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.d.vue.ts +2 -0
  224. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.vue +20 -8
  225. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.vue.d.ts +2 -0
  226. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/schema.d.ts +1 -0
  227. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -0
  228. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/config.vue +20 -8
  229. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -0
  230. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/schema.d.ts +1 -0
  231. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.d.vue.ts +2 -0
  232. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.vue +20 -8
  233. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.vue.d.ts +2 -0
  234. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/schema.d.ts +1 -0
  235. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.d.vue.ts +2 -0
  236. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.vue +20 -8
  237. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.vue.d.ts +2 -0
  238. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/schema.d.ts +1 -0
  239. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -0
  240. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/config.vue +20 -8
  241. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -0
  242. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/schema.d.ts +1 -0
  243. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.d.vue.ts +2 -0
  244. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.vue +20 -8
  245. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.vue.d.ts +2 -0
  246. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/schema.d.ts +1 -0
  247. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -0
  248. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/config.vue +20 -8
  249. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -0
  250. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/schema.d.ts +1 -0
  251. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.d.vue.ts +2 -0
  252. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.vue +20 -8
  253. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.vue.d.ts +2 -0
  254. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/schema.d.ts +1 -0
  255. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.d.vue.ts +2 -0
  256. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.vue +20 -7
  257. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.vue.d.ts +2 -0
  258. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/schema.d.ts +1 -0
  259. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.d.vue.ts +2 -0
  260. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.vue +20 -7
  261. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.vue.d.ts +2 -0
  262. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/schema.d.ts +1 -0
  263. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -0
  264. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue +20 -8
  265. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -0
  266. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/schema.d.ts +1 -0
  267. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/schema.js +2 -1
  268. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -0
  269. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue +20 -8
  270. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -0
  271. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/schema.d.ts +1 -0
  272. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/schema.js +2 -1
  273. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.d.vue.ts +2 -0
  274. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.vue +20 -7
  275. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.vue.d.ts +2 -0
  276. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/schema.d.ts +1 -0
  277. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.d.vue.ts +2 -0
  278. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.vue +20 -7
  279. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.vue.d.ts +2 -0
  280. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/schema.d.ts +1 -0
  281. package/dist/runtime/components/table/config.d.vue.ts +4 -2
  282. package/dist/runtime/components/table/config.vue +25 -45
  283. package/dist/runtime/components/table/config.vue.d.ts +4 -2
  284. package/dist/runtime/components/table/index.vue +22 -2
  285. package/dist/runtime/components/table/schema.d.ts +4 -2
  286. package/dist/runtime/components/table/schema.js +69 -13
  287. package/dist/runtime/components/table/utils/shared.d.ts +2 -0
  288. package/dist/runtime/components/table/utils/shared.js +12 -4
  289. package/dist/runtime/components/ui/field/FieldError.vue +1 -1
  290. package/dist/runtime/components/ui/field/FieldMessages.d.vue.ts +9 -0
  291. package/dist/runtime/components/ui/field/FieldMessages.vue +21 -0
  292. package/dist/runtime/components/ui/field/FieldMessages.vue.d.ts +9 -0
  293. package/dist/runtime/components/ui/field/FieldWarning.d.vue.ts +20 -0
  294. package/dist/runtime/components/ui/field/FieldWarning.vue +51 -0
  295. package/dist/runtime/components/ui/field/FieldWarning.vue.d.ts +20 -0
  296. package/dist/runtime/components/ui/field/index.d.ts +2 -0
  297. package/dist/runtime/components/ui/field/index.js +10 -4
  298. package/dist/runtime/components/ui/locale/Locale.d.vue.ts +2 -0
  299. package/dist/runtime/components/ui/locale/Locale.vue +165 -155
  300. package/dist/runtime/components/ui/locale/Locale.vue.d.ts +2 -0
  301. package/dist/runtime/share/form-validate.d.ts +18 -0
  302. package/dist/runtime/share/form-validate.js +8 -0
  303. package/package.json +1 -1
  304. package/dist/preview/assets/index-BqOX70Hd.css +0 -1
  305. package/dist/preview/assets/index-D-VR1i8D.js +0 -659
  306. package/dist/preview/assets/index-ihZGlPdX.js +0 -1
  307. package/dist/preview/assets/runtime-Bn8mqeDH.js +0 -1
  308. package/dist/preview/assets/runtime-Cc_Wk3o-.js +0 -1
  309. package/dist/preview/assets/runtime-CttAjIgg.js +0 -1
  310. package/dist/preview/assets/runtime-Cx4f2UTl.js +0 -1
  311. package/dist/preview/assets/runtime-D1dESjXR.js +0 -1
  312. package/dist/preview/assets/runtime-DIEP1Xbh.js +0 -1
  313. package/dist/preview/assets/runtime-DKceWuBx.js +0 -1
  314. package/dist/preview/assets/runtime-Dhid9O5c.js +0 -1
  315. package/dist/preview/assets/runtime-YMiqi6WY.js +0 -1
package/dist/mcp.mjs CHANGED
@@ -82475,6 +82475,27 @@ const __vite_glob_0_0$2 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.d
82475
82475
  schema: schema$15,
82476
82476
  type: type$15
82477
82477
  }, Symbol.toStringTag, { value: "Module" }));
82478
+ function validationRuleStruct(configure) {
82479
+ const CelBool = Expression({ configure, resultType: "bool" });
82480
+ return Struct({
82481
+ when: CelBool.annotations({
82482
+ title: "规则",
82483
+ description: md`
82484
+ 返回 \`true\` 时视为校验**未**通过,返回 \`false\` 视为通过
82485
+ `
82486
+ }),
82487
+ // Severity toggle. Off (default / absent) ⇒ error: standard blocks submit
82488
+ // and reds the field. On ⇒ warning: yellow hint only, never blocks submit.
82489
+ warning: optional(Boolean$.annotations({
82490
+ title: "仅警告",
82491
+ description: "开启后该规则仅黄色提示、不阻止提交"
82492
+ })),
82493
+ message: LocaleMarkdown({ configure }).annotations({
82494
+ title: "消息",
82495
+ description: "校验未通过时展示的本地化消息,支持 inline Markdown 与 `{{ 表达式 }}` 插值"
82496
+ })
82497
+ });
82498
+ }
82478
82499
  function commonFieldFields(configure) {
82479
82500
  const CelBool = Expression({ configure, resultType: "bool" });
82480
82501
  return {
@@ -82486,7 +82507,24 @@ function commonFieldFields(configure) {
82486
82507
  hidden: optional(CelBool.annotations({
82487
82508
  title: "隐藏条件",
82488
82509
  description: "返回 `true` 时字段在所有布局中都不渲染"
82489
- }))
82510
+ })),
82511
+ // Required marker + non-empty check share one expression — no drift
82512
+ // between the star the user sees and the rule that gates submit.
82513
+ required: optional(CelBool.annotations({
82514
+ title: "必填条件",
82515
+ description: "返回 `true` 时显示必填星号并要求非空,留空表示不必填"
82516
+ })),
82517
+ // Field-owned rules. `when` returns a bool — `true` triggers the rule; the
82518
+ // per-rule `warning` switch picks the severity (error by default, warning
82519
+ // when on). The message is a localized Markdown template with `{{ 表达式 }}`
82520
+ // interpolation. Cross-field rules read `form.*` and live on the field where
82521
+ // the error should appear.
82522
+ validations: optional(
82523
+ Array$(validationRuleStruct(configure)).annotations({
82524
+ title: "校验规则",
82525
+ description: "反馈消息将按照校验规则列表顺序展示"
82526
+ })
82527
+ )
82490
82528
  };
82491
82529
  }
82492
82530
  const FIELD_ORIENTATIONS = ["vertical", "floating"];
@@ -90854,9 +90892,13 @@ function columnFields(configure) {
90854
90892
  | 数据量 | **全量**,能够跨越多页 | 当前页 |
90855
90893
  | 开发量 | 需要后端支持,可能影响性能 | **配置即启用,无需后端支持** |
90856
90894
 
90857
- 注意:对于服务端排序,除了在这里打开排序开关,你还需要在「通用配置 → 数据源 → 请求」处,**将正在排序字段、排序状态传给后端**。
90895
+ 注意:对于服务端排序,除了在这里打开排序开关,你还需要在「通用配置 → 数据源 → 请求」处,通过 \`sorts\` 变量**将各列「排序字段」(sortKey)、排序方向传给后端**。
90858
90896
  `
90859
90897
  })),
90898
+ sortKey: optional(String$.pipe(minLength(1)).annotations({
90899
+ title: "排序字段",
90900
+ description: "服务端排序时通过数据源请求的 `sorts` 变量传给后端的字段标识;启用排序时必填"
90901
+ })),
90860
90902
  size: optional(Number$.pipe(finite(), positive()).annotations({
90861
90903
  title: "列宽",
90862
90904
  description: "指定一个合适的表格列宽度,当列内容长度大于这里指定的宽度后,会导致超出的部分被截断。"
@@ -90875,7 +90917,11 @@ function editableColumnFields() {
90875
90917
  }),
90876
90918
  enableSorting: optional(Boolean$.annotations({
90877
90919
  title: "允许排序",
90878
- description: "显示排序按钮;启用客户端排序,按当前 `binding` 路径上的值排序"
90920
+ description: "显示排序按钮;客户端排序按当前 `binding` 路径上的值排序,服务端排序则通过数据源请求的 `sorts` 变量将「排序字段」(sortKey) 传给后端"
90921
+ })),
90922
+ sortKey: optional(String$.pipe(minLength(1)).annotations({
90923
+ title: "排序字段",
90924
+ description: "服务端排序时通过数据源请求的 `sorts` 变量传给后端的字段标识;启用排序时必填"
90879
90925
  })),
90880
90926
  size: optional(Number$.pipe(finite(), positive()).annotations({
90881
90927
  title: "列宽",
@@ -90902,10 +90948,10 @@ function editableHeader(titleText) {
90902
90948
  function registerRowVariablesIfAbsent(env) {
90903
90949
  const declared = new Set(env.getDefinitions().variables.map((v) => v.name));
90904
90950
  if (!declared.has("row")) {
90905
- env.registerVariable("row", "dyn", { description: "当前行数据" });
90951
+ env.registerVariable("row", "dyn", { label: "当前行", description: "当前行数据" });
90906
90952
  }
90907
90953
  if (!declared.has("index")) {
90908
- env.registerVariable("index", "number", { description: "行索引" });
90954
+ env.registerVariable("index", "number", { label: "行序号", description: "行索引" });
90909
90955
  }
90910
90956
  }
90911
90957
  function configureWithRow(configure) {
@@ -93971,6 +94017,7 @@ function schema$m(configure) {
93971
94017
  description: "返回 `true` 时仅以纯文本展示当前已选项的标签"
93972
94018
  })),
93973
94019
  enableSorting: display.enableSorting,
94020
+ sortKey: display.sortKey,
93974
94021
  size: display.size,
93975
94022
  grow: display.grow,
93976
94023
  tooltip: display.tooltip,
@@ -93989,7 +94036,7 @@ const migrateFrom$8 = [
93989
94036
  { type: "com.shwfed.table.column.combobox-multi", compatibilityDate: "2026-05-26" },
93990
94037
  { type: "com.shwfed.table.column.combobox-multi.remote", compatibilityDate: "2026-05-26" }
93991
94038
  ];
93992
- const CARRY$1 = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "placeholder", "hidden", "disabled", "readonly"];
94039
+ const CARRY$1 = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "sortKey", "placeholder", "hidden", "disabled", "readonly"];
93993
94040
  const migrate$8 = (prev) => try_({
93994
94041
  try: () => {
93995
94042
  if (!prev || typeof prev !== "object") {
@@ -94247,6 +94294,7 @@ function schema$l(configure) {
94247
94294
  description: "返回 `true` 时仅以纯文本展示当前选项的标签"
94248
94295
  })),
94249
94296
  enableSorting: display.enableSorting,
94297
+ sortKey: display.sortKey,
94250
94298
  size: display.size,
94251
94299
  grow: display.grow,
94252
94300
  tooltip: display.tooltip,
@@ -94265,7 +94313,7 @@ const migrateFrom$7 = [
94265
94313
  { type: "com.shwfed.table.column.combobox-single", compatibilityDate: "2026-05-26" },
94266
94314
  { type: "com.shwfed.table.column.combobox-single.remote", compatibilityDate: "2026-05-26" }
94267
94315
  ];
94268
- const CARRY = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "placeholder", "hidden", "disabled", "readonly"];
94316
+ const CARRY = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "sortKey", "placeholder", "hidden", "disabled", "readonly"];
94269
94317
  const migrate$7 = (prev) => try_({
94270
94318
  try: () => {
94271
94319
  if (!prev || typeof prev !== "object") {
@@ -94991,6 +95039,15 @@ const ColumnGroup = Struct({
94991
95039
  description: "列分组定义"
94992
95040
  });
94993
95041
  const QUERY_VAR_DESCRIPTION = "搜索条件当前状态;未配置搜索条件时为空对象";
95042
+ const JSON_VAR_DESCRIPTION = "已解析的 JSON 响应;未配置 `request` 时为 `none`";
95043
+ const SORTS_VAR_DESCRIPTION = md`
95044
+ 当前的排序状态,为一个**列表**,每个元素包含两个字段:
95045
+
95046
+ - \`key: string\` 为该列上配置的键
95047
+ - \`mode: 'asc' | 'desc'\` 为该列的排序状态
95048
+
95049
+ 未排序的字段,**不会出现在这个列表中**。
95050
+ `;
94994
95051
  function configureTableActionsScope(env, configure) {
94995
95052
  configure(env);
94996
95053
  env.registerVariable("selected", "list<dyn>", {
@@ -95001,12 +95058,43 @@ function configureTableActionsScope(env, configure) {
95001
95058
  label: "搜索条件",
95002
95059
  description: QUERY_VAR_DESCRIPTION
95003
95060
  });
95061
+ env.registerVariable("sorts", "list<map<string, string>>", {
95062
+ label: "排序状态",
95063
+ description: SORTS_VAR_DESCRIPTION
95064
+ });
95065
+ }
95066
+ function registerDataSourceRequestVars(env) {
95067
+ env.registerVariable("pageIndex", "number", {
95068
+ label: "当前页码",
95069
+ description: "从 `0` 开始;未启用分页时为 `0`"
95070
+ });
95071
+ env.registerVariable("pageSize", "number", {
95072
+ label: "每页行数",
95073
+ description: "当前每页行数;未启用分页时为 `0`"
95074
+ });
95075
+ env.registerVariable("sorts", "list<map<string, string>>", {
95076
+ label: "排序状态",
95077
+ description: SORTS_VAR_DESCRIPTION
95078
+ });
95079
+ env.registerVariable("query", "dyn", {
95080
+ label: "搜索条件",
95081
+ description: QUERY_VAR_DESCRIPTION
95082
+ });
95083
+ }
95084
+ function registerDataSourceResponseVars(env) {
95085
+ env.registerVariable("json", "optional<dyn>", {
95086
+ label: "HTTP 响应体",
95087
+ description: JSON_VAR_DESCRIPTION
95088
+ });
95089
+ env.registerVariable("query", "dyn", {
95090
+ label: "搜索条件",
95091
+ description: QUERY_VAR_DESCRIPTION
95092
+ });
95004
95093
  }
95005
95094
  function DataSource(configure, extras) {
95006
95095
  const CelRequest = Expression({
95007
95096
  configure: (env) => {
95008
95097
  configure(env);
95009
- extras?.request?.(env);
95010
95098
  },
95011
95099
  resultType: "HttpRequest"
95012
95100
  });
@@ -95016,7 +95104,6 @@ function DataSource(configure, extras) {
95016
95104
  env.registerVariable("json", "optional<dyn>", {
95017
95105
  description: "HTTP 响应体(已解析 JSON);未配置 request 时为 none"
95018
95106
  });
95019
- extras?.data?.(env);
95020
95107
  },
95021
95108
  resultType: (type2) => type2.startsWith("list") || type2 === "dyn" || type2.startsWith("optional")
95022
95109
  });
@@ -95035,28 +95122,36 @@ function DataSource(configure, extras) {
95035
95122
  });
95036
95123
  }
95037
95124
  function tableDataSource(configure) {
95038
- const base2 = DataSource(configure, {
95039
- request: (env) => {
95040
- env.registerVariable("pageIndex", "number", { description: "当前页码(从 0 开始);未启用分页时为 0" });
95041
- env.registerVariable("pageSize", "number", { description: "每页行数;未启用分页时为 0" });
95042
- env.registerVariable("query", "dyn", { description: QUERY_VAR_DESCRIPTION });
95125
+ const CelRequest = Expression({
95126
+ configure: (env) => {
95127
+ configure(env);
95128
+ registerDataSourceRequestVars(env);
95043
95129
  },
95044
- data: (env) => {
95045
- env.registerVariable("query", "dyn", { description: QUERY_VAR_DESCRIPTION });
95046
- }
95130
+ resultType: "HttpRequest"
95131
+ });
95132
+ const CelRows = Expression({
95133
+ configure: (env) => {
95134
+ configure(env);
95135
+ registerDataSourceResponseVars(env);
95136
+ },
95137
+ resultType: (type2) => type2.startsWith("list") || type2 === "dyn" || type2.startsWith("optional")
95047
95138
  });
95048
95139
  const CelTotal = Expression({
95049
95140
  configure: (env) => {
95050
95141
  configure(env);
95051
- env.registerVariable("json", "optional<dyn>", {
95052
- description: "HTTP 响应体(已解析 JSON);未配置 request 时为 none"
95053
- });
95054
- env.registerVariable("query", "dyn", { description: QUERY_VAR_DESCRIPTION });
95142
+ registerDataSourceResponseVars(env);
95055
95143
  },
95056
95144
  resultType: (type2) => type2 === "number" || type2 === "dyn" || type2.startsWith("optional")
95057
95145
  });
95058
95146
  return Struct({
95059
- ...base2.fields,
95147
+ request: optional(CelRequest).annotations({
95148
+ title: "请求",
95149
+ description: "可选的 HTTP 请求表达式;未配置时数据从 `data` 表达式中读取(通常引用上下文变量)"
95150
+ }),
95151
+ data: CelRows.annotations({
95152
+ title: "数据",
95153
+ description: "返回行数据列表(`list<dyn>`)的 CEL 表达式;在配置了 `request` 时可通过 `json` 引用响应体"
95154
+ }),
95060
95155
  total: optional(CelTotal).annotations({
95061
95156
  title: "总数",
95062
95157
  description: "返回总行数(`number`)的 CEL 表达式;配置后启用服务端分页,留空则走前端分页"
@@ -95147,6 +95242,12 @@ function TableConfig(configure) {
95147
95242
  if (cfg.dataSource?.total !== void 0 && cfg.pagination === void 0) {
95148
95243
  return "配置了 dataSource.total 时必须启用分页";
95149
95244
  }
95245
+ for (const col of cfg.columns) {
95246
+ const c = col;
95247
+ if (c.enableSorting === true && (c.sortKey === void 0 || c.sortKey.length === 0)) {
95248
+ return "启用排序的列必须填写「排序字段」(sortKey)";
95249
+ }
95250
+ }
95150
95251
  return true;
95151
95252
  })).annotations({
95152
95253
  title: "TableConfig",
@@ -97030,6 +97131,11 @@ function allFieldSchemas(configure) {
97030
97131
  identifier: `${entry.type}@${entry.compatibilityDate}`
97031
97132
  }));
97032
97133
  }
97134
+ function registerFormVariablesIfAbsent(env) {
97135
+ const declared = new Set(env.getDefinitions().variables.map((v) => v.name));
97136
+ if (!declared.has("now")) env.registerVariable("now", "Date", { label: "当前时间", description: "当前日期/时间" });
97137
+ if (!declared.has("form")) env.registerVariable("form", "dyn", { label: "表单值", description: "当前表单状态" });
97138
+ }
97033
97139
  const KIND$1 = "shwfed.component.form";
97034
97140
  function unitFields(configure) {
97035
97141
  const fieldSchemas = allFieldSchemas(configure);
@@ -97058,11 +97164,6 @@ function FormUnit(configure) {
97058
97164
  description: "一组表单字段及其布局"
97059
97165
  });
97060
97166
  }
97061
- function registerFormVariablesIfAbsent(env) {
97062
- const declared = new Set(env.getDefinitions().variables.map((v) => v.name));
97063
- if (!declared.has("now")) env.registerVariable("now", "Date", { description: "当前日期/时间" });
97064
- if (!declared.has("form")) env.registerVariable("form", "dyn", { description: "当前表单状态" });
97065
- }
97066
97167
  function FormConfig(configure) {
97067
97168
  const formConfigure = (env) => {
97068
97169
  registerFormVariablesIfAbsent(env);
package/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "shwfed",
3
3
  "configKey": "shwfed",
4
- "version": "2.4.0",
4
+ "version": "2.5.0",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "unknown"
@@ -1 +1 @@
1
- import{d as V,b as w,z as F,c as v,g as e,w as n,u as s,f as _,F as U,v as j,o as E,h as c,i as u,j as d,t as p,k as m,l as f,_ as x,T as k,x as N,y as R}from"./index-D-VR1i8D.js";const D={class:"flex flex-col gap-3"},H={class:"flex items-start gap-2"},$={class:"grid grid-cols-2 gap-3"},B=V({name:"ShwfedHttpRequestActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(h){const o=w(h,"modelValue"),g=F(()=>{}),i=t=>N(g,t)??t,r=t=>R(g,t),S=["onSuccess","onWarning","onError","onInfo"];function T(t){const l={...o.value};t.length===0?delete l.messageExpression:l.messageExpression=t,o.value=l}function b(t){const l={...o.value};t.length===0?delete l.resultExpression:l.resultExpression=t,o.value=l}function y(t,l){const a={...o.value};l.length===0?Reflect.deleteProperty(a,t):a[t]=l,o.value=a}return(t,l)=>(E(),v("div",D,[e(s(x),{orientation:"vertical"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i("expression")),1)]),_:2},[r("expression")?{name:"tooltip",fn:n(()=>[e(s(m),{source:r("expression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(s(f),{"model-value":o.value.expression,multiline:"",placeholder:"例:http.post('/api/foo').body({ id: row.id })","result-type":"HttpRequest",class:"min-h-16","onUpdate:modelValue":l[0]||(l[0]=a=>o.value={...o.value,expression:a})},null,8,["model-value"])]),_:1}),_("div",H,[e(s(x),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i("messageExpression")),1)]),_:2},[r("messageExpression")?{name:"tooltip",fn:n(()=>[e(s(m),{source:r("messageExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(s(f),{"model-value":o.value.messageExpression??"",placeholder:"例:string(json.message)","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":T},null,8,["model-value"])]),_:1}),e(s(x),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i("resultExpression")),1)]),_:2},[r("resultExpression")?{name:"tooltip",fn:n(()=>[e(s(m),{source:r("resultExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(s(f),{"model-value":o.value.resultExpression??"",placeholder:"例:json.code == 0 ? 'success' : 'error'","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":b},null,8,["model-value"])]),_:1})]),_("div",$,[(E(),v(U,null,j(S,a=>e(s(x),{key:a,orientation:"vertical",class:"min-w-0"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i(a)),1)]),_:2},[r(a)?{name:"tooltip",fn:n(()=>[e(s(m),{source:r(a),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(k,{triggers:o.value[a]??[],"onUpdate:triggers":z=>y(a,z)},null,8,["triggers","onUpdate:triggers"])]),_:2},1024)),64))])]))}});export{B as default};
1
+ import{d as V,b as w,z as F,c as v,g as e,w as n,u as s,f as _,F as U,v as j,o as E,h as c,i as u,j as d,t as p,k as m,l as f,_ as x,T as k,x as N,y as R}from"./index-x-77enex.js";const D={class:"flex flex-col gap-3"},H={class:"flex items-start gap-2"},$={class:"grid grid-cols-2 gap-3"},B=V({name:"ShwfedHttpRequestActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(h){const o=w(h,"modelValue"),g=F(()=>{}),i=t=>N(g,t)??t,r=t=>R(g,t),S=["onSuccess","onWarning","onError","onInfo"];function T(t){const l={...o.value};t.length===0?delete l.messageExpression:l.messageExpression=t,o.value=l}function b(t){const l={...o.value};t.length===0?delete l.resultExpression:l.resultExpression=t,o.value=l}function y(t,l){const a={...o.value};l.length===0?Reflect.deleteProperty(a,t):a[t]=l,o.value=a}return(t,l)=>(E(),v("div",D,[e(s(x),{orientation:"vertical"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i("expression")),1)]),_:2},[r("expression")?{name:"tooltip",fn:n(()=>[e(s(m),{source:r("expression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(s(f),{"model-value":o.value.expression,multiline:"",placeholder:"例:http.post('/api/foo').body({ id: row.id })","result-type":"HttpRequest",class:"min-h-16","onUpdate:modelValue":l[0]||(l[0]=a=>o.value={...o.value,expression:a})},null,8,["model-value"])]),_:1}),_("div",H,[e(s(x),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i("messageExpression")),1)]),_:2},[r("messageExpression")?{name:"tooltip",fn:n(()=>[e(s(m),{source:r("messageExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(s(f),{"model-value":o.value.messageExpression??"",placeholder:"例:string(json.message)","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":T},null,8,["model-value"])]),_:1}),e(s(x),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i("resultExpression")),1)]),_:2},[r("resultExpression")?{name:"tooltip",fn:n(()=>[e(s(m),{source:r("resultExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(s(f),{"model-value":o.value.resultExpression??"",placeholder:"例:json.code == 0 ? 'success' : 'error'","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":b},null,8,["model-value"])]),_:1})]),_("div",$,[(E(),v(U,null,j(S,a=>e(s(x),{key:a,orientation:"vertical",class:"min-w-0"},{default:n(()=>[e(s(c),{class:"text-xs text-zinc-500"},u({default:n(()=>[d(" "+p(i(a)),1)]),_:2},[r(a)?{name:"tooltip",fn:n(()=>[e(s(m),{source:r(a),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(k,{triggers:o.value[a]??[],"onUpdate:triggers":z=>y(a,z)},null,8,["triggers","onUpdate:triggers"])]),_:2},1024)),64))])]))}});export{B as default};
@@ -1 +1 @@
1
- import{d as y,b as R,ab as U,c as V,f as x,g as t,w as n,u as s,F as D,v as F,o as z,h as i,j as u,k as c,l as d,_ as p,ac as g,i as f,t as _,T as $,x as C,y as H,$ as S}from"./index-D-VR1i8D.js";const L={class:"flex flex-col gap-3"},N={class:"grid grid-cols-2 gap-3"},B={class:"flex items-start gap-2"},M={class:"grid grid-cols-2 gap-3"},I=y({name:"ShwfedHttpDownloadActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(b){const l=R(b,"modelValue"),E=U(()=>{}),m=a=>C(E,a)??a,r=a=>H(E,a),j=["onSuccess","onWarning","onError","onInfo"],h=S({get:()=>l.value.template?.request??"",set:a=>{l.value={...l.value,template:{...l.value.template,request:a}}}}),w=S({get:()=>l.value.template?.download??"",set:a=>{const e=l.value.template??{request:""};if(a.length===0){const{download:o,...v}=e;l.value={...l.value,template:v}}else l.value={...l.value,template:{...e,download:a}}}});function q(a){const e={...l.value};a.length===0?delete e.messageExpression:e.messageExpression=a,l.value=e}function T(a){const e={...l.value};a.length===0?delete e.resultExpression:e.resultExpression=a,l.value=e}function k(a,e){const o={...l.value};e.length===0?Reflect.deleteProperty(o,a):o[a]=e,l.value=o}return(a,e)=>(z(),V("div",L,[x("div",N,[t(s(p),{orientation:"vertical"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},{tooltip:n(()=>[t(s(c),{source:r("template")??"返回 `HttpRequest` 的 CEL 表达式;未配置「下载请求」时直接下载其响应",block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),default:n(()=>[e[2]||(e[2]=u(" 请求 ",-1))]),_:1}),t(s(d),{"model-value":h.value,multiline:"",placeholder:"例:http.get('https://api.example.com/files/123')","result-type":"HttpRequest",class:"min-h-16","onUpdate:modelValue":e[0]||(e[0]=o=>h.value=o)},null,8,["model-value"])]),_:1}),t(s(p),{orientation:"vertical"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},{tooltip:n(()=>[t(s(c),{source:"可选的第二步:用第一步响应 `json` 中的凭据构造真正的下载请求,例如 `json.data.key`",block:"",class:"prose prose-sm prose-zinc"})]),default:n(()=>[e[3]||(e[3]=u(" 下载请求 ",-1))]),_:1}),t(s(d),{"model-value":w.value,multiline:"",placeholder:"例:http.get('https://api.example.com/download').query('key', json.data.key)","result-type":"HttpRequest","extra-vars":{json:s(g)},class:"min-h-16","onUpdate:modelValue":e[1]||(e[1]=o=>w.value=o)},null,8,["model-value","extra-vars"])]),_:1})]),x("div",B,[t(s(p),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},f({default:n(()=>[u(" "+_(m("messageExpression")),1)]),_:2},[r("messageExpression")?{name:"tooltip",fn:n(()=>[t(s(c),{source:r("messageExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),t(s(d),{"model-value":l.value.messageExpression??"",placeholder:"例:string(json.message)","result-type":"string","extra-vars":{json:s(g)},"onUpdate:modelValue":q},null,8,["model-value","extra-vars"])]),_:1}),t(s(p),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},f({default:n(()=>[u(" "+_(m("resultExpression")),1)]),_:2},[r("resultExpression")?{name:"tooltip",fn:n(()=>[t(s(c),{source:r("resultExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),t(s(d),{"model-value":l.value.resultExpression??"",placeholder:"例:json.code == 0 ? 'success' : 'error'","result-type":"string","extra-vars":{json:s(g)},"onUpdate:modelValue":T},null,8,["model-value","extra-vars"])]),_:1})]),x("div",M,[(z(),V(D,null,F(j,o=>t(s(p),{key:o,orientation:"vertical",class:"min-w-0"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},f({default:n(()=>[u(" "+_(m(o)),1)]),_:2},[r(o)?{name:"tooltip",fn:n(()=>[t(s(c),{source:r(o),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),t($,{triggers:l.value[o]??[],"onUpdate:triggers":v=>k(o,v)},null,8,["triggers","onUpdate:triggers"])]),_:2},1024)),64))])]))}});export{I as default};
1
+ import{d as y,b as R,ab as U,c as V,f as x,g as t,w as n,u as s,F as D,v as F,o as z,h as i,j as u,k as c,l as d,_ as p,ac as g,i as f,t as _,T as $,x as C,y as H,$ as S}from"./index-x-77enex.js";const L={class:"flex flex-col gap-3"},N={class:"grid grid-cols-2 gap-3"},B={class:"flex items-start gap-2"},M={class:"grid grid-cols-2 gap-3"},I=y({name:"ShwfedHttpDownloadActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(b){const l=R(b,"modelValue"),E=U(()=>{}),m=a=>C(E,a)??a,r=a=>H(E,a),j=["onSuccess","onWarning","onError","onInfo"],h=S({get:()=>l.value.template?.request??"",set:a=>{l.value={...l.value,template:{...l.value.template,request:a}}}}),w=S({get:()=>l.value.template?.download??"",set:a=>{const e=l.value.template??{request:""};if(a.length===0){const{download:o,...v}=e;l.value={...l.value,template:v}}else l.value={...l.value,template:{...e,download:a}}}});function q(a){const e={...l.value};a.length===0?delete e.messageExpression:e.messageExpression=a,l.value=e}function T(a){const e={...l.value};a.length===0?delete e.resultExpression:e.resultExpression=a,l.value=e}function k(a,e){const o={...l.value};e.length===0?Reflect.deleteProperty(o,a):o[a]=e,l.value=o}return(a,e)=>(z(),V("div",L,[x("div",N,[t(s(p),{orientation:"vertical"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},{tooltip:n(()=>[t(s(c),{source:r("template")??"返回 `HttpRequest` 的 CEL 表达式;未配置「下载请求」时直接下载其响应",block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),default:n(()=>[e[2]||(e[2]=u(" 请求 ",-1))]),_:1}),t(s(d),{"model-value":h.value,multiline:"",placeholder:"例:http.get('https://api.example.com/files/123')","result-type":"HttpRequest",class:"min-h-16","onUpdate:modelValue":e[0]||(e[0]=o=>h.value=o)},null,8,["model-value"])]),_:1}),t(s(p),{orientation:"vertical"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},{tooltip:n(()=>[t(s(c),{source:"可选的第二步:用第一步响应 `json` 中的凭据构造真正的下载请求,例如 `json.data.key`",block:"",class:"prose prose-sm prose-zinc"})]),default:n(()=>[e[3]||(e[3]=u(" 下载请求 ",-1))]),_:1}),t(s(d),{"model-value":w.value,multiline:"",placeholder:"例:http.get('https://api.example.com/download').query('key', json.data.key)","result-type":"HttpRequest","extra-vars":{json:s(g)},class:"min-h-16","onUpdate:modelValue":e[1]||(e[1]=o=>w.value=o)},null,8,["model-value","extra-vars"])]),_:1})]),x("div",B,[t(s(p),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},f({default:n(()=>[u(" "+_(m("messageExpression")),1)]),_:2},[r("messageExpression")?{name:"tooltip",fn:n(()=>[t(s(c),{source:r("messageExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),t(s(d),{"model-value":l.value.messageExpression??"",placeholder:"例:string(json.message)","result-type":"string","extra-vars":{json:s(g)},"onUpdate:modelValue":q},null,8,["model-value","extra-vars"])]),_:1}),t(s(p),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},f({default:n(()=>[u(" "+_(m("resultExpression")),1)]),_:2},[r("resultExpression")?{name:"tooltip",fn:n(()=>[t(s(c),{source:r("resultExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),t(s(d),{"model-value":l.value.resultExpression??"",placeholder:"例:json.code == 0 ? 'success' : 'error'","result-type":"string","extra-vars":{json:s(g)},"onUpdate:modelValue":T},null,8,["model-value","extra-vars"])]),_:1})]),x("div",M,[(z(),V(D,null,F(j,o=>t(s(p),{key:o,orientation:"vertical",class:"min-w-0"},{default:n(()=>[t(s(i),{class:"text-xs text-zinc-500"},f({default:n(()=>[u(" "+_(m(o)),1)]),_:2},[r(o)?{name:"tooltip",fn:n(()=>[t(s(c),{source:r(o),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),t($,{triggers:l.value[o]??[],"onUpdate:triggers":v=>k(o,v)},null,8,["triggers","onUpdate:triggers"])]),_:2},1024)),64))])]))}});export{I as default};
@@ -1 +1 @@
1
- import{d as x,b as k,aK as g,c as S,g as e,w as o,u as t,o as V,h as r,i as m,j as d,t as f,k as p,a5 as w,_,m as $,x as h,y}from"./index-D-VR1i8D.js";const z={class:"flex flex-col gap-4"},C=x({name:"ShwfedMarkdownItemConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(v){const a=k(v,"modelValue"),c=g(),u=l=>h(c,l)??l,s=l=>y(c,l);return(l,n)=>(V(),S("div",z,[e(t(_),{orientation:"vertical"},{default:o(()=>[e(t(r),{class:"text-xs text-zinc-500"},m({default:o(()=>[d(" "+f(u("name")),1)]),_:2},[s("name")?{name:"tooltip",fn:o(()=>[e(t(p),{source:s("name"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(t(w),{"model-value":a.value.name,placeholder:"仅用于编辑器内识别","onUpdate:modelValue":n[0]||(n[0]=i=>a.value={...a.value,name:String(i)})},null,8,["model-value"])]),_:1}),e(t(_),{orientation:"vertical"},{default:o(()=>[e(t(r),{class:"text-xs text-zinc-500"},m({default:o(()=>[d(" "+f(u("content")),1)]),_:2},[s("content")?{name:"tooltip",fn:o(()=>[e(t(p),{source:s("content"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(t($),{markdown:"",multiline:"","model-value":a.value.content,"onUpdate:modelValue":n[1]||(n[1]=i=>a.value={...a.value,content:i})},null,8,["model-value"])]),_:1})]))}});export{C as default};
1
+ import{d as x,b as k,aN as g,c as S,g as e,w as o,u as t,o as V,h as r,i as m,j as d,t as f,k as p,a5 as w,_,m as $,x as h,y}from"./index-x-77enex.js";const z={class:"flex flex-col gap-4"},C=x({name:"ShwfedMarkdownItemConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(v){const a=k(v,"modelValue"),c=g(),u=l=>h(c,l)??l,s=l=>y(c,l);return(l,n)=>(V(),S("div",z,[e(t(_),{orientation:"vertical"},{default:o(()=>[e(t(r),{class:"text-xs text-zinc-500"},m({default:o(()=>[d(" "+f(u("name")),1)]),_:2},[s("name")?{name:"tooltip",fn:o(()=>[e(t(p),{source:s("name"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(t(w),{"model-value":a.value.name,placeholder:"仅用于编辑器内识别","onUpdate:modelValue":n[0]||(n[0]=i=>a.value={...a.value,name:String(i)})},null,8,["model-value"])]),_:1}),e(t(_),{orientation:"vertical"},{default:o(()=>[e(t(r),{class:"text-xs text-zinc-500"},m({default:o(()=>[d(" "+f(u("content")),1)]),_:2},[s("content")?{name:"tooltip",fn:o(()=>[e(t(p),{source:s("content"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(t($),{markdown:"",multiline:"","model-value":a.value.content,"onUpdate:modelValue":n[1]||(n[1]=i=>a.value={...a.value,content:i})},null,8,["model-value"])]),_:1})]))}});export{C as default};
@@ -1 +1 @@
1
- import{d as $,b,J as S,c as m,g as e,w as a,u as l,o as _,h as f,i as v,j as i,t as r,k as p,l as V,_ as x,K as y,L as h,M as w,N,F as z,v as D,O as F,x as M,y as O}from"./index-D-VR1i8D.js";const T={class:"flex flex-col gap-3"},B=$({name:"ShwfedNavigationActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(g){const t=b(g,"modelValue"),c=S(()=>{}),d=o=>M(c,o)??o,n=o=>O(c,o),k=[{value:"_self",label:"当前页面打开"},{value:"_blank",label:"新页面打开"}];return(o,u)=>(_(),m("div",T,[e(l(x),{orientation:"vertical"},{default:a(()=>[e(l(f),{class:"text-xs text-zinc-500"},v({default:a(()=>[i(" "+r(d("url")),1)]),_:2},[n("url")?{name:"tooltip",fn:a(()=>[e(l(p),{source:n("url"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(l(V),{"model-value":t.value.url??"",placeholder:"例:'/detail/' + string(row.id)","result-type":"string",class:"min-h-10","onUpdate:modelValue":u[0]||(u[0]=s=>t.value={...t.value,url:s})},null,8,["model-value"])]),_:1}),e(l(x),{orientation:"vertical"},{default:a(()=>[e(l(f),{class:"text-xs text-zinc-500"},v({default:a(()=>[i(" "+r(d("mode")),1)]),_:2},[n("mode")?{name:"tooltip",fn:a(()=>[e(l(p),{source:n("mode"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(l(y),{"model-value":t.value.mode??"_self","onUpdate:modelValue":u[1]||(u[1]=s=>t.value={...t.value,mode:s})},{default:a(()=>[e(l(h),{class:"w-full"},{default:a(()=>[e(l(w))]),_:1}),e(l(N),null,{default:a(()=>[(_(),m(z,null,D(k,s=>e(l(F),{key:s.value,value:s.value},{default:a(()=>[i(r(s.label),1)]),_:2},1032,["value"])),64))]),_:1})]),_:1},8,["model-value"])]),_:1})]))}});export{B as default};
1
+ import{d as $,b,J as S,c as m,g as e,w as a,u as l,o as _,h as f,i as v,j as i,t as r,k as p,l as V,_ as x,K as y,L as h,M as w,N,F as z,v as D,O as F,x as M,y as O}from"./index-x-77enex.js";const T={class:"flex flex-col gap-3"},B=$({name:"ShwfedNavigationActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(g){const t=b(g,"modelValue"),c=S(()=>{}),d=o=>M(c,o)??o,n=o=>O(c,o),k=[{value:"_self",label:"当前页面打开"},{value:"_blank",label:"新页面打开"}];return(o,u)=>(_(),m("div",T,[e(l(x),{orientation:"vertical"},{default:a(()=>[e(l(f),{class:"text-xs text-zinc-500"},v({default:a(()=>[i(" "+r(d("url")),1)]),_:2},[n("url")?{name:"tooltip",fn:a(()=>[e(l(p),{source:n("url"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(l(V),{"model-value":t.value.url??"",placeholder:"例:'/detail/' + string(row.id)","result-type":"string",class:"min-h-10","onUpdate:modelValue":u[0]||(u[0]=s=>t.value={...t.value,url:s})},null,8,["model-value"])]),_:1}),e(l(x),{orientation:"vertical"},{default:a(()=>[e(l(f),{class:"text-xs text-zinc-500"},v({default:a(()=>[i(" "+r(d("mode")),1)]),_:2},[n("mode")?{name:"tooltip",fn:a(()=>[e(l(p),{source:n("mode"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),e(l(y),{"model-value":t.value.mode??"_self","onUpdate:modelValue":u[1]||(u[1]=s=>t.value={...t.value,mode:s})},{default:a(()=>[e(l(h),{class:"w-full"},{default:a(()=>[e(l(w))]),_:1}),e(l(N),null,{default:a(()=>[(_(),m(z,null,D(k,s=>e(l(F),{key:s.value,value:s.value},{default:a(()=>[i(r(s.label),1)]),_:2},1032,["value"])),64))]),_:1})]),_:1},8,["model-value"])]),_:1})]))}});export{B as default};
@@ -1 +1 @@
1
- import{d as g,b as d,x as u,aa as f,c as m,g as a,w as i,u as r,o as p,h as _,j as x,t as h,T as v,_ as T,$ as V}from"./index-D-VR1i8D.js";const w={class:"flex flex-col gap-3"},S=g({name:"ShwfedEventDispatchActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(l){const t=d(l,"modelValue"),o=u(f(),"triggers")??"触发的操作",c=V(()=>t.value.triggers??[]);function n(s){const e={...t.value};s.length===0?Reflect.deleteProperty(e,"triggers"):e.triggers=s,t.value=e}return(s,e)=>(p(),m("div",w,[a(r(T),{orientation:"vertical"},{default:i(()=>[a(r(_),{class:"text-xs text-zinc-500"},{default:i(()=>[x(h(r(o)),1)]),_:1}),a(v,{triggers:c.value,"onUpdate:triggers":n},null,8,["triggers"])]),_:1})]))}});export{S as default};
1
+ import{d as g,b as d,x as u,aa as f,c as m,g as a,w as i,u as r,o as p,h as _,j as x,t as h,T as v,_ as T,$ as V}from"./index-x-77enex.js";const w={class:"flex flex-col gap-3"},S=g({name:"ShwfedEventDispatchActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(l){const t=d(l,"modelValue"),o=u(f(),"triggers")??"触发的操作",c=V(()=>t.value.triggers??[]);function n(s){const e={...t.value};s.length===0?Reflect.deleteProperty(e,"triggers"):e.triggers=s,t.value=e}return(s,e)=>(p(),m("div",w,[a(r(T),{orientation:"vertical"},{default:i(()=>[a(r(_),{class:"text-xs text-zinc-500"},{default:i(()=>[x(h(r(o)),1)]),_:1}),a(v,{triggers:c.value,"onUpdate:triggers":n},null,8,["triggers"])]),_:1})]))}});export{S as default};
@@ -1 +1 @@
1
- import{d as z,o as y,c as w,r as T,n as V,u as e,a as U,b as $,s as j,e as F,w as l,f as v,g as s,_ as d,h as u,i as p,j as m,t as f,k as g,l as b,m as h,p as B,q as C,F as N,v as q,T as D,x as H,y as O}from"./index-D-VR1i8D.js";const R=z({__name:"FieldGroup",props:{class:{type:[Boolean,null,String,Object,Array]}},setup(_){const r=_;return(x,i)=>(y(),w("div",{"data-slot":"field-group",class:V(e(U)("group/field-group @container/field-group flex w-full flex-col gap-7 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4",r.class))},[T(x.$slots,"default")],2))}}),L={class:"grid grid-cols-2 gap-4"},P={class:"grid grid-cols-2 gap-4"},A={class:"flex items-start gap-2"},I={class:"grid grid-cols-2 gap-3"},M=z({name:"ShwfedHttpRequestConfirmActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(_){const r=$(_,"modelValue"),x=j(()=>{}),i=n=>H(x,n)??n,a=n=>O(x,n);function c(n){const t={...r.value,...n};for(const[o,k]of Object.entries(n))k===void 0&&Reflect.deleteProperty(t,o);r.value=t}const E=["onSuccess","onWarning","onError","onInfo"];function S(n,t){c({[n]:t.length===0?void 0:t})}return(n,t)=>(y(),F(e(R),null,{default:l(()=>[v("div",L,[s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("expression")),1)]),_:2},[a("expression")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("expression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(b),{"model-value":r.value.expression,multiline:"",placeholder:"例:http.post('/api/foo').body({ id: row.id })","result-type":"HttpRequest",class:"min-h-16","onUpdate:modelValue":t[0]||(t[0]=o=>c({expression:o}))},null,8,["model-value"])]),_:1}),s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("markdown")),1)]),_:2},[a("markdown")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("markdown"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(h),{markdown:"","model-value":r.value.markdown,"onUpdate:modelValue":t[1]||(t[1]=o=>c({markdown:o}))},null,8,["model-value"])]),_:1})]),v("div",P,[s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("icon")),1)]),_:2},[a("icon")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("icon"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(B),{"model-value":r.value.icon??"","onUpdate:modelValue":t[2]||(t[2]=o=>c(o.trim()===""?{icon:void 0}:{icon:o}))},null,8,["model-value"])]),_:1}),s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("color")),1)]),_:2},[a("color")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("color"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(C),{"model-value":r.value.color??"","onUpdate:modelValue":t[3]||(t[3]=o=>c(o.trim()===""?{color:void 0}:{color:o}))},null,8,["model-value"])]),_:1})]),v("div",A,[s(e(d),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("messageExpression")),1)]),_:2},[a("messageExpression")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("messageExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(b),{"model-value":r.value.messageExpression??"",placeholder:"例:string(json.message)","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":t[4]||(t[4]=o=>c({messageExpression:o===""?void 0:o}))},null,8,["model-value"])]),_:1}),s(e(d),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("resultExpression")),1)]),_:2},[a("resultExpression")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("resultExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(b),{"model-value":r.value.resultExpression??"",placeholder:"例:json.code == 0 ? 'success' : 'error'","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":t[5]||(t[5]=o=>c({resultExpression:o===""?void 0:o}))},null,8,["model-value"])]),_:1})]),v("div",I,[(y(),w(N,null,q(E,o=>s(e(d),{key:o,orientation:"vertical",class:"min-w-0"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i(o)),1)]),_:2},[a(o)?{name:"tooltip",fn:l(()=>[s(e(g),{source:a(o),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(D,{triggers:r.value[o]??[],"onUpdate:triggers":k=>S(o,k)},null,8,["triggers","onUpdate:triggers"])]),_:2},1024)),64))])]),_:1}))}});export{M as default};
1
+ import{d as z,o as y,c as w,r as T,n as V,u as e,a as U,b as $,s as j,e as F,w as l,f as v,g as s,_ as d,h as u,i as p,j as m,t as f,k as g,l as b,m as h,p as B,q as C,F as N,v as q,T as D,x as H,y as O}from"./index-x-77enex.js";const R=z({__name:"FieldGroup",props:{class:{type:[Boolean,null,String,Object,Array]}},setup(_){const r=_;return(x,i)=>(y(),w("div",{"data-slot":"field-group",class:V(e(U)("group/field-group @container/field-group flex w-full flex-col gap-7 data-[slot=checkbox-group]:gap-3 *:data-[slot=field-group]:gap-4",r.class))},[T(x.$slots,"default")],2))}}),L={class:"grid grid-cols-2 gap-4"},P={class:"grid grid-cols-2 gap-4"},A={class:"flex items-start gap-2"},I={class:"grid grid-cols-2 gap-3"},M=z({name:"ShwfedHttpRequestConfirmActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(_){const r=$(_,"modelValue"),x=j(()=>{}),i=n=>H(x,n)??n,a=n=>O(x,n);function c(n){const t={...r.value,...n};for(const[o,k]of Object.entries(n))k===void 0&&Reflect.deleteProperty(t,o);r.value=t}const E=["onSuccess","onWarning","onError","onInfo"];function S(n,t){c({[n]:t.length===0?void 0:t})}return(n,t)=>(y(),F(e(R),null,{default:l(()=>[v("div",L,[s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("expression")),1)]),_:2},[a("expression")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("expression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(b),{"model-value":r.value.expression,multiline:"",placeholder:"例:http.post('/api/foo').body({ id: row.id })","result-type":"HttpRequest",class:"min-h-16","onUpdate:modelValue":t[0]||(t[0]=o=>c({expression:o}))},null,8,["model-value"])]),_:1}),s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("markdown")),1)]),_:2},[a("markdown")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("markdown"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(h),{markdown:"","model-value":r.value.markdown,"onUpdate:modelValue":t[1]||(t[1]=o=>c({markdown:o}))},null,8,["model-value"])]),_:1})]),v("div",P,[s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("icon")),1)]),_:2},[a("icon")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("icon"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(B),{"model-value":r.value.icon??"","onUpdate:modelValue":t[2]||(t[2]=o=>c(o.trim()===""?{icon:void 0}:{icon:o}))},null,8,["model-value"])]),_:1}),s(e(d),{orientation:"vertical"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("color")),1)]),_:2},[a("color")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("color"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(C),{"model-value":r.value.color??"","onUpdate:modelValue":t[3]||(t[3]=o=>c(o.trim()===""?{color:void 0}:{color:o}))},null,8,["model-value"])]),_:1})]),v("div",A,[s(e(d),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("messageExpression")),1)]),_:2},[a("messageExpression")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("messageExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(b),{"model-value":r.value.messageExpression??"",placeholder:"例:string(json.message)","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":t[4]||(t[4]=o=>c({messageExpression:o===""?void 0:o}))},null,8,["model-value"])]),_:1}),s(e(d),{orientation:"vertical",class:"flex-1 basis-0 min-w-0"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i("resultExpression")),1)]),_:2},[a("resultExpression")?{name:"tooltip",fn:l(()=>[s(e(g),{source:a("resultExpression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(e(b),{"model-value":r.value.resultExpression??"",placeholder:"例:json.code == 0 ? 'success' : 'error'","result-type":"string","extra-vars":{json:{type:"dyn",label:"HTTP 响应体(已解析 JSON)"}},"onUpdate:modelValue":t[5]||(t[5]=o=>c({resultExpression:o===""?void 0:o}))},null,8,["model-value"])]),_:1})]),v("div",I,[(y(),w(N,null,q(E,o=>s(e(d),{key:o,orientation:"vertical",class:"min-w-0"},{default:l(()=>[s(e(u),{class:"text-xs text-zinc-500"},p({default:l(()=>[m(" "+f(i(o)),1)]),_:2},[a(o)?{name:"tooltip",fn:l(()=>[s(e(g),{source:a(o),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(D,{triggers:r.value[o]??[],"onUpdate:triggers":k=>S(o,k)},null,8,["triggers","onUpdate:triggers"])]),_:2},1024)),64))])]),_:1}))}});export{M as default};
@@ -1 +1 @@
1
- import{d as J,b as ee,P as le,Q as te,R as I,S as A,c as v,e as F,g as n,w as s,u as l,U as ae,V as oe,F as R,W as ne,t as p,f as c,X as W,Y as H,Z as se,$ as x,a0 as ie,a1 as h,o as d,a2 as j,a3 as K,I as O,a4 as Y,h as B,i as b,j as U,k as V,m as de,_,a5 as P,x as ue,y as ve,a6 as ce,a7 as re,a8 as me,a9 as fe}from"./index-D-VR1i8D.js";const pe={key:0,class:"flex min-h-96 items-center justify-center p-8 text-sm text-zinc-400"},xe={key:1},ke={key:2,class:"p-6 text-sm text-red-500"},ye={key:2,class:"flex flex-col gap-4"},ge={class:"grid grid-cols-2 gap-4"},Ie={key:0,class:"flex gap-2 min-h-96"},Be={class:"flex w-56 shrink-0 flex-col"},be={class:"flex flex-1 flex-col gap-2"},Ue={class:"flex-1"},Ve={key:1,class:"flex flex-col gap-2"},_e={class:"h-96"},De=J({name:"ShwfedModalLayoutActionConfig",__name:"config",props:se({configure:{type:Function}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(L){const i=ee(L,"modelValue"),X=L,D=x(()=>X.configure??(()=>{})),E=le(()=>{}),k=a=>ue(E,a)??a,r=a=>ve(E,a),q=x({get:()=>i.value.slot??ce(),set:a=>{i.value={...i.value,slot:a}}}),t=te(q,{configure:D.value});function Q(a){i.value={...i.value,modalTitle:a}}function S(a,e){const o=e.trim(),g={...i.value};o.length===0?Reflect.deleteProperty(g,a):g[a]=o,i.value=g}function T(){const a=t.layouts.value;t.layouts.value=[...a,{name:"新布局",layout:{columns:1,placements:{}}}],t.activeLayoutIndex.value=a.length}function M(a,e){t.addBlock(a,e)}function z(a){t.removeBlock(a)}function $(a){t.removeBlocks(a)}const u=ie(null),m=x(()=>{const a=u.value;return a?t.blocks.value.find(e=>e.id===a)??null:null}),w=x(()=>{const a=m.value;return a?re()?.(a.type,a.compatibilityDate)??null:null});function C(a){u.value=a}function Z(){u.value=null}I(()=>t.blocks.value.map(a=>a.id),a=>{const e=u.value;e&&!a.includes(e)&&(u.value=null)});function G(a){const e=u.value;e&&t.updateBlock(e,a)}const N=h(me,null);if(N){const a=N.add();I(m,e=>{e?(a.label.value=t.getBlockLabel(e),a.back.value=Z):(a.label.value=null,a.back.value=null)},{immediate:!0}),A(()=>{a.dispose()})}const f=h(fe,null),y=x(()=>f?.target.value??null);return I(u,a=>{f?.drilled&&(f.drilled.value=!!a)},{immediate:!0}),A(()=>{f?.drilled&&(f.drilled.value=!1)}),(a,e)=>(d(),v(R,null,[y.value&&!u.value?(d(),F(ae,{key:0,to:y.value},[n(l(K),{class:"flex-1"},{default:s(()=>[n(j,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[0]||(e[0]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[1]||(e[1]=o=>{l(t).activeLayoutIndex.value=o})},null,8,["model-value","active-index"])]),_:1}),n(l(Y),{variant:"ghost",size:"sm",onClick:e[2]||(e[2]=o=>T())},{default:s(()=>[n(l(O),{icon:"fluent:add-20-regular",class:"size-4"}),e[17]||(e[17]=c("span",null,"新增布局",-1))]),_:1})],8,["to"])):oe("",!0),u.value?(d(),v(R,{key:1},[m.value?w.value?(d(),v("div",xe,[(d(),F(ne(w.value.config),{"model-value":m.value,configure:D.value,"onUpdate:modelValue":e[3]||(e[3]=o=>G(o))},null,8,["model-value","configure"]))])):(d(),v("div",ke," 未注册的块类型:"+p(m.value.type)+"@"+p(m.value.compatibilityDate),1)):(d(),v("div",pe," 块已不存在 "))],64)):(d(),v("div",ye,[n(l(_),{orientation:"vertical"},{default:s(()=>[n(l(B),{class:"text-xs text-zinc-500"},b({default:s(()=>[U(" "+p(k("modalTitle")),1)]),_:2},[r("modalTitle")?{name:"tooltip",fn:s(()=>[n(l(V),{source:r("modalTitle"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),n(l(de),{markdown:"","model-value":i.value.modalTitle,"translate-hint":k("modalTitle"),"onUpdate:modelValue":Q},null,8,["model-value","translate-hint"])]),_:1}),c("div",ge,[n(l(_),{orientation:"vertical"},{default:s(()=>[n(l(B),{class:"text-xs text-zinc-500"},b({default:s(()=>[U(" "+p(k("modalWidth")),1)]),_:2},[r("modalWidth")?{name:"tooltip",fn:s(()=>[n(l(V),{source:r("modalWidth"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),n(l(P),{"model-value":i.value.modalWidth??"",placeholder:"例:720px / 60vw","onUpdate:modelValue":e[4]||(e[4]=o=>S("modalWidth",String(o)))},null,8,["model-value"])]),_:1}),n(l(_),{orientation:"vertical"},{default:s(()=>[n(l(B),{class:"text-xs text-zinc-500"},b({default:s(()=>[U(" "+p(k("modalMinHeight")),1)]),_:2},[r("modalMinHeight")?{name:"tooltip",fn:s(()=>[n(l(V),{source:r("modalMinHeight"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),n(l(P),{"model-value":i.value.modalMinHeight??"",placeholder:"例:400px / 60vh","onUpdate:modelValue":e[5]||(e[5]=o=>S("modalMinHeight",String(o)))},null,8,["model-value"])]),_:1})]),y.value?(d(),v("div",Ve,[n(W,{"model-value":l(t).layouts.value,index:l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[13]||(e[13]=o=>{l(t).layouts.value=o})},null,8,["model-value","index"]),c("div",_e,[n(H,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"selected-item-ids":l(t).selectedBlockIds.value,items:l(t).blocks.value,"find-entry":l(t).findBlockMeta,"get-item-label":l(t).getBlockLabel,"picker-entries":l(t).pickerEntries.value,"can-delete":!0,"item-noun":"块","onUpdate:modelValue":e[14]||(e[14]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[15]||(e[15]=o=>{l(t).activeLayoutIndex.value=o}),"onUpdate:selectedItemIds":e[16]||(e[16]=o=>{l(t).selectedBlockIds.value=o}),onAddNew:M,onDrillDown:C,onDeleteItem:z,onDeleteItems:$},null,8,["model-value","active-index","selected-item-ids","items","find-entry","get-item-label","picker-entries"])])])):(d(),v("div",Ie,[c("div",Be,[n(l(K),{class:"flex-1"},{default:s(()=>[n(j,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[6]||(e[6]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[7]||(e[7]=o=>{l(t).activeLayoutIndex.value=o})},null,8,["model-value","active-index"])]),_:1}),n(l(Y),{variant:"ghost",size:"sm",onClick:e[8]||(e[8]=o=>T())},{default:s(()=>[n(l(O),{icon:"fluent:add-20-regular",class:"size-4"}),e[18]||(e[18]=c("span",null,"新增布局",-1))]),_:1})]),c("div",be,[n(W,{"model-value":l(t).layouts.value,index:l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[9]||(e[9]=o=>{l(t).layouts.value=o})},null,8,["model-value","index"]),c("div",Ue,[n(H,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"selected-item-ids":l(t).selectedBlockIds.value,items:l(t).blocks.value,"find-entry":l(t).findBlockMeta,"get-item-label":l(t).getBlockLabel,"picker-entries":l(t).pickerEntries.value,"can-delete":!0,"item-noun":"块","onUpdate:modelValue":e[10]||(e[10]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[11]||(e[11]=o=>{l(t).activeLayoutIndex.value=o}),"onUpdate:selectedItemIds":e[12]||(e[12]=o=>{l(t).selectedBlockIds.value=o}),onAddNew:M,onDrillDown:C,onDeleteItem:z,onDeleteItems:$},null,8,["model-value","active-index","selected-item-ids","items","find-entry","get-item-label","picker-entries"])])])]))]))],64))}});export{De as default};
1
+ import{d as J,b as ee,P as le,Q as te,R as I,S as A,c as v,e as F,g as n,w as s,u as l,U as ae,V as oe,F as R,W as ne,t as p,f as c,X as W,Y as H,Z as se,$ as x,a0 as ie,a1 as h,o as d,a2 as j,a3 as K,I as O,a4 as Y,h as B,i as b,j as U,k as V,m as de,_,a5 as P,x as ue,y as ve,a6 as ce,a7 as re,a8 as me,a9 as fe}from"./index-x-77enex.js";const pe={key:0,class:"flex min-h-96 items-center justify-center p-8 text-sm text-zinc-400"},xe={key:1},ke={key:2,class:"p-6 text-sm text-red-500"},ye={key:2,class:"flex flex-col gap-4"},ge={class:"grid grid-cols-2 gap-4"},Ie={key:0,class:"flex gap-2 min-h-96"},Be={class:"flex w-56 shrink-0 flex-col"},be={class:"flex flex-1 flex-col gap-2"},Ue={class:"flex-1"},Ve={key:1,class:"flex flex-col gap-2"},_e={class:"h-96"},De=J({name:"ShwfedModalLayoutActionConfig",__name:"config",props:se({configure:{type:Function}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(L){const i=ee(L,"modelValue"),X=L,D=x(()=>X.configure??(()=>{})),E=le(()=>{}),k=a=>ue(E,a)??a,r=a=>ve(E,a),q=x({get:()=>i.value.slot??ce(),set:a=>{i.value={...i.value,slot:a}}}),t=te(q,{configure:D.value});function Q(a){i.value={...i.value,modalTitle:a}}function S(a,e){const o=e.trim(),g={...i.value};o.length===0?Reflect.deleteProperty(g,a):g[a]=o,i.value=g}function T(){const a=t.layouts.value;t.layouts.value=[...a,{name:"新布局",layout:{columns:1,placements:{}}}],t.activeLayoutIndex.value=a.length}function M(a,e){t.addBlock(a,e)}function z(a){t.removeBlock(a)}function $(a){t.removeBlocks(a)}const u=ie(null),m=x(()=>{const a=u.value;return a?t.blocks.value.find(e=>e.id===a)??null:null}),w=x(()=>{const a=m.value;return a?re()?.(a.type,a.compatibilityDate)??null:null});function C(a){u.value=a}function Z(){u.value=null}I(()=>t.blocks.value.map(a=>a.id),a=>{const e=u.value;e&&!a.includes(e)&&(u.value=null)});function G(a){const e=u.value;e&&t.updateBlock(e,a)}const N=h(me,null);if(N){const a=N.add();I(m,e=>{e?(a.label.value=t.getBlockLabel(e),a.back.value=Z):(a.label.value=null,a.back.value=null)},{immediate:!0}),A(()=>{a.dispose()})}const f=h(fe,null),y=x(()=>f?.target.value??null);return I(u,a=>{f?.drilled&&(f.drilled.value=!!a)},{immediate:!0}),A(()=>{f?.drilled&&(f.drilled.value=!1)}),(a,e)=>(d(),v(R,null,[y.value&&!u.value?(d(),F(ae,{key:0,to:y.value},[n(l(K),{class:"flex-1"},{default:s(()=>[n(j,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[0]||(e[0]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[1]||(e[1]=o=>{l(t).activeLayoutIndex.value=o})},null,8,["model-value","active-index"])]),_:1}),n(l(Y),{variant:"ghost",size:"sm",onClick:e[2]||(e[2]=o=>T())},{default:s(()=>[n(l(O),{icon:"fluent:add-20-regular",class:"size-4"}),e[17]||(e[17]=c("span",null,"新增布局",-1))]),_:1})],8,["to"])):oe("",!0),u.value?(d(),v(R,{key:1},[m.value?w.value?(d(),v("div",xe,[(d(),F(ne(w.value.config),{"model-value":m.value,configure:D.value,"onUpdate:modelValue":e[3]||(e[3]=o=>G(o))},null,8,["model-value","configure"]))])):(d(),v("div",ke," 未注册的块类型:"+p(m.value.type)+"@"+p(m.value.compatibilityDate),1)):(d(),v("div",pe," 块已不存在 "))],64)):(d(),v("div",ye,[n(l(_),{orientation:"vertical"},{default:s(()=>[n(l(B),{class:"text-xs text-zinc-500"},b({default:s(()=>[U(" "+p(k("modalTitle")),1)]),_:2},[r("modalTitle")?{name:"tooltip",fn:s(()=>[n(l(V),{source:r("modalTitle"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),n(l(de),{markdown:"","model-value":i.value.modalTitle,"translate-hint":k("modalTitle"),"onUpdate:modelValue":Q},null,8,["model-value","translate-hint"])]),_:1}),c("div",ge,[n(l(_),{orientation:"vertical"},{default:s(()=>[n(l(B),{class:"text-xs text-zinc-500"},b({default:s(()=>[U(" "+p(k("modalWidth")),1)]),_:2},[r("modalWidth")?{name:"tooltip",fn:s(()=>[n(l(V),{source:r("modalWidth"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),n(l(P),{"model-value":i.value.modalWidth??"",placeholder:"例:720px / 60vw","onUpdate:modelValue":e[4]||(e[4]=o=>S("modalWidth",String(o)))},null,8,["model-value"])]),_:1}),n(l(_),{orientation:"vertical"},{default:s(()=>[n(l(B),{class:"text-xs text-zinc-500"},b({default:s(()=>[U(" "+p(k("modalMinHeight")),1)]),_:2},[r("modalMinHeight")?{name:"tooltip",fn:s(()=>[n(l(V),{source:r("modalMinHeight"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),n(l(P),{"model-value":i.value.modalMinHeight??"",placeholder:"例:400px / 60vh","onUpdate:modelValue":e[5]||(e[5]=o=>S("modalMinHeight",String(o)))},null,8,["model-value"])]),_:1})]),y.value?(d(),v("div",Ve,[n(W,{"model-value":l(t).layouts.value,index:l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[13]||(e[13]=o=>{l(t).layouts.value=o})},null,8,["model-value","index"]),c("div",_e,[n(H,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"selected-item-ids":l(t).selectedBlockIds.value,items:l(t).blocks.value,"find-entry":l(t).findBlockMeta,"get-item-label":l(t).getBlockLabel,"picker-entries":l(t).pickerEntries.value,"can-delete":!0,"item-noun":"块","onUpdate:modelValue":e[14]||(e[14]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[15]||(e[15]=o=>{l(t).activeLayoutIndex.value=o}),"onUpdate:selectedItemIds":e[16]||(e[16]=o=>{l(t).selectedBlockIds.value=o}),onAddNew:M,onDrillDown:C,onDeleteItem:z,onDeleteItems:$},null,8,["model-value","active-index","selected-item-ids","items","find-entry","get-item-label","picker-entries"])])])):(d(),v("div",Ie,[c("div",Be,[n(l(K),{class:"flex-1"},{default:s(()=>[n(j,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[6]||(e[6]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[7]||(e[7]=o=>{l(t).activeLayoutIndex.value=o})},null,8,["model-value","active-index"])]),_:1}),n(l(Y),{variant:"ghost",size:"sm",onClick:e[8]||(e[8]=o=>T())},{default:s(()=>[n(l(O),{icon:"fluent:add-20-regular",class:"size-4"}),e[18]||(e[18]=c("span",null,"新增布局",-1))]),_:1})]),c("div",be,[n(W,{"model-value":l(t).layouts.value,index:l(t).activeLayoutIndex.value,"onUpdate:modelValue":e[9]||(e[9]=o=>{l(t).layouts.value=o})},null,8,["model-value","index"]),c("div",Ue,[n(H,{"model-value":l(t).layouts.value,"active-index":l(t).activeLayoutIndex.value,"selected-item-ids":l(t).selectedBlockIds.value,items:l(t).blocks.value,"find-entry":l(t).findBlockMeta,"get-item-label":l(t).getBlockLabel,"picker-entries":l(t).pickerEntries.value,"can-delete":!0,"item-noun":"块","onUpdate:modelValue":e[10]||(e[10]=o=>{l(t).layouts.value=o}),"onUpdate:activeIndex":e[11]||(e[11]=o=>{l(t).activeLayoutIndex.value=o}),"onUpdate:selectedItemIds":e[12]||(e[12]=o=>{l(t).selectedBlockIds.value=o}),onAddNew:M,onDrillDown:C,onDeleteItem:z,onDeleteItems:$},null,8,["model-value","active-index","selected-item-ids","items","find-entry","get-item-label","picker-entries"])])])]))]))],64))}});export{De as default};
@@ -1 +1 @@
1
- import{d as _,b as y,B as x,A as b,c,f as i,g as n,w as o,u as a,o as l,C as v,I as u,D as g,E as D,F as h,v as w,e as B,G as C,t as p,H as S}from"./index-D-VR1i8D.js";const $={class:"flex flex-col gap-3"},k={class:"flex-1"},E={class:"ml-auto text-xs tabular-nums text-zinc-400"},I=_({name:"ShwfedPrototypeActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(m){const r=y(m,"modelValue"),f=(()=>{const s=new Map;for(const e of x){if(e.type===b||e.deprecated)continue;const t=s.get(e.type);(!t||e.compatibilityDate>t.compatibilityDate)&&s.set(e.type,{type:e.type,compatibilityDate:e.compatibilityDate,name:e.metadata.name,icon:e.metadata.icon})}return[...s.values()].sort((e,t)=>e.name.localeCompare(t.name,"zh"))})();function d(s,e){r.value={type:s,compatibilityDate:e}}return(s,e)=>(l(),c("div",$,[e[0]||(e[0]=i("p",{class:"text-xs text-zinc-500"}," 原型按钮点击后无任何副作用,用于占位。选择下方任意类型可将其转换为正式按钮 —— 此转换仅能进行一次。 ",-1)),n(a(S),null,{default:o(()=>[n(a(v),{align:"inline-start"},{default:o(()=>[n(a(u),{icon:"fluent:arrow-swap-20-regular"})]),_:1}),n(a(g),null,{default:o(()=>[n(a(D),null,{default:o(()=>[(l(!0),c(h,null,w(a(f),t=>(l(),B(a(C),{key:t.type,value:t.type,onSelect:V=>d(t.type,t.compatibilityDate)},{default:o(()=>[n(a(u),{icon:t.icon,class:"size-4 shrink-0"},null,8,["icon"]),i("span",k,p(t.name),1),i("span",E,p(t.compatibilityDate),1)]),_:2},1032,["value","onSelect"]))),128))]),_:1})]),_:1})]),_:1})]))}});export{I as default};
1
+ import{d as _,b as y,B as x,A as b,c,f as i,g as n,w as o,u as a,o as l,C as v,I as u,D as g,E as D,F as h,v as w,e as B,G as C,t as p,H as S}from"./index-x-77enex.js";const $={class:"flex flex-col gap-3"},k={class:"flex-1"},E={class:"ml-auto text-xs tabular-nums text-zinc-400"},I=_({name:"ShwfedPrototypeActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(m){const r=y(m,"modelValue"),f=(()=>{const s=new Map;for(const e of x){if(e.type===b||e.deprecated)continue;const t=s.get(e.type);(!t||e.compatibilityDate>t.compatibilityDate)&&s.set(e.type,{type:e.type,compatibilityDate:e.compatibilityDate,name:e.metadata.name,icon:e.metadata.icon})}return[...s.values()].sort((e,t)=>e.name.localeCompare(t.name,"zh"))})();function d(s,e){r.value={type:s,compatibilityDate:e}}return(s,e)=>(l(),c("div",$,[e[0]||(e[0]=i("p",{class:"text-xs text-zinc-500"}," 原型按钮点击后无任何副作用,用于占位。选择下方任意类型可将其转换为正式按钮 —— 此转换仅能进行一次。 ",-1)),n(a(S),null,{default:o(()=>[n(a(v),{align:"inline-start"},{default:o(()=>[n(a(u),{icon:"fluent:arrow-swap-20-regular"})]),_:1}),n(a(g),null,{default:o(()=>[n(a(D),null,{default:o(()=>[(l(!0),c(h,null,w(a(f),t=>(l(),B(a(C),{key:t.type,value:t.type,onSelect:V=>d(t.type,t.compatibilityDate)},{default:o(()=>[n(a(u),{icon:t.icon,class:"size-4 shrink-0"},null,8,["icon"]),i("span",k,p(t.name),1),i("span",E,p(t.compatibilityDate),1)]),_:2},1032,["value","onSelect"]))),128))]),_:1})]),_:1})]),_:1})]))}});export{I as default};
@@ -1 +1 @@
1
- import{d as v,b as S,ad as h,o as k,c as y,g as s,w as l,u as t,h as r,i as u,j as d,t as p,k as m,l as T,_ as f,T as V,x as w,y as z}from"./index-D-VR1i8D.js";const $={class:"flex flex-col gap-3"},C=v({name:"ShwfedStateWriteActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(_){const o=S(_,"modelValue"),i=h(()=>{}),c=e=>w(i,e)??e,n=e=>z(i,e);function g(e){const a={...o.value};e.length===0?Reflect.deleteProperty(a,"onSuccess"):a.onSuccess=e,o.value=a}return(e,a)=>(k(),y("div",$,[s(t(f),{orientation:"vertical"},{default:l(()=>[s(t(r),{class:"text-xs text-zinc-500"},u({default:l(()=>[d(" "+p(c("expression")),1)]),_:2},[n("expression")?{name:"tooltip",fn:l(()=>[s(t(m),{source:n("expression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(t(T),{"model-value":o.value.expression,multiline:"",placeholder:"例:{ invoices: rows, totalAmount: rows.map(r, r.amount).sum() }","result-type":"map",class:"min-h-16","onUpdate:modelValue":a[0]||(a[0]=x=>o.value={...o.value,expression:x})},null,8,["model-value"])]),_:1}),s(t(f),{orientation:"vertical"},{default:l(()=>[s(t(r),{class:"text-xs text-zinc-500"},u({default:l(()=>[d(" "+p(c("onSuccess")),1)]),_:2},[n("onSuccess")?{name:"tooltip",fn:l(()=>[s(t(m),{source:n("onSuccess"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(V,{triggers:o.value.onSuccess??[],"onUpdate:triggers":g},null,8,["triggers"])]),_:1})]))}});export{C as default};
1
+ import{d as v,b as S,ad as h,o as k,c as y,g as s,w as l,u as t,h as r,i as u,j as d,t as p,k as m,l as T,_ as f,T as V,x as w,y as z}from"./index-x-77enex.js";const $={class:"flex flex-col gap-3"},C=v({name:"ShwfedStateWriteActionConfig",__name:"config",props:{modelValue:{required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(_){const o=S(_,"modelValue"),i=h(()=>{}),c=e=>w(i,e)??e,n=e=>z(i,e);function g(e){const a={...o.value};e.length===0?Reflect.deleteProperty(a,"onSuccess"):a.onSuccess=e,o.value=a}return(e,a)=>(k(),y("div",$,[s(t(f),{orientation:"vertical"},{default:l(()=>[s(t(r),{class:"text-xs text-zinc-500"},u({default:l(()=>[d(" "+p(c("expression")),1)]),_:2},[n("expression")?{name:"tooltip",fn:l(()=>[s(t(m),{source:n("expression"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(t(T),{"model-value":o.value.expression,multiline:"",placeholder:"例:{ invoices: rows, totalAmount: rows.map(r, r.amount).sum() }","result-type":"map",class:"min-h-16","onUpdate:modelValue":a[0]||(a[0]=x=>o.value={...o.value,expression:x})},null,8,["model-value"])]),_:1}),s(t(f),{orientation:"vertical"},{default:l(()=>[s(t(r),{class:"text-xs text-zinc-500"},u({default:l(()=>[d(" "+p(c("onSuccess")),1)]),_:2},[n("onSuccess")?{name:"tooltip",fn:l(()=>[s(t(m),{source:n("onSuccess"),block:"",class:"prose prose-sm prose-zinc"},null,8,["source"])]),key:"0"}:void 0]),1024),s(V,{triggers:o.value.onSuccess??[],"onUpdate:triggers":g},null,8,["triggers"])]),_:1})]))}});export{C as default};
@@ -1 +1 @@
1
- import{d as f,aG as u,aH as m,aI as p,S as g,V as l,a1 as I,aJ as y}from"./index-D-VR1i8D.js";const w=f({name:"ShwfedActionDefinition",inheritAttrs:!1,__name:"definition",props:{actionId:{},effect:{}},setup(r){const n=r,a=u(),t=I(y,void 0),i=crypto.randomUUID(),c=import.meta.dev;let e,s=!1;function d(){!c||s||(s=!0,console.warn("[shwfed-action-definition] must be used inside <shwfed-actions>."))}function o(){if(!t){d();return}e&&e!==n.actionId&&t.unregisterAction(e,i),t.registerAction({ownerId:i,actionId:n.actionId,effect:n.effect,render:a.default}),e=n.actionId}return o(),m(()=>{o()}),p(()=>{o()}),g(()=>{!t||!e||t.unregisterAction(e,i)}),(A,_)=>l("",!0)}});export{w as _};
1
+ import{d as f,aJ as u,aK as m,aL as p,S as g,V as l,a1 as I,aM as y}from"./index-x-77enex.js";const w=f({name:"ShwfedActionDefinition",inheritAttrs:!1,__name:"definition",props:{actionId:{},effect:{}},setup(r){const n=r,a=u(),t=I(y,void 0),i=crypto.randomUUID(),c=import.meta.dev;let e,s=!1;function d(){!c||s||(s=!0,console.warn("[shwfed-action-definition] must be used inside <shwfed-actions>."))}function o(){if(!t){d();return}e&&e!==n.actionId&&t.unregisterAction(e,i),t.registerAction({ownerId:i,actionId:n.actionId,effect:n.effect,render:a.default}),e=n.actionId}return o(),m(()=>{o()}),p(()=>{o()}),g(()=>{!t||!e||t.unregisterAction(e,i)}),(A,_)=>l("",!0)}});export{w as _};