var __create = Object.create;
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __getProtoOf = Object.getPrototypeOf;
var __hasOwnProp = Object.prototype.hasOwnProperty;
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 __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
  // If the importer is in node compatibility mode or this is not an ESM
  // file that has been converted to a CommonJS file using a Babel-
  // compatible transform (i.e. "__esModule" has not been set), then set
  // "default" to the CommonJS "module.exports" for node compatibility.
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
  mod
));
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);

// src/components/walletCard/Guest/index.tsx
var Guest_exports = {};
__export(Guest_exports, {
  default: () => Guest_default
});
module.exports = __toCommonJS(Guest_exports);
var import_react = __toESM(require("react"));
var import_useEngineContext = __toESM(require("../../../hooks/useEngineContext"));
var import_button = __toESM(require("../../button"));
var import_index = require("./index.less");
var Guest = (props) => {
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
  const { setting } = props;
  const context = (0, import_useEngineContext.default)();
  const { utils } = context.appHelper || {};
  const goLogin = () => {
    console.log(utils, "wh978796");
    utils == null ? void 0 : utils.action({
      type: "pisell1.login",
      data: {},
      callback: (status) => {
        console.log(status, "wh978796");
        if (status === "success") {
        }
      }
    });
  };
  const getTextStyle = (config, otherConfig) => ({
    color: (config == null ? void 0 : config.color) || (otherConfig == null ? void 0 : otherConfig.color) || "#fff",
    fontSize: (config == null ? void 0 : config.size) || (otherConfig == null ? void 0 : otherConfig.size) || 14,
    fontWeight: (config == null ? void 0 : config.weight) || (otherConfig == null ? void 0 : otherConfig.weight) || 400,
    fontStyle: (config == null ? void 0 : config.style) || "normal"
  });
  return /* @__PURE__ */ import_react.default.createElement(
    "div",
    {
      className: "pisell-wallet-guest-wrap",
      style: {
        backgroundColor: setting == null ? void 0 : setting.backgroundColor
      }
    },
    ((_a = utils == null ? void 0 : utils.translation) == null ? void 0 : _a.call(utils, setting == null ? void 0 : setting.backgroundImage)) ? /* @__PURE__ */ import_react.default.createElement(
      "img",
      {
        className: "pisell-wallet-guest-bg",
        src: ((_b = utils == null ? void 0 : utils.translation) == null ? void 0 : _b.call(utils, setting.backgroundImage)) || "",
        alt: ((_c = utils == null ? void 0 : utils.translation) == null ? void 0 : _c.call(utils, setting == null ? void 0 : setting.backgroundImageAlt)) || "",
        title: ((_d = utils == null ? void 0 : utils.translation) == null ? void 0 : _d.call(utils, setting == null ? void 0 : setting.backgroundImageAlt)) || ""
      }
    ) : null,
    /* @__PURE__ */ import_react.default.createElement(
      "div",
      {
        className: `pisell-wallet-guest-content ${setting.align === "center" ? "pisell-wallet-guest-center" : ""}`
      },
      /* @__PURE__ */ import_react.default.createElement("div", null, /* @__PURE__ */ import_react.default.createElement(
        "div",
        {
          className: "pisell-wallet-guest-title",
          style: getTextStyle(setting == null ? void 0 : setting.titleConfig, {
            size: 18,
            weight: 600
          })
        },
        ((_f = utils == null ? void 0 : utils.translation) == null ? void 0 : _f.call(
          utils,
          (setting == null ? void 0 : setting.title) || ((_e = setting == null ? void 0 : setting.titleConfig) == null ? void 0 : _e.text)
        )) || ""
      ), /* @__PURE__ */ import_react.default.createElement(
        "div",
        {
          className: "pisell-wallet-guest-subtitle",
          style: getTextStyle(setting == null ? void 0 : setting.subtitleConfig, {
            color: "#D0D5DD"
          })
        },
        ((_h = utils == null ? void 0 : utils.translation) == null ? void 0 : _h.call(
          utils,
          (setting == null ? void 0 : setting.subtitle) || ((_g = setting == null ? void 0 : setting.subtitleConfig) == null ? void 0 : _g.text)
        )) || ""
      )),
      ((_j = utils == null ? void 0 : utils.translation) == null ? void 0 : _j.call(
        utils,
        (setting == null ? void 0 : setting.buttonText) || ((_i = setting == null ? void 0 : setting.buttonConfig) == null ? void 0 : _i.text)
      )) ? /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-wallet-guest-button-wrap" }, /* @__PURE__ */ import_react.default.createElement(
        import_button.default,
        {
          style: {
            backgroundColor: (setting == null ? void 0 : setting.buttonColor) || "#7F56D9",
            borderColor: (setting == null ? void 0 : setting.buttonBorderColor) || "#7F56D9"
          },
          onClick: goLogin
        },
        /* @__PURE__ */ import_react.default.createElement(
          "div",
          {
            style: getTextStyle(setting == null ? void 0 : setting.buttonConfig, {
              weight: 600
            })
          },
          ((_l = utils == null ? void 0 : utils.translation) == null ? void 0 : _l.call(
            utils,
            (setting == null ? void 0 : setting.buttonText) || ((_k = setting == null ? void 0 : setting.buttonConfig) == null ? void 0 : _k.text)
          )) || ""
        )
      )) : null
    )
  );
};
var Guest_default = Guest;
