exports.id = 758;
exports.ids = [758];
exports.modules = {

/***/ 3159:
/***/ ((module) => {

// Exports
module.exports = {
	"button": "style_button__S6JFm",
	"primary": "style_primary__U52fV",
	"default": "style_default__cP1_n"
};


/***/ }),

/***/ 323:
/***/ ((module) => {

// Exports
module.exports = {
	"menu": "style_menu__wQIhJ",
	"menuItem": "style_menuItem__LZayI"
};


/***/ }),

/***/ 4947:
/***/ ((module) => {

// Exports
module.exports = {
	"header": "style_header__TIuTt",
	"weshopLogo": "style_weshopLogo__iSMzq",
	"zIndex": "style_zIndex__dY6xN",
	"logoWrap": "style_logoWrap__g_YF9",
	"joinIn": "style_joinIn__lwu8y",
	"menuWrap": "style_menuWrap__3pejS",
	"loginWrap": "style_loginWrap__3eybZ",
	"menu": "style_menu__gI_3Y",
	"power": "style_power__ijC5D",
	"powerLeft": "style_powerLeft__ROY3b",
	"num": "style_num__cqxyF",
	"primaryColor": "style_primaryColor__6Qxvy",
	"buy": "style_buy__igRJm",
	"locationTip": "style_locationTip__BUhBr"
};


/***/ }),

/***/ 5254:
/***/ ((module) => {

// Exports
module.exports = {
	"main": "style_main__K_bz6",
	"mask": "style_mask__rYCOL"
};


/***/ }),

/***/ 5654:
/***/ ((module) => {

// Exports
module.exports = {
	"onMouseAssistDiv": "style_onMouseAssistDiv__kHBIl",
	"avatar": "style_avatar___fnH2",
	"userInfoCard": "style_userInfoCard__ad1ry",
	"logoutHeader": "style_logoutHeader__xvQl7",
	"userImg": "style_userImg__wo4VN",
	"userUname": "style_userUname__GnXME",
	"memberType": "style_memberType__4Xnis",
	"logoutContent": "style_logoutContent__O_ZAg",
	"clickDiv": "style_clickDiv___Tgvg",
	"clickTextDiv": "style_clickTextDiv__9JpDk",
	"clickSvg": "style_clickSvg__Q3PWi",
	"clickTitleDiv": "style_clickTitleDiv__WKDsR",
	"buttonDivider": "style_buttonDivider__uS_Ip"
};


/***/ }),

/***/ 3435:
/***/ ((module) => {

// Exports
module.exports = {
	"mask": "style_mask__PbUhI"
};


/***/ }),

/***/ 8208:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Te": () => (/* binding */ previewLoader),
/* harmony export */   "VK": () => (/* binding */ browserCheck),
/* harmony export */   "be": () => (/* binding */ handleDownloadClick),
/* harmony export */   "jz": () => (/* binding */ commonCopyText),
/* harmony export */   "kS": () => (/* binding */ compositeImage),
/* harmony export */   "po": () => (/* binding */ loadImage),
/* harmony export */   "vB": () => (/* binding */ smallLoader),
/* harmony export */   "yL": () => (/* binding */ verfiyInfer)
/* harmony export */ });
/* unused harmony exports scrollToTop, emptyLoader, validatePhoneNumber, loginUrl, getNewUIDGenerator */
/* harmony import */ var ua_parser_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9621);
/* harmony import */ var ua_parser_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(ua_parser_js__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _components_Toast__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(9204);
/* harmony import */ var _constans__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1653);
/* harmony import */ var _constans_international__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3413);




const handleDownloadClick = async (imageUrl, fileName, tFun)=>{
    return new Promise((resolve, reject)=>{
        const image = new Image();
        image.onload = ()=>resolve(image);
        image.onerror = ()=>reject(new Error("Failed to load image"));
        image.setAttribute("crossOrigin", "Anonymous");
        image.src = imageUrl;
    }).then((img)=>{
        const canvas = document.createElement("canvas");
        canvas.width = img.width;
        canvas.height = img.height;
        const ctx = canvas.getContext("2d");
        // 将img中的内容画到画布上
        ctx?.drawImage(img, 0, 0, canvas.width, canvas.height);
        // 将画布内容转换为Blob
        canvas.toBlob((blob)=>{
            if (!blob) return;
            // blob转为同源url
            const blobUrl = window.URL.createObjectURL(blob);
            // 创建a链接
            const a = document.createElement("a");
            a.href = blobUrl;
            a.download = fileName;
            // 触发a链接点击事件，浏览器开始下载文件
            a.click();
            window.URL.revokeObjectURL(blobUrl);
            a.remove();
        });
        return true;
    }).catch((e)=>{
        console.error("Failed to download file", e);
        (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
            message: tFun("toast.imageDownloadFail")
        });
        return false;
    });
};
function scrollToTop() {
    const c = document.documentElement.scrollTop || document.body.scrollTop;
    if (c > 0) {
        window.requestAnimationFrame(scrollToTop);
        window.scrollTo(0, c - c / 8);
    }
}
async function compositeImage(list, width, height, counterSelect) {
    if (list?.length === 1 && !counterSelect) return list[0];
    const canvas = document.createElement("canvas");
    canvas.width = width;
    canvas.height = height;
    let dataUrl = "";
    const images = list.map((item)=>{
        if (item) {
            const img = new Image();
            img.src = item;
            return img;
        }
    });
    try {
        await Promise.all(images.map((img_1)=>img_1?.decode()));
        const ctx = canvas.getContext("2d");
        if (ctx) {
            ctx.fillStyle = "rgba(0, 0, 0, 0)";
        }
        images.forEach((item_1)=>{
            if (item_1) ctx?.drawImage(item_1, 0, 0);
        });
        if (counterSelect) {
            if (ctx) {
                const imageData = ctx.getImageData(0, 0, canvas.width, canvas.height);
                const data = imageData.data;
                for(let i = 0; i < data.length; i += 4){
                    const r = data[i];
                    const g = data[i + 1];
                    const b = data[i + 2];
                    const a = data[i + 3];
                    if (r !== 0 || g !== 0 || b !== 0 || a !== 0) {
                        data[i + 3] = 0 // Set alpha value to 0 (fully transparent)
                        ;
                    } else {
                        data[i] = 117 // Set red channel to 117
                        ;
                        data[i + 1] = 48 // Set green channel to 48
                        ;
                        data[i + 2] = 254 // Set blue channel to 254
                        ;
                        data[i + 3] = 128 // Set alpha value to 128 (semi-transparent)
                        ;
                    }
                }
                ctx.putImageData(imageData, 0, 0);
            }
        }
        dataUrl = canvas.toDataURL("image/png");
        return dataUrl;
    } catch (error) {
        console.log(error);
        return "";
    }
}
// 生成模型输入校验
const verfiyInfer = (params, tFun)=>{
    if (!params.image && params.agentName !== "text2image") {
        (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
            message: tFun("toast.handle.picFirst")
        });
        return;
    }
    if (!params.mask && params.agentName !== "text2image" && params.agentName !== "image2image") {
        (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
            message: tFun("toast.handle.picKeep")
        });
        const element = document.getElementById("myEdit");
        if (element) element.scrollTop = 0;
        return;
    }
    if (params.paramType === "template") {
        if (!params.agentName) return;
        if (!params?.fashionModelId && _constans__WEBPACK_IMPORTED_MODULE_1__/* .RACR_AGENT.includes */ .AL.includes(params.agentName)) {
            (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
                message: tFun("toast.handle.maskFirst")
            });
            return;
        }
        if (!params.locationId && params.agentName !== "accessory") {
            (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
                message: tFun("toast.handle.locationFirst")
            });
            return;
        }
    }
    if (params.paramType === "prompt" && !params.posPrompt) {
        (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
            message: tFun("toast.handle.positive")
        });
        return;
    }
    return true;
};
function emptyLoader(item) {
    return `${item.src}?w=${item.width || 276}`;
}
function previewLoader(item) {
    return _constans_international__WEBPACK_IMPORTED_MODULE_2__/* .PREVIEW_WEBP */ .GJ ? `${item.src}_preview.webp` : item.src;
}
function smallLoader(item) {
    return `${item.src}_256x256.jpeg`;
}
// 手机号校验
function validatePhoneNumber(phoneNumber) {
    const regEx = /^(13[0-9]|14[5-9]|15[0-3,5-9]|16[6]|17[0-8]|18[0-9]|19[1,8,9])\d{8}$/;
    return regEx.test(phoneNumber);
}
const loadImage = async (url)=>{
    try {
        return new Promise((resolve)=>{
            const img = new Image();
            img.src = url;
            img.onload = ()=>{
                img.width = img.naturalWidth;
                img.height = img.naturalHeight;
                resolve({
                    width: img.width,
                    height: img.height
                });
            };
            img.onerror = ()=>{
                console.log("Failed to load image:", url);
                resolve({});
            };
        });
    } catch (error) {
        console.error(error);
        return {};
    }
};
const loginUrl = ()=>{
    location.href = "/login?from=" + encodeURIComponent(window.location.href);
    return;
};
const browserCheck = ()=>{
    const parser = new (ua_parser_js__WEBPACK_IMPORTED_MODULE_0___default())();
    const result = parser.getResult();
    console.log(`Browser: ${result.browser.name}`);
    console.log(`Version: ${result.browser.version} / ${result?.browser?.major}`);
    if (result?.browser?.name === "Chrome" && parseInt(result?.browser?.major) < 32) {
        return true;
    } else if (result?.browser?.name === "Edge" && parseInt(result?.browser?.major) < 18) {
        return true;
    } else if (result?.browser?.name === "Safari" && parseInt(result?.browser?.major) < 16) {
        return true;
    } else if (result?.browser?.name === "Firefox" && parseInt(result?.browser?.major) < 65) {
        return true;
    } else if (result?.browser?.name === "Opera" && parseInt(result?.browser?.major) < 19) {
        return true;
    } else if (result?.browser?.name === "IE") {
        return true;
    }
    return false;
};
const getNewUIDGenerator = ()=>{
    let lastID = -1;
    return ()=>{
        lastID += 1;
        return lastID;
    };
};
const commonCopyText = (value, data, message)=>{
    const logParam = window?.logger.getParams(window?.logger.EID.COMMON_CLICK, window?.logger.EVENT_TYPE.CLICK, {
        type: "copy",
        ...data
    });
    window?.logger.log([
        logParam
    ]);
    (0,_components_Toast__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z)({
        message: message,
        duration: 3000,
        type: "success"
    });
    // 创建一个临时textarea元素
    const textarea = document.createElement("textarea");
    // 设置textarea的值为要复制的文本
    textarea.value = value;
    // 将textarea添加到DOM中
    document.body.appendChild(textarea);
    // 选择textarea中的文本
    textarea.select();
    // 执行复制操作
    document.execCommand("copy");
    // 移除临时textarea元素
    document.body.removeChild(textarea);
// navigator.clipboard?.writeText(value)
};


/***/ }),

/***/ 7550:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3159);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_style_module_css__WEBPACK_IMPORTED_MODULE_2__);



const Button = ({ type ="primary" , onClick , style , children  })=>{
    return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("button", {
        className: `${(_style_module_css__WEBPACK_IMPORTED_MODULE_2___default().button)} ${(_style_module_css__WEBPACK_IMPORTED_MODULE_2___default())[type]}`,
        onClick: onClick,
        style: style,
        children: children
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Button);


/***/ }),

/***/ 3962:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (/* binding */ CustomLink)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1853);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__);



// typically you want to use `next/link` for this usecase
// but this example shows how you can also access the router
// and use it manually
function CustomLink({ children , href , target , prefetch =false , replace =false , shallow =false , ...props }) {
    const router = (0,next_router__WEBPACK_IMPORTED_MODULE_1__.useRouter)();
    (0,react__WEBPACK_IMPORTED_MODULE_2__.useEffect)(()=>{
        if (prefetch) {
            router.prefetch(href);
        }
    }, [
        router,
        href,
        prefetch
    ]);
    return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("a", {
        ...props,
        href: href,
        onClick: (event)=>{
            event.preventDefault();
            if (replace) {
                router.replace(href, undefined, {
                    shallow
                });
            } else if (target) {
                window.open(href);
            } else {
                router.push(href, undefined, {
                    shallow
                });
            }
        },
        children: children
    });
}


/***/ }),

/***/ 695:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(323);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_style_module_css__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var _components_CustomLink__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3962);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1853);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _hooks_createContext__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2228);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1377);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(next_i18next__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var _common_constans_international__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3413);








const Menu = ()=>{
    const { t  } = (0,next_i18next__WEBPACK_IMPORTED_MODULE_5__.useTranslation)("common");
    const [screenWidth, setScreenWidth] = (0,react__WEBPACK_IMPORTED_MODULE_4__.useState)(0);
    (0,react__WEBPACK_IMPORTED_MODULE_4__.useEffect)(()=>{
        const handleResize = ()=>{
            setScreenWidth(window.innerWidth);
        };
        window.addEventListener("resize", handleResize);
        handleResize();
        return ()=>window.removeEventListener("resize", handleResize);
    }, [
        screenWidth
    ]);
    const { userInfos: [userInfos]  } = (0,react__WEBPACK_IMPORTED_MODULE_4__.useContext)(_hooks_createContext__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z);
    const router = (0,next_router__WEBPACK_IMPORTED_MODULE_2__.useRouter)();
    return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
        className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().menu),
        children: router.pathname !== "/login" && router.pathname !== "/loginI18n" && router.pathname !== "/perfect" && screenWidth > 587 && _common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .HEAD_MENU.map */ .Ul.map((item, index)=>{
            return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                className: `ag14 ${(_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().menuItem)}`,
                style: router.pathname === item.href ? {
                    color: "var(--PrimaryColor6)"
                } : undefined,
                children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_CustomLink__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z, {
                    href: item.key === "workstation" && !userInfos ? "/login" : item.href,
                    target: item.key === "blog" ? "_blank" : "",
                    children: t("menu", {
                        returnObjects: true
                    })[item?.key]
                })
            }, index);
        })
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Menu);


/***/ }),

/***/ 7184:
/***/ ((module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _CustomLink__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3962);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(4947);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(_style_module_css__WEBPACK_IMPORTED_MODULE_12__);
/* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5675);
/* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_image__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _Button__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7550);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1853);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var _components_Logout__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1251);
/* harmony import */ var _pages_api_base__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8502);
/* harmony import */ var _hooks_createContext__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(2228);
/* harmony import */ var _components_Menu__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(695);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(1377);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(next_i18next__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var _common_constans_international__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(3413);
var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_components_Logout__WEBPACK_IMPORTED_MODULE_6__, _pages_api_base__WEBPACK_IMPORTED_MODULE_7__]);
([_components_Logout__WEBPACK_IMPORTED_MODULE_6__, _pages_api_base__WEBPACK_IMPORTED_MODULE_7__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);













const Header = ()=>{
    const { t  } = (0,next_i18next__WEBPACK_IMPORTED_MODULE_10__.useTranslation)("common");
    const { segementModal: [segementModal] , userInfos: [userInfos, setUserInfos] , powerBalanceAmount: [powerBalanceAmount, setPowerBalance]  } = (0,react__WEBPACK_IMPORTED_MODULE_4__.useContext)(_hooks_createContext__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .Z);
    const [loginNum, setLoginNum] = (0,react__WEBPACK_IMPORTED_MODULE_4__.useState)(0);
    const router = (0,next_router__WEBPACK_IMPORTED_MODULE_5__.useRouter)();
    const [GPUinfo, setGPUinfo] = (0,react__WEBPACK_IMPORTED_MODULE_4__.useState)();
    (0,react__WEBPACK_IMPORTED_MODULE_4__.useEffect)(()=>{
        if (router.pathname !== "/login" && router.pathname !== "/loginI18n" && router.pathname !== "/perfect" && router.pathname !== "/free") {
            const queryUserInfo = async ()=>{
                const value = await (0,_pages_api_base__WEBPACK_IMPORTED_MODULE_7__/* .getUser */ .PR)({
                    noLogin: true
                });
                if (value) {
                    if (!value?.isAgency && router.pathname === "/union") {
                        await router.push("/");
                    }
                    setPowerBalance(value?.powerBalanceAmount);
                    setLoginNum(1);
                    setUserInfos(value);
                    if (router.pathname === "/") {
                        router.push("/workspace");
                    }
                } else {
                    setLoginNum(2);
                }
            };
            queryUserInfo();
        }
    }, []);
    // 点击logo跳转
    const clickLogo = ()=>{
        if (_common_constans_international__WEBPACK_IMPORTED_MODULE_11__/* .IS_LOCAL */ .Kc) {
            router.push("https://www.weshop.com");
        } else {
            if (userInfos?.uid) {
                router.push("/workspace");
            } else {
                router.push("/");
            }
        }
    };
    (0,react__WEBPACK_IMPORTED_MODULE_4__.useEffect)(()=>{
        if (!_common_constans_international__WEBPACK_IMPORTED_MODULE_11__/* .IS_SHOW_GPU */ .Cu) return;
        let isRequestCompleted = true;
        const fetchData = async ()=>{
            try {
                await showGPUinfo();
            } catch (error) {
                console.error(error);
            }
            isRequestCompleted = true;
        };
        const startPolling = ()=>{
            if (!isRequestCompleted) return;
            isRequestCompleted = false;
            fetchData();
        };
        startPolling();
        let intervalId = null;
        intervalId = setInterval(startPolling, 3000) // Start polling with a delay of 3 seconds
        ;
        return ()=>{
            if (intervalId) clearInterval(intervalId);
        };
    }, []);
    const showGPUinfo = async ()=>{
        const value = await (0,_pages_api_base__WEBPACK_IMPORTED_MODULE_7__/* .getGpuInfo */ .Se)();
        if (value) setGPUinfo(value);
    };
    return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("header", {
        className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().headerWrap),
        children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
            className: `${(_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().header)} ${segementModal ? (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().zIndex) : ""}`,
            children: [
                /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().menuWrap),
                    children: [
                        /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                            onClick: clickLogo,
                            style: {
                                cursor: "pointer"
                            },
                            children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_2___default()), {
                                src: _common_constans_international__WEBPACK_IMPORTED_MODULE_11__/* .PAGE_LOGO */ .xt,
                                alt: "picture for logo",
                                width: 144,
                                height: 32
                            })
                        }),
                        /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Menu__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z, {})
                    ]
                }),
                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().loginWrap),
                    children: GPUinfo && _common_constans_international__WEBPACK_IMPORTED_MODULE_11__/* .IS_SHOW_GPU */ .Cu ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                        className: `ag14 ${(_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().power)}`,
                        children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                            className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().powerLeft),
                            children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().num),
                                children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("span", {
                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().locationTip),
                                    children: [
                                        t("GPUInfo.GpuMake"),
                                        ": ",
                                        GPUinfo?.GpuMake,
                                        ",",
                                        " ",
                                        t("GPUInfo.GpuUtilization"),
                                        ": ",
                                        GPUinfo?.GpuUtilization,
                                        ",",
                                        " ",
                                        t("GPUInfo.vramUsage"),
                                        ": ",
                                        GPUinfo?.vramUsage
                                    ]
                                })
                            })
                        })
                    }) : null
                }),
                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
                    children: _common_constans_international__WEBPACK_IMPORTED_MODULE_11__/* .SHOW_COMPUTER_POWER */ .fo ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
                        className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().loginWrap),
                        children: [
                            /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                className: `ag14 ${(_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().power)}`,
                                children: loginNum === 1 ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().powerLeft),
                                    children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_CustomLink__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z, {
                                        href: `/member`,
                                        target: "_blank",
                                        children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
                                            className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().num),
                                            children: [
                                                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_2___default()), {
                                                    src: "/cpu-charge.svg",
                                                    width: 20,
                                                    height: 20,
                                                    alt: "cpu-charge",
                                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().cpuCharge)
                                                }),
                                                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", {
                                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().primaryColor),
                                                    children: powerBalanceAmount
                                                }),
                                                t("computerPower"),
                                                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("span", {
                                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().buy),
                                                    children: t("purchase")
                                                })
                                            ]
                                        })
                                    })
                                }) : loginNum === 2 ? /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(_CustomLink__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z, {
                                    href: `/member`,
                                    children: [
                                        " ",
                                        t("pricing")
                                    ]
                                }) : null
                            }),
                            loginNum === 1 ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_components_Logout__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .Z, {
                                isMobile: false,
                                uname: userInfos?.uname
                            }) : loginNum === 2 ? router.pathname !== "/login" && router.pathname !== "/perfect" && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_CustomLink__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z, {
                                href: `/login?from=${encodeURIComponent(window.location.href)}`,
                                children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().joinIn),
                                    children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_Button__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {
                                        style: {
                                            borderRadius: "6px",
                                            fontSize: "14px",
                                            fontWeight: "400",
                                            lineHeight: "22px",
                                            padding: "0 20px"
                                        },
                                        children: t("loginSignUp")
                                    })
                                })
                            }) : null
                        ]
                    }) : null
                })
            ]
        })
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Header);

__webpack_async_result__();
} catch(e) { __webpack_async_result__(e); } });

/***/ }),

/***/ 2758:
/***/ ((module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(968);
/* harmony import */ var next_head__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(next_head__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _Header__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7184);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(5254);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(_style_module_css__WEBPACK_IMPORTED_MODULE_12__);
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5725);
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(antd__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _hooks_createContext__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2228);
/* harmony import */ var _common_constans_international__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3413);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(1377);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(next_i18next__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var _common_utils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(8208);
/* harmony import */ var _RequestLoading__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(4385);
/* harmony import */ var _MobileHeader__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(6449);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(1853);
/* harmony import */ var next_router__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(next_router__WEBPACK_IMPORTED_MODULE_11__);
var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_Header__WEBPACK_IMPORTED_MODULE_3__]);
_Header__WEBPACK_IMPORTED_MODULE_3__ = (__webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__)[0];















const Layout = ({ children , title =_common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .PAGE_TITLE */ .Ti  })=>{
    const { t  } = (0,next_i18next__WEBPACK_IMPORTED_MODULE_7__.useTranslation)("common");
    const { requestLoading: [requestLoading]  } = (0,react__WEBPACK_IMPORTED_MODULE_2__.useContext)(_hooks_createContext__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .Z);
    const [isMobile, setIsMobile] = (0,react__WEBPACK_IMPORTED_MODULE_2__.useState)(false);
    const [browserStatus, setBrowserStatus] = (0,react__WEBPACK_IMPORTED_MODULE_2__.useState)(false);
    const [noticeShow, setNoticeShow] = (0,react__WEBPACK_IMPORTED_MODULE_2__.useState)(false);
    const isWorkspace = (0,next_router__WEBPACK_IMPORTED_MODULE_11__.useRouter)().pathname == "/workspace";
    (0,react__WEBPACK_IMPORTED_MODULE_2__.useEffect)(()=>{
        if (!_common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .IS_LOCAL */ .Kc && _common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .IS_EN */ .jY) {
            setNoticeShow(true);
        }
    }, []);
    (0,react__WEBPACK_IMPORTED_MODULE_2__.useEffect)(()=>{
        const isMobileDevice = /(android|iphone|ipad|mobile)/i.test(navigator.userAgent);
        setIsMobile(isMobileDevice);
        const check = (0,_common_utils__WEBPACK_IMPORTED_MODULE_8__/* .browserCheck */ .VK)();
        setBrowserStatus(check);
        if (false) {}
    }, []);
    return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
        children: [
            /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((next_head__WEBPACK_IMPORTED_MODULE_1___default()), {
                children: [
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("title", {
                        children: title
                    }),
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", {
                        name: "baidu-site-verification",
                        content: "codeva-p7MgIbmFl0"
                    }),
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", {
                        name: "viewport",
                        content: "width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
                    }),
                     false ? /*#__PURE__*/ 0 : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
                        children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("meta", {
                            name: "description",
                            content: "WeShop唯象妙境是国内首款AI商拍工具，专注电商产品图片的智能生成。品牌方无需再受到模特、经纪、摄影、后期、场租、机酒的限制，在高效产出优质商品图的同时，还能大幅节约拍摄成本。用WeShop唯象妙境，鼠标就是快门，点击即看成片。"
                        })
                    }),
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("link", {
                        rel: "icon",
                        href: _common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .PAGE_FAVICON */ .QS
                    })
                ]
            }),
            isMobile ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_MobileHeader__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .Z, {}) : /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_Header__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .Z, {}),
            /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("main", {
                className: (_style_module_css__WEBPACK_IMPORTED_MODULE_12___default().main),
                children: [
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(antd__WEBPACK_IMPORTED_MODULE_4__.Modal, {
                        open: browserStatus,
                        closable: false,
                        maskClosable: false,
                        footer: null,
                        children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("p", {
                            children: t("bowserHint")
                        })
                    }),
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                        style: {
                            marginTop: isWorkspace && noticeShow ? "calc(var(--HeaderHeight) + 48px)" : "0"
                        },
                        children: children
                    }),
                    requestLoading ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_RequestLoading__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .Z, {}) : null
                ]
            })
        ]
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Layout);

__webpack_async_result__();
} catch(e) { __webpack_async_result__(e); } });

/***/ }),

/***/ 1251:
/***/ ((module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.a(module, async (__webpack_handle_async_dependencies__, __webpack_async_result__) => { try {
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5675);
/* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(next_image__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(5654);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_style_module_css__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _pages_api_base__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8502);
/* harmony import */ var _hooks_createContext__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2228);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(1377);
/* harmony import */ var next_i18next__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(next_i18next__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var _common_constans_international__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3413);
var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([_pages_api_base__WEBPACK_IMPORTED_MODULE_3__]);
_pages_api_base__WEBPACK_IMPORTED_MODULE_3__ = (__webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__)[0];








const Logout = ({ uname , isMobile  })=>{
    const { t  } = (0,next_i18next__WEBPACK_IMPORTED_MODULE_5__.useTranslation)("common");
    const { userInfos: [userInfos, setUserInfos]  } = (0,react__WEBPACK_IMPORTED_MODULE_2__.useContext)(_hooks_createContext__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .Z);
    const [isCardVisible, setCardVisibility] = (0,react__WEBPACK_IMPORTED_MODULE_2__.useState)(false);
    const cardRef = (0,react__WEBPACK_IMPORTED_MODULE_2__.useRef)(null);
    const imageRef = (0,react__WEBPACK_IMPORTED_MODULE_2__.useRef)(null);
    // const [hoverDiv, setHoverDiv] = useState(false)
    (0,react__WEBPACK_IMPORTED_MODULE_2__.useEffect)(()=>{
        const handleClickOutside = (event)=>{
            if (cardRef.current && !cardRef.current.contains(event.target) && imageRef.current && !imageRef.current.contains(event.target)) {
                openCard(false);
            }
        };
        document.addEventListener("mousedown", handleClickOutside);
        return ()=>{
            document.removeEventListener("mousedown", handleClickOutside);
        };
    }, []);
    const buttonInfos = [
        {
            key: "mComputerPower",
            label: t("mComputerPower"),
            router: "/member",
            imgSvg: "/member-user.svg",
            imgAlt: "member-user for logo",
            isShow: !isMobile,
            marginTop: true,
            borderBottom: false
        },
        {
            key: "mOrder",
            label: t("mOrder"),
            router: "/order",
            imgSvg: "/receipt-text.svg",
            imgAlt: "receipt-text for logo",
            isShow: !isMobile,
            marginTop: false,
            borderBottom: false
        },
        {
            key: "我的推广",
            label: "我的推广",
            router: "/union",
            imgSvg: "/empty-wallet.svg",
            imgAlt: "mpty-wallet for logo",
            isShow: userInfos?.isAgency,
            marginTop: false,
            borderBottom: true
        },
        {
            key: "mReferrals",
            label: "My Referrals",
            router: "/referral",
            imgSvg: "/ic_menu_referral.svg",
            imgAlt: "referrals",
            isShow: !_common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .IS_CN */ .RD,
            marginTop: false,
            borderBottom: true
        },
        {
            key: "我的API",
            label: t("mApiKey"),
            router: "/apiKey",
            imgSvg: "/api.svg",
            imgAlt: "apiKey for logo",
            isShow: _common_constans_international__WEBPACK_IMPORTED_MODULE_6__/* .IS_CN */ .RD,
            marginTop: true,
            borderBottom: true
        },
        {
            key: "logout",
            label: t("logout"),
            router: "/logout",
            imgSvg: "/logout.svg",
            imgAlt: "logout for logo",
            isShow: true,
            marginTop: true,
            borderBottom: false
        }
    ];
    const openCard = (isOpen)=>{
        setCardVisibility(isOpen);
    // setHoverDiv(isOpen)
    };
    const handleJump = async (path)=>{
        if (path === "/logout") {
            await (0,_pages_api_base__WEBPACK_IMPORTED_MODULE_3__/* .joinOut */ .pz)();
            setUserInfos(null);
            location.reload();
        } else {
            await window.open(path);
        }
    };
    return /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
        children: [
            /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_1___default()), {
                className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().avatar),
                ref: imageRef,
                src: "/ic_user_default.svg",
                alt: "user for logo",
                width: 32,
                height: 32,
                onClick: ()=>{
                    openCard(!isCardVisible);
                }
            }),
            isCardVisible && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
                ref: cardRef,
                className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().userInfoCard),
                children: [
                    /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
                        className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().logoutHeader),
                        children: [
                            /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().userImg),
                                children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_1___default()), {
                                    src: "/ic_user_default.svg",
                                    alt: "user info for logo",
                                    width: 64,
                                    height: 64
                                })
                            }),
                            /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                className: `${(_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().userUname)} ag16`,
                                children: uname
                            }),
                            /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                className: `${(_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().memberType)} ag12`,
                                children: userInfos?.planName
                            })
                        ]
                    }),
                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                        className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().logoutContent),
                        children: buttonInfos.map((item, index)=>{
                            return item.isShow && /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)((react__WEBPACK_IMPORTED_MODULE_2___default().Fragment), {
                                children: [
                                    /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                        className: `${(_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().clickDiv)} ${(_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().avatar)}`,
                                        onClick: ()=>handleJump(item.router),
                                        style: item?.marginTop ? {
                                            marginTop: "8px"
                                        } : {},
                                        children: /*#__PURE__*/ (0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsxs)("div", {
                                            className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().clickTextDiv),
                                            children: [
                                                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_1___default()), {
                                                    className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().clickSvg),
                                                    src: item.imgSvg,
                                                    alt: item.imgAlt,
                                                    width: 16,
                                                    height: 16
                                                }),
                                                /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                                    className: `${(_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().clickTitleDiv)} ag14`,
                                                    children: item.label
                                                })
                                            ]
                                        })
                                    }),
                                    item.borderBottom && /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                                        className: (_style_module_css__WEBPACK_IMPORTED_MODULE_7___default().buttonDivider)
                                    })
                                ]
                            }, `button_${index}`);
                        })
                    })
                ]
            })
        ]
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Logout);

__webpack_async_result__();
} catch(e) { __webpack_async_result__(e); } });

/***/ }),

/***/ 6449:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _CustomLink__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3962);
/* harmony import */ var _Header_style_module_css__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(4947);
/* harmony import */ var _Header_style_module_css__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_Header_style_module_css__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5675);
/* harmony import */ var next_image__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(next_image__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _common_constans_international__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3413);





const MobileHeader = ()=>{
    return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("header", {
        className: (_Header_style_module_css__WEBPACK_IMPORTED_MODULE_4___default().headerWrap),
        children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
            className: (_Header_style_module_css__WEBPACK_IMPORTED_MODULE_4___default().header),
            children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
                className: (_Header_style_module_css__WEBPACK_IMPORTED_MODULE_4___default().menuWrap),
                children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(_CustomLink__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .Z, {
                    href: "/",
                    children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx((next_image__WEBPACK_IMPORTED_MODULE_2___default()), {
                        src: _common_constans_international__WEBPACK_IMPORTED_MODULE_3__/* .PAGE_LOGO */ .xt,
                        alt: "picture for logo",
                        width: 290,
                        height: 36,
                        className: `${_common_constans_international__WEBPACK_IMPORTED_MODULE_3__/* .IS_CN */ .RD ? (_Header_style_module_css__WEBPACK_IMPORTED_MODULE_4___default().cnLogo) : ""} ${(_Header_style_module_css__WEBPACK_IMPORTED_MODULE_4___default().weshopLogo)}`
                    })
                })
            })
        })
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (MobileHeader);


/***/ }),

/***/ 4385:
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "Z": () => (__WEBPACK_DEFAULT_EXPORT__)
/* harmony export */ });
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(997);
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3435);
/* harmony import */ var _style_module_css__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_style_module_css__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5725);
/* harmony import */ var antd__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(antd__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6689);
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_2__);




const RequesLoading = ()=>{
    const [isShow, setShow] = (0,react__WEBPACK_IMPORTED_MODULE_2__.useState)(false);
    (0,react__WEBPACK_IMPORTED_MODULE_2__.useEffect)(()=>{
        const timeId = setTimeout(()=>{
            setShow(true);
        }, 500);
        return ()=>{
            clearTimeout(timeId);
        };
    }, []);
    return /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.Fragment, {
        children: isShow ? /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx("div", {
            className: (_style_module_css__WEBPACK_IMPORTED_MODULE_3___default().mask),
            children: /*#__PURE__*/ react_jsx_runtime__WEBPACK_IMPORTED_MODULE_0__.jsx(antd__WEBPACK_IMPORTED_MODULE_1__.Spin, {
                size: "large"
            })
        }) : null
    });
};
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (RequesLoading);


/***/ })

};
;