"use strict";
const common_vendor = require("../../../common/vendor.js");
if (!Array) {
  const _easycom_s_coupon_list2 = common_vendor.resolveComponent("s-coupon-list");
  const _easycom_su_popup2 = common_vendor.resolveComponent("su-popup");
  (_easycom_s_coupon_list2 + _easycom_su_popup2)();
}
const _easycom_s_coupon_list = () => "../s-coupon-list/s-coupon-list.js";
const _easycom_su_popup = () => "../../ui/su-popup/su-popup.js";
if (!Math) {
  (_easycom_s_coupon_list + _easycom_su_popup)();
}
const _sfc_main = {
  __name: "s-coupon-get",
  props: {
    modelValue: {
      type: Object,
      default() {
      }
    },
    show: {
      type: Boolean,
      default: false
    }
  },
  emits: ["get", "close"],
  setup(__props, { emit: emits }) {
    const props = __props;
    const state = common_vendor.reactive({
      couponInfo: common_vendor.computed(() => props.modelValue)
    });
    const getBuy = (id) => {
      emits("get", id);
    };
    return (_ctx, _cache) => {
      return {
        a: common_vendor.f(state.couponInfo, (item, k0, i0) => {
          return {
            a: common_vendor.t(item.canTake ? "立即领取" : "已领取"),
            b: common_vendor.n(!item.canTake ? "boder-btn" : ""),
            c: common_vendor.o(($event) => getBuy(item.id), item.id),
            d: !item.canTake,
            e: "f49e1509-1-" + i0 + ",f49e1509-0",
            f: common_vendor.p({
              data: item
            }),
            g: item.id
          };
        }),
        b: common_vendor.o(($event) => emits("close")),
        c: common_vendor.p({
          show: __props.show,
          type: "bottom",
          round: "20",
          showClose: true,
          backgroundColor: "#f2f2f2"
        })
      };
    };
  }
};
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-f49e1509"], ["__file", "/Users/RuHu.Xu/Desktop/mall-newfeifan-zx-app/sheep/components/s-coupon-get/s-coupon-get.vue"]]);
wx.createComponent(Component);
