@shwfed/config 2.4.1 → 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 (128) hide show
  1. package/dist/mcp.mjs +87 -24
  2. package/dist/module.json +1 -1
  3. package/dist/preview/assets/{config-Q86AhjHq.js → config-BkytEQN5.js} +1 -1
  4. package/dist/preview/assets/{config-EKVeWrbS.js → config-CK011_jJ.js} +1 -1
  5. package/dist/preview/assets/{config-ByTxMBcK.js → config-C_bBX0wD.js} +1 -1
  6. package/dist/preview/assets/{config-DiwVK32V.js → config-Cbn8o9BY.js} +1 -1
  7. package/dist/preview/assets/{config-BovRv7Mw.js → config-DYL6kHr3.js} +1 -1
  8. package/dist/preview/assets/{config-C7xYpB3N.js → config-Dx0zHfGt.js} +1 -1
  9. package/dist/preview/assets/{config-D50Rl2n_.js → config-E-DM6b5t.js} +1 -1
  10. package/dist/preview/assets/{config-Ch5dL5lp.js → config-PjseWUbC.js} +1 -1
  11. package/dist/preview/assets/{config-CH9wsYX8.js → config-dwcdYHd4.js} +1 -1
  12. package/dist/preview/assets/{definition.vue_vue_type_script_setup_true_lang-D8NPPbjZ.js → definition.vue_vue_type_script_setup_true_lang-uJFJXxli.js} +1 -1
  13. package/dist/preview/assets/{index-65eB1l4r.css → index-7MVXgV5n.css} +1 -1
  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-Ch3JIgUQ.js → runtime-BRMGkqSr.js} +1 -1
  17. package/dist/preview/assets/{runtime-BwR_BbTu.js → runtime-CHLboM_z.js} +1 -1
  18. package/dist/preview/assets/{runtime-BQSwNpLC.js → runtime-CeHdesjP.js} +1 -1
  19. package/dist/preview/assets/{runtime-D34aQN00.js → runtime-D4_9FCLy.js} +1 -1
  20. package/dist/preview/assets/{runtime-aPt-bW3F.js → runtime-DHBTDws7.js} +1 -1
  21. package/dist/preview/assets/{runtime-a9TOQRwD.js → runtime-DJHpCLnr.js} +1 -1
  22. package/dist/preview/assets/{runtime-Cunk4vOs.js → runtime-DKq86fZU.js} +1 -1
  23. package/dist/preview/assets/{runtime-CjvZcU7X.js → runtime-DjpjaNec.js} +1 -1
  24. package/dist/preview/assets/{runtime-BP7zXnyG.js → runtime-ZQryOEKm.js} +1 -1
  25. package/dist/preview/index.html +2 -2
  26. package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/schema.d.ts +1 -1
  27. package/dist/runtime/components/form/index.vue +5 -18
  28. package/dist/runtime/components/form/schema.d.ts +2 -10
  29. package/dist/runtime/components/form/schema.js +2 -5
  30. package/dist/runtime/components/form/utils/cel-scope.d.ts +12 -3
  31. package/dist/runtime/components/form/utils/cel-scope.js +17 -18
  32. package/dist/runtime/components/form/utils/form-vars.d.ts +19 -0
  33. package/dist/runtime/components/form/utils/form-vars.js +5 -0
  34. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.date/config.vue +20 -8
  35. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.date/schema.d.ts +1 -0
  36. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.icon/config.vue +20 -8
  37. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.icon/schema.d.ts +1 -0
  38. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.number/config.vue +20 -8
  39. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.number/schema.d.ts +1 -0
  40. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.text/config.vue +20 -8
  41. package/dist/runtime/components/table/columns/2026-04-14/com.shwfed.table.column.text/schema.d.ts +1 -0
  42. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch/config.vue +20 -8
  43. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch/schema.d.ts +1 -0
  44. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch.remote/config.vue +20 -8
  45. package/dist/runtime/components/table/columns/2026-05-13/com.shwfed.table.column.switch.remote/schema.d.ts +1 -0
  46. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -0
  47. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/config.vue +20 -8
  48. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -0
  49. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.combobox-single/schema.d.ts +1 -0
  50. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.number-input/config.vue +20 -7
  51. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.number-input/schema.d.ts +1 -0
  52. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch/config.vue +20 -8
  53. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch/schema.d.ts +1 -0
  54. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch.local/config.vue +20 -8
  55. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.switch.local/schema.d.ts +1 -0
  56. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.text-input/config.vue +20 -8
  57. package/dist/runtime/components/table/columns/2026-05-20/com.shwfed.table.column.text-input/schema.d.ts +1 -0
  58. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.d.vue.ts +2 -0
  59. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.vue +20 -8
  60. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.vue.d.ts +2 -0
  61. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/schema.d.ts +1 -0
  62. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.d.vue.ts +2 -0
  63. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.vue +20 -8
  64. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.vue.d.ts +2 -0
  65. package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/schema.d.ts +1 -0
  66. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -0
  67. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/config.vue +20 -8
  68. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -0
  69. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi/schema.d.ts +1 -0
  70. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.d.vue.ts +2 -0
  71. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.vue +20 -8
  72. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.vue.d.ts +2 -0
  73. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/schema.d.ts +1 -0
  74. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.d.vue.ts +2 -0
  75. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.vue +20 -8
  76. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.vue.d.ts +2 -0
  77. package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/schema.d.ts +1 -0
  78. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -0
  79. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/config.vue +20 -8
  80. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -0
  81. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi/schema.d.ts +1 -0
  82. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.d.vue.ts +2 -0
  83. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.vue +20 -8
  84. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.vue.d.ts +2 -0
  85. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/schema.d.ts +1 -0
  86. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -0
  87. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/config.vue +20 -8
  88. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -0
  89. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single/schema.d.ts +1 -0
  90. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.d.vue.ts +2 -0
  91. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.vue +20 -8
  92. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.vue.d.ts +2 -0
  93. package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/schema.d.ts +1 -0
  94. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.d.vue.ts +2 -0
  95. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.vue +20 -7
  96. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.vue.d.ts +2 -0
  97. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/schema.d.ts +1 -0
  98. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.d.vue.ts +2 -0
  99. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.vue +20 -7
  100. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.vue.d.ts +2 -0
  101. package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/schema.d.ts +1 -0
  102. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -0
  103. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue +20 -8
  104. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -0
  105. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/schema.d.ts +1 -0
  106. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/schema.js +2 -1
  107. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -0
  108. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue +20 -8
  109. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -0
  110. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/schema.d.ts +1 -0
  111. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/schema.js +2 -1
  112. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.d.vue.ts +2 -0
  113. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.vue +20 -7
  114. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.vue.d.ts +2 -0
  115. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/schema.d.ts +1 -0
  116. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.d.vue.ts +2 -0
  117. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.vue +20 -7
  118. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.vue.d.ts +2 -0
  119. package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/schema.d.ts +1 -0
  120. package/dist/runtime/components/table/config.vue +20 -45
  121. package/dist/runtime/components/table/index.vue +22 -2
  122. package/dist/runtime/components/table/schema.d.ts +4 -2
  123. package/dist/runtime/components/table/schema.js +69 -13
  124. package/dist/runtime/components/table/utils/shared.d.ts +2 -0
  125. package/dist/runtime/components/table/utils/shared.js +10 -2
  126. package/package.json +1 -1
  127. package/dist/preview/assets/index-CIrlYN0M.js +0 -1
  128. package/dist/preview/assets/index-DUDlWaQI.js +0 -661
@@ -62,6 +62,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
62
62
  readonly message: string;
63
63
  }[]] | undefined;
64
64
  readonly nodeSelectable?: string | undefined;
65
+ readonly sortKey?: string | undefined;
65
66
  }) => any;
66
67
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
67
68
  "onUpdate:modelValue"?: ((value: {
@@ -123,6 +124,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
123
124
  readonly message: string;
124
125
  }[]] | undefined;
125
126
  readonly nodeSelectable?: string | undefined;
127
+ readonly sortKey?: string | undefined;
126
128
  }) => any) | undefined;
127
129
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
128
130
  declare const _default: typeof __VLS_export;
@@ -512,14 +512,10 @@ const derivedModel = computed({
512
512
  <Separator />
513
513
  <div class="flex flex-wrap gap-x-8 gap-y-3">
514
514
  <Field
515
- orientation="horizontal"
516
- class="w-auto gap-2"
515
+ orientation="vertical"
516
+ class="w-full max-w-xs"
517
517
  >
518
- <Switch
519
- :model-value="value.enableSorting ?? false"
520
- @update:model-value="(v) => value = { ...value, enableSorting: v }"
521
- />
522
- <FieldLabel class="text-sm text-zinc-600">
518
+ <FieldLabel class="text-xs text-zinc-500">
523
519
  <template
524
520
  v-if="fieldDescription('enableSorting')"
525
521
  #tooltip
@@ -532,6 +528,23 @@ const derivedModel = computed({
532
528
  </template>
533
529
  {{ fieldTitle("enableSorting") }}
534
530
  </FieldLabel>
531
+ <InputGroup>
532
+ <InputGroupInput
533
+ :model-value="value.sortKey"
534
+ placeholder="例:created_at"
535
+ @update:model-value="(v) => value = { ...value, sortKey: v || void 0 }"
536
+ />
537
+ <InputGroupAddon align="inline-end">
538
+ <InputGroupButton
539
+ :variant="value.enableSorting ? 'primary' : 'ghost'"
540
+ size="xs"
541
+ @click="value = { ...value, enableSorting: !value.enableSorting }"
542
+ >
543
+ <Icon :icon="value.enableSorting ? 'fluent:arrow-sort-up-16-regular' : 'fluent:arrow-sort-16-regular'" />
544
+ {{ fieldTitle("enableSorting") }}
545
+ </InputGroupButton>
546
+ </InputGroupAddon>
547
+ </InputGroup>
535
548
  </Field>
536
549
  </div>
537
550
  </div>
@@ -62,6 +62,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
62
62
  readonly message: string;
63
63
  }[]] | undefined;
64
64
  readonly nodeSelectable?: string | undefined;
65
+ readonly sortKey?: string | undefined;
65
66
  }) => any;
66
67
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
67
68
  "onUpdate:modelValue"?: ((value: {
@@ -123,6 +124,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
123
124
  readonly message: string;
124
125
  }[]] | undefined;
125
126
  readonly nodeSelectable?: string | undefined;
127
+ readonly sortKey?: string | undefined;
126
128
  }) => any) | undefined;
127
129
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
128
130
  declare const _default: typeof __VLS_export;
@@ -68,6 +68,7 @@ export declare function schema(configure: (env: Environment) => void): Schema.St
68
68
  }>]>;
69
69
  binding: Schema.refine<string, typeof Schema.String>;
70
70
  enableSorting: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
71
+ sortKey: Schema.optional<Schema.refine<string, typeof Schema.String>>;
71
72
  size: Schema.optional<Schema.refine<number, Schema.filter<typeof Schema.Number>>>;
72
73
  grow: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
73
74
  tooltip: Schema.optional<Schema.TupleType<readonly [Schema.Struct<{
@@ -89,6 +89,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
89
89
  }[];
90
90
  };
91
91
  readonly enableSorting?: boolean | undefined;
92
+ readonly sortKey?: string | undefined;
92
93
  }) => any;
93
94
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
94
95
  "onUpdate:modelValue"?: ((value: {
@@ -177,6 +178,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
177
178
  }[];
178
179
  };
179
180
  readonly enableSorting?: boolean | undefined;
181
+ readonly sortKey?: string | undefined;
180
182
  }) => any) | undefined;
181
183
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
182
184
  declare const _default: typeof __VLS_export;
@@ -4,7 +4,6 @@ import { Icon } from "@iconify/vue";
4
4
  import { Button } from "../../../../ui/button";
5
5
  import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from "../../../../ui/dropdown-menu";
6
6
  import { ExpressionEditor } from "../../../../ui/expression-editor";
7
- import { Switch } from "../../../../ui/switch";
8
7
  import { Separator } from "../../../../ui/separator";
9
8
  import { Field, FieldLabel } from "../../../../ui/field";
10
9
  import { Locale } from "../../../../ui/locale";
@@ -905,14 +904,10 @@ function setItemKeywords(index, text) {
905
904
  <Separator />
906
905
  <div class="flex flex-wrap gap-x-8 gap-y-3">
907
906
  <Field
908
- orientation="horizontal"
909
- class="w-auto gap-2"
907
+ orientation="vertical"
908
+ class="w-full max-w-xs"
910
909
  >
911
- <Switch
912
- :model-value="value.enableSorting ?? false"
913
- @update:model-value="(v) => value = { ...value, enableSorting: v }"
914
- />
915
- <FieldLabel class="text-sm text-zinc-600">
910
+ <FieldLabel class="text-xs text-zinc-500">
916
911
  <template
917
912
  v-if="fieldDescription('enableSorting')"
918
913
  #tooltip
@@ -925,6 +920,23 @@ function setItemKeywords(index, text) {
925
920
  </template>
926
921
  {{ fieldTitle("enableSorting") }}
927
922
  </FieldLabel>
923
+ <InputGroup>
924
+ <InputGroupInput
925
+ :model-value="value.sortKey"
926
+ placeholder="例:created_at"
927
+ @update:model-value="(v) => value = { ...value, sortKey: v || void 0 }"
928
+ />
929
+ <InputGroupAddon align="inline-end">
930
+ <InputGroupButton
931
+ :variant="value.enableSorting ? 'primary' : 'ghost'"
932
+ size="xs"
933
+ @click="value = { ...value, enableSorting: !value.enableSorting }"
934
+ >
935
+ <Icon :icon="value.enableSorting ? 'fluent:arrow-sort-up-16-regular' : 'fluent:arrow-sort-16-regular'" />
936
+ {{ fieldTitle("enableSorting") }}
937
+ </InputGroupButton>
938
+ </InputGroupAddon>
939
+ </InputGroup>
928
940
  </Field>
929
941
  </div>
930
942
  </div>
@@ -89,6 +89,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
89
89
  }[];
90
90
  };
91
91
  readonly enableSorting?: boolean | undefined;
92
+ readonly sortKey?: string | undefined;
92
93
  }) => any;
93
94
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
94
95
  "onUpdate:modelValue"?: ((value: {
@@ -177,6 +178,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
177
178
  }[];
178
179
  };
179
180
  readonly enableSorting?: boolean | undefined;
181
+ readonly sortKey?: string | undefined;
180
182
  }) => any) | undefined;
181
183
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
182
184
  declare const _default: typeof __VLS_export;
@@ -172,6 +172,7 @@ export declare function schema(configure: (env: Environment) => void): Schema.St
172
172
  disabled: Schema.optional<Schema.Schema<string, string, never>>;
173
173
  readonly: Schema.optional<Schema.Schema<string, string, never>>;
174
174
  enableSorting: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
175
+ sortKey: Schema.optional<Schema.refine<string, typeof Schema.String>>;
175
176
  size: Schema.optional<Schema.refine<number, Schema.filter<typeof Schema.Number>>>;
176
177
  grow: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
177
178
  tooltip: Schema.optional<Schema.TupleType<readonly [Schema.Struct<{
@@ -189,6 +189,7 @@ export function schema(configure) {
189
189
  description: "\u8FD4\u56DE `true` \u65F6\u4EC5\u4EE5\u7EAF\u6587\u672C\u5C55\u793A\u5F53\u524D\u5DF2\u9009\u9879\u7684\u6807\u7B7E"
190
190
  })),
191
191
  enableSorting: display.enableSorting,
192
+ sortKey: display.sortKey,
192
193
  size: display.size,
193
194
  grow: display.grow,
194
195
  tooltip: display.tooltip,
@@ -207,7 +208,7 @@ export const migrateFrom = [
207
208
  { type: "com.shwfed.table.column.combobox-multi", compatibilityDate: "2026-05-26" },
208
209
  { type: "com.shwfed.table.column.combobox-multi.remote", compatibilityDate: "2026-05-26" }
209
210
  ];
210
- const CARRY = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "placeholder", "hidden", "disabled", "readonly"];
211
+ const CARRY = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "sortKey", "placeholder", "hidden", "disabled", "readonly"];
211
212
  export const migrate = (prev) => Effect.try({
212
213
  try: () => {
213
214
  if (!prev || typeof prev !== "object") {
@@ -89,6 +89,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
89
89
  }[];
90
90
  };
91
91
  readonly enableSorting?: boolean | undefined;
92
+ readonly sortKey?: string | undefined;
92
93
  }) => any;
93
94
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
94
95
  "onUpdate:modelValue"?: ((value: {
@@ -177,6 +178,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
177
178
  }[];
178
179
  };
179
180
  readonly enableSorting?: boolean | undefined;
181
+ readonly sortKey?: string | undefined;
180
182
  }) => any) | undefined;
181
183
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
182
184
  declare const _default: typeof __VLS_export;
@@ -4,7 +4,6 @@ import { Icon } from "@iconify/vue";
4
4
  import { Button } from "../../../../ui/button";
5
5
  import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from "../../../../ui/dropdown-menu";
6
6
  import { ExpressionEditor } from "../../../../ui/expression-editor";
7
- import { Switch } from "../../../../ui/switch";
8
7
  import { Separator } from "../../../../ui/separator";
9
8
  import { Field, FieldLabel } from "../../../../ui/field";
10
9
  import { Locale } from "../../../../ui/locale";
@@ -905,14 +904,10 @@ function setItemKeywords(index, text) {
905
904
  <Separator />
906
905
  <div class="flex flex-wrap gap-x-8 gap-y-3">
907
906
  <Field
908
- orientation="horizontal"
909
- class="w-auto gap-2"
907
+ orientation="vertical"
908
+ class="w-full max-w-xs"
910
909
  >
911
- <Switch
912
- :model-value="value.enableSorting ?? false"
913
- @update:model-value="(v) => value = { ...value, enableSorting: v }"
914
- />
915
- <FieldLabel class="text-sm text-zinc-600">
910
+ <FieldLabel class="text-xs text-zinc-500">
916
911
  <template
917
912
  v-if="fieldDescription('enableSorting')"
918
913
  #tooltip
@@ -925,6 +920,23 @@ function setItemKeywords(index, text) {
925
920
  </template>
926
921
  {{ fieldTitle("enableSorting") }}
927
922
  </FieldLabel>
923
+ <InputGroup>
924
+ <InputGroupInput
925
+ :model-value="value.sortKey"
926
+ placeholder="例:created_at"
927
+ @update:model-value="(v) => value = { ...value, sortKey: v || void 0 }"
928
+ />
929
+ <InputGroupAddon align="inline-end">
930
+ <InputGroupButton
931
+ :variant="value.enableSorting ? 'primary' : 'ghost'"
932
+ size="xs"
933
+ @click="value = { ...value, enableSorting: !value.enableSorting }"
934
+ >
935
+ <Icon :icon="value.enableSorting ? 'fluent:arrow-sort-up-16-regular' : 'fluent:arrow-sort-16-regular'" />
936
+ {{ fieldTitle("enableSorting") }}
937
+ </InputGroupButton>
938
+ </InputGroupAddon>
939
+ </InputGroup>
928
940
  </Field>
929
941
  </div>
930
942
  </div>
@@ -89,6 +89,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
89
89
  }[];
90
90
  };
91
91
  readonly enableSorting?: boolean | undefined;
92
+ readonly sortKey?: string | undefined;
92
93
  }) => any;
93
94
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
94
95
  "onUpdate:modelValue"?: ((value: {
@@ -177,6 +178,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
177
178
  }[];
178
179
  };
179
180
  readonly enableSorting?: boolean | undefined;
181
+ readonly sortKey?: string | undefined;
180
182
  }) => any) | undefined;
181
183
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
182
184
  declare const _default: typeof __VLS_export;
@@ -172,6 +172,7 @@ export declare function schema(configure: (env: Environment) => void): Schema.St
172
172
  disabled: Schema.optional<Schema.Schema<string, string, never>>;
173
173
  readonly: Schema.optional<Schema.Schema<string, string, never>>;
174
174
  enableSorting: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
175
+ sortKey: Schema.optional<Schema.refine<string, typeof Schema.String>>;
175
176
  size: Schema.optional<Schema.refine<number, Schema.filter<typeof Schema.Number>>>;
176
177
  grow: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
177
178
  tooltip: Schema.optional<Schema.TupleType<readonly [Schema.Struct<{
@@ -189,6 +189,7 @@ export function schema(configure) {
189
189
  description: "\u8FD4\u56DE `true` \u65F6\u4EC5\u4EE5\u7EAF\u6587\u672C\u5C55\u793A\u5F53\u524D\u9009\u9879\u7684\u6807\u7B7E"
190
190
  })),
191
191
  enableSorting: display.enableSorting,
192
+ sortKey: display.sortKey,
192
193
  size: display.size,
193
194
  grow: display.grow,
194
195
  tooltip: display.tooltip,
@@ -207,7 +208,7 @@ export const migrateFrom = [
207
208
  { type: "com.shwfed.table.column.combobox-single", compatibilityDate: "2026-05-26" },
208
209
  { type: "com.shwfed.table.column.combobox-single.remote", compatibilityDate: "2026-05-26" }
209
210
  ];
210
- const CARRY = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "placeholder", "hidden", "disabled", "readonly"];
211
+ const CARRY = ["id", "groupId", "title", "size", "grow", "tooltip", "enableSorting", "sortKey", "placeholder", "hidden", "disabled", "readonly"];
211
212
  export const migrate = (prev) => Effect.try({
212
213
  try: () => {
213
214
  if (!prev || typeof prev !== "object") {
@@ -64,6 +64,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
64
64
  readonly message: string;
65
65
  }[]] | undefined;
66
66
  readonly nodeSelectable?: string | undefined;
67
+ readonly sortKey?: string | undefined;
67
68
  }) => any;
68
69
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
69
70
  "onUpdate:modelValue"?: ((value: {
@@ -127,6 +128,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
127
128
  readonly message: string;
128
129
  }[]] | undefined;
129
130
  readonly nodeSelectable?: string | undefined;
131
+ readonly sortKey?: string | undefined;
130
132
  }) => any) | undefined;
131
133
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
132
134
  declare const _default: typeof __VLS_export;
@@ -606,14 +606,10 @@ const derivedModel = computed({
606
606
  <Separator />
607
607
  <div class="flex flex-wrap gap-x-8 gap-y-3">
608
608
  <Field
609
- orientation="horizontal"
610
- class="w-auto gap-2"
609
+ orientation="vertical"
610
+ class="w-full max-w-xs"
611
611
  >
612
- <Switch
613
- :model-value="value.enableSorting ?? false"
614
- @update:model-value="(v) => value = { ...value, enableSorting: v }"
615
- />
616
- <FieldLabel class="text-sm text-zinc-600">
612
+ <FieldLabel class="text-xs text-zinc-500">
617
613
  <template
618
614
  v-if="fieldDescription('enableSorting')"
619
615
  #tooltip
@@ -626,6 +622,23 @@ const derivedModel = computed({
626
622
  </template>
627
623
  {{ fieldTitle("enableSorting") }}
628
624
  </FieldLabel>
625
+ <InputGroup>
626
+ <InputGroupInput
627
+ :model-value="value.sortKey"
628
+ placeholder="例:created_at"
629
+ @update:model-value="(v) => value = { ...value, sortKey: v || void 0 }"
630
+ />
631
+ <InputGroupAddon align="inline-end">
632
+ <InputGroupButton
633
+ :variant="value.enableSorting ? 'primary' : 'ghost'"
634
+ size="xs"
635
+ @click="value = { ...value, enableSorting: !value.enableSorting }"
636
+ >
637
+ <Icon :icon="value.enableSorting ? 'fluent:arrow-sort-up-16-regular' : 'fluent:arrow-sort-16-regular'" />
638
+ {{ fieldTitle("enableSorting") }}
639
+ </InputGroupButton>
640
+ </InputGroupAddon>
641
+ </InputGroup>
629
642
  </Field>
630
643
  </div>
631
644
  </div>
@@ -64,6 +64,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
64
64
  readonly message: string;
65
65
  }[]] | undefined;
66
66
  readonly nodeSelectable?: string | undefined;
67
+ readonly sortKey?: string | undefined;
67
68
  }) => any;
68
69
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
69
70
  "onUpdate:modelValue"?: ((value: {
@@ -127,6 +128,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
127
128
  readonly message: string;
128
129
  }[]] | undefined;
129
130
  readonly nodeSelectable?: string | undefined;
131
+ readonly sortKey?: string | undefined;
130
132
  }) => any) | undefined;
131
133
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
132
134
  declare const _default: typeof __VLS_export;
@@ -72,6 +72,7 @@ export declare function schema(configure: (env: Environment) => void): Schema.St
72
72
  }>]>;
73
73
  binding: Schema.refine<string, typeof Schema.String>;
74
74
  enableSorting: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
75
+ sortKey: Schema.optional<Schema.refine<string, typeof Schema.String>>;
75
76
  size: Schema.optional<Schema.refine<number, Schema.filter<typeof Schema.Number>>>;
76
77
  grow: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
77
78
  tooltip: Schema.optional<Schema.TupleType<readonly [Schema.Struct<{
@@ -63,6 +63,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
63
63
  readonly message: string;
64
64
  }[]] | undefined;
65
65
  readonly nodeSelectable?: string | undefined;
66
+ readonly sortKey?: string | undefined;
66
67
  }) => any;
67
68
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
68
69
  "onUpdate:modelValue"?: ((value: {
@@ -125,6 +126,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
125
126
  readonly message: string;
126
127
  }[]] | undefined;
127
128
  readonly nodeSelectable?: string | undefined;
129
+ readonly sortKey?: string | undefined;
128
130
  }) => any) | undefined;
129
131
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
130
132
  declare const _default: typeof __VLS_export;
@@ -537,14 +537,10 @@ const derivedModel = computed({
537
537
  <Separator />
538
538
  <div class="flex flex-wrap gap-x-8 gap-y-3">
539
539
  <Field
540
- orientation="horizontal"
541
- class="w-auto gap-2"
540
+ orientation="vertical"
541
+ class="w-full max-w-xs"
542
542
  >
543
- <Switch
544
- :model-value="value.enableSorting ?? false"
545
- @update:model-value="(v) => value = { ...value, enableSorting: v }"
546
- />
547
- <FieldLabel class="text-sm text-zinc-600">
543
+ <FieldLabel class="text-xs text-zinc-500">
548
544
  <template
549
545
  v-if="fieldDescription('enableSorting')"
550
546
  #tooltip
@@ -557,6 +553,23 @@ const derivedModel = computed({
557
553
  </template>
558
554
  {{ fieldTitle("enableSorting") }}
559
555
  </FieldLabel>
556
+ <InputGroup>
557
+ <InputGroupInput
558
+ :model-value="value.sortKey"
559
+ placeholder="例:created_at"
560
+ @update:model-value="(v) => value = { ...value, sortKey: v || void 0 }"
561
+ />
562
+ <InputGroupAddon align="inline-end">
563
+ <InputGroupButton
564
+ :variant="value.enableSorting ? 'primary' : 'ghost'"
565
+ size="xs"
566
+ @click="value = { ...value, enableSorting: !value.enableSorting }"
567
+ >
568
+ <Icon :icon="value.enableSorting ? 'fluent:arrow-sort-up-16-regular' : 'fluent:arrow-sort-16-regular'" />
569
+ {{ fieldTitle("enableSorting") }}
570
+ </InputGroupButton>
571
+ </InputGroupAddon>
572
+ </InputGroup>
560
573
  </Field>
561
574
  </div>
562
575
  </div>
@@ -63,6 +63,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
63
63
  readonly message: string;
64
64
  }[]] | undefined;
65
65
  readonly nodeSelectable?: string | undefined;
66
+ readonly sortKey?: string | undefined;
66
67
  }) => any;
67
68
  }, string, import("vue").PublicProps, Readonly<__VLS_ModelProps> & Readonly<{
68
69
  "onUpdate:modelValue"?: ((value: {
@@ -125,6 +126,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_ModelProps, {},
125
126
  readonly message: string;
126
127
  }[]] | undefined;
127
128
  readonly nodeSelectable?: string | undefined;
129
+ readonly sortKey?: string | undefined;
128
130
  }) => any) | undefined;
129
131
  }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
130
132
  declare const _default: typeof __VLS_export;
@@ -69,6 +69,7 @@ export declare function schema(configure: (env: Environment) => void): Schema.St
69
69
  }>]>;
70
70
  binding: Schema.refine<string, typeof Schema.String>;
71
71
  enableSorting: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
72
+ sortKey: Schema.optional<Schema.refine<string, typeof Schema.String>>;
72
73
  size: Schema.optional<Schema.refine<number, Schema.filter<typeof Schema.Number>>>;
73
74
  grow: Schema.optional<Schema.SchemaClass<boolean, boolean, never>>;
74
75
  tooltip: Schema.optional<Schema.TupleType<readonly [Schema.Struct<{
@@ -5,7 +5,7 @@ import { BREADCRUMB_EXTENSION_KEY } from "../config/breadcrumb-extension";
5
5
  import { TABLE_COLUMN_LAYOUT_KEY } from "./column-layout";
6
6
  import { Icon } from "@iconify/vue";
7
7
  import { ParseResult, Schema } from "effect";
8
- import { TableConfig, Pagination, ColumnGroup, tableDataSource, configureTableActionsScope, metadata as tableMetadata } from "./schema";
8
+ import { TableConfig, Pagination, ColumnGroup, tableDataSource, configureTableActionsScope, registerDataSourceRequestVars, registerDataSourceResponseVars, metadata as tableMetadata } from "./schema";
9
9
  import { COLUMNS, findColumn as findColumnEntry } from "./utils/resolve";
10
10
  import {
11
11
  useTreeDnd
@@ -36,6 +36,22 @@ import ShwfedFormConfig from "../form/config.vue";
36
36
  import { defaultFormConfig } from "../form/schema";
37
37
  import { Environment } from "../../vendor/cel-js/lib/index";
38
38
  defineOptions({ name: "ShwfedTableConfig" });
39
+ function probeCELContext(register) {
40
+ const probe = new Environment({ unlistedVariablesAreDyn: false });
41
+ const baseline = new Set(probe.getDefinitions().variables.map((v) => v.name));
42
+ register(probe);
43
+ const out = {};
44
+ for (const v of probe.getDefinitions().variables) {
45
+ if (baseline.has(v.name)) continue;
46
+ out[v.name] = {
47
+ type: v.type,
48
+ label: v.label ?? v.name,
49
+ description: v.description ?? void 0,
50
+ value: void 0
51
+ };
52
+ }
53
+ return out;
54
+ }
39
55
  const RowKeyCELContext = defineComponent({
40
56
  name: "RowKeyCELContext",
41
57
  setup(_, { slots }) {
@@ -97,40 +113,14 @@ const CellStyleCELContext = defineComponent({
97
113
  const RequestCELContext = defineComponent({
98
114
  name: "RequestCELContext",
99
115
  setup(_, { slots }) {
100
- provideCELContext({
101
- pageIndex: {
102
- type: "number",
103
- label: "\u5F53\u524D\u9875\u7801",
104
- description: "\u4ECE `0` \u5F00\u59CB\uFF1B\u672A\u542F\u7528\u5206\u9875\u65F6\u4E3A `0`\u3002",
105
- value: 0
106
- },
107
- pageSize: {
108
- type: "number",
109
- label: "\u6BCF\u9875\u884C\u6570",
110
- description: "\u5F53\u524D\u6BCF\u9875\u884C\u6570\uFF1B\u672A\u542F\u7528\u5206\u9875\u65F6\u4E3A `0`\u3002",
111
- value: 0
112
- },
113
- query: {
114
- type: "dyn",
115
- label: "\u641C\u7D22\u6761\u4EF6",
116
- description: "\u641C\u7D22\u6761\u4EF6\u5F53\u524D\u72B6\u6001\uFF1B\u672A\u914D\u7F6E\u65F6\u4E3A\u7A7A\u5BF9\u8C61\u3002",
117
- value: {}
118
- }
119
- });
116
+ provideCELContext(probeCELContext(registerDataSourceRequestVars));
120
117
  return () => slots.default?.();
121
118
  }
122
119
  });
123
120
  const JsonCELContext = defineComponent({
124
121
  name: "JsonCELContext",
125
122
  setup(_, { slots }) {
126
- provideCELContext({
127
- json: {
128
- type: "optional<dyn>",
129
- label: "HTTP \u54CD\u5E94\u4F53",
130
- description: "\u5DF2\u89E3\u6790\u7684 JSON \u54CD\u5E94\uFF1B\u672A\u914D\u7F6E `request` \u65F6\u4E3A `none`\u3002",
131
- value: void 0
132
- }
133
- });
123
+ provideCELContext(probeCELContext(registerDataSourceResponseVars));
134
124
  return () => slots.default?.();
135
125
  }
136
126
  });
@@ -165,22 +155,7 @@ function configureTableQuery(env) {
165
155
  const tableConfigSchema = TableConfig(configure);
166
156
  const dataSourceSchema = tableDataSource(configure);
167
157
  const pickerEntries = computed(() => COLUMNS.filter((e) => !e.deprecated));
168
- const advertisedHostContext = (() => {
169
- const probe = new Environment({ unlistedVariablesAreDyn: false });
170
- const baseline = new Set(probe.getDefinitions().variables.map((v) => v.name));
171
- configure(probe);
172
- const out = {};
173
- for (const v of probe.getDefinitions().variables) {
174
- if (baseline.has(v.name)) continue;
175
- out[v.name] = {
176
- type: v.type,
177
- label: v.label ?? v.name,
178
- description: v.description ?? void 0,
179
- value: void 0
180
- };
181
- }
182
- return out;
183
- })();
158
+ const advertisedHostContext = probeCELContext(configure);
184
159
  provideCELContext(advertisedHostContext);
185
160
  const generalFieldTitle = (f) => getStructFieldTitle(tableConfigSchema, f) ?? f;
186
161
  const generalFieldDescription = (f) => getStructFieldDescription(tableConfigSchema, f);
@@ -95,7 +95,13 @@ function getLocaleText(value) {
95
95
  return getLocalizedText(value, locale.value);
96
96
  }
97
97
  function mergeCelContext(local) {
98
- return { ...celBindings(inheritedContext), query: queryState.value, ...local };
98
+ return { ...celBindings(inheritedContext), query: queryState.value, sorts: currentSorts(), ...local };
99
+ }
100
+ function currentSorts() {
101
+ const sortKeyById = new Map(
102
+ (config.value?.columns ?? []).map((c) => [c.id, c.sortKey]).filter((e) => typeof e[1] === "string" && e[1].length > 0)
103
+ );
104
+ return tableApi.getState().sorting.map((s) => ({ key: sortKeyById.get(s.id), mode: s.desc ? "desc" : "asc" })).filter((s) => s.key !== void 0);
99
105
  }
100
106
  function translateColumn(column) {
101
107
  const entry = findColumn(column.type, column.compatibilityDate);
@@ -222,6 +228,11 @@ const tableApi = useVueTable({
222
228
  get manualPagination() {
223
229
  return isManualPagination.value;
224
230
  },
231
+ // Defer to server order under server pagination — the page only holds one
232
+ // server-sorted slice, so client re-sorting it would be wrong.
233
+ get manualSorting() {
234
+ return isManualPagination.value;
235
+ },
225
236
  get rowCount() {
226
237
  return isManualPagination.value ? serverTotal.value : void 0;
227
238
  },
@@ -256,6 +267,14 @@ provideCELContext({
256
267
  get value() {
257
268
  return queryState.value;
258
269
  }
270
+ },
271
+ sorts: {
272
+ type: "list<map<string, string>>",
273
+ label: "\u6392\u5E8F\u72B6\u6001",
274
+ description: '\u5F53\u524D\u6392\u5E8F\u5217\u8868\uFF0C\u6BCF\u9879\u4E3A `{key, mode}`\uFF1B`key` \u53D6\u81EA\u5217\u7684\u300C\u6392\u5E8F\u5B57\u6BB5\u300D(sortKey)\uFF0C`mode` \u4E3A `"asc"`/`"desc"`\uFF1B\u672A\u6392\u5E8F\u65F6\u4E3A\u7A7A\u6570\u7EC4\u3002',
275
+ get value() {
276
+ return currentSorts();
277
+ }
259
278
  }
260
279
  });
261
280
  provideSharedFetchLayer();
@@ -423,7 +442,8 @@ watch(
423
442
  () => {
424
443
  if (!isManualPagination.value) return null;
425
444
  const { pageIndex, pageSize } = tableApi.getState().pagination;
426
- return `${pageIndex}:${pageSize}`;
445
+ const sorting = tableApi.getState().sorting;
446
+ return `${pageIndex}:${pageSize}:${JSON.stringify(sorting)}`;
427
447
  },
428
448
  (next, prev) => {
429
449
  if (next !== null && next !== prev) void fetchDataSource();