"use strict"; const common_vendor = require("../../common/vendor.js"); const gLoading = () => "../loading.js"; const _sfc_main = { components: { gLoading }, data() { return { cdnBaseImg: this.G.store().cdnBaseImg, svgBaseImg: this.G.store().svgBaseImg }; }, props: { list: { type: Array, default: () => { return []; } }, // 骨架屏的loading状态 loading: { default: () => { return false; } }, speed: { default: () => { return -1; } }, num: { type: Number, default: () => { return 5; } }, height: { type: Number, default: () => { return 22; } }, cusBg: { default: "" }, cusType: { default: "num" }, cusTitle: { default: "" }, titleNav: { default: "" }, subhead: { default: "" }, // 标签距离底部距离 marginBottom: { default: 10 }, border: { default: false }, bottomBox: { default: false }, bottomNav: { default: "" } }, methods: { handleClick($item, $index) { this.$emit("clickItem", { item: $item, index: $index }); }, titleNavigator() { if (this.titleNav) { this.$emit("clickItem", { item: { path: this.titleNav } }); } }, bottomNavigator() { if (this.titleNav) { this.$emit("clickItem", { item: { path: this.bottomNav } }); } } } }; if (!Array) { const _component_g_loading = common_vendor.resolveComponent("g-loading"); const _easycom_u_skeleton2 = common_vendor.resolveComponent("u-skeleton"); (_component_g_loading + _easycom_u_skeleton2)(); } const _easycom_u_skeleton = () => "../../uni_modules/vk-uview-ui/components/u-skeleton/u-skeleton.js"; if (!Math) { _easycom_u_skeleton(); } function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) { return common_vendor.e({ a: $props.cusTitle }, $props.cusTitle ? common_vendor.e({ b: common_vendor.t($props.cusTitle), c: $props.subhead }, $props.subhead ? { d: common_vendor.t($props.subhead) } : {}, { e: $props.titleNav }, $props.titleNav ? {} : {}, { f: common_vendor.o((...args) => $options.titleNavigator && $options.titleNavigator(...args)) }) : {}, { g: common_vendor.f($props.list, (item, index, i0) => { return common_vendor.e($props.height < 38 ? common_vendor.e({ a: $props.speed == 1 }, $props.speed == 1 ? common_vendor.e({ b: $props.cusType == "num" }, $props.cusType == "num" ? { c: common_vendor.t(item.num) } : {}, { d: $props.cusType == "image" }, $props.cusType == "image" ? common_vendor.e({ e: item.icon }, item.icon ? common_vendor.e({ f: item.iconType == 1 }, item.iconType == 1 ? { g: common_vendor.n(`icon-${item.icon}`), h: common_vendor.n(`g_fs_${$props.height - 4}`), i: item.iconColor ? item.iconColor : "#333" } : { j: common_vendor.n(`g_h_${$props.height - 4}`), k: common_vendor.n(`g_w_${$props.height - 4}`), l: common_vendor.n(`t-icon-${item.icon}`), m: `${$props.height - 4}px`, n: `${$props.height - 4}px` }) : { o: item.image, p: $props.height + "px", q: $props.height + "px" }, { r: common_vendor.t(item.image), s: common_vendor.n(`g_h_${$props.height - 4}`) }) : {}, { t: item.tip }, item.tip ? {} : {}, { v: common_vendor.n(item.num == "-" ? "" : "g_fw_bold") }) : {}, { w: $props.speed == 0 }, $props.speed == 0 ? { x: "694b87a9-0-" + i0, y: common_vendor.p({ minHeight: "0", text: "empty" }) } : {}, { z: common_vendor.n(`g_h_${$props.height}`) }) : common_vendor.e({ A: $props.speed == 1 }, $props.speed == 1 ? common_vendor.e({ B: $props.cusType == "num" }, $props.cusType == "num" ? { C: common_vendor.t(item.num) } : {}, { D: $props.cusType == "image" }, $props.cusType == "image" ? common_vendor.e({ E: item.icon }, item.icon ? common_vendor.e({ F: item.iconType == 1 }, item.iconType == 1 ? { G: common_vendor.n(`icon-${item.icon}`), H: common_vendor.n(`g_fs_${$props.height - 4}`), I: item.iconColor ? item.iconColor : "#333" } : { J: common_vendor.n(`g_h_${$props.height - 4}`), K: common_vendor.n(`g_w_${$props.height - 4}`), L: common_vendor.n(`t-icon-${item.icon}`), M: `${$props.height - 4}px`, N: `${$props.height - 4}px` }) : { O: item.image, P: $props.height + "px", Q: $props.height + "px" }) : {}, { R: item.tip }, item.tip ? {} : {}, { S: common_vendor.n(item.num == "-" ? "" : "g_fw_bold") }) : {}, { T: $props.speed == 0 }, $props.speed == 0 ? { U: "694b87a9-1-" + i0, V: common_vendor.p({ minHeight: "0", text: "empty" }) } : {}), { W: common_vendor.t(item.name), X: index, Y: common_vendor.o(($event) => $options.handleClick(item, index), index), Z: common_vendor.n($props.border && (index + 1) % $props.num != 0 ? "g_border_e_r" : ""), aa: common_vendor.n($props.border && index < $props.num ? "g_border_e_b" : "") }); }), h: $props.height < 38, i: common_vendor.n(`g_mb_${$props.marginBottom}`), j: "calc(100% / " + $props.num + " - 1rpx)", k: common_vendor.n($props.height < 38 ? "g_pt_16" : "g_pt_10"), l: $props.bottomBox }, $props.bottomBox ? { m: common_vendor.o((...args) => $options.bottomNavigator && $options.bottomNavigator(...args)) } : {}, { n: $props.cusBg ? $props.cusBg : "#fff", o: common_vendor.p({ loading: $props.loading, animation: true, bgColor: "#fff" }) }); } const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]); wx.createComponent(Component); //# sourceMappingURL=../../../.sourcemap/mp-weixin/components/panel/numCard.js.map