@fecp/mobile 1.1.2 → 1.1.4
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.
- package/es/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/composables/use-route.mjs +1 -0
- package/es/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/grid/Grid.mjs +1 -0
- package/es/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/grid-item/GridItem.mjs +1 -0
- package/es/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/grid-item/index.mjs +1 -0
- package/es/packages/mobile/src/components/feedback/floatingBubble/FloatingBubble.vue.mjs +39 -18
- package/es/packages/mobile/src/components/feedback/floatingBubble/index.mjs +2 -2
- package/es/packages/mobile/src/components/form/formItem/FormItem.vue.mjs +4 -3
- package/es/packages/mobile/src/utils/use-route.mjs +23 -0
- package/lib/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/composables/use-route.js +1 -0
- package/lib/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/grid/Grid.js +1 -0
- package/lib/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/grid-item/GridItem.js +1 -0
- package/lib/node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/grid-item/index.js +1 -0
- package/lib/packages/mobile/src/components/feedback/floatingBubble/FloatingBubble.vue.js +38 -17
- package/lib/packages/mobile/src/components/form/formItem/FormItem.vue.js +4 -3
- package/lib/packages/mobile/src/utils/use-route.js +23 -0
- package/package.json +1 -1
|
@@ -2,24 +2,45 @@
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
/* empty css */
|
|
4
4
|
/* empty css */
|
|
5
|
-
import { createBlock, openBlock,
|
|
6
|
-
import
|
|
5
|
+
import { createBlock, openBlock, mergeProps, unref, createSlots, renderList, withCtx, renderSlot } from "vue";
|
|
6
|
+
import { routeProps, useRoute } from "../../../utils/use-route.mjs";
|
|
7
7
|
import { FloatingBubble } from "../../../../../../node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/floating-bubble/index.mjs";
|
|
8
|
-
const _sfc_main = {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
8
|
+
const _sfc_main = {
|
|
9
|
+
__name: "FloatingBubble",
|
|
10
|
+
props: {
|
|
11
|
+
axis: {
|
|
12
|
+
//拖拽的方向,xy 代表自由拖拽,lock 代表禁止拖拽
|
|
13
|
+
type: String,
|
|
14
|
+
default: "xy"
|
|
15
|
+
},
|
|
16
|
+
magnetic: {
|
|
17
|
+
//自动磁吸的方向 'x' | 'y'
|
|
18
|
+
type: String,
|
|
19
|
+
default: ""
|
|
20
|
+
},
|
|
21
|
+
...routeProps
|
|
22
|
+
},
|
|
23
|
+
setup(__props) {
|
|
24
|
+
const route = useRoute();
|
|
25
|
+
return (_ctx, _cache) => {
|
|
26
|
+
const _component_van_floating_bubble = FloatingBubble;
|
|
27
|
+
return openBlock(), createBlock(_component_van_floating_bubble, mergeProps(_ctx.$attrs, {
|
|
28
|
+
axis: __props.axis,
|
|
29
|
+
magnetic: "x",
|
|
30
|
+
onClick: unref(route)
|
|
31
|
+
}), createSlots({ _: 2 }, [
|
|
32
|
+
renderList(_ctx.$slots, (item, key) => {
|
|
33
|
+
return {
|
|
34
|
+
name: key,
|
|
35
|
+
fn: withCtx(() => [
|
|
36
|
+
renderSlot(_ctx.$slots, key)
|
|
37
|
+
])
|
|
38
|
+
};
|
|
39
|
+
})
|
|
40
|
+
]), 1040, ["axis", "onClick"]);
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
};
|
|
23
44
|
export {
|
|
24
|
-
|
|
45
|
+
_sfc_main as default
|
|
25
46
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
1
|
+
import _sfc_main from "./FloatingBubble.vue.mjs";
|
|
2
2
|
import install from "../../../utils/install.mjs";
|
|
3
3
|
const MobileFloatingBubble = install.withInstall(
|
|
4
4
|
"MobileFloatingBubble",
|
|
5
|
-
|
|
5
|
+
_sfc_main
|
|
6
6
|
);
|
|
7
7
|
export {
|
|
8
8
|
MobileFloatingBubble,
|
|
@@ -51,13 +51,13 @@ const _sfc_main = {
|
|
|
51
51
|
const formReadonly = inject("formReadonly");
|
|
52
52
|
const dicListMap = inject("dicListMap");
|
|
53
53
|
const formItemDisabled = computed(() => {
|
|
54
|
-
if (formDisabled.value) {
|
|
54
|
+
if (formDisabled == null ? void 0 : formDisabled.value) {
|
|
55
55
|
return formDisabled.value;
|
|
56
56
|
}
|
|
57
57
|
return props.disabled;
|
|
58
58
|
});
|
|
59
59
|
const formItemReadonly = computed(() => {
|
|
60
|
-
if (formReadonly.value) {
|
|
60
|
+
if (formReadonly == null ? void 0 : formReadonly.value) {
|
|
61
61
|
return formReadonly.value;
|
|
62
62
|
}
|
|
63
63
|
return props.readonly;
|
|
@@ -84,6 +84,7 @@ const _sfc_main = {
|
|
|
84
84
|
return parseRule(props.fieldType, attrs);
|
|
85
85
|
});
|
|
86
86
|
return (_ctx, _cache) => {
|
|
87
|
+
var _a;
|
|
87
88
|
return openBlock(), createBlock(resolveDynamicComponent(unref(formItem)), mergeProps(_ctx.$attrs, {
|
|
88
89
|
modelValue: unref(compValue),
|
|
89
90
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(compValue) ? compValue.value = $event : null),
|
|
@@ -92,7 +93,7 @@ const _sfc_main = {
|
|
|
92
93
|
disabled: unref(formItemDisabled),
|
|
93
94
|
readonly: unref(formItemReadonly),
|
|
94
95
|
placeholder: unref(formItemReadonly) ? "" : __props.placeholder,
|
|
95
|
-
dicList: unref(dicListMap)[unref(attrs).dicKey]
|
|
96
|
+
dicList: (_a = unref(dicListMap)) == null ? void 0 : _a[unref(attrs).dicKey]
|
|
96
97
|
}), null, 16, ["modelValue", "rules", "required", "disabled", "readonly", "placeholder", "dicList"]);
|
|
97
98
|
};
|
|
98
99
|
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { getCurrentInstance } from "vue";
|
|
2
|
+
const routeProps = {
|
|
3
|
+
to: [String, Object],
|
|
4
|
+
url: String,
|
|
5
|
+
replace: Boolean
|
|
6
|
+
};
|
|
7
|
+
function route({ to, url, replace, $router: router }) {
|
|
8
|
+
debugger;
|
|
9
|
+
if (to && router) {
|
|
10
|
+
router[replace ? "replace" : "push"](to);
|
|
11
|
+
} else if (url) {
|
|
12
|
+
replace ? location.replace(url) : location.href = url;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
function useRoute() {
|
|
16
|
+
const vm = getCurrentInstance().proxy;
|
|
17
|
+
return () => route(vm);
|
|
18
|
+
}
|
|
19
|
+
export {
|
|
20
|
+
route,
|
|
21
|
+
routeProps,
|
|
22
|
+
useRoute
|
|
23
|
+
};
|
|
@@ -3,5 +3,6 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
3
3
|
const GridItem$1 = require("./GridItem.js");
|
|
4
4
|
const withInstall = require("../utils/with-install.js");
|
|
5
5
|
const GridItem = withInstall.withInstall(GridItem$1.default);
|
|
6
|
+
debugger;
|
|
6
7
|
exports.gridItemProps = GridItem$1.gridItemProps;
|
|
7
8
|
exports.GridItem = GridItem;
|
|
@@ -5,21 +5,42 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
5
5
|
;/* empty css */
|
|
6
6
|
;/* empty css */
|
|
7
7
|
const vue = require("vue");
|
|
8
|
-
const
|
|
8
|
+
const useRoute = require("../../../utils/use-route.js");
|
|
9
9
|
const index = require("../../../../../../node_modules/.pnpm/vant@4.9.17_vue@3.5.13_typescript@5.7.3_/node_modules/vant/es/floating-bubble/index.js");
|
|
10
|
-
const _sfc_main = {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
10
|
+
const _sfc_main = {
|
|
11
|
+
__name: "FloatingBubble",
|
|
12
|
+
props: {
|
|
13
|
+
axis: {
|
|
14
|
+
//拖拽的方向,xy 代表自由拖拽,lock 代表禁止拖拽
|
|
15
|
+
type: String,
|
|
16
|
+
default: "xy"
|
|
17
|
+
},
|
|
18
|
+
magnetic: {
|
|
19
|
+
//自动磁吸的方向 'x' | 'y'
|
|
20
|
+
type: String,
|
|
21
|
+
default: ""
|
|
22
|
+
},
|
|
23
|
+
...useRoute.routeProps
|
|
24
|
+
},
|
|
25
|
+
setup(__props) {
|
|
26
|
+
const route = useRoute.useRoute();
|
|
27
|
+
return (_ctx, _cache) => {
|
|
28
|
+
const _component_van_floating_bubble = index.FloatingBubble;
|
|
29
|
+
return vue.openBlock(), vue.createBlock(_component_van_floating_bubble, vue.mergeProps(_ctx.$attrs, {
|
|
30
|
+
axis: __props.axis,
|
|
31
|
+
magnetic: "x",
|
|
32
|
+
onClick: vue.unref(route)
|
|
33
|
+
}), vue.createSlots({ _: 2 }, [
|
|
34
|
+
vue.renderList(_ctx.$slots, (item, key) => {
|
|
35
|
+
return {
|
|
36
|
+
name: key,
|
|
37
|
+
fn: vue.withCtx(() => [
|
|
38
|
+
vue.renderSlot(_ctx.$slots, key)
|
|
39
|
+
])
|
|
40
|
+
};
|
|
41
|
+
})
|
|
42
|
+
]), 1040, ["axis", "onClick"]);
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
exports.default = _sfc_main;
|
|
@@ -53,13 +53,13 @@ const _sfc_main = {
|
|
|
53
53
|
const formReadonly = vue.inject("formReadonly");
|
|
54
54
|
const dicListMap = vue.inject("dicListMap");
|
|
55
55
|
const formItemDisabled = vue.computed(() => {
|
|
56
|
-
if (formDisabled.value) {
|
|
56
|
+
if (formDisabled == null ? void 0 : formDisabled.value) {
|
|
57
57
|
return formDisabled.value;
|
|
58
58
|
}
|
|
59
59
|
return props.disabled;
|
|
60
60
|
});
|
|
61
61
|
const formItemReadonly = vue.computed(() => {
|
|
62
|
-
if (formReadonly.value) {
|
|
62
|
+
if (formReadonly == null ? void 0 : formReadonly.value) {
|
|
63
63
|
return formReadonly.value;
|
|
64
64
|
}
|
|
65
65
|
return props.readonly;
|
|
@@ -86,6 +86,7 @@ const _sfc_main = {
|
|
|
86
86
|
return formRule.parseRule(props.fieldType, attrs);
|
|
87
87
|
});
|
|
88
88
|
return (_ctx, _cache) => {
|
|
89
|
+
var _a;
|
|
89
90
|
return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(formItem)), vue.mergeProps(_ctx.$attrs, {
|
|
90
91
|
modelValue: vue.unref(compValue),
|
|
91
92
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => vue.isRef(compValue) ? compValue.value = $event : null),
|
|
@@ -94,7 +95,7 @@ const _sfc_main = {
|
|
|
94
95
|
disabled: vue.unref(formItemDisabled),
|
|
95
96
|
readonly: vue.unref(formItemReadonly),
|
|
96
97
|
placeholder: vue.unref(formItemReadonly) ? "" : __props.placeholder,
|
|
97
|
-
dicList: vue.unref(dicListMap)[vue.unref(attrs).dicKey]
|
|
98
|
+
dicList: (_a = vue.unref(dicListMap)) == null ? void 0 : _a[vue.unref(attrs).dicKey]
|
|
98
99
|
}), null, 16, ["modelValue", "rules", "required", "disabled", "readonly", "placeholder", "dicList"]);
|
|
99
100
|
};
|
|
100
101
|
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const vue = require("vue");
|
|
4
|
+
const routeProps = {
|
|
5
|
+
to: [String, Object],
|
|
6
|
+
url: String,
|
|
7
|
+
replace: Boolean
|
|
8
|
+
};
|
|
9
|
+
function route({ to, url, replace, $router: router }) {
|
|
10
|
+
debugger;
|
|
11
|
+
if (to && router) {
|
|
12
|
+
router[replace ? "replace" : "push"](to);
|
|
13
|
+
} else if (url) {
|
|
14
|
+
replace ? location.replace(url) : location.href = url;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
function useRoute() {
|
|
18
|
+
const vm = vue.getCurrentInstance().proxy;
|
|
19
|
+
return () => route(vm);
|
|
20
|
+
}
|
|
21
|
+
exports.route = route;
|
|
22
|
+
exports.routeProps = routeProps;
|
|
23
|
+
exports.useRoute = useRoute;
|