(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode(".api-render-page{display:flex!important;flex-direction:column!important;height:100%!important;background:#f7f3e8!important;padding:16px!important;box-sizing:border-box!important;width:100%!important;overflow-x:hidden!important}.event-status-bar{display:flex;align-items:center;gap:12px;padding:10px 16px;background:linear-gradient(135deg,#667eea,#764ba2);border-radius:8px;margin-bottom:12px;color:#fff;font-size:13px}.event-code{font-weight:600}.event-type{padding:2px 10px;border-radius:12px;font-size:11px;font-weight:500;text-transform:uppercase}.event-type.tool_event_start{background:#ffc1074d;color:#ffc107}.event-type.tool_event_end{background:#4caf504d;color:#4caf50}.event-type.tool_event_process{background:#2196f34d;color:#2196f3}.update-params{font-family:monospace;background:#ffffff26;padding:2px 8px;border-radius:4px;font-size:11px}.store-info-panel{background:#fff;border-radius:8px;box-shadow:0 1px 3px #00000014;margin-bottom:12px;overflow:hidden}.store-info-panel .panel-header{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#fafafa;border-bottom:1px solid #eee}.store-info-panel .panel-header h3{margin:0;font-size:15px;color:#333;font-weight:600}.store-id{font-size:12px;color:#999;font-family:monospace}.store-info-content{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px;padding:16px}.info-row{display:flex;gap:8px;font-size:13px}.info-label{color:#888;white-space:nowrap}.info-value{color:#333;font-weight:500}.info-value.store-name{font-size:18px;font-weight:600;color:#c41e3a}.detail-grid{display:flex;flex-direction:row;width:100%;gap:12px;overflow:hidden}.detail-grid .steps-panel,.detail-grid .ingredient-panel{flex:1;min-width:0;overflow:hidden}.empty-store{display:flex;flex-direction:column;align-items:center;justify-content:center;height:300px;background:#fff;border-radius:8px;color:#999;text-align:center}.empty-store p{margin:4px 0}.empty-store .hint{font-size:12px;color:#ccc}.render-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px}.dish-info{display:flex;align-items:center;gap:12px}.dish-name{margin:0;font-size:24px;color:#c41e3a;font-weight:600}.dish-tags{display:flex;gap:8px}.tag{padding:4px 12px;border-radius:16px;font-size:13px;font-weight:500}.tag.cuisine{background:#fff0f0;color:#c41e3a;border:1px solid #ffcdd2}.tag.category{background:#e3f2fd;color:#1976d2;border:1px solid #bbdefb}.dish-meta{display:flex;gap:20px}.meta-item{font-size:14px;color:#666}.meta-item.cost{color:#c41e3a;font-weight:600}.clear-all-btn{padding:6px 12px;border:1px solid #ddd;border-radius:4px;background:#fff;color:#666;font-size:12px;cursor:pointer}.clear-all-btn:hover{background:#f5f5f5}.edit-tip{display:flex;justify-content:space-between;margin-bottom:12px;font-size:12px;color:#999}.render-grid{display:grid;grid-template-columns:1.5fr 1fr;grid-template-rows:1fr 1fr;gap:12px;flex:1;min-height:0}.grid-card{background:#fff;border-radius:8px;box-shadow:0 1px 3px #00000014;display:flex;flex-direction:column;overflow:hidden}.card-header{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#fafafa;border-bottom:1px solid #eee}.card-header h3{margin:0;font-size:15px;color:#333;font-weight:600}.card-toggle{color:#999;font-size:16px;cursor:pointer}.card-content{flex:1;overflow:auto;padding:12px 16px}.empty-card{display:flex;align-items:center;justify-content:center;height:100px;color:#999;font-size:13px}.data-table{width:100%;border-collapse:collapse;font-size:13px}.data-table th{text-align:left;padding:8px 10px;background:#f5f5f5;color:#666;font-weight:500;border-bottom:2px solid #e0e0e0;white-space:nowrap}.data-table td{padding:8px 10px;border-bottom:1px solid #f0f0f0;color:#333}.data-table tbody tr:nth-child(2n){background:#fafafa}.data-table tbody tr:hover{background:#f5f5f5}.process-card{grid-column:1;grid-row:1}.col-num{width:30px;text-align:center!important;color:#999}.col-name{width:120px}.col-role{width:70px}.col-time{width:60px}.col-points{color:#888!important;font-size:12px}.role-badge{display:inline-block;padding:2px 8px;border-radius:12px;font-size:11px;font-weight:500}.role-gray{background:#f0f0f0;color:#666}.role-green{background:#e8f5e9;color:#2e7d32}.role-blue{background:#e3f2fd;color:#1565c0}.role-orange{background:#fff3e0;color:#e65100}.role-purple{background:#f3e5f5;color:#7b1fa2}.card-footer{display:flex;justify-content:space-between;align-items:center;margin-top:12px;padding-top:12px;border-top:1px solid #eee}.summary{font-size:12px;color:#666}.add-btn{padding:6px 12px;border:1px dashed #ccc;border-radius:4px;background:transparent;color:#666;font-size:12px;cursor:pointer;transition:all .2s}.add-btn:hover{border-color:#667eea;color:#667eea}.cost-card{grid-column:2;grid-row:1}.cost-card .subtotal{font-weight:500;color:#333}.cost-total{display:flex;justify-content:flex-end;align-items:center;gap:12px;margin-top:12px;padding-top:12px;border-top:1px solid #eee;font-size:14px}.cost-total .total-value{font-size:18px;font-weight:600;color:#c41e3a}.scenario-card{grid-column:1;grid-row:2}.scenario-list{list-style:none;padding:0;margin:0}.scenario-list li{display:flex;align-items:flex-start;gap:10px;padding:8px 0;font-size:14px;color:#333}.scenario-list .bullet{width:6px;height:6px;border-radius:50%;background:#ff9800;margin-top:6px;flex-shrink:0}.schedule-card{grid-column:2;grid-row:2}.schedule-card .impact{color:#c41e3a;font-weight:500;font-family:monospace}.schedule-card .status{color:#4caf50;font-weight:500}.schedule-footer{margin-top:12px;padding-top:12px;border-top:1px solid #eee;font-size:12px;color:#4caf50;text-align:center}.render-footer{display:flex;justify-content:space-between;align-items:center;margin-top:12px;padding-top:12px;border-top:1px solid #e0e0e0}.footer-right{display:flex;gap:12px}.action-btn{padding:10px 20px;border-radius:6px;font-size:14px;cursor:pointer;transition:all .2s}.action-btn.save{background:#fff;border:1px solid #8d6e63;color:#5d4037}.action-btn.save:hover{background:#f5f5f5}.action-btn.stock{background:#5d4037;border:none;color:#fff}.action-btn.stock:hover{background:#4e342e}@media (max-width: 1200px){.render-grid{grid-template-columns:1fr;grid-template-rows:auto}.process-card,.cost-card,.scenario-card,.schedule-card{grid-column:1;grid-row:auto}}.ingredient-panel{background:#fff;border-radius:8px;box-shadow:0 1px 3px #00000014;overflow:hidden;display:flex;flex-direction:column;height:100%}.ingredient-panel .panel-header{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#fafafa;border-bottom:1px solid #eee}.ingredient-panel .panel-header h3{margin:0;font-size:15px;color:#333;font-weight:600}.ingredient-count{font-size:12px;color:#999;font-family:monospace}.ingredient-table-container{padding:0;flex:1;overflow:auto}.ingredient-panel>.panel-header,.ingredient-panel>.ingredient-footer{flex-shrink:0}.ingredient-panel>.ingredient-table-container{flex:1 1 auto;overflow:auto;min-height:0}.ingredient-table{width:100%;border-collapse:collapse;font-size:13px}.ingredient-table th{text-align:left;padding:10px 16px;background:#fafafa;color:#666;font-weight:500;border-bottom:2px solid #e0e0e0;white-space:nowrap}.ingredient-table td{padding:10px 16px;border-bottom:1px solid #f0f0f0;color:#333}.ingredient-table tbody tr:nth-child(2n){background:#fafafa}.ingredient-table tbody tr:hover{background:#f5f5f5}.ingredient-table .col-ingredient{width:auto}.ingredient-type-badge{display:inline-block;padding:2px 8px;border-radius:4px;font-size:11px;font-weight:500;margin-right:8px;background:#e8f5e9;color:#2e7d32}.ingredient-table .col-amount,.ingredient-table .col-unit-price{width:100px;text-align:right}.ingredient-table .col-subtotal{width:100px;text-align:right;font-weight:500;color:#c41e3a}.ingredient-footer{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#fafafa;border-top:1px solid #eee}.cost-summary{display:flex;align-items:center;gap:12px;font-size:14px}.cost-label{color:#666}.cost-value{font-size:18px;font-weight:600;color:#c41e3a}.ingredient-pagination{display:flex;align-items:center;gap:12px}.ingredient-pagination .page-btn{padding:4px 12px;border:1px solid #ddd;border-radius:4px;background:#fff;color:#666;font-size:12px;cursor:pointer;transition:all .2s}.ingredient-pagination .page-btn:hover:not(:disabled){border-color:#667eea;color:#667eea}.ingredient-pagination .page-btn:disabled{opacity:.5;cursor:not-allowed}.ingredient-pagination .page-info{font-size:12px;color:#999}.cell-truncate{cursor:pointer;max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cell-expanded{cursor:pointer;white-space:normal;word-break:break-all;min-width:300px;max-width:none;width:auto;background-color:#fffbe6;padding:8px 12px;border-radius:4px;position:relative;z-index:10;box-shadow:0 2px 8px #00000026}.cell-truncate:hover{background-color:#f5f5f5}.steps-panel{background:#fff;border-radius:8px;box-shadow:0 1px 3px #00000014;overflow:hidden;display:flex;flex-direction:column;height:100%}.steps-panel .panel-header{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:#fafafa;border-bottom:1px solid #eee}.steps-panel .panel-header h3{margin:0;font-size:15px;color:#333;font-weight:600}.steps-count{font-size:12px;color:#999;font-family:monospace}.steps-table-container{padding:0;flex:1;overflow:auto}.steps-panel>.panel-header,.steps-panel>.steps-footer{flex-shrink:0}.steps-panel>.steps-table-container{flex:1 1 auto;overflow:auto;min-height:0}.steps-table{width:100%;border-collapse:collapse;font-size:13px}.steps-table th{text-align:left;padding:10px 16px;background:#fafafa;color:#666;font-weight:500;border-bottom:2px solid #e0e0e0;white-space:nowrap}.steps-table td{padding:10px 16px;border-bottom:1px solid #f0f0f0;color:#333}.steps-table tbody tr:nth-child(2n){background:#fafafa}.steps-table tbody tr:hover{background:#f5f5f5}.steps-table .col-step-num{width:50px;text-align:center;color:#999;font-weight:500}.steps-table .col-step-desc{width:auto}.steps-table .col-step-cause{min-width:150px;max-width:250px;color:#666}.steps-table .col-step-points{min-width:150px;max-width:250px;color:#ff9800}.steps-table .col-step-duration{width:80px;text-align:right;color:#666}.steps-footer{display:flex;justify-content:flex-end;align-items:center;padding:12px 16px;background:#fafafa;border-top:1px solid #eee}.steps-summary{font-size:14px;color:#666}.steps-summary .total-duration{font-weight:600;color:#c41e3a}.dish-create-panel{background:#fff;border-radius:8px;box-shadow:0 1px 3px #00000014;margin-bottom:12px;overflow:hidden}.dish-create-panel .panel-header{display:flex;justify-content:space-between;align-items:center;padding:12px 16px;background:linear-gradient(135deg,#ff9800,#f57c00);border-bottom:1px solid #eee}.dish-create-panel.completed .panel-header{background:linear-gradient(135deg,#eee,#e0e0e0)}.dish-create-panel .panel-header h3{margin:0;font-size:15px;color:#fff;font-weight:600}.dish-create-panel.completed .panel-header h3{color:#ff8f00}.dish-status.creating{padding:4px 12px;border-radius:12px;font-size:12px;font-weight:500;background:#ffffff40;color:#fff}.dish-status.completed{padding:4px 12px;border-radius:12px;font-size:12px;font-weight:500;background:#00000014;color:#c62828}.dish-create-content{padding:16px}.dish-basic-info{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.dish-basic-info .dish-name{font-size:20px;font-weight:600;color:#c41e3a}.dish-store-id{display:flex;align-items:center;gap:6px;padding:4px 10px;background:#f5f5f5;border-radius:4px;font-size:13px}.dish-store-id .label{color:#888}.dish-store-id .value{color:#333;font-weight:500;font-family:monospace}.dish-scene{display:flex;align-items:center;gap:8px;padding:8px 12px;background:#fff8e1;border-radius:6px}.scene-label{font-size:13px;color:#ff8f00;font-weight:500;white-space:nowrap}.scene-value{font-size:13px;color:#333}.modal-overlay{position:fixed;top:0;left:0;right:0;bottom:0;background:#00000080;display:flex;align-items:center;justify-content:center;z-index:1000}.modal-content{background:#fff;border-radius:12px;width:420px;max-width:90%;box-shadow:0 4px 20px #00000026}.modal-header{display:flex;justify-content:space-between;align-items:center;padding:16px 20px;border-bottom:1px solid #eee}.modal-header h3{margin:0;font-size:18px;color:#333}.modal-close{background:none;border:none;font-size:24px;color:#999;cursor:pointer;line-height:1}.modal-close:hover{color:#666}.modal-body{padding:20px}.modal-body p{margin:0 0 16px;color:#666}.stock-summary{background:#fafafa;border-radius:8px;padding:16px}.stock-item{display:flex;justify-content:space-between;padding:8px 0;border-bottom:1px solid #eee}.stock-item:last-child{border-bottom:none}.stock-label{color:#666;font-size:14px}.stock-value{color:#333;font-size:14px;font-weight:500}.modal-footer{display:flex;justify-content:flex-end;gap:12px;padding:16px 20px;border-top:1px solid #eee;background:#fafafa;border-radius:0 0 12px 12px}.btn{padding:10px 24px;border-radius:6px;font-size:14px;cursor:pointer;transition:all .2s}.btn:disabled{opacity:.6;cursor:not-allowed}.btn-cancel{background:#fff;border:1px solid #ddd;color:#666}.btn-cancel:hover:not(:disabled){background:#f5f5f5}.btn-confirm{background:#5d4037;border:none;color:#fff}.btn-confirm:hover:not(:disabled){background:#4e342e}*{box-sizing:border-box}body{margin:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;background:#f7f3e8}.app-container{height:100vh;display:flex;flex-direction:column}.app-main{flex:1;padding:16px;overflow:hidden}*{margin:0;padding:0;box-sizing:border-box}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;background-color:#f5f5f5;color:#333;line-height:1.6}.app-container{min-height:100vh;padding:24px}.page-header{display:flex;align-items:center;gap:12px;margin-bottom:24px}.page-title{font-size:24px;font-weight:600;color:#1a1a1a}.page-subtitle{font-size:14px;color:#888}.main-content{display:grid;grid-template-columns:360px 1fr;gap:24px}.left-column,.right-column{display:flex;flex-direction:column;gap:20px}.card{background:#fff;border-radius:12px;box-shadow:0 2px 8px #0000000f;border:1px solid #e8e8e8;overflow:hidden}.card-header{padding:20px 24px;border-bottom:1px solid #f0f0f0;display:flex;justify-content:space-between;align-items:center}.card-header h3{font-size:16px;font-weight:600;color:#1a1a1a;display:flex;align-items:center;gap:8px}.card-body{padding:20px 24px}.dish-info-card{background:#fff;border-radius:12px;box-shadow:0 2px 8px #0000000f;border:1px solid #e8e8e8;overflow:hidden}.dish-info-header{padding:24px;border-bottom:1px solid #f0f0f0}.dish-name-row{display:flex;align-items:flex-start;gap:12px;margin-bottom:12px}.dish-name{font-size:24px;font-weight:600;color:#1a1a1a;flex:1}.dish-icon{width:40px;height:40px;background:linear-gradient(135deg,#ff6b6b,#ee5a24);border-radius:10px;display:flex;align-items:center;justify-content:center;font-size:20px}.dish-tags{display:flex;gap:8px;flex-wrap:wrap}.tag{padding:4px 12px;border-radius:16px;font-size:12px;font-weight:500}.tag-cuisine{background:#fff0e6;color:#ee5a24}.tag-type{background:#e6f7ff;color:#1890ff}.tag-version{background:#f5f5f5;color:#666}.dish-description{font-size:14px;color:#666;line-height:1.8;margin-top:16px;padding-top:16px;border-top:1px solid #f0f0f0}.dish-info-actions{padding:20px 24px;display:flex;gap:12px;justify-content:flex-end;background:#fafafa}.btn{padding:10px 20px;border-radius:8px;font-weight:500;cursor:pointer;transition:all .2s ease;border:none;font-size:14px}.btn-primary{background:linear-gradient(135deg,#667eea,#764ba2);color:#fff}.btn-primary:hover{transform:translateY(-2px);box-shadow:0 4px 12px #667eea66}.btn-default{background:#fff;border:1px solid #d9d9d9;color:#666}.btn-default:hover{border-color:#667eea;color:#667eea}.btn-danger{background:#fff1f0;border:1px solid #ffa39e;color:#ff4d4f}.btn-danger:hover{background:#ff4d4f;color:#fff}.step-list{display:flex;flex-direction:column;gap:0}.step-item{display:flex;gap:16px;padding:16px 0;border-bottom:1px solid #f5f5f5}.step-item:last-child{border-bottom:none}.step-order{width:28px;height:28px;background:#667eea;color:#fff;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:14px;font-weight:600;flex-shrink:0}.step-content{flex:1}.step-name{font-size:14px;font-weight:500;color:#333;margin-bottom:4px}.step-meta{font-size:12px;color:#888}.step-keypoint{margin-top:8px;padding:8px 12px;background:#f8f9fa;border-radius:6px;font-size:13px;color:#666;border-left:3px solid #667eea}.cost-table{width:100%;border-collapse:collapse}.cost-table th{background:#fafafa;padding:12px 16px;text-align:left;font-size:12px;font-weight:500;color:#888;border-bottom:1px solid #f0f0f0}.cost-table td{padding:14px 16px;border-bottom:1px solid #f5f5f5;font-size:14px;color:#333}.cost-table td:last-child{text-align:right;font-weight:500}.cost-total-row{background:linear-gradient(135deg,#667eea,#764ba2);color:#fff;border-radius:8px;margin-top:16px;padding:16px 20px;display:flex;justify-content:space-between;align-items:center}.cost-total-label{font-size:14px;font-weight:500}.cost-total-value{font-size:24px;font-weight:700}.schedule-list{display:flex;flex-direction:column;gap:0}.schedule-item{display:flex;align-items:center;gap:16px;padding:16px 0;border-bottom:1px solid #f5f5f5}.schedule-item:last-child{border-bottom:none}.chef-avatar{width:44px;height:44px;background:linear-gradient(135deg,#667eea,#764ba2);color:#fff;border-radius:50%;display:flex;align-items:center;justify-content:center;font-weight:600;font-size:16px}.chef-info{flex:1}.chef-name{font-size:14px;font-weight:500;color:#333;margin-bottom:2px}.chef-role{font-size:12px;color:#888}.chef-time{text-align:right}.chef-additional-time{font-size:18px;font-weight:600;color:#667eea}.chef-unit{font-size:12px;color:#888}.schedule-total{margin-top:16px;padding:16px 20px;background:#f8f9fa;border-radius:8px;display:flex;justify-content:space-between;align-items:center}.schedule-total-label{font-size:14px;color:#666}.schedule-total-value{font-size:20px;font-weight:700;color:#333}.scenario-list{display:flex;flex-direction:column;gap:12px}.scenario-item{padding:16px;background:#f8f9fa;border-radius:8px;font-size:14px;color:#333;line-height:1.6;border-left:3px solid #667eea}.data-table{width:100%;border-collapse:collapse}.data-table th{background:#fafafa;padding:12px 16px;text-align:left;font-size:13px;font-weight:500;color:#666;border-bottom:1px solid #f0f0f0}.data-table td{padding:14px 16px;border-bottom:1px solid #f5f5f5;font-size:14px;color:#333}.data-table tbody tr:hover{background:#fafafa}.data-table tbody tr:last-child td{border-bottom:none}.empty-state{text-align:center;padding:60px 20px;color:#999}.empty-state-icon{font-size:48px;margin-bottom:16px;opacity:.5}@media (max-width: 1024px){.main-content{grid-template-columns:1fr}.left-column{order:-1}}@media (max-width: 768px){.app-container{padding:16px}.dish-info-actions{flex-direction:column}.btn{width:100%}}")),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})(); (function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))r(l);new MutationObserver(l=>{for(const o of l)if(o.type==="childList")for(const i of o.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&r(i)}).observe(document,{childList:!0,subtree:!0});function n(l){const o={};return l.integrity&&(o.integrity=l.integrity),l.referrerPolicy&&(o.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?o.credentials="include":l.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(l){if(l.ep)return;l.ep=!0;const o=n(l);fetch(l.href,o)}})();function od(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ga={exports:{}},Gl={},ya={exports:{}},Y={};/** * @license React * react.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Fr=Symbol.for("react.element"),id=Symbol.for("react.portal"),sd=Symbol.for("react.fragment"),ud=Symbol.for("react.strict_mode"),ad=Symbol.for("react.profiler"),cd=Symbol.for("react.provider"),fd=Symbol.for("react.context"),dd=Symbol.for("react.forward_ref"),pd=Symbol.for("react.suspense"),hd=Symbol.for("react.memo"),md=Symbol.for("react.lazy"),Qs=Symbol.iterator;function gd(e){return e===null||typeof e!="object"?null:(e=Qs&&e[Qs]||e["@@iterator"],typeof e=="function"?e:null)}var va={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_a=Object.assign,wa={};function Jn(e,t,n){this.props=e,this.context=t,this.refs=wa,this.updater=n||va}Jn.prototype.isReactComponent={};Jn.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Jn.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Sa(){}Sa.prototype=Jn.prototype;function Qi(e,t,n){this.props=e,this.context=t,this.refs=wa,this.updater=n||va}var Ki=Qi.prototype=new Sa;Ki.constructor=Qi;_a(Ki,Jn.prototype);Ki.isPureReactComponent=!0;var Ks=Array.isArray,Ea=Object.prototype.hasOwnProperty,Ji={current:null},ka={key:!0,ref:!0,__self:!0,__source:!0};function Na(e,t,n){var r,l={},o=null,i=null;if(t!=null)for(r in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(o=""+t.key),t)Ea.call(t,r)&&!ka.hasOwnProperty(r)&&(l[r]=t[r]);var s=arguments.length-2;if(s===1)l.children=n;else if(1>>1,X=x[W];if(0>>1;Wl(Dt,B))Jel(ht,Dt)?(x[W]=ht,x[Je]=B,W=Je):(x[W]=Dt,x[Ue]=B,W=Ue);else if(Jel(ht,B))x[W]=ht,x[Je]=B,W=Je;else break e}}return z}function l(x,z){var B=x.sortIndex-z.sortIndex;return B!==0?B:x.id-z.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var i=Date,s=i.now();e.unstable_now=function(){return i.now()-s}}var u=[],a=[],f=1,h=null,y=3,E=!1,m=!1,w=!1,N=typeof setTimeout=="function"?setTimeout:null,d=typeof clearTimeout=="function"?clearTimeout:null,c=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function p(x){for(var z=n(a);z!==null;){if(z.callback===null)r(a);else if(z.startTime<=x)r(a),z.sortIndex=z.expirationTime,t(u,z);else break;z=n(a)}}function S(x){if(w=!1,p(x),!m)if(n(u)!==null)m=!0,de(R);else{var z=n(a);z!==null&&Te(S,z.startTime-x)}}function R(x,z){m=!1,w&&(w=!1,d(A),A=-1),E=!0;var B=y;try{for(p(z),h=n(u);h!==null&&(!(h.expirationTime>z)||x&&!L());){var W=h.callback;if(typeof W=="function"){h.callback=null,y=h.priorityLevel;var X=W(h.expirationTime<=z);z=e.unstable_now(),typeof X=="function"?h.callback=X:h===n(u)&&r(u),p(z)}else r(u);h=n(u)}if(h!==null)var St=!0;else{var Ue=n(a);Ue!==null&&Te(S,Ue.startTime-z),St=!1}return St}finally{h=null,y=B,E=!1}}var P=!1,T=null,A=-1,C=5,$=-1;function L(){return!(e.unstable_now()-$x||125W?(x.sortIndex=B,t(a,x),n(u)===null&&x===n(a)&&(w?(d(A),A=-1):w=!0,Te(S,B-W))):(x.sortIndex=X,t(u,x),m||E||(m=!0,de(R))),x},e.unstable_shouldYield=L,e.unstable_wrapCallback=function(x){var z=y;return function(){var B=y;y=z;try{return x.apply(this,arguments)}finally{y=B}}}})(Pa);Ta.exports=Pa;var Td=Ta.exports;/** * @license React * react-dom.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Pd=b,Ge=Td;function k(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),qo=Object.prototype.hasOwnProperty,Od=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Ys={},qs={};function jd(e){return qo.call(qs,e)?!0:qo.call(Ys,e)?!1:Od.test(e)?qs[e]=!0:(Ys[e]=!0,!1)}function Dd(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Ad(e,t,n,r){if(t===null||typeof t>"u"||Dd(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Fe(e,t,n,r,l,o,i){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=i}var Re={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Re[e]=new Fe(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Re[t]=new Fe(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Re[e]=new Fe(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Re[e]=new Fe(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Re[e]=new Fe(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Re[e]=new Fe(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Re[e]=new Fe(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Re[e]=new Fe(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Re[e]=new Fe(e,5,!1,e.toLowerCase(),null,!1,!1)});var qi=/[\-:]([a-z])/g;function Xi(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(qi,Xi);Re[t]=new Fe(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(qi,Xi);Re[t]=new Fe(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(qi,Xi);Re[t]=new Fe(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Re[e]=new Fe(e,1,!1,e.toLowerCase(),null,!1,!1)});Re.xlinkHref=new Fe("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Re[e]=new Fe(e,1,!1,e.toLowerCase(),null,!0,!0)});function Gi(e,t,n,r){var l=Re.hasOwnProperty(t)?Re[t]:null;(l!==null?l.type!==0:r||!(2s||l[i]!==o[s]){var u=` `+l[i].replace(" at new "," at ");return e.displayName&&u.includes("")&&(u=u.replace("",e.displayName)),u}while(1<=i&&0<=s);break}}}finally{So=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?sr(e):""}function Id(e){switch(e.tag){case 5:return sr(e.type);case 16:return sr("Lazy");case 13:return sr("Suspense");case 19:return sr("SuspenseList");case 0:case 2:case 15:return e=Eo(e.type,!1),e;case 11:return e=Eo(e.type.render,!1),e;case 1:return e=Eo(e.type,!0),e;default:return""}}function bo(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case En:return"Fragment";case Sn:return"Portal";case Xo:return"Profiler";case Zi:return"StrictMode";case Go:return"Suspense";case Zo:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Da:return(e.displayName||"Context")+".Consumer";case ja:return(e._context.displayName||"Context")+".Provider";case bi:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case es:return t=e.displayName||null,t!==null?t:bo(e.type)||"Memo";case It:t=e._payload,e=e._init;try{return bo(e(t))}catch{}}return null}function Ld(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return bo(t);case 8:return t===Zi?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Yt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Ia(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function zd(e){var t=Ia(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(i){r=""+i,o.call(this,i)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(i){r=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function qr(e){e._valueTracker||(e._valueTracker=zd(e))}function La(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Ia(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Cl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function ei(e,t){var n=t.checked;return ce({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Gs(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Yt(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function za(e,t){t=t.checked,t!=null&&Gi(e,"checked",t,!1)}function ti(e,t){za(e,t);var n=Yt(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?ni(e,t.type,n):t.hasOwnProperty("defaultValue")&&ni(e,t.type,Yt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Zs(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function ni(e,t,n){(t!=="number"||Cl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var ur=Array.isArray;function An(e,t,n,r){if(e=e.options,t){t={};for(var l=0;l"+t.valueOf().toString()+"",t=Xr.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Sr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var fr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Fd=["Webkit","ms","Moz","O"];Object.keys(fr).forEach(function(e){Fd.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),fr[t]=fr[e]})});function Ba(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||fr.hasOwnProperty(e)&&fr[e]?(""+t).trim():t+"px"}function $a(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,l=Ba(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,l):e[n]=l}}var Md=ce({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function oi(e,t){if(t){if(Md[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(k(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(k(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(k(61))}if(t.style!=null&&typeof t.style!="object")throw Error(k(62))}}function ii(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var si=null;function ts(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ui=null,In=null,Ln=null;function tu(e){if(e=Br(e)){if(typeof ui!="function")throw Error(k(280));var t=e.stateNode;t&&(t=no(t),ui(e.stateNode,e.type,t))}}function Ha(e){In?Ln?Ln.push(e):Ln=[e]:In=e}function Va(){if(In){var e=In,t=Ln;if(Ln=In=null,tu(e),t)for(e=0;e>>=0,e===0?32:31-(qd(e)/Xd|0)|0}var Gr=64,Zr=4194304;function ar(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Ol(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,l=e.suspendedLanes,o=e.pingedLanes,i=n&268435455;if(i!==0){var s=i&~l;s!==0?r=ar(s):(o&=i,o!==0&&(r=ar(o)))}else i=n&~l,i!==0?r=ar(i):o!==0&&(r=ar(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&l)&&(l=r&-r,o=t&-t,l>=o||l===16&&(o&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0n;n++)t.push(e);return t}function Mr(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-ct(t),e[t]=n}function ep(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0=pr),cu=" ",fu=!1;function ac(e,t){switch(e){case"keyup":return Tp.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function cc(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var kn=!1;function Op(e,t){switch(e){case"compositionend":return cc(t);case"keypress":return t.which!==32?null:(fu=!0,cu);case"textInput":return e=t.data,e===cu&&fu?null:e;default:return null}}function jp(e,t){if(kn)return e==="compositionend"||!as&&ac(e,t)?(e=sc(),hl=is=Mt=null,kn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=mu(n)}}function hc(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?hc(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function mc(){for(var e=window,t=Cl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Cl(e.document)}return t}function cs(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function Bp(e){var t=mc(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&hc(n.ownerDocument.documentElement,n)){if(r!==null&&cs(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var l=n.textContent.length,o=Math.min(r.start,l);r=r.end===void 0?o:Math.min(r.end,l),!e.extend&&o>r&&(l=r,r=o,o=l),l=gu(n,o);var i=gu(n,r);l&&i&&(e.rangeCount!==1||e.anchorNode!==l.node||e.anchorOffset!==l.offset||e.focusNode!==i.node||e.focusOffset!==i.offset)&&(t=t.createRange(),t.setStart(l.node,l.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(i.node,i.offset)):(t.setEnd(i.node,i.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n=document.documentMode,Nn=null,hi=null,mr=null,mi=!1;function yu(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;mi||Nn==null||Nn!==Cl(r)||(r=Nn,"selectionStart"in r&&cs(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),mr&&Rr(mr,r)||(mr=r,r=Al(hi,"onSelect"),0Rn||(e.current=Si[Rn],Si[Rn]=null,Rn--)}function te(e,t){Rn++,Si[Rn]=e.current,e.current=t}var qt={},Ae=Gt(qt),He=Gt(!1),cn=qt;function Bn(e,t){var n=e.type.contextTypes;if(!n)return qt;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var l={},o;for(o in n)l[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function Ve(e){return e=e.childContextTypes,e!=null}function Ll(){re(He),re(Ae)}function Nu(e,t,n){if(Ae.current!==qt)throw Error(k(168));te(Ae,t),te(He,n)}function Nc(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var l in r)if(!(l in t))throw Error(k(108,Ld(e)||"Unknown",l));return ce({},n,r)}function zl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||qt,cn=Ae.current,te(Ae,e),te(He,He.current),!0}function xu(e,t,n){var r=e.stateNode;if(!r)throw Error(k(169));n?(e=Nc(e,t,cn),r.__reactInternalMemoizedMergedChildContext=e,re(He),re(Ae),te(Ae,e)):re(He),te(He,n)}var kt=null,ro=!1,zo=!1;function xc(e){kt===null?kt=[e]:kt.push(e)}function Zp(e){ro=!0,xc(e)}function Zt(){if(!zo&&kt!==null){zo=!0;var e=0,t=Z;try{var n=kt;for(Z=1;e>=i,l-=i,Nt=1<<32-ct(t)+l|n<A?(C=T,T=null):C=T.sibling;var $=y(d,T,p[A],S);if($===null){T===null&&(T=C);break}e&&T&&$.alternate===null&&t(d,T),c=o($,c,A),P===null?R=$:P.sibling=$,P=$,T=C}if(A===p.length)return n(d,T),ie&&en(d,A),R;if(T===null){for(;AA?(C=T,T=null):C=T.sibling;var L=y(d,T,$.value,S);if(L===null){T===null&&(T=C);break}e&&T&&L.alternate===null&&t(d,T),c=o(L,c,A),P===null?R=L:P.sibling=L,P=L,T=C}if($.done)return n(d,T),ie&&en(d,A),R;if(T===null){for(;!$.done;A++,$=p.next())$=h(d,$.value,S),$!==null&&(c=o($,c,A),P===null?R=$:P.sibling=$,P=$);return ie&&en(d,A),R}for(T=r(d,T);!$.done;A++,$=p.next())$=E(T,d,A,$.value,S),$!==null&&(e&&$.alternate!==null&&T.delete($.key===null?A:$.key),c=o($,c,A),P===null?R=$:P.sibling=$,P=$);return e&&T.forEach(function(Ne){return t(d,Ne)}),ie&&en(d,A),R}function N(d,c,p,S){if(typeof p=="object"&&p!==null&&p.type===En&&p.key===null&&(p=p.props.children),typeof p=="object"&&p!==null){switch(p.$$typeof){case Yr:e:{for(var R=p.key,P=c;P!==null;){if(P.key===R){if(R=p.type,R===En){if(P.tag===7){n(d,P.sibling),c=l(P,p.props.children),c.return=d,d=c;break e}}else if(P.elementType===R||typeof R=="object"&&R!==null&&R.$$typeof===It&&Tu(R)===P.type){n(d,P.sibling),c=l(P,p.props),c.ref=rr(d,P,p),c.return=d,d=c;break e}n(d,P);break}else t(d,P);P=P.sibling}p.type===En?(c=un(p.props.children,d.mode,S,p.key),c.return=d,d=c):(S=El(p.type,p.key,p.props,null,d.mode,S),S.ref=rr(d,c,p),S.return=d,d=S)}return i(d);case Sn:e:{for(P=p.key;c!==null;){if(c.key===P)if(c.tag===4&&c.stateNode.containerInfo===p.containerInfo&&c.stateNode.implementation===p.implementation){n(d,c.sibling),c=l(c,p.children||[]),c.return=d,d=c;break e}else{n(d,c);break}else t(d,c);c=c.sibling}c=Wo(p,d.mode,S),c.return=d,d=c}return i(d);case It:return P=p._init,N(d,c,P(p._payload),S)}if(ur(p))return m(d,c,p,S);if(Zn(p))return w(d,c,p,S);ol(d,p)}return typeof p=="string"&&p!==""||typeof p=="number"?(p=""+p,c!==null&&c.tag===6?(n(d,c.sibling),c=l(c,p),c.return=d,d=c):(n(d,c),c=Vo(p,d.mode,S),c.return=d,d=c),i(d)):n(d,c)}return N}var Hn=Pc(!0),Oc=Pc(!1),Ul=Gt(null),Bl=null,On=null,hs=null;function ms(){hs=On=Bl=null}function gs(e){var t=Ul.current;re(Ul),e._currentValue=t}function Ni(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Fn(e,t){Bl=e,hs=On=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&($e=!0),e.firstContext=null)}function lt(e){var t=e._currentValue;if(hs!==e)if(e={context:e,memoizedValue:t,next:null},On===null){if(Bl===null)throw Error(k(308));On=e,Bl.dependencies={lanes:0,firstContext:e}}else On=On.next=e;return t}var rn=null;function ys(e){rn===null?rn=[e]:rn.push(e)}function jc(e,t,n,r){var l=t.interleaved;return l===null?(n.next=n,ys(t)):(n.next=l.next,l.next=n),t.interleaved=n,Pt(e,r)}function Pt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Lt=!1;function vs(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Dc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Ct(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Wt(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,q&2){var l=r.pending;return l===null?t.next=t:(t.next=l.next,l.next=t),r.pending=t,Pt(e,n)}return l=r.interleaved,l===null?(t.next=t,ys(r)):(t.next=l.next,l.next=t),r.interleaved=t,Pt(e,n)}function gl(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rs(e,n)}}function Pu(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var l=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var i={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?l=o=i:o=o.next=i,n=n.next}while(n!==null);o===null?l=o=t:o=o.next=t}else l=o=t;n={baseState:r.baseState,firstBaseUpdate:l,lastBaseUpdate:o,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function $l(e,t,n,r){var l=e.updateQueue;Lt=!1;var o=l.firstBaseUpdate,i=l.lastBaseUpdate,s=l.shared.pending;if(s!==null){l.shared.pending=null;var u=s,a=u.next;u.next=null,i===null?o=a:i.next=a,i=u;var f=e.alternate;f!==null&&(f=f.updateQueue,s=f.lastBaseUpdate,s!==i&&(s===null?f.firstBaseUpdate=a:s.next=a,f.lastBaseUpdate=u))}if(o!==null){var h=l.baseState;i=0,f=a=u=null,s=o;do{var y=s.lane,E=s.eventTime;if((r&y)===y){f!==null&&(f=f.next={eventTime:E,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var m=e,w=s;switch(y=t,E=n,w.tag){case 1:if(m=w.payload,typeof m=="function"){h=m.call(E,h,y);break e}h=m;break e;case 3:m.flags=m.flags&-65537|128;case 0:if(m=w.payload,y=typeof m=="function"?m.call(E,h,y):m,y==null)break e;h=ce({},h,y);break e;case 2:Lt=!0}}s.callback!==null&&s.lane!==0&&(e.flags|=64,y=l.effects,y===null?l.effects=[s]:y.push(s))}else E={eventTime:E,lane:y,tag:s.tag,payload:s.payload,callback:s.callback,next:null},f===null?(a=f=E,u=h):f=f.next=E,i|=y;if(s=s.next,s===null){if(s=l.shared.pending,s===null)break;y=s,s=y.next,y.next=null,l.lastBaseUpdate=y,l.shared.pending=null}}while(!0);if(f===null&&(u=h),l.baseState=u,l.firstBaseUpdate=a,l.lastBaseUpdate=f,t=l.shared.interleaved,t!==null){l=t;do i|=l.lane,l=l.next;while(l!==t)}else o===null&&(l.shared.lanes=0);pn|=i,e.lanes=i,e.memoizedState=h}}function Ou(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;tn?n:4,e(!0);var r=Mo.transition;Mo.transition={};try{e(!1),t()}finally{Z=n,Mo.transition=r}}function qc(){return ot().memoizedState}function nh(e,t,n){var r=Kt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Xc(e))Gc(t,n);else if(n=jc(e,t,n,r),n!==null){var l=Le();ft(n,e,r,l),Zc(n,t,r)}}function rh(e,t,n){var r=Kt(e),l={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Xc(e))Gc(t,l);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var i=t.lastRenderedState,s=o(i,n);if(l.hasEagerState=!0,l.eagerState=s,dt(s,i)){var u=t.interleaved;u===null?(l.next=l,ys(t)):(l.next=u.next,u.next=l),t.interleaved=l;return}}catch{}finally{}n=jc(e,t,l,r),n!==null&&(l=Le(),ft(n,e,r,l),Zc(n,t,r))}}function Xc(e){var t=e.alternate;return e===ae||t!==null&&t===ae}function Gc(e,t){gr=Vl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Zc(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rs(e,n)}}var Wl={readContext:lt,useCallback:Pe,useContext:Pe,useEffect:Pe,useImperativeHandle:Pe,useInsertionEffect:Pe,useLayoutEffect:Pe,useMemo:Pe,useReducer:Pe,useRef:Pe,useState:Pe,useDebugValue:Pe,useDeferredValue:Pe,useTransition:Pe,useMutableSource:Pe,useSyncExternalStore:Pe,useId:Pe,unstable_isNewReconciler:!1},lh={readContext:lt,useCallback:function(e,t){return yt().memoizedState=[e,t===void 0?null:t],e},useContext:lt,useEffect:Du,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,vl(4194308,4,Wc.bind(null,t,e),n)},useLayoutEffect:function(e,t){return vl(4194308,4,e,t)},useInsertionEffect:function(e,t){return vl(4,2,e,t)},useMemo:function(e,t){var n=yt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=yt();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=nh.bind(null,ae,e),[r.memoizedState,e]},useRef:function(e){var t=yt();return e={current:e},t.memoizedState=e},useState:ju,useDebugValue:Cs,useDeferredValue:function(e){return yt().memoizedState=e},useTransition:function(){var e=ju(!1),t=e[0];return e=th.bind(null,e[1]),yt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=ae,l=yt();if(ie){if(n===void 0)throw Error(k(407));n=n()}else{if(n=t(),ke===null)throw Error(k(349));dn&30||zc(r,t,n)}l.memoizedState=n;var o={value:n,getSnapshot:t};return l.queue=o,Du(Mc.bind(null,r,o,e),[e]),r.flags|=2048,Lr(9,Fc.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=yt(),t=ke.identifierPrefix;if(ie){var n=xt,r=Nt;n=(r&~(1<<32-ct(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Ar++,0<\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=i.createElement(n,{is:r.is}):(e=i.createElement(n),n==="select"&&(i=e,r.multiple?i.multiple=!0:r.size&&(i.size=r.size))):e=i.createElementNS(e,n),e[vt]=t,e[Or]=r,af(e,t,!1,!1),t.stateNode=e;e:{switch(i=ii(n,r),n){case"dialog":ne("cancel",e),ne("close",e),l=r;break;case"iframe":case"object":case"embed":ne("load",e),l=r;break;case"video":case"audio":for(l=0;lQn&&(t.flags|=128,r=!0,lr(o,!1),t.lanes=4194304)}else{if(!r)if(e=Hl(i),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),lr(o,!0),o.tail===null&&o.tailMode==="hidden"&&!i.alternate&&!ie)return Oe(t),null}else 2*me()-o.renderingStartTime>Qn&&n!==1073741824&&(t.flags|=128,r=!0,lr(o,!1),t.lanes=4194304);o.isBackwards?(i.sibling=t.child,t.child=i):(n=o.last,n!==null?n.sibling=i:t.child=i,o.last=i)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=me(),t.sibling=null,n=ue.current,te(ue,r?n&1|2:n&1),t):(Oe(t),null);case 22:case 23:return Ds(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ye&1073741824&&(Oe(t),t.subtreeFlags&6&&(t.flags|=8192)):Oe(t),null;case 24:return null;case 25:return null}throw Error(k(156,t.tag))}function dh(e,t){switch(ds(t),t.tag){case 1:return Ve(t.type)&&Ll(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Vn(),re(He),re(Ae),Ss(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return ws(t),null;case 13:if(re(ue),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(k(340));$n()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return re(ue),null;case 4:return Vn(),null;case 10:return gs(t.type._context),null;case 22:case 23:return Ds(),null;case 24:return null;default:return null}}var sl=!1,je=!1,ph=typeof WeakSet=="function"?WeakSet:Set,j=null;function jn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){he(e,t,r)}else n.current=null}function Ai(e,t,n){try{n()}catch(r){he(e,t,r)}}var Vu=!1;function hh(e,t){if(gi=jl,e=mc(),cs(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var l=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var i=0,s=-1,u=-1,a=0,f=0,h=e,y=null;t:for(;;){for(var E;h!==n||l!==0&&h.nodeType!==3||(s=i+l),h!==o||r!==0&&h.nodeType!==3||(u=i+r),h.nodeType===3&&(i+=h.nodeValue.length),(E=h.firstChild)!==null;)y=h,h=E;for(;;){if(h===e)break t;if(y===n&&++a===l&&(s=i),y===o&&++f===r&&(u=i),(E=h.nextSibling)!==null)break;h=y,y=h.parentNode}h=E}n=s===-1||u===-1?null:{start:s,end:u}}else n=null}n=n||{start:0,end:0}}else n=null;for(yi={focusedElem:e,selectionRange:n},jl=!1,j=t;j!==null;)if(t=j,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,j=e;else for(;j!==null;){t=j;try{var m=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(m!==null){var w=m.memoizedProps,N=m.memoizedState,d=t.stateNode,c=d.getSnapshotBeforeUpdate(t.elementType===t.type?w:st(t.type,w),N);d.__reactInternalSnapshotBeforeUpdate=c}break;case 3:var p=t.stateNode.containerInfo;p.nodeType===1?p.textContent="":p.nodeType===9&&p.documentElement&&p.removeChild(p.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(k(163))}}catch(S){he(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,j=e;break}j=t.return}return m=Vu,Vu=!1,m}function yr(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var l=r=r.next;do{if((l.tag&e)===e){var o=l.destroy;l.destroy=void 0,o!==void 0&&Ai(t,n,o)}l=l.next}while(l!==r)}}function io(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Ii(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function df(e){var t=e.alternate;t!==null&&(e.alternate=null,df(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[vt],delete t[Or],delete t[wi],delete t[Xp],delete t[Gp])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function pf(e){return e.tag===5||e.tag===3||e.tag===4}function Wu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||pf(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Li(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Il));else if(r!==4&&(e=e.child,e!==null))for(Li(e,t,n),e=e.sibling;e!==null;)Li(e,t,n),e=e.sibling}function zi(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(zi(e,t,n),e=e.sibling;e!==null;)zi(e,t,n),e=e.sibling}var xe=null,ut=!1;function At(e,t,n){for(n=n.child;n!==null;)hf(e,t,n),n=n.sibling}function hf(e,t,n){if(_t&&typeof _t.onCommitFiberUnmount=="function")try{_t.onCommitFiberUnmount(Zl,n)}catch{}switch(n.tag){case 5:je||jn(n,t);case 6:var r=xe,l=ut;xe=null,At(e,t,n),xe=r,ut=l,xe!==null&&(ut?(e=xe,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):xe.removeChild(n.stateNode));break;case 18:xe!==null&&(ut?(e=xe,n=n.stateNode,e.nodeType===8?Lo(e.parentNode,n):e.nodeType===1&&Lo(e,n),xr(e)):Lo(xe,n.stateNode));break;case 4:r=xe,l=ut,xe=n.stateNode.containerInfo,ut=!0,At(e,t,n),xe=r,ut=l;break;case 0:case 11:case 14:case 15:if(!je&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){l=r=r.next;do{var o=l,i=o.destroy;o=o.tag,i!==void 0&&(o&2||o&4)&&Ai(n,t,i),l=l.next}while(l!==r)}At(e,t,n);break;case 1:if(!je&&(jn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){he(n,t,s)}At(e,t,n);break;case 21:At(e,t,n);break;case 22:n.mode&1?(je=(r=je)||n.memoizedState!==null,At(e,t,n),je=r):At(e,t,n);break;default:At(e,t,n)}}function Qu(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new ph),t.forEach(function(r){var l=kh.bind(null,e,r);n.has(r)||(n.add(r),r.then(l,l))})}}function it(e,t){var n=t.deletions;if(n!==null)for(var r=0;rl&&(l=i),r&=~o}if(r=l,r=me()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*gh(r/1960))-r,10e?16:e,Ut===null)var r=!1;else{if(e=Ut,Ut=null,Jl=0,q&6)throw Error(k(331));var l=q;for(q|=4,j=e.current;j!==null;){var o=j,i=o.child;if(j.flags&16){var s=o.deletions;if(s!==null){for(var u=0;ume()-Os?sn(e,0):Ps|=n),We(e,t)}function Ef(e,t){t===0&&(e.mode&1?(t=Zr,Zr<<=1,!(Zr&130023424)&&(Zr=4194304)):t=1);var n=Le();e=Pt(e,t),e!==null&&(Mr(e,t,n),We(e,n))}function Eh(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ef(e,n)}function kh(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,l=e.memoizedState;l!==null&&(n=l.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(k(314))}r!==null&&r.delete(t),Ef(e,n)}var kf;kf=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||He.current)$e=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return $e=!1,ch(e,t,n);$e=!!(e.flags&131072)}else $e=!1,ie&&t.flags&1048576&&Cc(t,Ml,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;_l(e,t),e=t.pendingProps;var l=Bn(t,Ae.current);Fn(t,n),l=ks(null,t,r,e,l,n);var o=Ns();return t.flags|=1,typeof l=="object"&&l!==null&&typeof l.render=="function"&&l.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Ve(r)?(o=!0,zl(t)):o=!1,t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,vs(t),l.updater=oo,t.stateNode=l,l._reactInternals=t,Ci(t,r,e,n),t=Pi(null,t,r,!0,o,n)):(t.tag=0,ie&&o&&fs(t),Ie(null,t,l,n),t=t.child),t;case 16:r=t.elementType;e:{switch(_l(e,t),e=t.pendingProps,l=r._init,r=l(r._payload),t.type=r,l=t.tag=xh(r),e=st(r,e),l){case 0:t=Ti(null,t,r,e,n);break e;case 1:t=Bu(null,t,r,e,n);break e;case 11:t=Mu(null,t,r,e,n);break e;case 14:t=Uu(null,t,r,st(r.type,e),n);break e}throw Error(k(306,r,""))}return t;case 0:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:st(r,l),Ti(e,t,r,l,n);case 1:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:st(r,l),Bu(e,t,r,l,n);case 3:e:{if(of(t),e===null)throw Error(k(387));r=t.pendingProps,o=t.memoizedState,l=o.element,Dc(e,t),$l(t,r,null,n);var i=t.memoizedState;if(r=i.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:i.cache,pendingSuspenseBoundaries:i.pendingSuspenseBoundaries,transitions:i.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){l=Wn(Error(k(423)),t),t=$u(e,t,r,n,l);break e}else if(r!==l){l=Wn(Error(k(424)),t),t=$u(e,t,r,n,l);break e}else for(qe=Vt(t.stateNode.containerInfo.firstChild),Xe=t,ie=!0,at=null,n=Oc(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if($n(),r===l){t=Ot(e,t,n);break e}Ie(e,t,r,n)}t=t.child}return t;case 5:return Ac(t),e===null&&ki(t),r=t.type,l=t.pendingProps,o=e!==null?e.memoizedProps:null,i=l.children,vi(r,l)?i=null:o!==null&&vi(r,o)&&(t.flags|=32),lf(e,t),Ie(e,t,i,n),t.child;case 6:return e===null&&ki(t),null;case 13:return sf(e,t,n);case 4:return _s(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Hn(t,null,r,n):Ie(e,t,r,n),t.child;case 11:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:st(r,l),Mu(e,t,r,l,n);case 7:return Ie(e,t,t.pendingProps,n),t.child;case 8:return Ie(e,t,t.pendingProps.children,n),t.child;case 12:return Ie(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,l=t.pendingProps,o=t.memoizedProps,i=l.value,te(Ul,r._currentValue),r._currentValue=i,o!==null)if(dt(o.value,i)){if(o.children===l.children&&!He.current){t=Ot(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var s=o.dependencies;if(s!==null){i=o.child;for(var u=s.firstContext;u!==null;){if(u.context===r){if(o.tag===1){u=Ct(-1,n&-n),u.tag=2;var a=o.updateQueue;if(a!==null){a=a.shared;var f=a.pending;f===null?u.next=u:(u.next=f.next,f.next=u),a.pending=u}}o.lanes|=n,u=o.alternate,u!==null&&(u.lanes|=n),Ni(o.return,n,t),s.lanes|=n;break}u=u.next}}else if(o.tag===10)i=o.type===t.type?null:o.child;else if(o.tag===18){if(i=o.return,i===null)throw Error(k(341));i.lanes|=n,s=i.alternate,s!==null&&(s.lanes|=n),Ni(i,n,t),i=o.sibling}else i=o.child;if(i!==null)i.return=o;else for(i=o;i!==null;){if(i===t){i=null;break}if(o=i.sibling,o!==null){o.return=i.return,i=o;break}i=i.return}o=i}Ie(e,t,l.children,n),t=t.child}return t;case 9:return l=t.type,r=t.pendingProps.children,Fn(t,n),l=lt(l),r=r(l),t.flags|=1,Ie(e,t,r,n),t.child;case 14:return r=t.type,l=st(r,t.pendingProps),l=st(r.type,l),Uu(e,t,r,l,n);case 15:return nf(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,l=t.pendingProps,l=t.elementType===r?l:st(r,l),_l(e,t),t.tag=1,Ve(r)?(e=!0,zl(t)):e=!1,Fn(t,n),bc(t,r,l),Ci(t,r,l,n),Pi(null,t,r,!0,e,n);case 19:return uf(e,t,n);case 22:return rf(e,t,n)}throw Error(k(156,t.tag))};function Nf(e,t){return Xa(e,t)}function Nh(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function nt(e,t,n,r){return new Nh(e,t,n,r)}function Is(e){return e=e.prototype,!(!e||!e.isReactComponent)}function xh(e){if(typeof e=="function")return Is(e)?1:0;if(e!=null){if(e=e.$$typeof,e===bi)return 11;if(e===es)return 14}return 2}function Jt(e,t){var n=e.alternate;return n===null?(n=nt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function El(e,t,n,r,l,o){var i=2;if(r=e,typeof e=="function")Is(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case En:return un(n.children,l,o,t);case Zi:i=8,l|=8;break;case Xo:return e=nt(12,n,t,l|2),e.elementType=Xo,e.lanes=o,e;case Go:return e=nt(13,n,t,l),e.elementType=Go,e.lanes=o,e;case Zo:return e=nt(19,n,t,l),e.elementType=Zo,e.lanes=o,e;case Aa:return uo(n,l,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case ja:i=10;break e;case Da:i=9;break e;case bi:i=11;break e;case es:i=14;break e;case It:i=16,r=null;break e}throw Error(k(130,e==null?e:typeof e,""))}return t=nt(i,n,t,l),t.elementType=e,t.type=r,t.lanes=o,t}function un(e,t,n,r){return e=nt(7,e,r,t),e.lanes=n,e}function uo(e,t,n,r){return e=nt(22,e,r,t),e.elementType=Aa,e.lanes=n,e.stateNode={isHidden:!1},e}function Vo(e,t,n){return e=nt(6,e,null,t),e.lanes=n,e}function Wo(e,t,n){return t=nt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Ch(e,t,n,r,l){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=No(0),this.expirationTimes=No(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=No(0),this.identifierPrefix=r,this.onRecoverableError=l,this.mutableSourceEagerHydrationData=null}function Ls(e,t,n,r,l,o,i,s,u){return e=new Ch(e,t,n,s,u),t===1?(t=1,o===!0&&(t|=8)):t=0,o=nt(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},vs(o),e}function Rh(e,t,n){var r=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Tf)}catch(e){console.error(e)}}Tf(),Ra.exports=Ze;var Dh=Ra.exports,bu=Dh;Yo.createRoot=bu.createRoot,Yo.hydrateRoot=bu.hydrateRoot;function Pf(e,t){return function(){return e.apply(t,arguments)}}const{toString:Ah}=Object.prototype,{getPrototypeOf:Us}=Object,{iterator:ho,toStringTag:Of}=Symbol,mo=(e=>t=>{const n=Ah.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),pt=e=>(e=e.toLowerCase(),t=>mo(t)===e),go=e=>t=>typeof t===e,{isArray:Xn}=Array,Kn=go("undefined");function Hr(e){return e!==null&&!Kn(e)&&e.constructor!==null&&!Kn(e.constructor)&&Qe(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const jf=pt("ArrayBuffer");function Ih(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&jf(e.buffer),t}const Lh=go("string"),Qe=go("function"),Df=go("number"),Vr=e=>e!==null&&typeof e=="object",zh=e=>e===!0||e===!1,kl=e=>{if(mo(e)!=="object")return!1;const t=Us(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Of in e)&&!(ho in e)},Fh=e=>{if(!Vr(e)||Hr(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},Mh=pt("Date"),Uh=pt("File"),Bh=pt("Blob"),$h=pt("FileList"),Hh=e=>Vr(e)&&Qe(e.pipe),Vh=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Qe(e.append)&&((t=mo(e))==="formdata"||t==="object"&&Qe(e.toString)&&e.toString()==="[object FormData]"))},Wh=pt("URLSearchParams"),[Qh,Kh,Jh,Yh]=["ReadableStream","Request","Response","Headers"].map(pt),qh=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Wr(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,l;if(typeof e!="object"&&(e=[e]),Xn(e))for(r=0,l=e.length;r0;)if(l=n[r],t===l.toLowerCase())return l;return null}const on=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,If=e=>!Kn(e)&&e!==on;function $i(){const{caseless:e,skipUndefined:t}=If(this)&&this||{},n={},r=(l,o)=>{const i=e&&Af(n,o)||o;kl(n[i])&&kl(l)?n[i]=$i(n[i],l):kl(l)?n[i]=$i({},l):Xn(l)?n[i]=l.slice():(!t||!Kn(l))&&(n[i]=l)};for(let l=0,o=arguments.length;l(Wr(t,(l,o)=>{n&&Qe(l)?Object.defineProperty(e,o,{value:Pf(l,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,o,{value:l,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),Gh=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Zh=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},bh=(e,t,n,r)=>{let l,o,i;const s={};if(t=t||{},e==null)return t;do{for(l=Object.getOwnPropertyNames(e),o=l.length;o-- >0;)i=l[o],(!r||r(i,e,t))&&!s[i]&&(t[i]=e[i],s[i]=!0);e=n!==!1&&Us(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},em=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},tm=e=>{if(!e)return null;if(Xn(e))return e;let t=e.length;if(!Df(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},nm=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Us(Uint8Array)),rm=(e,t)=>{const r=(e&&e[ho]).call(e);let l;for(;(l=r.next())&&!l.done;){const o=l.value;t.call(e,o[0],o[1])}},lm=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},om=pt("HTMLFormElement"),im=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,l){return r.toUpperCase()+l}),ea=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),sm=pt("RegExp"),Lf=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Wr(n,(l,o)=>{let i;(i=t(l,o,e))!==!1&&(r[o]=i||l)}),Object.defineProperties(e,r)},um=e=>{Lf(e,(t,n)=>{if(Qe(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Qe(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},am=(e,t)=>{const n={},r=l=>{l.forEach(o=>{n[o]=!0})};return Xn(e)?r(e):r(String(e).split(t)),n},cm=()=>{},fm=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function dm(e){return!!(e&&Qe(e.append)&&e[Of]==="FormData"&&e[ho])}const pm=e=>{const t=new Array(10),n=(r,l)=>{if(Vr(r)){if(t.indexOf(r)>=0)return;if(Hr(r))return r;if(!("toJSON"in r)){t[l]=r;const o=Xn(r)?[]:{};return Wr(r,(i,s)=>{const u=n(i,l+1);!Kn(u)&&(o[s]=u)}),t[l]=void 0,o}}return r};return n(e,0)},hm=pt("AsyncFunction"),mm=e=>e&&(Vr(e)||Qe(e))&&Qe(e.then)&&Qe(e.catch),zf=((e,t)=>e?setImmediate:t?((n,r)=>(on.addEventListener("message",({source:l,data:o})=>{l===on&&o===n&&r.length&&r.shift()()},!1),l=>{r.push(l),on.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Qe(on.postMessage)),gm=typeof queueMicrotask<"u"?queueMicrotask.bind(on):typeof process<"u"&&process.nextTick||zf,ym=e=>e!=null&&Qe(e[ho]),v={isArray:Xn,isArrayBuffer:jf,isBuffer:Hr,isFormData:Vh,isArrayBufferView:Ih,isString:Lh,isNumber:Df,isBoolean:zh,isObject:Vr,isPlainObject:kl,isEmptyObject:Fh,isReadableStream:Qh,isRequest:Kh,isResponse:Jh,isHeaders:Yh,isUndefined:Kn,isDate:Mh,isFile:Uh,isBlob:Bh,isRegExp:sm,isFunction:Qe,isStream:Hh,isURLSearchParams:Wh,isTypedArray:nm,isFileList:$h,forEach:Wr,merge:$i,extend:Xh,trim:qh,stripBOM:Gh,inherits:Zh,toFlatObject:bh,kindOf:mo,kindOfTest:pt,endsWith:em,toArray:tm,forEachEntry:rm,matchAll:lm,isHTMLForm:om,hasOwnProperty:ea,hasOwnProp:ea,reduceDescriptors:Lf,freezeMethods:um,toObjectSet:am,toCamelCase:im,noop:cm,toFiniteNumber:fm,findKey:Af,global:on,isContextDefined:If,isSpecCompliantForm:dm,toJSONObject:pm,isAsyncFn:hm,isThenable:mm,setImmediate:zf,asap:gm,isIterable:ym};let H=class Ff extends Error{static from(t,n,r,l,o,i){const s=new Ff(t.message,n||t.code,r,l,o);return s.cause=t,s.name=t.name,i&&Object.assign(s,i),s}constructor(t,n,r,l,o){super(t),this.name="AxiosError",this.isAxiosError=!0,n&&(this.code=n),r&&(this.config=r),l&&(this.request=l),o&&(this.response=o,this.status=o.status)}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:v.toJSONObject(this.config),code:this.code,status:this.status}}};H.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";H.ERR_BAD_OPTION="ERR_BAD_OPTION";H.ECONNABORTED="ECONNABORTED";H.ETIMEDOUT="ETIMEDOUT";H.ERR_NETWORK="ERR_NETWORK";H.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";H.ERR_DEPRECATED="ERR_DEPRECATED";H.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";H.ERR_BAD_REQUEST="ERR_BAD_REQUEST";H.ERR_CANCELED="ERR_CANCELED";H.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";H.ERR_INVALID_URL="ERR_INVALID_URL";const vm=null;function Hi(e){return v.isPlainObject(e)||v.isArray(e)}function Mf(e){return v.endsWith(e,"[]")?e.slice(0,-2):e}function ta(e,t,n){return e?e.concat(t).map(function(l,o){return l=Mf(l),!n&&o?"["+l+"]":l}).join(n?".":""):t}function _m(e){return v.isArray(e)&&!e.some(Hi)}const wm=v.toFlatObject(v,{},null,function(t){return/^is[A-Z]/.test(t)});function yo(e,t,n){if(!v.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=v.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(w,N){return!v.isUndefined(N[w])});const r=n.metaTokens,l=n.visitor||f,o=n.dots,i=n.indexes,u=(n.Blob||typeof Blob<"u"&&Blob)&&v.isSpecCompliantForm(t);if(!v.isFunction(l))throw new TypeError("visitor must be a function");function a(m){if(m===null)return"";if(v.isDate(m))return m.toISOString();if(v.isBoolean(m))return m.toString();if(!u&&v.isBlob(m))throw new H("Blob is not supported. Use a Buffer instead.");return v.isArrayBuffer(m)||v.isTypedArray(m)?u&&typeof Blob=="function"?new Blob([m]):Buffer.from(m):m}function f(m,w,N){let d=m;if(m&&!N&&typeof m=="object"){if(v.endsWith(w,"{}"))w=r?w:w.slice(0,-2),m=JSON.stringify(m);else if(v.isArray(m)&&_m(m)||(v.isFileList(m)||v.endsWith(w,"[]"))&&(d=v.toArray(m)))return w=Mf(w),d.forEach(function(p,S){!(v.isUndefined(p)||p===null)&&t.append(i===!0?ta([w],S,o):i===null?w:w+"[]",a(p))}),!1}return Hi(m)?!0:(t.append(ta(N,w,o),a(m)),!1)}const h=[],y=Object.assign(wm,{defaultVisitor:f,convertValue:a,isVisitable:Hi});function E(m,w){if(!v.isUndefined(m)){if(h.indexOf(m)!==-1)throw Error("Circular reference detected in "+w.join("."));h.push(m),v.forEach(m,function(d,c){(!(v.isUndefined(d)||d===null)&&l.call(t,d,v.isString(c)?c.trim():c,w,y))===!0&&E(d,w?w.concat(c):[c])}),h.pop()}}if(!v.isObject(e))throw new TypeError("data must be an object");return E(e),t}function na(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Bs(e,t){this._pairs=[],e&&yo(e,this,t)}const Uf=Bs.prototype;Uf.append=function(t,n){this._pairs.push([t,n])};Uf.toString=function(t){const n=t?function(r){return t.call(this,r,na)}:na;return this._pairs.map(function(l){return n(l[0])+"="+n(l[1])},"").join("&")};function Sm(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Bf(e,t,n){if(!t)return e;const r=n&&n.encode||Sm,l=v.isFunction(n)?{serialize:n}:n,o=l&&l.serialize;let i;if(o?i=o(t,l):i=v.isURLSearchParams(t)?t.toString():new Bs(t,l).toString(r),i){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+i}return e}class ra{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){v.forEach(this.handlers,function(r){r!==null&&t(r)})}}const $f={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Em=typeof URLSearchParams<"u"?URLSearchParams:Bs,km=typeof FormData<"u"?FormData:null,Nm=typeof Blob<"u"?Blob:null,xm={isBrowser:!0,classes:{URLSearchParams:Em,FormData:km,Blob:Nm},protocols:["http","https","file","blob","url","data"]},$s=typeof window<"u"&&typeof document<"u",Vi=typeof navigator=="object"&&navigator||void 0,Cm=$s&&(!Vi||["ReactNative","NativeScript","NS"].indexOf(Vi.product)<0),Rm=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Tm=$s&&window.location.href||"http://localhost",Pm=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:$s,hasStandardBrowserEnv:Cm,hasStandardBrowserWebWorkerEnv:Rm,navigator:Vi,origin:Tm},Symbol.toStringTag,{value:"Module"})),De={...Pm,...xm};function Om(e,t){return yo(e,new De.classes.URLSearchParams,{visitor:function(n,r,l,o){return De.isNode&&v.isBuffer(n)?(this.append(r,n.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...t})}function jm(e){return v.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Dm(e){const t={},n=Object.keys(e);let r;const l=n.length;let o;for(r=0;r=n.length;return i=!i&&v.isArray(l)?l.length:i,u?(v.hasOwnProp(l,i)?l[i]=[l[i],r]:l[i]=r,!s):((!l[i]||!v.isObject(l[i]))&&(l[i]=[]),t(n,r,l[i],o)&&v.isArray(l[i])&&(l[i]=Dm(l[i])),!s)}if(v.isFormData(e)&&v.isFunction(e.entries)){const n={};return v.forEachEntry(e,(r,l)=>{t(jm(r),l,n,0)}),n}return null}function Am(e,t,n){if(v.isString(e))try{return(t||JSON.parse)(e),v.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Qr={transitional:$f,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",l=r.indexOf("application/json")>-1,o=v.isObject(t);if(o&&v.isHTMLForm(t)&&(t=new FormData(t)),v.isFormData(t))return l?JSON.stringify(Hf(t)):t;if(v.isArrayBuffer(t)||v.isBuffer(t)||v.isStream(t)||v.isFile(t)||v.isBlob(t)||v.isReadableStream(t))return t;if(v.isArrayBufferView(t))return t.buffer;if(v.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let s;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Om(t,this.formSerializer).toString();if((s=v.isFileList(t))||r.indexOf("multipart/form-data")>-1){const u=this.env&&this.env.FormData;return yo(s?{"files[]":t}:t,u&&new u,this.formSerializer)}}return o||l?(n.setContentType("application/json",!1),Am(t)):t}],transformResponse:[function(t){const n=this.transitional||Qr.transitional,r=n&&n.forcedJSONParsing,l=this.responseType==="json";if(v.isResponse(t)||v.isReadableStream(t))return t;if(t&&v.isString(t)&&(r&&!this.responseType||l)){const i=!(n&&n.silentJSONParsing)&&l;try{return JSON.parse(t,this.parseReviver)}catch(s){if(i)throw s.name==="SyntaxError"?H.from(s,H.ERR_BAD_RESPONSE,this,null,this.response):s}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:De.classes.FormData,Blob:De.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};v.forEach(["delete","get","head","post","put","patch"],e=>{Qr.headers[e]={}});const Im=v.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Lm=e=>{const t={};let n,r,l;return e&&e.split(` `).forEach(function(i){l=i.indexOf(":"),n=i.substring(0,l).trim().toLowerCase(),r=i.substring(l+1).trim(),!(!n||t[n]&&Im[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},la=Symbol("internals");function ir(e){return e&&String(e).trim().toLowerCase()}function Nl(e){return e===!1||e==null?e:v.isArray(e)?e.map(Nl):String(e)}function zm(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const Fm=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Qo(e,t,n,r,l){if(v.isFunction(r))return r.call(this,t,n);if(l&&(t=n),!!v.isString(t)){if(v.isString(r))return t.indexOf(r)!==-1;if(v.isRegExp(r))return r.test(t)}}function Mm(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function Um(e,t){const n=v.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(l,o,i){return this[r].call(this,t,l,o,i)},configurable:!0})})}let Ke=class{constructor(t){t&&this.set(t)}set(t,n,r){const l=this;function o(s,u,a){const f=ir(u);if(!f)throw new Error("header name must be a non-empty string");const h=v.findKey(l,f);(!h||l[h]===void 0||a===!0||a===void 0&&l[h]!==!1)&&(l[h||u]=Nl(s))}const i=(s,u)=>v.forEach(s,(a,f)=>o(a,f,u));if(v.isPlainObject(t)||t instanceof this.constructor)i(t,n);else if(v.isString(t)&&(t=t.trim())&&!Fm(t))i(Lm(t),n);else if(v.isObject(t)&&v.isIterable(t)){let s={},u,a;for(const f of t){if(!v.isArray(f))throw TypeError("Object iterator must return a key-value pair");s[a=f[0]]=(u=s[a])?v.isArray(u)?[...u,f[1]]:[u,f[1]]:f[1]}i(s,n)}else t!=null&&o(n,t,r);return this}get(t,n){if(t=ir(t),t){const r=v.findKey(this,t);if(r){const l=this[r];if(!n)return l;if(n===!0)return zm(l);if(v.isFunction(n))return n.call(this,l,r);if(v.isRegExp(n))return n.exec(l);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=ir(t),t){const r=v.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Qo(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let l=!1;function o(i){if(i=ir(i),i){const s=v.findKey(r,i);s&&(!n||Qo(r,r[s],s,n))&&(delete r[s],l=!0)}}return v.isArray(t)?t.forEach(o):o(t),l}clear(t){const n=Object.keys(this);let r=n.length,l=!1;for(;r--;){const o=n[r];(!t||Qo(this,this[o],o,t,!0))&&(delete this[o],l=!0)}return l}normalize(t){const n=this,r={};return v.forEach(this,(l,o)=>{const i=v.findKey(r,o);if(i){n[i]=Nl(l),delete n[o];return}const s=t?Mm(o):String(o).trim();s!==o&&delete n[o],n[s]=Nl(l),r[s]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return v.forEach(this,(r,l)=>{r!=null&&r!==!1&&(n[l]=t&&v.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(l=>r.set(l)),r}static accessor(t){const r=(this[la]=this[la]={accessors:{}}).accessors,l=this.prototype;function o(i){const s=ir(i);r[s]||(Um(l,i),r[s]=!0)}return v.isArray(t)?t.forEach(o):o(t),this}};Ke.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);v.reduceDescriptors(Ke.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});v.freezeMethods(Ke);function Ko(e,t){const n=this||Qr,r=t||n,l=Ke.from(r.headers);let o=r.data;return v.forEach(e,function(s){o=s.call(n,o,l.normalize(),t?t.status:void 0)}),l.normalize(),o}function Vf(e){return!!(e&&e.__CANCEL__)}let Kr=class extends H{constructor(t,n,r){super(t??"canceled",H.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function Wf(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new H("Request failed with status code "+n.status,[H.ERR_BAD_REQUEST,H.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function Bm(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function $m(e,t){e=e||10;const n=new Array(e),r=new Array(e);let l=0,o=0,i;return t=t!==void 0?t:1e3,function(u){const a=Date.now(),f=r[o];i||(i=a),n[l]=u,r[l]=a;let h=o,y=0;for(;h!==l;)y+=n[h++],h=h%e;if(l=(l+1)%e,l===o&&(o=(o+1)%e),a-i{n=f,l=null,o&&(clearTimeout(o),o=null),e(...a)};return[(...a)=>{const f=Date.now(),h=f-n;h>=r?i(a,f):(l=a,o||(o=setTimeout(()=>{o=null,i(l)},r-h)))},()=>l&&i(l)]}const Xl=(e,t,n=3)=>{let r=0;const l=$m(50,250);return Hm(o=>{const i=o.loaded,s=o.lengthComputable?o.total:void 0,u=i-r,a=l(u),f=i<=s;r=i;const h={loaded:i,total:s,progress:s?i/s:void 0,bytes:u,rate:a||void 0,estimated:a&&s&&f?(s-i)/a:void 0,event:o,lengthComputable:s!=null,[t?"download":"upload"]:!0};e(h)},n)},oa=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},ia=e=>(...t)=>v.asap(()=>e(...t)),Vm=De.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,De.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(De.origin),De.navigator&&/(msie|trident)/i.test(De.navigator.userAgent)):()=>!0,Wm=De.hasStandardBrowserEnv?{write(e,t,n,r,l,o,i){if(typeof document>"u")return;const s=[`${e}=${encodeURIComponent(t)}`];v.isNumber(n)&&s.push(`expires=${new Date(n).toUTCString()}`),v.isString(r)&&s.push(`path=${r}`),v.isString(l)&&s.push(`domain=${l}`),o===!0&&s.push("secure"),v.isString(i)&&s.push(`SameSite=${i}`),document.cookie=s.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Qm(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Km(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Qf(e,t,n){let r=!Qm(t);return e&&(r||n==!1)?Km(e,t):t}const sa=e=>e instanceof Ke?{...e}:e;function mn(e,t){t=t||{};const n={};function r(a,f,h,y){return v.isPlainObject(a)&&v.isPlainObject(f)?v.merge.call({caseless:y},a,f):v.isPlainObject(f)?v.merge({},f):v.isArray(f)?f.slice():f}function l(a,f,h,y){if(v.isUndefined(f)){if(!v.isUndefined(a))return r(void 0,a,h,y)}else return r(a,f,h,y)}function o(a,f){if(!v.isUndefined(f))return r(void 0,f)}function i(a,f){if(v.isUndefined(f)){if(!v.isUndefined(a))return r(void 0,a)}else return r(void 0,f)}function s(a,f,h){if(h in t)return r(a,f);if(h in e)return r(void 0,a)}const u={url:o,method:o,data:o,baseURL:i,transformRequest:i,transformResponse:i,paramsSerializer:i,timeout:i,timeoutMessage:i,withCredentials:i,withXSRFToken:i,adapter:i,responseType:i,xsrfCookieName:i,xsrfHeaderName:i,onUploadProgress:i,onDownloadProgress:i,decompress:i,maxContentLength:i,maxBodyLength:i,beforeRedirect:i,transport:i,httpAgent:i,httpsAgent:i,cancelToken:i,socketPath:i,responseEncoding:i,validateStatus:s,headers:(a,f,h)=>l(sa(a),sa(f),h,!0)};return v.forEach(Object.keys({...e,...t}),function(f){const h=u[f]||l,y=h(e[f],t[f],f);v.isUndefined(y)&&h!==s||(n[f]=y)}),n}const Kf=e=>{const t=mn({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:l,xsrfCookieName:o,headers:i,auth:s}=t;if(t.headers=i=Ke.from(i),t.url=Bf(Qf(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),s&&i.set("Authorization","Basic "+btoa((s.username||"")+":"+(s.password?unescape(encodeURIComponent(s.password)):""))),v.isFormData(n)){if(De.hasStandardBrowserEnv||De.hasStandardBrowserWebWorkerEnv)i.setContentType(void 0);else if(v.isFunction(n.getHeaders)){const u=n.getHeaders(),a=["content-type","content-length"];Object.entries(u).forEach(([f,h])=>{a.includes(f.toLowerCase())&&i.set(f,h)})}}if(De.hasStandardBrowserEnv&&(r&&v.isFunction(r)&&(r=r(t)),r||r!==!1&&Vm(t.url))){const u=l&&o&&Wm.read(o);u&&i.set(l,u)}return t},Jm=typeof XMLHttpRequest<"u",Ym=Jm&&function(e){return new Promise(function(n,r){const l=Kf(e);let o=l.data;const i=Ke.from(l.headers).normalize();let{responseType:s,onUploadProgress:u,onDownloadProgress:a}=l,f,h,y,E,m;function w(){E&&E(),m&&m(),l.cancelToken&&l.cancelToken.unsubscribe(f),l.signal&&l.signal.removeEventListener("abort",f)}let N=new XMLHttpRequest;N.open(l.method.toUpperCase(),l.url,!0),N.timeout=l.timeout;function d(){if(!N)return;const p=Ke.from("getAllResponseHeaders"in N&&N.getAllResponseHeaders()),R={data:!s||s==="text"||s==="json"?N.responseText:N.response,status:N.status,statusText:N.statusText,headers:p,config:e,request:N};Wf(function(T){n(T),w()},function(T){r(T),w()},R),N=null}"onloadend"in N?N.onloadend=d:N.onreadystatechange=function(){!N||N.readyState!==4||N.status===0&&!(N.responseURL&&N.responseURL.indexOf("file:")===0)||setTimeout(d)},N.onabort=function(){N&&(r(new H("Request aborted",H.ECONNABORTED,e,N)),N=null)},N.onerror=function(S){const R=S&&S.message?S.message:"Network Error",P=new H(R,H.ERR_NETWORK,e,N);P.event=S||null,r(P),N=null},N.ontimeout=function(){let S=l.timeout?"timeout of "+l.timeout+"ms exceeded":"timeout exceeded";const R=l.transitional||$f;l.timeoutErrorMessage&&(S=l.timeoutErrorMessage),r(new H(S,R.clarifyTimeoutError?H.ETIMEDOUT:H.ECONNABORTED,e,N)),N=null},o===void 0&&i.setContentType(null),"setRequestHeader"in N&&v.forEach(i.toJSON(),function(S,R){N.setRequestHeader(R,S)}),v.isUndefined(l.withCredentials)||(N.withCredentials=!!l.withCredentials),s&&s!=="json"&&(N.responseType=l.responseType),a&&([y,m]=Xl(a,!0),N.addEventListener("progress",y)),u&&N.upload&&([h,E]=Xl(u),N.upload.addEventListener("progress",h),N.upload.addEventListener("loadend",E)),(l.cancelToken||l.signal)&&(f=p=>{N&&(r(!p||p.type?new Kr(null,e,N):p),N.abort(),N=null)},l.cancelToken&&l.cancelToken.subscribe(f),l.signal&&(l.signal.aborted?f():l.signal.addEventListener("abort",f)));const c=Bm(l.url);if(c&&De.protocols.indexOf(c)===-1){r(new H("Unsupported protocol "+c+":",H.ERR_BAD_REQUEST,e));return}N.send(o||null)})},qm=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,l;const o=function(a){if(!l){l=!0,s();const f=a instanceof Error?a:this.reason;r.abort(f instanceof H?f:new Kr(f instanceof Error?f.message:f))}};let i=t&&setTimeout(()=>{i=null,o(new H(`timeout of ${t}ms exceeded`,H.ETIMEDOUT))},t);const s=()=>{e&&(i&&clearTimeout(i),i=null,e.forEach(a=>{a.unsubscribe?a.unsubscribe(o):a.removeEventListener("abort",o)}),e=null)};e.forEach(a=>a.addEventListener("abort",o));const{signal:u}=r;return u.unsubscribe=()=>v.asap(s),u}},Xm=function*(e,t){let n=e.byteLength;if(n{const l=Gm(e,t);let o=0,i,s=u=>{i||(i=!0,r&&r(u))};return new ReadableStream({async pull(u){try{const{done:a,value:f}=await l.next();if(a){s(),u.close();return}let h=f.byteLength;if(n){let y=o+=h;n(y)}u.enqueue(new Uint8Array(f))}catch(a){throw s(a),a}},cancel(u){return s(u),l.return()}},{highWaterMark:2})},aa=64*1024,{isFunction:cl}=v,bm=(({Request:e,Response:t})=>({Request:e,Response:t}))(v.global),{ReadableStream:ca,TextEncoder:fa}=v.global,da=(e,...t)=>{try{return!!e(...t)}catch{return!1}},eg=e=>{e=v.merge.call({skipUndefined:!0},bm,e);const{fetch:t,Request:n,Response:r}=e,l=t?cl(t):typeof fetch=="function",o=cl(n),i=cl(r);if(!l)return!1;const s=l&&cl(ca),u=l&&(typeof fa=="function"?(m=>w=>m.encode(w))(new fa):async m=>new Uint8Array(await new n(m).arrayBuffer())),a=o&&s&&da(()=>{let m=!1;const w=new n(De.origin,{body:new ca,method:"POST",get duplex(){return m=!0,"half"}}).headers.has("Content-Type");return m&&!w}),f=i&&s&&da(()=>v.isReadableStream(new r("").body)),h={stream:f&&(m=>m.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(m=>{!h[m]&&(h[m]=(w,N)=>{let d=w&&w[m];if(d)return d.call(w);throw new H(`Response type '${m}' is not supported`,H.ERR_NOT_SUPPORT,N)})});const y=async m=>{if(m==null)return 0;if(v.isBlob(m))return m.size;if(v.isSpecCompliantForm(m))return(await new n(De.origin,{method:"POST",body:m}).arrayBuffer()).byteLength;if(v.isArrayBufferView(m)||v.isArrayBuffer(m))return m.byteLength;if(v.isURLSearchParams(m)&&(m=m+""),v.isString(m))return(await u(m)).byteLength},E=async(m,w)=>{const N=v.toFiniteNumber(m.getContentLength());return N??y(w)};return async m=>{let{url:w,method:N,data:d,signal:c,cancelToken:p,timeout:S,onDownloadProgress:R,onUploadProgress:P,responseType:T,headers:A,withCredentials:C="same-origin",fetchOptions:$}=Kf(m),L=t||fetch;T=T?(T+"").toLowerCase():"text";let Ne=qm([c,p&&p.toAbortSignal()],S),fe=null;const Se=Ne&&Ne.unsubscribe&&(()=>{Ne.unsubscribe()});let Me;try{if(P&&a&&N!=="get"&&N!=="head"&&(Me=await E(A,d))!==0){let W=new n(w,{method:"POST",body:d,duplex:"half"}),X;if(v.isFormData(d)&&(X=W.headers.get("content-type"))&&A.setContentType(X),W.body){const[St,Ue]=oa(Me,Xl(ia(P)));d=ua(W.body,aa,St,Ue)}}v.isString(C)||(C=C?"include":"omit");const de=o&&"credentials"in n.prototype,Te={...$,signal:Ne,method:N.toUpperCase(),headers:A.normalize().toJSON(),body:d,duplex:"half",credentials:de?C:void 0};fe=o&&new n(w,Te);let x=await(o?L(fe,$):L(w,Te));const z=f&&(T==="stream"||T==="response");if(f&&(R||z&&Se)){const W={};["status","statusText","headers"].forEach(Dt=>{W[Dt]=x[Dt]});const X=v.toFiniteNumber(x.headers.get("content-length")),[St,Ue]=R&&oa(X,Xl(ia(R),!0))||[];x=new r(ua(x.body,aa,St,()=>{Ue&&Ue(),Se&&Se()}),W)}T=T||"text";let B=await h[v.findKey(h,T)||"text"](x,m);return!z&&Se&&Se(),await new Promise((W,X)=>{Wf(W,X,{data:B,headers:Ke.from(x.headers),status:x.status,statusText:x.statusText,config:m,request:fe})})}catch(de){throw Se&&Se(),de&&de.name==="TypeError"&&/Load failed|fetch/i.test(de.message)?Object.assign(new H("Network Error",H.ERR_NETWORK,m,fe),{cause:de.cause||de}):H.from(de,de&&de.code,m,fe)}}},tg=new Map,Jf=e=>{let t=e&&e.env||{};const{fetch:n,Request:r,Response:l}=t,o=[r,l,n];let i=o.length,s=i,u,a,f=tg;for(;s--;)u=o[s],a=f.get(u),a===void 0&&f.set(u,a=s?new Map:eg(t)),f=a;return a};Jf();const Hs={http:vm,xhr:Ym,fetch:{get:Jf}};v.forEach(Hs,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const pa=e=>`- ${e}`,ng=e=>v.isFunction(e)||e===null||e===!1;function rg(e,t){e=v.isArray(e)?e:[e];const{length:n}=e;let r,l;const o={};for(let i=0;i`adapter ${u} `+(a===!1?"is not supported by the environment":"is not available in the build"));let s=n?i.length>1?`since : `+i.map(pa).join(` `):" "+pa(i[0]):"as no adapter specified";throw new H("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return l}const Yf={getAdapter:rg,adapters:Hs};function Jo(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Kr(null,e)}function ha(e){return Jo(e),e.headers=Ke.from(e.headers),e.data=Ko.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Yf.getAdapter(e.adapter||Qr.adapter,e)(e).then(function(r){return Jo(e),r.data=Ko.call(e,e.transformResponse,r),r.headers=Ke.from(r.headers),r},function(r){return Vf(r)||(Jo(e),r&&r.response&&(r.response.data=Ko.call(e,e.transformResponse,r.response),r.response.headers=Ke.from(r.response.headers))),Promise.reject(r)})}const qf="1.13.4",vo={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{vo[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const ma={};vo.transitional=function(t,n,r){function l(o,i){return"[Axios v"+qf+"] Transitional option '"+o+"'"+i+(r?". "+r:"")}return(o,i,s)=>{if(t===!1)throw new H(l(i," has been removed"+(n?" in "+n:"")),H.ERR_DEPRECATED);return n&&!ma[i]&&(ma[i]=!0,console.warn(l(i," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(o,i,s):!0}};vo.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function lg(e,t,n){if(typeof e!="object")throw new H("options must be an object",H.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let l=r.length;for(;l-- >0;){const o=r[l],i=t[o];if(i){const s=e[o],u=s===void 0||i(s,o,e);if(u!==!0)throw new H("option "+o+" must be "+u,H.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new H("Unknown option "+o,H.ERR_BAD_OPTION)}}const xl={assertOptions:lg,validators:vo},gt=xl.validators;let an=class{constructor(t){this.defaults=t||{},this.interceptors={request:new ra,response:new ra}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let l={};Error.captureStackTrace?Error.captureStackTrace(l):l=new Error;const o=l.stack?l.stack.replace(/^.+\n/,""):"";try{r.stack?o&&!String(r.stack).endsWith(o.replace(/^.+\n.+\n/,""))&&(r.stack+=` `+o):r.stack=o}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=mn(this.defaults,n);const{transitional:r,paramsSerializer:l,headers:o}=n;r!==void 0&&xl.assertOptions(r,{silentJSONParsing:gt.transitional(gt.boolean),forcedJSONParsing:gt.transitional(gt.boolean),clarifyTimeoutError:gt.transitional(gt.boolean)},!1),l!=null&&(v.isFunction(l)?n.paramsSerializer={serialize:l}:xl.assertOptions(l,{encode:gt.function,serialize:gt.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),xl.assertOptions(n,{baseUrl:gt.spelling("baseURL"),withXsrfToken:gt.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let i=o&&v.merge(o.common,o[n.method]);o&&v.forEach(["delete","get","head","post","put","patch","common"],m=>{delete o[m]}),n.headers=Ke.concat(i,o);const s=[];let u=!0;this.interceptors.request.forEach(function(w){typeof w.runWhen=="function"&&w.runWhen(n)===!1||(u=u&&w.synchronous,s.unshift(w.fulfilled,w.rejected))});const a=[];this.interceptors.response.forEach(function(w){a.push(w.fulfilled,w.rejected)});let f,h=0,y;if(!u){const m=[ha.bind(this),void 0];for(m.unshift(...s),m.push(...a),y=m.length,f=Promise.resolve(n);h{if(!r._listeners)return;let o=r._listeners.length;for(;o-- >0;)r._listeners[o](l);r._listeners=null}),this.promise.then=l=>{let o;const i=new Promise(s=>{r.subscribe(s),o=s}).then(l);return i.cancel=function(){r.unsubscribe(o)},i},t(function(o,i,s){r.reason||(r.reason=new Kr(o,i,s),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Xf(function(l){t=l}),cancel:t}}};function ig(e){return function(n){return e.apply(null,n)}}function sg(e){return v.isObject(e)&&e.isAxiosError===!0}const Wi={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Wi).forEach(([e,t])=>{Wi[t]=e});function Gf(e){const t=new an(e),n=Pf(an.prototype.request,t);return v.extend(n,an.prototype,t,{allOwnKeys:!0}),v.extend(n,t,null,{allOwnKeys:!0}),n.create=function(l){return Gf(mn(e,l))},n}const ee=Gf(Qr);ee.Axios=an;ee.CanceledError=Kr;ee.CancelToken=og;ee.isCancel=Vf;ee.VERSION=qf;ee.toFormData=yo;ee.AxiosError=H;ee.Cancel=ee.CanceledError;ee.all=function(t){return Promise.all(t)};ee.spread=ig;ee.isAxiosError=sg;ee.mergeConfig=mn;ee.AxiosHeaders=Ke;ee.formToJSON=e=>Hf(v.isHTMLForm(e)?new FormData(e):e);ee.getAdapter=Yf.getAdapter;ee.HttpStatusCode=Wi;ee.default=ee;const{Axios:pg,AxiosError:hg,CanceledError:mg,isCancel:gg,CancelToken:yg,VERSION:vg,all:_g,Cancel:wg,isAxiosError:Sg,spread:Eg,toFormData:kg,AxiosHeaders:Ng,HttpStatusCode:xg,formToJSON:Cg,getAdapter:Rg,mergeConfig:Tg}=ee,wn="https://dataapi.kitchain.cn/api/v1";function ug(){const[e,t]=b.useState(null),[n,r]=b.useState([]),[l,o]=b.useState([]),[i,s]=b.useState(""),[u,a]=b.useState(""),[f,h]=b.useState(""),[y,E]=b.useState(""),[m,w]=b.useState(!1),[N,d]=b.useState(null),[c,p]=b.useState(0),[S,R]=b.useState(null),[P,T]=b.useState(1),A=5,[C,$]=b.useState(null),[L,Ne]=b.useState({steps:[],ingredients:[]}),[fe,Se]=b.useState([]),[Me,de]=b.useState(null),Te=b.useRef(Me);Te.current=Me;const[x,z]=b.useState([]),[B,W]=b.useState(null),X=b.useRef(B);X.current=B;const[St,Ue]=b.useState(!1),[Dt,Je]=b.useState(!1),[ht,Vs]=b.useState(!1),Zf=async _=>{console.log("[API] 开始查询门店数据, store_name:",_);try{const O=await ee.get(`${wn}/stores/`,{params:{store_name:_}});console.log("[API] 门店响应完整:",O),console.log("[API] 门店响应 data:",O.data);const I=O.data;if(console.log("[API] result:",I,"code:",I.code,"data:",I.data),I.code===200&&I.data){const M=I.data.items||I.data,Q=Array.isArray(M)?M[0]:M;console.log("[API] 设置门店数据:",Q),t(Q),p(K=>K+1),console.log("[API] currentStoreData 已设置")}else console.warn("[API] 门店响应码不为200或无data:",I)}catch(O){console.error("[API] 按名称查询门店数据失败:",O)}},bf=async _=>{try{const O={};_.dish_id!==void 0&&(O.dish_id=_.dish_id),_.dish_name&&(O.dish_name=_.dish_name),_.store_id!==void 0&&(O.store_id=_.store_id),_.store_name&&(O.store_name=_.store_name),console.log("[API] 查询原料参数:",O),R(_);const M=(await ee.get(`${wn}/ingredients/by-dish`,{params:O})).data;if(console.log("[API] 原料响应:",JSON.stringify(M,null,2)),M.code===200&&M.data){let Q;Array.isArray(M.data)?Q=M.data:M.data.items?Q=M.data.items:Q=[];const K=Q;console.log("[API] 原料数据字段:",K.length>0?Object.keys(K[0]):[]),console.log("[API] 原料数据完整内容:",JSON.stringify(K[0],null,2)),r(K),console.log("[API] 设置原料数据, 共",K.length,"条")}}catch(O){console.error("[ApiRenderPage] 查询原料数据失败:",O)}},ed=async _=>{try{const I=(await ee.get(`${wn}/steps/${_}`)).data;if(console.log("[API] 步骤(ID)响应:",JSON.stringify(I,null,2)),I.code===200){const M=I.message||"",Q=M.match(/门店\s+'([^']+)'/),K=M.match(/菜品\s+'([^']+)'/),vn=Q?Q[1]:"",bt=K?K[1]:"";console.log("[API] 解析 - 门店:",vn,"菜品:",bt);const Gn=Array.isArray(I.data)?I.data:[];console.log("[API] 步骤数据:",Gn),o(Gn),s(bt),a(vn)}}catch(O){console.error("[ApiRenderPage] 查询步骤数据失败:",O)}},td=async _=>{try{console.log("[API] 创建菜品, 数据:",_);const I=(await ee.post(`${wn}/dishes/`,_)).data;if(console.log("[API] 创建菜品响应:",I),I.code!==200)throw new Error(I.message||"创建菜品失败");return I}catch(O){throw console.error("[ApiRenderPage] 创建菜品失败:",O),O}},nd=async(_,O,I)=>{try{console.log("[API] 创建步骤, dishId:",_,"storeId:",O,"steps:",I);const Q=(await ee.post(`${wn}/steps/batch`,{dish_id:_,store_id:O,steps:I})).data;if(console.log("[API] 创建步骤响应:",Q),Q.code!==200)throw new Error(Q.message||"创建步骤失败");return Q}catch(M){throw console.error("[ApiRenderPage] 创建步骤失败:",M),M}},rd=async _=>{try{console.log("[API] 创建原料, 数据:",_);const I=(await ee.post(`${wn}/ingredients/`,_)).data;if(console.log("[API] 创建原料响应:",I),I.code!==200)throw new Error(I.message||"创建原料失败");return I}catch(O){throw console.error("[ApiRenderPage] 创建原料失败:",O),O}},ld=async()=>{if(!L.dish_name){d("缺少菜品名称");return}Vs(!0),d(null);try{if(await td({dish_name:L.dish_name}),console.log("[Stock] 菜品创建成功"),L.steps.length>0&&(await nd(0,10,L.steps.map(_=>({step_no:_.step_no,cooking_description:_.cooking_description,cause:_.cause,key_points:_.key_points}))),console.log("[Stock] 步骤创建成功")),L.ingredients.length>0){for(const _ of L.ingredients)await rd({store_id:10,ing_name:_.ing_name,ing_type:_.ing_type,ing_cost:_.ing_cost,ingredient_count:_.ingredient_count,ing_amount:_.ing_amount});console.log("[Stock] 原料创建成功")}console.log("[Stock] 入库完成"),Je(!1),alert("入库成功!")}catch(_){console.error("[Stock] 入库失败:",_),d("入库失败,请重试")}finally{Vs(!1)}};return b.useEffect(()=>{const _=O=>{var bt,Gn;console.log("========== 收到 postMessage =========="),console.log("origin:",O.origin),console.log("data:",JSON.stringify(O.data,null,2)),console.log("======================================");const I=O.data;console.log("[Debug] 消息类型:",I==null?void 0:I.type);let M,Q,K,vn;if((I==null?void 0:I.type)==="tool_event"&&(I!=null&&I.event)){const pe=I;M=pe.event.type,Q=pe.event.code,K=pe.event.data||{},vn=pe.event.id,pe.event.timestamp}else if((Gn=(bt=I==null?void 0:I.type)==null?void 0:bt.startsWith)!=null&&Gn.call(bt,"tool_event"))M=I.type,Q=I.code,K=I.data||{},vn=I.id,I.timestamp;else{console.log("[Debug] 消息格式不正确");return}if(console.log(`[解析] ${Q} | ${M} | id: ${vn}`,K),Q==="UPDATE_STORES"){console.log("[Debug] 匹配到 UPDATE_STORES 事件"),console.log("[Debug] eventType:",M),console.log("[Debug] eventData:",JSON.stringify(K,null,2));const pe=K;if(Q==="UPDATE_STORES"&&pe.code===0&&pe.data&&pe.data.items){const V=pe.data.items[0];console.log("[Debug] 直接从事件获取门店数据:",V),V&&(t(V),p(se=>se+1),console.log("[Debug] 门店数据设置成功"));return}const D=(pe.data||{}).store_name;if(console.log("[Debug] storeName:",D),!D){console.warn("[Event] 门店名称为空");return}M==="tool_event_start"&&(console.log("[Event] 开始查询门店, store_name:",D),Zf(String(D)))}else if(Q==="UPDATE_INGREDIENTS_BY_DISH"){if(M==="tool_event_start"){console.log("[Event] UPDATE_INGREDIENTS_BY_DISH (tool_event_start):",K);const ge=K.data||{};console.log("[Event] dataObj:",JSON.stringify(ge,null,2));const D=ge.dish_name,F=ge.store_name;console.log("[Event] 菜品名称:",D,"门店名称:",F),Ne(U=>({...U,dish_name:D||U.dish_name,store_name:F||U.store_name})),console.log("[Event] 菜品信息渲染完成")}else if(M==="tool_event_end"){console.log("[Event] UPDATE_INGREDIENTS_BY_DISH 数据:",K);const D=(K.data||{}).data||[];console.log("[Event] dataArray:",JSON.stringify(D,null,2));const F=D==null?void 0:D[0],U=Number(F==null?void 0:F.store_id)||0,V=Number(F==null?void 0:F.dish_id)||0;if(console.log("[Event] 当前查询: store_id=",U,"dish_id=",V),console.log("[Event] 制作流程数据(Ref):",X.current),X.current){const J=X.current.store_id,ve=X.current.dish_id;console.log("[Event] 制作流程: store_id=",J,"dish_id=",ve),J!==U||ve!==V?(console.log("[Event] 菜品不一致,清空制作流程数据"),o([]),z([]),W(null),s(""),a("")):console.log("[Event] 菜品一致,保留制作流程数据")}else console.log("[Event] 制作流程无数据,无需清空");r([]),Se([]),de(null),h(""),E("");const se=(D||[]).map(J=>({id:Number(J.id)||0,store_id:Number(J.store_id)||0,dish_id:Number(J.dish_id)||0,ing_name:J.ing_name||"",ing_type:Number(J.ing_type)||0,ing_cost:Number(J.ing_cost)||0,ingredient_count:Number(J.ingredient_count)||0,ing_amount:Number(J.ing_amount)||0,ing_yield_rate:Number(J.ing_yield_rate)||0,ing_process_ratio:Number(J.ing_process_ratio)||0,ing_ratio:Number(J.ing_ratio)||0,ing_type_code:J.ing_type_code||"",ing_spec:J.ing_spec||"",ing_weight_g:Number(J.ing_weight_g)||0,ing_id:Number(J.ing_id)||0}));de({store_id:U,dish_id:V}),console.log("[Event] newBatchIngredients:",JSON.stringify(se,null,2)),Se(se),console.log("[Event] 原料加载完成,共",se.length,"条")}}else if(Q==="UPDATE_STEPS_BY_ID"){if(M==="tool_event_end"){console.log("[Event] UPDATE_STEPS_BY_ID 数据:",K);const ge=K.data||{},D=ge.data||[];console.log("[Event] dataObj:",JSON.stringify(ge,null,2)),console.log("[Event] dataArray:",JSON.stringify(D,null,2));const F=ge.message;let U="",V="";if(F){const oe=F.match(/门店 '([^']+)' 的菜品 '([^']+)'/);oe&&(V=oe[1],U=oe[2])}console.log("[Event] 门店名称:",V,"菜品名称:",U),Ne(oe=>({...oe,dish_name:U||oe.dish_name})),s(U),a(V);const se=D==null?void 0:D[0],J=Number(se==null?void 0:se.store_id)||0,ve=Number(se==null?void 0:se.dish_id)||0;if(console.log("[Event] 当前查询: store_id=",J,"dish_id=",ve),console.log("[Event] 原料数据(Ref):",Te.current),Te.current){const oe=Te.current.store_id,G=Te.current.dish_id;console.log("[Event] 原料: store_id=",oe,"dish_id=",G),oe!==J||G!==ve?(console.log("[Event] 菜品不一致,清空原料成本明细数据"),r([]),Se([]),de(null),h(""),E("")):console.log("[Event] 菜品一致,保留原料成本明细数据")}else console.log("[Event] 原料无数据,无需清空");o([]),z([]),W(null);const le=(D||[]).map(oe=>({id:Number(oe.id)||0,dish_id:Number(oe.dish_id)||0,store_id:Number(oe.store_id)||0,step_no:Number(oe.step_no)||0,cooking_description:oe.cooking_description||"",cause:oe.cause||"",key_points:oe.key_points||""}));W({store_id:J,dish_id:ve}),console.log("[Event] newBatchSteps:",JSON.stringify(le,null,2)),z(le),console.log("[Event] 步骤加载完成,共",le.length,"条")}}else if(Q==="UPDATE_STEPS_BY_NAME"){if(M==="tool_event_start"){console.log("[Event] UPDATE_STEPS_BY_NAME (tool_event_start):",K);const ge=K.data||{};console.log("[Event] dataObj:",JSON.stringify(ge,null,2));const D=ge.dish_name,F=ge.store_name;console.log("[Event] 菜品名称:",D,"门店名称:",F),Ne(U=>({...U,dish_name:D||U.dish_name,store_name:F||U.store_name})),console.log("[Event] 菜品信息渲染完成")}else if(M==="tool_event_end"){console.log("[Event] UPDATE_STEPS_BY_NAME 数据:",K);const D=(K.data||{}).data||{},F=D.data||[];console.log("[Event] dataObj:",JSON.stringify(D,null,2)),console.log("[Event] dataArray:",JSON.stringify(F,null,2));const U=D.message;let V="",se="";if(U){const G=U.match(/门店 '([^']+)' 的菜品 '([^']+)'/);G&&(se=G[1],V=G[2])}console.log("[Event] 门店名称:",se,"菜品名称:",V),Ne(G=>({...G,dish_name:V||G.dish_name})),s(V),a(se);const J=F==null?void 0:F[0],ve=Number(J==null?void 0:J.store_id)||0,le=Number(J==null?void 0:J.dish_id)||0;if(console.log("[Event] 当前查询: store_id=",ve,"dish_id=",le),console.log("[Event] 原料数据(Ref):",Te.current),Te.current){const G=Te.current.store_id,Ws=Te.current.dish_id;console.log("[Event] 原料: store_id=",G,"dish_id=",Ws),G!==ve||Ws!==le?(console.log("[Event] 菜品不一致,清空原料成本明细数据"),r([]),Se([]),de(null),h(""),E("")):console.log("[Event] 菜品一致,保留原料成本明细数据")}else console.log("[Event] 原料无数据,无需清空");o([]),z([]),W(null);const oe=(F||[]).map(G=>({id:Number(G.id)||0,dish_id:Number(G.dish_id)||0,store_id:Number(G.store_id)||0,step_no:Number(G.step_no)||0,cooking_description:G.cooking_description||"",cause:G.cause||"",key_points:G.key_points||""}));W({store_id:ve,dish_id:le}),console.log("[Event] newBatchSteps:",JSON.stringify(oe,null,2)),z(oe),console.log("[Event] 步骤加载完成,共",oe.length,"条")}}else if(Q==="UPDATE_BATCH_STEPS_BY_NAME"){if(M==="tool_event_end"){console.log("[Event] UPDATE_BATCH_STEPS_BY_NAME 数据:",K);const D=(K.data||{}).data||[];console.log("[Event] dataArray:",JSON.stringify(D,null,2)),o([]),z([]),W(null),s(""),a("");const F=(D||[]).map(V=>({id:Number(V.id)||0,dish_id:Number(V.dish_id)||0,store_id:Number(V.store_id)||0,step_no:Number(V.step_no)||0,cooking_description:V.cooking_description||"",cause:V.cause||"",key_points:V.key_points||""})),U=D==null?void 0:D[0];W({store_id:Number(U==null?void 0:U.store_id)||0,dish_id:Number(U==null?void 0:U.dish_id)||0}),console.log("[Event] newBatchSteps:",JSON.stringify(F,null,2)),z(F),console.log("[Event] 批量步骤加载完成,共",F.length,"条")}}else if(Q==="CREATE_DISH_BY_NAME"){if(M==="tool_event_end"){console.log("[Event] CREATE_DISH_BY_NAME 数据:",K);const D=(K.data||{}).data||{};console.log("[Event] 菜品信息数据:",D);const F=D.dish_name,U=Number(D.store_id)||0,V=D.category_name,se=D.big_category_name,ve=(D.steps||[]).map(G=>({step_no:Number(G.step_no)||0,cooking_description:G.cooking_description||"",cause:G.cause||"",key_points:G.key_points||""})),oe=(D.ingredients||[]).map(G=>({ing_name:G.ing_name||"",ing_type:Number(G.ing_type)||1,ing_amount:Number(G.ing_amount)||0,ing_cost:Number(G.ing_cost)||0,ingredient_count:Number(G.ingredient_count)||0}));Ne({dish_name:F,store_id:U,category_name:V,big_category_name:se,steps:ve,ingredients:oe}),Ue(!0),console.log("[Event] 菜品信息显示完成,共",ve.length,"个步骤,",oe.length,"个原料")}}else if(Q==="GET_DISH_BY_NAME"){if(M==="tool_event_end"){console.log("[Event] GET_DISH_BY_NAME 数据:",K);const D=(K.data||{}).data||{};console.log("[Event] 菜品信息数据:",D);const F=D.dish_name,U=Number(D.store_id)||0,V=D.category_name,se=D.big_category_name,J=Number(D.id)||0;Ne(ve=>({...ve,dish_name:F,store_id:U,category_name:V,big_category_name:se})),o([]),z([]),W(null),s(""),a(""),r([]),Se([]),de(null),h(""),E(""),console.log("[Event] 菜品信息获取完成:",{dishName:F,storeId:U,categoryName:V,bigCategoryName:se,dishId:J}),F&&U&&(console.log("[Event] 开始查询原料, dish_name:",F,"store_id:",U),bf({dish_name:F,store_id:U})),J&&(console.log("[Event] 开始查询步骤, id:",J),ed(J))}}else if(Q==="UPDATE_BATCH_INGREDIENTS_BY_NAME"){if(M==="tool_event_end"){console.log("[Event] 检测到 UPDATE_BATCH_INGREDIENTS_BY_NAME 事件"),console.log("[Event] eventData:",JSON.stringify(K,null,2));const D=(K.data||{}).data||{};console.log("[Event] dataObj:",JSON.stringify(D,null,2)),r([]),Se([]),de(null),h(""),E("");const F=D.resolved;console.log("[Event] resolved:",JSON.stringify(F,null,2));const U={store_id:Number(F==null?void 0:F.store_id)||0,store_name:(F==null?void 0:F.store_name)||"",dish_id:Number(F==null?void 0:F.dish_id)||0,dish_name:(F==null?void 0:F.dish_name)||""};de(U);const V=D.created||[],se=D.updated||[],J=[...V,...se];console.log("[Event] allIngredients:",JSON.stringify(J,null,2));const ve=(J||[]).map(le=>({id:Number(le.id)||0,store_id:Number(le.store_id)||0,dish_id:Number(le.dish_id)||0,ing_name:le.ing_name||"",ing_type:Number(le.ing_type)||0,ing_cost:Number(le.ing_cost)||0,ingredient_count:Number(le.ingredient_count)||0,ing_amount:Number(le.ing_amount)||0,ing_yield_rate:Number(le.ing_yield_rate)||0,ing_process_ratio:Number(le.ing_process_ratio)||0,ing_ratio:Number(le.ing_ratio)||0,ing_type_code:le.ing_type_code||"",ing_spec:le.ing_spec||"",ing_weight_g:Number(le.ing_weight_g)||0,ing_id:Number(le.ing_id)||0}));console.log("[Event] newBatchIngredients:",JSON.stringify(ve,null,2)),Se(ve),console.log("[Event] 批量原料加载完成,共",ve.length,"条")}}else if(Q==="CREATE_BATCH_STEPS_WITH_DETAIL"){if(M==="tool_event_end"){console.log("[Event] 检测到 CREATE_BATCH_STEPS_WITH_DETAIL 事件"),console.log("[Event] eventData:",JSON.stringify(K,null,2));const D=(K.data||{}).data||[];console.log("[Event] dataArray:",JSON.stringify(D,null,2)),o([]),z([]),W(null),s(""),a("");const F=(D||[]).map(V=>({id:Number(V.id)||0,dish_id:Number(V.dish_id)||0,store_id:Number(V.store_id)||0,step_no:Number(V.step_no)||0,cooking_description:V.cooking_description||"",cause:V.cause||"",key_points:V.key_points||""})),U=D==null?void 0:D[0];W({store_id:Number(U==null?void 0:U.store_id)||0,dish_id:Number(U==null?void 0:U.dish_id)||0}),console.log("[Event] newBatchSteps:",JSON.stringify(F,null,2)),z(F),console.log("[Event] 批量步骤加载完成,共",F.length,"条")}}else if(Q==="CREATE_BATCH_STEPS_BY_NAME"&&M==="tool_event_end"){console.log("[Event] 检测到 CREATE_BATCH_STEPS_BY_NAME 事件"),console.log("[Event] eventData:",JSON.stringify(K,null,2));const D=(K.data||{}).data||[];console.log("[Event] dataArray:",JSON.stringify(D,null,2)),o([]),z([]),W(null),s(""),a("");const F=(D||[]).map(V=>({id:Number(V.id)||0,dish_id:Number(V.dish_id)||0,store_id:Number(V.store_id)||0,step_no:Number(V.step_no)||0,cooking_description:V.cooking_description||"",cause:V.cause||"",key_points:V.key_points||""})),U=D==null?void 0:D[0];W({store_id:Number(U==null?void 0:U.store_id)||0,dish_id:Number(U==null?void 0:U.dish_id)||0}),console.log("[Event] newBatchSteps:",JSON.stringify(F,null,2)),z(F),console.log("[Event] 批量步骤加载完成,共",F.length,"条")}};return window.addEventListener("message",_),()=>window.removeEventListener("message",_)},[]),g.jsxs("div",{className:"api-render-page",children:[m&&g.jsx("div",{className:"empty-store",children:g.jsx("p",{children:"正在处理..."})}),N&&!m&&g.jsxs("div",{className:"empty-store",children:[g.jsxs("p",{style:{color:"#c41e3a"},children:["错误: ",N]}),g.jsx("p",{className:"hint",children:"请检查后端服务是否启动"})]}),e&&g.jsxs("div",{className:"store-info-panel",children:[g.jsxs("div",{className:"panel-header",children:[g.jsx("h3",{children:"门店信息"}),g.jsxs("span",{className:"store-id",children:["ID: ",e.id]})]}),g.jsxs("div",{className:"store-info-content",children:[g.jsxs("div",{className:"info-row",children:[g.jsx("span",{className:"info-label",children:"门店名称:"}),g.jsx("span",{className:"info-value store-name",children:e.store_name||"-"})]}),g.jsxs("div",{className:"info-row",children:[g.jsx("span",{className:"info-label",children:"ID:"}),g.jsx("span",{className:"info-value",children:e.id})]}),g.jsxs("div",{className:"info-row",children:[g.jsx("span",{className:"info-label",children:"门店编号:"}),g.jsx("span",{className:"info-value",children:e.store_id||"-"})]})]})]}),(L.dish_name||L.category_name||L.big_category_name||L.store_id!==void 0||L.cuisine||L.steps.length>0||L.ingredients.length>0)&&g.jsxs("div",{className:"dish-create-panel",children:[g.jsx("div",{className:"panel-header",children:g.jsx("h3",{children:"菜品信息"})}),g.jsx("div",{className:"dish-create-content",children:g.jsxs("div",{className:"dish-basic-info",children:[L.dish_name&&g.jsx("div",{className:"dish-name",children:L.dish_name}),L.store_id!==void 0&&g.jsxs("div",{className:"dish-store-id",children:[g.jsx("span",{className:"label",children:"门店ID:"}),g.jsx("span",{className:"value",children:L.store_id})]}),L.category_name&&g.jsx("span",{className:"tag cuisine",children:L.category_name}),L.big_category_name&&g.jsx("span",{className:"tag category",children:L.big_category_name})]})})]}),(l.length>0||n.length>0||L.steps.length>0||L.ingredients.length>0||x.length>0||fe.length>0)&&g.jsxs("div",{className:"detail-grid",children:[g.jsxs("div",{className:"steps-panel",children:[g.jsxs("div",{className:"panel-header",children:[g.jsxs("div",{children:[g.jsx("h3",{children:"制作流程"}),B&&x.length>0&&g.jsxs("div",{className:"query-info",style:{fontSize:"12px",color:"#666",marginTop:"4px"},children:[B.store_id!==0&&g.jsxs("span",{children:["门店ID: ",B.store_id]}),B.store_id!==0&&B.dish_id!==0&&g.jsx("span",{style:{marginLeft:"12px"},children:"|"}),B.dish_id!==0&&g.jsxs("span",{style:{marginLeft:"12px"},children:["菜品ID: ",B.dish_id]})]}),(i||u)&&g.jsxs("div",{className:"query-info",style:{fontSize:"12px",color:"#666",marginTop:"4px"},children:[i&&g.jsxs("span",{children:["菜品: ",i]}),i&&u&&g.jsx("span",{style:{marginLeft:"12px"},children:"|"}),u&&g.jsxs("span",{style:{marginLeft:"12px"},children:["门店: ",u]})]})]}),g.jsxs("span",{className:"steps-count",children:["共 ",(L.steps.length>0?L.steps:x.length>0?x:l).length," 道工序"]})]}),g.jsx("div",{className:"steps-table-container",children:g.jsxs("table",{className:"steps-table",children:[g.jsx("thead",{children:g.jsxs("tr",{children:[g.jsx("th",{className:"col-step-num",children:"序号"}),g.jsx("th",{className:"col-step-desc",children:"步骤"}),g.jsx("th",{className:"col-step-cause",children:"原因"}),g.jsx("th",{className:"col-step-points",children:"要点"})]})}),g.jsx("tbody",{children:x.length>0?x.sort((_,O)=>_.step_no-O.step_no).map((_,O)=>{const I=(C==null?void 0:C.rowId)===O&&(C==null?void 0:C.col)==="desc",M=(C==null?void 0:C.rowId)===O&&(C==null?void 0:C.col)==="cause",Q=(C==null?void 0:C.rowId)===O&&(C==null?void 0:C.col)==="points";return g.jsxs("tr",{children:[g.jsx("td",{className:"col-step-num",children:_.step_no}),g.jsx("td",{className:I?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(I?null:{rowId:O,col:"desc"}),children:I?_.cooking_description:(_.cooking_description||"-").length>5?`${(_.cooking_description||"-").slice(0,5)}...`:_.cooking_description||"-"}),g.jsx("td",{className:M?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(M?null:{rowId:O,col:"cause"}),children:M?_.cause:(_.cause||"-").length>5?`${(_.cause||"-").slice(0,5)}...`:_.cause||"-"}),g.jsx("td",{className:Q?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(Q?null:{rowId:O,col:"points"}),children:Q?_.key_points:(_.key_points||"-").length>5?`${(_.key_points||"-").slice(0,5)}...`:_.key_points||"-"})]},`batch-step-${_.id}`)}):L.steps.length>0?L.steps.sort((_,O)=>_.step_no-O.step_no).map((_,O)=>{const I=(C==null?void 0:C.rowId)===O&&(C==null?void 0:C.col)==="desc",M=(C==null?void 0:C.rowId)===O&&(C==null?void 0:C.col)==="cause",Q=(C==null?void 0:C.rowId)===O&&(C==null?void 0:C.col)==="points";return g.jsxs("tr",{children:[g.jsx("td",{className:"col-step-num",children:_.step_no}),g.jsx("td",{className:I?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(I?null:{rowId:O,col:"desc"}),children:I?_.cooking_description:(_.cooking_description||"-").length>5?`${(_.cooking_description||"-").slice(0,5)}...`:_.cooking_description||"-"}),g.jsx("td",{className:M?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(M?null:{rowId:O,col:"cause"}),children:M?_.cause:(_.cause||"-").length>5?`${(_.cause||"-").slice(0,5)}...`:_.cause||"-"}),g.jsx("td",{className:Q?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(Q?null:{rowId:O,col:"points"}),children:Q?_.key_points:(_.key_points||"-").length>5?`${(_.key_points||"-").slice(0,5)}...`:_.key_points||"-"})]},`create-step-${_.step_no}`)}):l.length>0?l.sort((_,O)=>_.step_no-O.step_no).map(_=>{const O=(C==null?void 0:C.rowId)===_.id&&(C==null?void 0:C.col)==="desc",I=(C==null?void 0:C.rowId)===_.id&&(C==null?void 0:C.col)==="cause",M=(C==null?void 0:C.rowId)===_.id&&(C==null?void 0:C.col)==="points";return g.jsxs("tr",{children:[g.jsx("td",{className:"col-step-num",children:_.step_no}),g.jsx("td",{className:O?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(O?null:{rowId:_.id,col:"desc"}),children:O?_.cooking_description:(_.cooking_description||"-").length>5?`${(_.cooking_description||"-").slice(0,5)}...`:_.cooking_description||"-"}),g.jsx("td",{className:I?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(I?null:{rowId:_.id,col:"cause"}),children:I?_.cause:(_.cause||"-").length>5?`${(_.cause||"-").slice(0,5)}...`:_.cause||"-"}),g.jsx("td",{className:M?"cell-expanded":"cell-truncate",onDoubleClick:()=>$(M?null:{rowId:_.id,col:"points"}),children:M?_.key_points:(_.key_points||"-").length>5?`${(_.key_points||"-").slice(0,5)}...`:_.key_points||"-"})]},_.id)}):g.jsx("tr",{children:g.jsx("td",{colSpan:4,style:{textAlign:"center",color:"#999",padding:"20px"},children:"暂无步骤数据"})})})]})}),g.jsx("div",{className:"steps-footer",children:g.jsx("div",{className:"steps-summary",children:g.jsxs("span",{children:["共 ",(L.steps.length>0?L.steps:x.length>0?x:l).length," 道工序"]})})})]}),g.jsxs("div",{className:"ingredient-panel",children:[g.jsxs("div",{className:"panel-header",children:[g.jsxs("div",{children:[g.jsx("h3",{children:"原料成本明细"}),Me&&fe.length>0&&g.jsxs("div",{className:"query-info",style:{fontSize:"12px",color:"#666",marginTop:"4px"},children:[Me.store_id!==0&&g.jsxs("span",{children:["门店ID: ",Me.store_id]}),Me.store_id!==0&&Me.dish_id!==0&&g.jsx("span",{style:{marginLeft:"12px"},children:"|"}),Me.dish_id!==0&&g.jsxs("span",{style:{marginLeft:"12px"},children:["菜品ID: ",Me.dish_id]})]}),(f||y)&&g.jsxs("div",{className:"query-info",style:{fontSize:"12px",color:"#666",marginTop:"4px"},children:[f&&g.jsxs("span",{children:["菜品: ",f]}),f&&y&&g.jsx("span",{style:{marginLeft:"12px"},children:"|"}),y&&g.jsxs("span",{style:{marginLeft:"12px"},children:["门店: ",y]})]})]}),g.jsxs("span",{className:"ingredient-count",children:["共 ",(L.ingredients.length>0?L.ingredients:fe.length>0?fe:n).length," 种原料"]})]}),g.jsx("div",{className:"ingredient-table-container",children:g.jsxs("table",{className:"ingredient-table",children:[g.jsx("thead",{children:g.jsxs("tr",{children:[g.jsx("th",{className:"col-ingredient",children:"原料名称"}),g.jsx("th",{className:"col-amount",children:"用量"}),g.jsx("th",{className:"col-unit-price",children:"单价(元)"}),g.jsx("th",{className:"col-subtotal",children:"小计"})]})}),g.jsx("tbody",{children:fe.length>0?fe.map((_,O)=>g.jsxs("tr",{children:[g.jsx("td",{className:"col-ingredient",children:_.ing_name||"-"}),g.jsx("td",{className:"col-amount",children:_.ing_amount}),g.jsx("td",{className:"col-unit-price",children:_.ing_cost.toFixed(2)}),g.jsx("td",{className:"col-subtotal",children:_.ingredient_count.toFixed(2)})]},`batch-ing-${O}`)):L.ingredients.length>0?L.ingredients.map((_,O)=>g.jsxs("tr",{children:[g.jsx("td",{className:"col-ingredient",children:_.ing_name}),g.jsx("td",{className:"col-amount",children:_.ing_amount}),g.jsx("td",{className:"col-unit-price",children:_.ing_cost.toFixed(2)}),g.jsx("td",{className:"col-subtotal",children:_.ingredient_count.toFixed(2)})]},`create-ing-${O}`)):n.length>0?(()=>{const _=(P-1)*A,O=_+A;return n.slice(_,O).map((M,Q)=>g.jsxs("tr",{children:[g.jsxs("td",{className:"col-ingredient",children:[g.jsx("span",{className:"ingredient-type-badge",children:M.ing_type_name}),M.ing_name]}),g.jsx("td",{className:"col-amount",children:M.ing_amount}),g.jsx("td",{className:"col-unit-price",children:M.ing_cost.toFixed(2)}),g.jsx("td",{className:"col-subtotal",children:M.ingredient_count.toFixed(2)})]},M.id||_+Q))})():g.jsx("tr",{children:g.jsx("td",{colSpan:4,style:{textAlign:"center",color:"#999",padding:"20px"},children:"暂无原料数据"})})})]})}),g.jsxs("div",{className:"ingredient-footer",children:[L.ingredients.length===0&&fe.length===0&&n.length>0&&g.jsxs("div",{className:"ingredient-pagination",children:[g.jsx("button",{className:"page-btn",disabled:P<=1,onClick:()=>T(P-1),children:"上一页"}),g.jsxs("span",{className:"page-info",children:[Math.ceil(n.length/A)," 页 / ",P," 页"]}),g.jsx("button",{className:"page-btn",disabled:P>=Math.ceil(n.length/A),onClick:()=>T(P+1),children:"下一页"})]}),g.jsxs("div",{className:"cost-summary",children:[g.jsx("span",{className:"cost-label",children:"单价求和:"}),g.jsxs("span",{className:"cost-value",children:[(fe.length>0?fe.reduce((_,O)=>_+O.ing_cost,0):L.ingredients.length>0?L.ingredients.reduce((_,O)=>_+O.ing_cost,0):n.reduce((_,O)=>_+(O.ing_cost||0),0)).toFixed(2)," 元"]})]})]})]})]}),!e&&n.length===0&&l.length===0&&L.steps.length===0&&L.ingredients.length===0&&fe.length===0&&x.length===0&&!N&&!m&&g.jsxs("div",{className:"empty-store",children:[g.jsx("p",{children:"暂无数据"}),g.jsx("p",{className:"hint",children:"通过 postMessage 发送事件更新数据"})]}),g.jsxs("footer",{className:"render-footer",children:[L.scene&&g.jsxs("div",{className:"dish-scene",children:[g.jsx("span",{className:"scene-label",children:"推荐场景:"}),g.jsx("span",{className:"scene-value",children:L.scene})]}),g.jsxs("div",{className:"footer-right",children:[g.jsx("button",{className:"action-btn save",children:"💾 保存"}),g.jsx("button",{className:"action-btn stock",onClick:()=>Je(!0),children:"📦 入库"})]})]}),Dt&&g.jsx("div",{className:"modal-overlay",onClick:()=>!ht&&Je(!1),children:g.jsxs("div",{className:"modal-content",onClick:_=>_.stopPropagation(),children:[g.jsxs("div",{className:"modal-header",children:[g.jsx("h3",{children:"确认入库"}),!ht&&g.jsx("button",{className:"modal-close",onClick:()=>Je(!1),children:"×"})]}),g.jsxs("div",{className:"modal-body",children:[g.jsx("p",{children:"确定要将以下菜品信息入库吗?"}),g.jsxs("div",{className:"stock-summary",children:[g.jsxs("div",{className:"stock-item",children:[g.jsx("span",{className:"stock-label",children:"菜品名称:"}),g.jsx("span",{className:"stock-value",children:L.dish_name||"-"})]}),g.jsxs("div",{className:"stock-item",children:[g.jsx("span",{className:"stock-label",children:"菜系:"}),g.jsx("span",{className:"stock-value",children:L.cuisine||"-"})]}),g.jsxs("div",{className:"stock-item",children:[g.jsx("span",{className:"stock-label",children:"制作工序:"}),g.jsxs("span",{className:"stock-value",children:[L.steps.length," 道"]})]}),g.jsxs("div",{className:"stock-item",children:[g.jsx("span",{className:"stock-label",children:"原料种类:"}),g.jsxs("span",{className:"stock-value",children:[L.ingredients.length," 种"]})]})]})]}),g.jsxs("div",{className:"modal-footer",children:[g.jsx("button",{className:"btn btn-cancel",onClick:()=>Je(!1),disabled:ht,children:"取消"}),g.jsx("button",{className:"btn btn-confirm",onClick:ld,disabled:ht,children:ht?"入库中...":"确认入库"})]})]})})]},c)}function ag(){return g.jsx(ug,{})}Yo.createRoot(document.getElementById("root")).render(g.jsx(Sd.StrictMode,{children:g.jsx(ag,{})}));