"use strict";
const common_vendor = require("../../../common/vendor.js");
const TUIKit_tuiCustomerServicePlugin_utils_env = require("../utils/env.js");
const _sfc_main = {
  props: {
    payload: {
      type: Object,
      default: () => ({})
    }
  },
  emits: ["sendMessage"],
  setup(props) {
    const jumpProductCard = () => {
      if (window) {
        window.open(props.payload.content.url, "_blank");
      } else {
        common_vendor.index && common_vendor.index.navigateTo({ url: `/TUIKit/components/TUIChat/web-view?url=${props.payload.content.url}` });
      }
    };
    return {
      props,
      isApp: TUIKit_tuiCustomerServicePlugin_utils_env.isApp,
      jumpProductCard
    };
  }
};
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
  return common_vendor.e({
    a: $setup.isApp
  }, $setup.isApp ? {
    b: $setup.props.payload.content.pic
  } : {
    c: $setup.props.payload.content.pic
  }, {
    d: common_vendor.t($setup.props.payload.content.header),
    e: common_vendor.t($setup.props.payload.content.desc),
    f: common_vendor.o$1((...args) => $setup.jumpProductCard && $setup.jumpProductCard(...args))
  });
}
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-24d6579f"]]);
wx.createComponent(Component);
//# sourceMappingURL=../../../../.sourcemap/mp-weixin/TUIKit/tui-customer-service-plugin/components/message-product-card.js.map
