@fecp/mobile 1.1.39 → 1.1.40

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.
@@ -1,4 +1,4 @@
1
- import { useAttrs, ref, computed, createBlock, openBlock, unref, mergeProps, isRef, withCtx, createElementBlock, toDisplayString } from "vue";
1
+ import { useAttrs, ref, watch, computed, createBlock, openBlock, unref, mergeProps, isRef, withCtx, createElementBlock, toDisplayString } from "vue";
2
2
  import { MobileField } from "../field/index.mjs";
3
3
  import { getOptions } from "../../../utils/optionUtil.mjs";
4
4
  import { MobileCheckboxGroup } from "../checkboxGroup/index.mjs";
@@ -39,6 +39,21 @@ const _sfc_main = {
39
39
  }).then((data) => {
40
40
  finalOptions.value = data;
41
41
  });
42
+ watch(
43
+ () => props.options,
44
+ () => {
45
+ getOptions({
46
+ ...attrs,
47
+ staticOptions: props.options,
48
+ optionsFieldNames: props.fieldNames
49
+ }).then((data) => {
50
+ finalOptions.value = data;
51
+ });
52
+ },
53
+ {
54
+ deep: true
55
+ }
56
+ );
42
57
  const emit = __emit;
43
58
  const compValue = computed({
44
59
  get: () => {
@@ -11,7 +11,7 @@
11
11
  /* empty css */
12
12
  /* empty css */
13
13
  /* empty css */
14
- import { useAttrs, ref, computed, watch, createBlock, openBlock, unref, mergeProps, isRef, createSlots, withCtx, createVNode, withModifiers } from "vue";
14
+ import { useAttrs, ref, watch, computed, createBlock, openBlock, unref, mergeProps, isRef, createSlots, withCtx, createVNode, withModifiers } from "vue";
15
15
  import { MobileField } from "../field/index.mjs";
16
16
  import { getOptions } from "../../../utils/optionUtil.mjs";
17
17
  import { Picker } from "../../../../../../node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/picker/index.mjs";
@@ -77,6 +77,21 @@ const _sfc_main = {
77
77
  }).then((data) => {
78
78
  finalOptions.value = data;
79
79
  });
80
+ watch(
81
+ () => props.pickerOptions,
82
+ () => {
83
+ getOptions({
84
+ ...attrs,
85
+ staticOptions: props.pickerOptions,
86
+ optionsFieldNames: props.treeOptionsFieldNames
87
+ }).then((data) => {
88
+ finalOptions.value = data;
89
+ });
90
+ },
91
+ {
92
+ deep: true
93
+ }
94
+ );
80
95
  const fieldTextValue = ref("");
81
96
  const showPicker = ref(false);
82
97
  const emit = __emit;
@@ -41,6 +41,21 @@ const _sfc_main = {
41
41
  }).then((data) => {
42
42
  finalOptions.value = data;
43
43
  });
44
+ vue.watch(
45
+ () => props.options,
46
+ () => {
47
+ optionUtil.getOptions({
48
+ ...attrs,
49
+ staticOptions: props.options,
50
+ optionsFieldNames: props.fieldNames
51
+ }).then((data) => {
52
+ finalOptions.value = data;
53
+ });
54
+ },
55
+ {
56
+ deep: true
57
+ }
58
+ );
44
59
  const emit = __emit;
45
60
  const compValue = vue.computed({
46
61
  get: () => {
@@ -79,6 +79,21 @@ const _sfc_main = {
79
79
  }).then((data) => {
80
80
  finalOptions.value = data;
81
81
  });
82
+ vue.watch(
83
+ () => props.pickerOptions,
84
+ () => {
85
+ optionUtil.getOptions({
86
+ ...attrs,
87
+ staticOptions: props.pickerOptions,
88
+ optionsFieldNames: props.treeOptionsFieldNames
89
+ }).then((data) => {
90
+ finalOptions.value = data;
91
+ });
92
+ },
93
+ {
94
+ deep: true
95
+ }
96
+ );
82
97
  const fieldTextValue = vue.ref("");
83
98
  const showPicker = vue.ref(false);
84
99
  const emit = __emit;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fecp/mobile",
3
- "version": "1.1.39",
3
+ "version": "1.1.40",
4
4
  "main": "lib/packages/mobile/index.js",
5
5
  "module": "es/packages/mobile/index.mjs",
6
6
  "files": [