UNPKG

flamingo-ui

Version:

火烈鸟UI组件库

153 lines (152 loc) 5.6 kB
var __defProp = Object.defineProperty; var __defProps = Object.defineProperties; var __getOwnPropDesc = Object.getOwnPropertyDescriptor; var __getOwnPropDescs = Object.getOwnPropertyDescriptors; var __getOwnPropNames = Object.getOwnPropertyNames; var __getOwnPropSymbols = Object.getOwnPropertySymbols; var __hasOwnProp = Object.prototype.hasOwnProperty; var __propIsEnum = Object.prototype.propertyIsEnumerable; var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; var __spreadValues = (a, b) => { for (var prop in b || (b = {})) if (__hasOwnProp.call(b, prop)) __defNormalProp(a, prop, b[prop]); if (__getOwnPropSymbols) for (var prop of __getOwnPropSymbols(b)) { if (__propIsEnum.call(b, prop)) __defNormalProp(a, prop, b[prop]); } return a; }; var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b)); var __export = (target, all) => { for (var name in all) __defProp(target, name, { get: all[name], enumerable: true }); }; var __copyProps = (to, from, except, desc) => { if (from && typeof from === "object" || typeof from === "function") { for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); } return to; }; var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); var stdin_exports = {}; __export(stdin_exports, { default: () => stdin_default }); module.exports = __toCommonJS(stdin_exports); var import_PayProblem_sfc = require("./PayProblem-sfc.css"); var import_vue = require("vue"); var import_utils = require("../utils/index"); var import_vue2 = require("vue"); const __vue_sfc__ = { name: "PayProblem", props: { // 支付问题按钮 question: { type: Function, default: null }, // 已完成支付按钮 finish: { type: Function, default: null }, // 允许触碰遮罩层关闭 closeOnClickOverlay: { type: Boolean, default: false }, // 移除弹窗方法 remove: Function }, setup(props, ctx) { const data = (0, import_vue.reactive)({ // 组件显示 show: true }); const fncallback = (0, import_utils.debounce)((callback) => { callback ? callback(data) : data.show = false; }); (0, import_vue.watch)(() => data.show, () => { if (data.show == false) { props.remove(); } }); const close = () => { props.closeOnClickOverlay ? data.show = false : ""; }; const confirm = () => { data.show = false; }; return __spreadProps(__spreadValues({}, (0, import_vue.toRefs)(data)), { fncallback, close, confirm }); } }; const _hoisted_1 = /* @__PURE__ */ (0, import_vue2.createElementVNode)( "p", { class: "fmg-payproblem-title" }, "\u63D0\u793A", -1 /* HOISTED */ ); const _hoisted_2 = /* @__PURE__ */ (0, import_vue2.createElementVNode)( "div", { class: "fmg-payproblem-message" }, [ /* @__PURE__ */ (0, import_vue2.createElementVNode)("ul", null, [ /* @__PURE__ */ (0, import_vue2.createElementVNode)("li", null, "1\u3001\u5982\u652F\u4ED8\u9047\u5230\u95EE\u9898\uFF0C\u8BF7\u70B9\u51FB\u201C\u652F\u4ED8\u9047\u5230\u95EE\u9898\u201D\uFF0C\u8054\u7CFB\u5BA2\u670D\u8FDB\u884C\u53CD\u9988\u3002"), /* @__PURE__ */ (0, import_vue2.createElementVNode)("li", null, "2\u3001\u5982\u5DF2\u5B8C\u6210\u652F\u4ED8\uFF0C\u8BF7\u70B9\u51FB\u201C\u5DF2\u5B8C\u6210\u652F\u4ED8\u201D\uFF0C\u53EF\u5728\u201C\u8D2D\u4E70\u8BB0\u5F55\u201D\u67E5\u770B\uFF0C\u6708\u5361\u5230\u8D26\u53EF\u80FD\u5EF6\u8FDF\u3002") ]) ], -1 /* HOISTED */ ); const _hoisted_3 = { class: "fmg-payproblem-donebtn" }; function __vue_render__(_ctx, _cache) { return (0, import_vue2.openBlock)(), (0, import_vue2.createElementBlock)( "div", { class: (0, import_vue2.normalizeClass)(["fmg-payproblem", { "fmg-payproblem-hide": !_ctx.show }]), onClick: _cache[4] || (_cache[4] = (...args) => _ctx.close && _ctx.close(...args)), onTouchmove: _cache[5] || (_cache[5] = (0, import_vue2.withModifiers)(() => { }, ["prevent"])) }, [ (0, import_vue2.createElementVNode)("div", { class: "fmg-payproblem-wrapper", onClick: _cache[3] || (_cache[3] = (0, import_vue2.withModifiers)(() => { }, ["stop"])) }, [ _hoisted_1, (0, import_vue2.createElementVNode)("img", { onClick: _cache[0] || (_cache[0] = (...args) => _ctx.confirm && _ctx.confirm(...args)), class: "fmg-payproblem-icon", src: "https://gres.guopan.cn/png/20230313/payment-close.png", alt: "" }), _hoisted_2, (0, import_vue2.createElementVNode)("div", _hoisted_3, [ (0, import_vue2.createElementVNode)("a", { class: "hadProblem", onClick: _cache[1] || (_cache[1] = ($event) => _ctx.fncallback(_ctx.question)) }, "\u652F\u4ED8\u9047\u5230\u95EE\u9898"), (0, import_vue2.createElementVNode)("a", { class: "haddone", onClick: _cache[2] || (_cache[2] = ($event) => _ctx.fncallback(_ctx.finish)) }, "\u5DF2\u5B8C\u6210\u652F\u4ED8") ]) ]) ], 34 /* CLASS, HYDRATE_EVENTS */ ); } __vue_sfc__.render = __vue_render__; __vue_sfc__._scopeId = "data-v-0a090e40"; var stdin_default = __vue_sfc__;