@billgangcom/theme-lib 1.5.0 → 1.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- (function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode('@charset "UTF-8";@import"https://fonts.googleapis.com/css2?family=Archivo:ital,wght@0,100..900;1,100..900&display=swap";._icon_21b8w_1 path{fill:var(--icon-fill)}._hoverable_21b8w_5{cursor:pointer}._button_rcjso_1{background-color:#ff3f19;padding:10px 16px;color:#fff;border-radius:12px;cursor:pointer;font-size:16px}._button_rcjso_1:disabled{opacity:.7;cursor:auto}._wrapper_1y283_1{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%}._label_1y283_9{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._input_1y283_17{width:100%;background-color:var(--background-color);border-radius:12px;padding:7px 11px;font-size:16px;line-height:24px;border:1px solid var(--background-color)}._input_1y283_17::placeholder{color:#c2c2c2}._input_1y283_17:disabled{background-color:var(--background-color);opacity:.7}._required_1y283_36{border:1px solid #ff3f19}._paddingless_1y283_40{padding:0}._wrapper_dmzhr_1{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%}._label_dmzhr_9{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._select_dmzhr_17{width:100%;background-color:var(--background-color);border-radius:12px;padding:10px 12px;font-size:14px;line-height:20px;display:flex;align-items:center;justify-content:space-between;cursor:pointer}._icon_dmzhr_30{transition:.2s}._rotate_dmzhr_34{transform:rotate(180deg)}._content_dmzhr_38{position:relative}._options_dmzhr_42{position:absolute;top:45px;width:100%;background-color:var(--background-color);border-radius:12px;font-size:14px;line-height:20px;display:flex;flex-direction:column;max-height:200px;z-index:10;overflow-y:scroll;cursor:pointer}._option_dmzhr_42{padding:10px 12px;border-radius:12px}._option_dmzhr_42:hover{background-color:#e6e6e6}._wrapper_3w2ni_1{display:flex;width:fit-content;gap:8px;align-items:center;border-radius:12px;line-height:20px;color:#252525;font-size:14px;font-weight:400}._switch_3w2ni_13{width:40px;height:24px;background-color:#ccc;border-radius:25px;display:flex;align-items:center;padding:2px;cursor:pointer;transition:background-color .2s}._switch_3w2ni_13._active_3w2ni_24{background:#ff3f19}._switch_3w2ni_13 ._toggle_3w2ni_27{width:14px;height:14px;background-color:#fff;border-radius:16px;transition:transform .2s;transform:translate(2px)}._switch_3w2ni_13._active_3w2ni_24 ._toggle_3w2ni_27{transform:translate(18px)}._background_3w2ni_39{background-color:#f8f8f8}._padding_3w2ni_43{padding:8px}._wrapper_1inu5_1{border:var(--default-border);width:fit-content;height:fit-content;max-height:500px;max-width:500px;min-width:300px;padding:10px;left:10px;top:10px;position:absolute;z-index:1000;background-color:#fff;display:flex;border-radius:8px;justify-content:center;align-items:center;overflow:hidden}._blocks_1op3c_1{display:flex;align-items:center;gap:8px}._block_1op3c_1{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_1op3c_18{border:1px solid #ff3f19}._applyButton_1cqw4_2{flex:0 1 50%;font-weight:400}._cancelButton_1cqw4_7{background-color:#f8f8f8;color:var(--accent-color)}._content_1cqw4_12{display:flex;flex-direction:column;width:100%}._label_1cqw4_18{padding:8px 12px;border-radius:8px;display:flex;align-items:center;position:relative;gap:8px;width:100%;background-color:var(--background-color);cursor:pointer}._colorValue_1cqw4_30{width:20px;height:20px;padding:2.5px;border-radius:2px}._modal_1cqw4_37{left:15px;width:288px;overflow-y:auto;z-index:100000000;position:fixed;background-color:#fff;border-radius:12px;padding:10px;border:1px solid #e6e6e6;height:400px;display:flex;flex-direction:column;gap:10px;font-size:16px;line-height:24px;font-weight:700}._colorMap_1cqw4_56{position:relative;width:100%;height:300px;cursor:pointer;border-radius:4px}._indicator_1cqw4_64{position:absolute;width:20px;height:20px;border:4px solid white;border-radius:50%;pointer-events:none}._hueSlider_1cqw4_73{width:80%;left:30px;height:8px;position:absolute;bottom:80px;background:linear-gradient(to right,red,#ff0,#0f0,#0ff,#00f,#f0f,red,red);border-radius:5px}input[type=range]{-webkit-appearance:none;height:8px;outline:none;border-radius:5px;position:relative;display:flex;justify-content:center}input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;width:20px;height:20px;border:5px solid #fff;border-radius:50%;cursor:pointer}._slider_1cqw4_102{width:100%;cursor:pointer}._buttons_1cqw4_107{display:flex;gap:5px;width:100%}._name_1cqw4_113{line-height:20px;padding:0 4px 4px}._secondary_1cqw4_118{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._input_1cqw4_126{line-height:20px;font-size:14px;font-weight:400}._modal_1qb2a_1{position:fixed;top:0;left:0;right:0;bottom:0;background:#2525253d;z-index:100000;display:flex;padding:20px;justify-content:center;align-items:center;overflow:hidden}._wrapper_1qvfi_1{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%;position:relative}._label_1qvfi_10{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._textarea_1qvfi_18{width:100%;background-color:var(--background-color);border-radius:12px;padding:8px 12px;font-size:16px;line-height:24px;resize:none;min-height:80px}._textarea_1qvfi_18::placeholder{color:#c2c2c2}._length_1qvfi_33{position:absolute;bottom:12px;right:12px;color:#c2c2c2;line-height:20px}._wrapper_1fcne_2{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%}._label_1fcne_10{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._options_1fcne_18{display:flex;gap:20px}._radioLabel_1fcne_23{display:flex;align-items:center;cursor:pointer;position:relative}._radio_1fcne_23{position:absolute;opacity:0;cursor:pointer}._custom_1fcne_36{height:20px;width:20px;border-radius:50%;border:1px solid #e6e6e6;display:inline-block;margin-right:8px;position:relative}._radio_1fcne_23:checked+._custom_1fcne_36{border-color:#ff3f19;background:#ffeae5}._custom_1fcne_36:after{content:"";position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:8px;height:8px;border-radius:50%;background-color:#e53e3e;opacity:0}._radio_1fcne_23:checked+._custom_1fcne_36:after{opacity:1}._option_1fcne_18{font-size:16px;line-height:24px;font-weight:400}._tip_pl6k0_1{display:flex;align-items:center;padding:8px;border-radius:12px;gap:8px}._text_pl6k0_9{flex:1 1 auto;line-height:20px;font-size:14px}._warning_pl6k0_15{background:#faf8e6;color:#c1972a}._error_pl6k0_20{background:#ffc3b7;color:#ff3f19}._hide_pl6k0_25{display:none}._customCheckbox_1b69m_1{display:inline-block;cursor:pointer;position:relative}._checkboxBox_1b69m_7{display:inline-block;width:20px;height:20px;border:1px solid #e6e6e6;border-radius:6px;position:relative}._checkboxBox_1b69m_7._checked_1b69m_16{background:#ffeae5;border:1px solid #ff3f19}._icon_1b69m_21{position:absolute;top:3px;left:3px}._wrapper_arjxm_2{display:flex;flex-direction:column;gap:6px}._label_arjxm_8{color:#757575;font-weight:400;font-size:14px;line-height:20px}._icon_arjxm_15{padding:4px;background-color:#fff;border:1px solid #f0f0f0;display:flex;justify-content:center;align-items:center;border-radius:6px}._text_arjxm_25{font-weight:400;font-size:16px;line-height:24px;color:#ff3f19}._content_arjxm_32{display:flex;align-items:center;gap:6px;cursor:pointer;background-color:#f8f8f8;border-radius:12px;padding:6px 8px}._modal_arjxm_42{background-color:#f8f8f8;border:1px solid #f0f0f0;border-radius:16px;width:100%;max-width:640px}._top_arjxm_50{padding:16px 24px;display:flex;align-items:center;justify-content:space-between}._title_arjxm_57{color:#252525;font-weight:400;font-size:18px;line-height:24px}._modalContent_arjxm_64{padding:16px 24px;border-top-left-radius:16px;border-top-right-radius:16px;border-top:1px solid #f0f0f0;border-bottom:1px solid #f0f0f0;background-color:#fff}._images_arjxm_73{display:grid;grid-template-columns:repeat(3,1fr);align-items:center;gap:10px;overflow-y:scroll;max-height:390px}._add_arjxm_82{display:flex;flex-direction:column;gap:8px;padding:43px 16px;border:1px dashed #e6e6e6;justify-content:center;align-items:center;border-radius:16px;aspect-ratio:1/1}._description_arjxm_94{text-align:center;color:#252525;font-size:14px;line-height:20px}._description_arjxm_94 span:last-child{padding-top:4px}._bottom_arjxm_104{display:flex;justify-content:end;align-items:center;width:100%;background-color:#fff;border-bottom-left-radius:16px;border-bottom-right-radius:16px;padding:16px 24px 12px;gap:6px}._cancel_arjxm_116{background-color:var(--background-color);color:var(--accent-color)}._highlight_arjxm_121{color:#ff3f19;cursor:pointer}._accent_arjxm_126{color:var(--accent-color)}._image_arjxm_73{position:relative;padding:43px 16px;border:1px solid #e6e6e6;justify-content:center;align-items:center;border-radius:16px;aspect-ratio:1/1}._selected_arjxm_140{border:1px solid #ff3f19}._checkbox_arjxm_144{position:absolute;top:12px;left:12px}._loading_arjxm_150{position:relative;padding:43px 16px;border:1px solid #e6e6e6;background-color:#f8f8f8;justify-content:center;align-items:center;display:flex;border-radius:16px;aspect-ratio:1/1}._spinner_arjxm_162{width:24px;height:24px;border:2px solid #ff3f19;border-top-color:#f8f8f8;border-radius:50%;animation:_spin_arjxm_162 1s linear infinite}@keyframes _spin_arjxm_162{to{transform:rotate(360deg)}}._buttons_1gn8m_1{display:flex;align-items:center;gap:16px}._button_1gn8m_1{cursor:pointer;padding:10px}._devices_hxl12_1{display:flex;gap:4px;background:var(--background-color);padding:4px;border-radius:16px}._device_hxl12_1{padding:6px 8px;display:flex;align-items:center;justify-content:center;cursor:pointer;border-radius:12px;border:1px solid var(--background-color)}._device_hxl12_1:hover{border:var(--default-border);box-shadow:0 0 1px #dfdfdf}._active_hxl12_23{background-color:#fff}._active_hxl12_23:hover{border:1px solid var(--background-color);box-shadow:none}._header_wxpoz_1{position:absolute;top:0;left:0;width:100%;padding:11px 22px;line-height:20px;border-bottom:var(--default-border);display:flex;align-items:center;justify-content:space-between;gap:24px;z-index:50000}._left_wxpoz_16,._right_wxpoz_17{display:flex;align-items:center;gap:24px}._preview_vijvm_2{display:flex;align-items:center;gap:4px;color:var(--accent-color);line-height:20px;padding:10px 16px;cursor:pointer;border:1px solid #fff;border-radius:16px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}._preview_vijvm_2:hover{border:var(--default-border);box-shadow:0 0 1px #dfdfdf}._active_vijvm_22{background-color:var(--background-color)}._active_vijvm_22:hover{border:1px solid #fff;box-shadow:none}._settings_q79q3_1{display:flex;gap:20px;align-items:center;color:var(--accent-color)}._language_1mbvp_1{display:flex;align-items:center;gap:4px;background-color:var(--background-color);padding:10px 12px;border-radius:12px;cursor:pointer}._text_1mbvp_11{padding-right:4px;color:var(--main-color)}._pages_x8pw2_1{position:relative}._default_x8pw2_5{display:flex;align-items:center;gap:4px;padding:10px 12px;background-color:var(--background-color);border-radius:8px;cursor:pointer;position:relative}._text_x8pw2_16{padding-right:4px;color:var(--main-color);flex:1 1 auto}._modal_x8pw2_22{position:absolute;top:45px;width:320px;left:0;z-index:100;background-color:#fff;border:1px solid #e6e6e6;border-radius:8px;padding:8px 12px;display:flex;flex-direction:column}._page_x8pw2_1{display:flex;align-items:center;gap:8px;padding:12px 8px;border-radius:8px;cursor:pointer}._hoverable_x8pw2_45{background-color:var(--background-color)}._separator_x8pw2_49{border-bottom:1px solid #f0f0f0}._button_x8pw2_53{background:inherit;color:#ff3f19;display:flex;align-items:center;justify-content:start;gap:8px;padding:16px 8px 12px;transition:.2s}._button_x8pw2_53:hover{background-color:var(--background-color)}._zoom_a77cn_1{display:flex;align-items:center;gap:4px;background-color:var(--background-color);padding:10px 12px;border-radius:12px;cursor:pointer}._theme_3wxbf_1{display:flex;align-items:center;gap:4px;padding:9px 12px;background:#e5fadd;color:#338b13;border-radius:100px}._exit_2ce42_1{border-bottom:var(--default-border);display:flex;gap:8px;align-items:center;padding:22px;cursor:pointer}._text_2ce42_10{color:#252525;line-height:20px}._navbar_2ac63_1{width:100px;border-right:var(--default-border)}._main_2ac63_6{display:flex;flex-direction:column;gap:8px;padding:16px 12px}._block_2ac63_13{display:flex;align-items:center;flex-direction:column;gap:4px;color:var(--accent-color);line-height:20px;padding:12px 24px;cursor:pointer;border:1px solid #fff;border-radius:16px}._block_2ac63_13:hover{border:var(--default-border);box-shadow:0 0 1px #dfdfdf}._active_2ac63_30{background-color:var(--background-color);color:#252525}._active_2ac63_30:hover{border:1px solid #fff;box-shadow:none}._preview_jui5n_1{width:100%;background-color:var(--background-color);padding:16px 32px 0;position:relative;z-index:500}._main_jui5n_9{width:100%;display:flex;flex-direction:column;overflow-y:auto;height:100%;position:relative;z-index:1}._content_jui5n_19{background-color:#fff;border:var(--default-border);border-bottom:none;height:100%}._loading_jui5n_26{width:100%;height:100%;display:flex;justify-content:center;align-items:center}._loader_jui5n_34{border:4px solid rgba(0,0,0,.1);border-left-color:#fff;border-radius:50%;width:40px;height:40px;animation:_spin_jui5n_1 1s linear infinite}@keyframes _spin_jui5n_1{0%{transform:rotate(0)}to{transform:rotate(360deg)}}._header_1t64j_1{display:flex;width:100%;padding:18px;justify-content:center;border:var(--default-border);background-color:#fff;border-top-left-radius:16px;border-top-right-radius:16px;border-bottom:none;z-index:5}._circles_1t64j_14{left:28px;top:28px;position:absolute;display:flex;align-items:center;gap:8px}._circle_1t64j_14{width:12px;height:12px;border-radius:50%;border:.5px solid #e6e6e6}._red_1t64j_30{background:#ff5f57}._green_1t64j_34{background:#28c840}._yellow_1t64j_38{background:#febc2e}._input_1t64j_42{background-color:var(--background-color);padding:6px 8px;display:flex;max-width:480px;width:100%;border-radius:6px}._main_1t64j_51{flex:1 1 auto;display:flex;align-items:center;justify-content:center;gap:4px}._text_1t64j_59{font-weight:600;font-size:12px;line-height:16px;margin:0 0 0 4px}._content_92dk8_1{width:100%;height:100%}._block_92dk8_6{position:relative;cursor:pointer;border-left:1px solid #e6e6e6;border-right:1px solid #e6e6e6}._active_92dk8_13{border:2px solid #ff3f19}._name_92dk8_17{z-index:10;position:absolute;top:-28px;left:-2px;border-top-left-radius:8px;border-top-right-radius:8px;color:#fff;background:#ff3f19;padding:4px 12px;line-height:20px;text-align:center}._empty_92dk8_31{height:100%;width:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;text-align:center}._icon_92dk8_42{width:64px;height:64px;background-color:var(--background-color);display:flex;border-radius:50%;justify-content:center;align-items:center;margin:0 0 8px}._title_92dk8_53{font-weight:700;font-size:24px;line-height:32px}._text_92dk8_59{font-size:16px;line-height:24px;color:var(--accent-color)}._sections_92dk8_65{padding:0 20px;margin:20px 0 0;display:flex;flex-wrap:wrap;justify-content:center;gap:24px}._section_92dk8_65{cursor:pointer;display:flex;gap:10px;max-width:288px;width:100%;align-items:center;justify-content:space-between;padding:24px;background-color:var(--background-color);border-radius:24px;color:var(--accent-color)}._sidebar_1f3hk_1{position:absolute;display:flex;height:fit-content();flex-direction:column;right:10px;z-index:20;padding:10px;cursor:auto}._content_1f3hk_12{height:100%;border:1px solid #e6e6e6;border-radius:8px;background-color:#fff;padding:8px;max-width:60px;width:100%}._button_1f3hk_22{display:flex;align-items:center;border-radius:8px;padding:8px;transition:.2s background-color}._moveButton_1f3hk_30:hover{background-color:var(--background-color)}._border_1f3hk_34{border-bottom:var(--default-border)}._deleteButton_1f3hk_38:hover{background-color:#dd6363;color:#fff}._results_f488n_1{display:flex;flex-direction:column;padding:8px;gap:20px}._name_f488n_8{color:var(--main-color);font-weight:600;font-size:16px;line-height:24px}._product_f488n_15{display:flex;align-items:center;justify-content:space-between;cursor:pointer}._search_1s0qp_1{background:var(--background-color);padding:8px 12px;display:flex;align-items:center;border-radius:12px;width:100%;gap:10px;margin:8px 0}._input_1s0qp_12{width:100%;font-size:16px;line-height:24px;color:#252525}._input_1s0qp_12::placeholder{color:#c2c2c2}._sidebar_1r5sp_1{max-width:320px;width:100%;padding:16px;border-right:var(--default-border);height:100%;position:relative}._title_1r5sp_10{color:var(--main-color);font-weight:700;font-size:20px;line-height:24px;padding-bottom:8px}._active_1r5sp_18{display:flex;align-items:center;gap:8px}._layers_62wod_1{display:flex;flex-direction:column;position:relative;height:100%}._block_62wod_8{position:relative;display:flex;align-items:center;gap:4px;font-size:16px;line-height:24px;padding:8px 12px;border-radius:8px;cursor:pointer}._block_62wod_8:hover{background-color:var(--background-color)}._dragging_62wod_23{box-shadow:0 2.1px 4.36px #00000004;box-shadow:0 5.3px 10.22px #00000005;border:var(--default-border);box-shadow:0 10.81px 19.93px #00000006;cursor:grabbing}._active_62wod_31{background:#ffeae5}._add_62wod_35{z-index:2;position:absolute;display:flex;justify-content:center;align-items:center;bottom:0;left:0;border-bottom:2px solid #ff3f19;width:100%}._button_62wod_47{position:relative;display:flex;justify-content:center;align-items:center;top:12px;background-color:#ff3f19;width:24px;height:24px;border-radius:50%;padding:4px}._empty_62wod_60{display:flex;flex-direction:column;justify-content:center;height:100%;width:100%;align-items:center;text-align:center;gap:4px;color:var(--accent-color)}._title_62wod_72{font-size:16px;line-height:24px;font-weight:700;color:var(--accent-color)}._icon_62wod_79{margin:0 0 12px}._text_62wod_83{font-size:16px;font-weight:400;line-height:24px}._highlight_62wod_89{color:#ff3f19;cursor:pointer}._block_1d6lb_1{position:relative;display:flex;align-items:center;gap:4px;font-size:16px;line-height:24px;padding:8px 12px;border-radius:8px;cursor:pointer}._block_1d6lb_1:hover{background-color:var(--background-color)}._theme_1xj36_1{display:flex;flex-direction:column}._block_1xj36_6{justify-content:start;display:flex;align-items:center;gap:8px;width:100%;padding:16px 8px;cursor:pointer;border-radius:8px}._block_1xj36_6:hover{background-color:var(--background-color)}._name_1xj36_20{flex:1 1 auto}._back_14yda_1{display:flex;align-items:center;gap:8px;padding-bottom:8px}._render_14yda_8{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:501}._open_14yda_23{animation:.2s _open_14yda_23 forwards}@keyframes _open_14yda_23{0%{transform:translate(320px);z-index:1}99%{z-index:1}to{z-index:5000;transform:translate(0)}}@keyframes _close_14yda_50{0%{z-index:1;transform:translate(0)}to{z-index:1;transform:translate(320px)}}._close_14yda_50{animation:.2s _close_14yda_50 forwards}._clicked_14yda_54{opacity:0}._title_14yda_58{color:var(--main-color);font-weight:700;font-size:20px;line-height:24px}._button_14yda_65{align-self:center;flex:1}._loading_14yda_70{flex:1 1 auto}._settings_14yda_74{flex:1 1 auto;overflow-y:scroll;overflow-x:hidden}._buttons_14yda_80{justify-content:space-between;display:flex;gap:10px}._deleteButton_14yda_86{display:flex;align-items:center;border-radius:8px;padding:8px;transition:.2s background-color}._deleteButton_14yda_86:hover{background-color:#dd6363;color:#fff}._settings_1r85j_1{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:3}._open_1r85j_16{transform:translate(0)}._close_1r85j_20{transform:translate(320px)}._header_1r85j_24{display:flex;align-items:center;gap:8px}._title_1r85j_30{font-weight:700;font-size:20px;line-height:24px;flex:1 1 auto}._addButton_1r85j_37{color:#ff3f19;display:flex;align-items:center;gap:4px;cursor:pointer}._wrapper_n1a7x_1{overflow-y:scroll}._category_n1a7x_5{display:flex;flex-direction:column}._categoryTitle_n1a7x_10{font-weight:600;font-size:16px;line-height:24px}._color_n1a7x_16{display:flex;flex-direction:column}._color_n1a7x_16:not(:last-child){border-bottom:1px solid #f0f0f0}._content_n1a7x_24{padding:12px 0;gap:8px;display:flex;align-items:center;flex:1 1 auto}._preview_n1a7x_32{width:39px;height:39px;flex:0 0 39px;padding:5px;border-radius:50%;border:1px solid #e6e6e6}._wrapper_kb55x_2{overflow-y:scroll}._category_kb55x_6{display:flex;flex-direction:column}._categoryTitle_kb55x_11{font-weight:600;font-size:16px;line-height:24px}._color_kb55x_17{gap:8px;display:flex;flex-direction:column}._name_kb55x_23{line-height:20px;padding:0 4px 4px}._content_kb55x_28{display:flex;flex-direction:column;width:100%}._label_kb55x_34{padding:8px 12px;border-radius:12px;display:flex;align-items:center;gap:5px;width:100%;background-color:var(--background-color);cursor:pointer}._input_kb55x_45[type=color]{width:20px;height:20px;padding:1px}._input_kb55x_45{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;height:100%;border:none;padding:0;cursor:pointer;border-radius:50%}._input_kb55x_45::-webkit-color-swatch{border-radius:50%;border:none}._input_kb55x_45::-webkit-color-swatch-wrapper{padding:0;border-radius:50%}._title_kb55x_71{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._field_kb55x_79{display:flex;flex-direction:column;gap:10px;padding:16px 0}._field_kb55x_79:not(:last-child){border-bottom:1px solid #f0f0f0}._alignments_kb55x_89{display:flex;flex-direction:column;gap:10px}._lineField_kb55x_95{display:flex;justify-content:space-between;align-items:center}._style_kb55x_101{flex:1 0 50%;display:flex;flex-direction:column;gap:8px}._header_kb55x_108{display:flex;align-items:center;justify-content:space-between}._wrapper_k9on2_1{overflow-y:scroll}._category_k9on2_5{display:flex;flex-direction:column}._categoryTitle_k9on2_10{font-weight:600;font-size:16px;line-height:24px}._font_k9on2_16{padding:12px 0;gap:8px;display:flex;align-items:center;position:relative;flex:1 1 auto;cursor:pointer}._font_k9on2_16:hover{background-color:#f8f8f8;border-radius:8px}._font_k9on2_16:not(:last-child){border-bottom:var(--default-border)}._font_k9on2_16:not(:last-child):hover{border-bottom:1px solid #f8f8f8}._content_k9on2_36{display:flex;flex-direction:column;width:100%}._icon_k9on2_42{padding:8px;border-radius:8px;background-color:#f8f8f8;display:flex;align-items:center;justify-content:center}._paragraph_k9on2_51{padding:12px}._deleteIcon_k9on2_55{position:absolute;right:10px;width:20px;height:20px}._iconButton_k9on2_62{width:32px;height:32px}._wrapper_94fpv_1{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:5}._open_94fpv_16{transform:translate(0)}._close_94fpv_20{transform:translate(320px)}._header_94fpv_24{display:flex;align-items:center;gap:8px;margin:0 0 10px}._title_94fpv_31{font-weight:700;font-size:20px;line-height:24px}._options_94fpv_37{display:flex;flex-direction:column;gap:10px;flex:1 1 auto}._clicked_94fpv_44{opacity:0}._wrapper_1j33r_1{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:5}._open_1j33r_16{transform:translate(0)}._close_1j33r_20{transform:translate(320px)}._header_1j33r_24{display:flex;align-items:center;gap:8px;margin:0 0 10px}._title_1j33r_31{font-weight:700;font-size:20px;line-height:24px}._options_1j33r_37{display:flex;flex-direction:column;gap:10px;flex:1 1 auto}._clicked_1j33r_44{opacity:0}._label_1j33r_48{font-size:14px;font-weight:400;line-height:20px;color:var(--accent-color)}._alignments_1j33r_55{display:flex;flex-direction:column;gap:10px}._blocks_1j33r_61{display:flex;align-items:center;gap:8px}._alignment_1j33r_55{padding:8px;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_1j33r_75{border:1px solid #ff3f19}._wrapper_jjfwh_1{display:flex;flex-direction:column;gap:20px;background:#fff;max-width:640px;width:100%;padding:16px 24px;border-radius:16px}._header_jjfwh_12{display:flex;justify-content:space-between;align-items:center;font-size:24px;font-weight:700;line-height:32px}._content_jjfwh_21{display:flex;flex-direction:column;gap:10px;overflow-y:scroll;max-height:500px}._buttons_jjfwh_29{display:flex;justify-content:end;gap:12px}._cancel_jjfwh_35{background-color:var(--background-color);color:var(--accent-color)}._label_jjfwh_40,._description_jjfwh_41{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._preview_jjfwh_49{display:flex;flex-direction:column;gap:10px}._block_jjfwh_55{padding:24px;display:flex;flex-direction:column;border:1px solid var(--background-color);border-radius:8px}._slug_jjfwh_63{line-height:20px;color:#ff3f19;margin-bottom:4px}._title_jjfwh_69{font-weight:600;font-size:16px;line-height:24px}._layout_kjedu_1{width:100%;height:100%;display:flex;position:relative}._main_kjedu_8{display:flex;flex-direction:column;width:100%;position:relative}._content_kjedu_15{position:relative;padding-top:64px;height:100%;display:flex}*{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Noto Sans,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"}*{padding:0;margin:0;border:0}*,*:before,*:after{box-sizing:border-box}:focus,:active{outline:none}a:focus,a:active{outline:none}nav,footer,header,aside{display:block}html,body{width:100%;line-height:1;font-size:16px;-ms-text-size-adjust:100%;-moz-text-size-adjust:100%;-webkit-text-size-adjust:100%}input,button,textarea{font-family:inherit}input::-ms-clear{display:none}button{background-color:transparent;cursor:pointer}button::-moz-focus-inner{padding:0;border:0}a,a:visited,a:hover{text-decoration:none}ul li{list-style:none}img{vertical-align:top}h1,h2,h3,h4,h5,h6,a{font-size:inherit}a{color:inherit}*{-webkit-tap-highlight-color:transparent}input{border:none;background:none;outline:none;padding:0}input[type=color]{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:40px;height:40px;border:none;background:transparent}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}*{-ms-overflow-style:none;scrollbar-width:none}* ::-webkit-scrollbar{display:none}:root{--default-border: 1px solid #f0f0f0;--accent-color: #757575;--main-color: #252525;--background-color: #f8f8f8}#root{height:100vh}body,html{background-color:#fff;font-family:Archivo,sans-serif;max-height:100vh;overflow:hidden}._wrapper_o1bnv_2{display:flex;flex-direction:column;gap:10px}._alignmentBlock_o1bnv_8{padding:10px 0 16px;display:flex;flex-direction:column;gap:6px;border-bottom:1px solid #f0f0f0}._title_o1bnv_16{font-weight:700;line-height:24px;font-size:16px;color:#252525}._subtitle_o1bnv_23{color:#757575;font-size:14px;line-height:20px;font-weight:400}._alignmentContent_o1bnv_30{display:flex;justify-content:space-between;align-items:stretch;gap:8px}._alignments_o1bnv_37{border-radius:12px;background:#f8f8f8;display:grid;gap:4px;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(3,1fr);flex:0 0 50%}._alignment_o1bnv_8{cursor:pointer;display:flex;height:100%;width:100%;align-items:center;justify-content:center}._circle_o1bnv_56{width:6px;height:6px;border-radius:50%;background-color:#c2c2c2}._paddings_o1bnv_63{border-radius:12px;display:grid;gap:4px;grid-template-columns:repeat(2,1fr);grid-template-rows:repeat(2,1fr)}._padding_o1bnv_63{width:68px;display:flex;align-items:center;gap:4px;background:#f8f8f8;border-radius:12px;padding:10px 8px}._input_o1bnv_81{width:100%}._subtitle_2zbxx_1{color:#757575;font-size:14px;line-height:20px;font-weight:400}._header_2zbxx_8,._text_2zbxx_9{padding:10px 0 16px;display:flex;flex-direction:column;border-bottom:1px solid #f0f0f0}._top_2zbxx_16{display:flex;justify-content:space-between;align-items:center;margin:0 0 8px}._itemsBlock_2zbxx_23{display:flex;flex-direction:column;gap:6px}._typeTexts_3zlec_1{display:flex;align-items:center;gap:8px}._block_3zlec_7{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_3zlec_18{border:1px solid #ff3f19}._subtitle_2l7ty_1{color:#757575;font-size:14px;line-height:20px;font-weight:400}._header_2l7ty_8,._text_2l7ty_9,._productsBlock_2l7ty_10{padding:10px 0 16px;display:flex;flex-direction:column;border-bottom:1px solid #f0f0f0;width:100%}._productsBlock_2l7ty_10{position:relative}._top_2l7ty_22{display:flex;justify-content:space-between;align-items:center;margin:0 0 8px}._itemsBlock_2l7ty_29{display:flex;flex-direction:column;gap:6px}._typeTexts_2l7ty_35{display:flex;align-items:center;gap:8px}._block_2l7ty_41{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_2l7ty_52{border:1px solid #ff3f19}._products_2l7ty_10{width:100%;display:flex;flex-direction:column;gap:8px}._product_2l7ty_10{display:flex;align-items:center;gap:8px;width:100%}._button_2l7ty_70{background:inherit;color:#ff3f19;display:flex;align-items:center;justify-content:center;gap:6px;width:100%}._image_2l7ty_80{border-radius:8px;border:1px solid #f0f0f0;background-color:#fff;padding:4px}._info_2l7ty_87{border-radius:12px;display:flex;gap:4px;justify-content:space-between;align-items:center;flex:1 1 auto;background-color:#f8f8f8;padding:8px 12px}._name_2l7ty_98{flex:1 1 100%}._buttons_2l7ty_102{display:flex;align-items:center;gap:8px}._modal_2l7ty_108{position:fixed;background-color:#fff;right:-300px;top:0;z-index:10000;max-width:276px;width:100%;padding:16px;border-radius:12px}._modal_2l7ty_108 ._top_2l7ty_22{display:flex;align-items:center;justify-content:space-between}._other_2l7ty_125{display:flex;flex-direction:column;gap:6px}._subtitle_1y5sw_1{color:#757575;font-size:14px;line-height:20px;font-weight:400}._header_1y5sw_8,._text_1y5sw_9,._productsBlock_1y5sw_10,._buttonsBlock_1y5sw_11{padding:10px 0 16px;display:flex;flex-direction:column;border-bottom:1px solid #f0f0f0}._buttonsBlock_1y5sw_11{position:relative}._top_1y5sw_22{display:flex;justify-content:space-between;align-items:center;margin:0 0 8px}._itemsBlock_1y5sw_29{display:flex;flex-direction:column;gap:6px}._typeTexts_1y5sw_35{display:flex;align-items:center;gap:8px}._block_1y5sw_41{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_1y5sw_52{border:1px solid #ff3f19}._products_1y5sw_10{width:100%;display:flex;flex-direction:column;gap:8px}._product_1y5sw_10{display:flex;align-items:center;gap:8px;width:100%}._button_1y5sw_11{background:inherit;color:#ff3f19;display:flex;align-items:center;justify-content:center;gap:6px;width:100%}._image_1y5sw_80{border-radius:8px;border:1px solid #f0f0f0;background-color:#fff;padding:4px}._info_1y5sw_87{border-radius:12px;display:flex;gap:4px;justify-content:space-between;align-items:center;flex:1 1 auto;background-color:#f8f8f8;padding:8px 12px}._name_1y5sw_98{flex:1 1 100%}._buttons_1y5sw_11{display:flex;align-items:center;gap:8px}._modal_1y5sw_108{position:fixed;background-color:#fff;right:-300px;z-index:10000;max-width:276px;width:100%;bottom:20px;padding:16px;border-radius:12px}._modal_1y5sw_108 ._top_1y5sw_22{display:flex;align-items:center;justify-content:space-between}._other_1y5sw_125{display:flex;flex-direction:column;gap:6px}._options_1y5sw_131{display:flex;flex-direction:column;gap:15px}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-BO6B5tl0.cjs"),m=require("react"),wt=["desktop","tablet","mobile"],Dt=[{icon:"paint",name:"Colors"},{icon:"font",name:"Fonts"},{icon:"corners-out",name:"Borders"},{icon:"arrow-square",name:"Buttons"},{icon:"textbox",name:"Inputs"}],Rt="https://g-api.billgang.com",Ct="https://www.googleapis.com/webfonts/v1/webfonts",Ot="_buttons_1gn8m_1",It="_button_1gn8m_1",Tt={buttons:Ot,button:It},Nt=()=>r.jsxRuntimeExports.jsxs("div",{className:Tt.buttons,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"undo",hoverable:!0,width:20,height:20}),r.jsxRuntimeExports.jsx(r.Icon,{name:"redo",hoverable:!0,width:20,height:20})]}),kt="_devices_hxl12_1",Pt="_device_hxl12_1",$t="_active_hxl12_23",xe={devices:kt,device:Pt,active:$t},Mt=()=>{const{currentDevice:t,setCurrentDevice:e}=r.useDeviceStore();return r.jsxRuntimeExports.jsx("div",{className:xe.devices,children:wt.map(n=>r.jsxRuntimeExports.jsx("div",{className:r.clx(xe.device,{[xe.active]:t===n}),onClick:()=>e(n),children:r.jsxRuntimeExports.jsx(r.Icon,{name:n,fill:t===n?"#252525":"#757575",width:20,height:20})},n))})},At="_header_wxpoz_1",Bt="_left_wxpoz_16",Lt="_right_wxpoz_17",oe={header:At,left:Bt,right:Lt},Ht="_preview_vijvm_2",Ft="_active_vijvm_22",ve={preview:Ht,active:Ft},Ut=()=>{const{onPreview:t,setOnPreview:e}=r.usePreviewStore();return r.jsxRuntimeExports.jsxs("div",{className:r.clx(ve.preview,{[ve.active]:t}),onClick:()=>e(!t),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-up-right",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:ve.text,children:"Preview"})]})},qt="_settings_q79q3_1",zt={settings:qt},Vt="_language_1mbvp_1",Yt="_text_1mbvp_11",Be={language:Vt,text:Yt},Gt=()=>r.jsxRuntimeExports.jsxs("div",{className:Be.language,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"globe",fill:"#252525",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:Be.text,children:"Default"}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-down",width:20,height:20})]}),Xt="_pages_x8pw2_1",Wt="_text_x8pw2_16",Qt="_modal_x8pw2_22",Zt="_page_x8pw2_1",Jt="_hoverable_x8pw2_45",Kt="_separator_x8pw2_49",en="_button_x8pw2_53",F={pages:Xt,default:"_default_x8pw2_5",text:Wt,modal:Qt,page:Zt,hoverable:Jt,separator:Kt,button:en},$=t=>t?t.replace(/_/g," ").split(" ").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" and "):"",tn=()=>{const{currentPage:t,setCurrentPage:e,setIsOpenModal:n,pages:s,setIsEdit:o,setEditedPage:i,deletePage:a,isOpenSelectModal:c,setIsOpenSelectModal:u}=r.usePagesStore(),{deletePage:h}=r.useLayersStore(),[f,l]=m.useState("");return m.useEffect(()=>{const p=()=>{u(!1)};return document.body.addEventListener("click",p),()=>{document.body.removeEventListener("click",p)}},[]),r.jsxRuntimeExports.jsxs("div",{className:F.pages,children:[r.jsxRuntimeExports.jsxs("div",{className:F.default,onClick:p=>{p.stopPropagation(),u(!c)},children:[r.jsxRuntimeExports.jsx(r.Icon,{name:s[t].icon,fill:"#252525",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:F.text,children:r.defaultPageNames.includes(s[t].name)?`${$(s[t].name)} page`:s[t].name}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-down",width:20,height:20})]}),c&&r.jsxRuntimeExports.jsxs("div",{className:F.modal,onClick:p=>p.stopPropagation(),children:[Object.keys(s).map(p=>{const d=s[p];return r.jsxRuntimeExports.jsxs("div",{className:r.clx(F.page,{[F.hoverable]:f===p}),onMouseEnter:()=>l(p),onMouseLeave:()=>l(""),onClick:()=>{l(""),o(!1),e(p),u(!1)},children:[r.jsxRuntimeExports.jsx(r.Icon,{name:d.icon,fill:"#252525"}),r.jsxRuntimeExports.jsx("span",{className:F.text,children:r.defaultPageNames.includes(d.name)?`${$(d.name)} page`:d.name}),f===p&&r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"settings",fill:"#757575",onClick:x=>{x.stopPropagation(),o(!0),i(p),n(!0)}}),!r.defaultPageNames.includes(d.name)&&r.jsxRuntimeExports.jsx(r.Icon,{name:"trash",fill:"#C12A2A",onClick:x=>{s[t].name===d.name&&e("home"),x.stopPropagation(),a(p),h(d.name)}})]}),s[t].name===d.name&&r.jsxRuntimeExports.jsx(r.Icon,{name:"check",fill:"#FF3F19"})]},p)}),r.jsxRuntimeExports.jsx("div",{className:F.separator}),r.jsxRuntimeExports.jsxs(r.Button,{className:F.button,onClick:p=>{p.stopPropagation(),n(!0)},size:"l",children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"plus",fill:"#ff3f19"}),r.jsxRuntimeExports.jsx("span",{children:"Create Page Blank"})]})]})]})},nn="_zoom_a77cn_1",rn={zoom:nn},sn=()=>{const[t,e]=m.useState(),n=()=>{e(Number(Math.round(window.devicePixelRatio*50).toFixed(0)))};return m.useEffect(()=>(n(),window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}),[]),r.jsxRuntimeExports.jsxs("div",{className:rn.zoom,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"zoom-minus",width:20,height:20}),r.jsxRuntimeExports.jsxs("span",{children:[t," %"]})]})},on=()=>r.jsxRuntimeExports.jsxs("div",{className:zt.settings,children:[r.jsxRuntimeExports.jsx(Gt,{}),r.jsxRuntimeExports.jsx(tn,{}),r.jsxRuntimeExports.jsx(sn,{})]}),an="_theme_3wxbf_1",cn={theme:an},un=()=>r.jsxRuntimeExports.jsxs("div",{className:cn.theme,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"check",width:18,height:18}),r.jsxRuntimeExports.jsx("div",{children:"Current Theme"})]}),ln=()=>{const{themeSettings:t}=r.useThemeSettingsStore(),{settings:e}=r.useSettingsStore(),[n,s]=m.useState(null),[o,i]=m.useState(!1),{pages:a}=r.usePagesStore(),{blocks:c}=r.useLayersStore();function u(d,x){return x.map(v=>Object.values(v.value).filter(_=>_.type===d).map(_=>_.value).flat()).flat()}function h(d,x){return u(d,x).some(v=>v)}function f(d,x){const g=u(d,x);return Array.isArray(g)&&g.length>0?Math.max(...g):0}function l(d){const x=Object.keys(a).find(g=>a[g].name===d);return x?a[x]:null}const p=()=>{if(o)n&&clearTimeout(n);else{const x=Object.keys(c).map(g=>{const v=l(g);return{name:v?v.name:g,path:g==="home"?"/":(v==null?void 0:v.path)||g,layout:{...c[g]},neededProductIds:[...u("ProductId",Object.values(c[g]))],neededCategoryIds:[...u("CategoryId",Object.values(c[g]))],neededAnnouncementIds:[...u("AnnouncementId",Object.values(c[g]))],neededListingIds:[...u("ListingId",Object.values(c[g]))],neededFaqs:h("Faqs",Object.values(c[g])),neededReviewCount:f("ReviewCount",Object.values(c[g])),seo:{pageTitle:v?v.seo.title:"",pageDescription:v?v.seo.description:""}}});r.updateSettings("POST","save",{themeSettings:t,settings:e,updatedPages:x})}i(!0);const d=setTimeout(()=>{i(!1)},2e3);s(d)};return r.jsxRuntimeExports.jsxs("div",{className:oe.header,children:[r.jsxRuntimeExports.jsxs("div",{className:oe.left,children:[r.jsxRuntimeExports.jsx(Mt,{}),r.jsxRuntimeExports.jsx(Ut,{})]}),r.jsxRuntimeExports.jsx("div",{className:oe.center,children:r.jsxRuntimeExports.jsx(on,{})}),r.jsxRuntimeExports.jsxs("div",{className:oe.right,children:[r.jsxRuntimeExports.jsx(un,{}),r.jsxRuntimeExports.jsx(Nt,{}),r.jsxRuntimeExports.jsx(r.Button,{onClick:p,children:"Save"})]})]})},dn="_exit_2ce42_1",gn="_text_2ce42_10",Le={exit:dn,text:gn},pn=()=>r.jsxRuntimeExports.jsxs("div",{className:Le.exit,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"sign-out",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:Le.text,children:"Exit"})]}),hn="_navbar_2ac63_1",fn="_main_2ac63_6",mn="_block_2ac63_13",xn="_active_2ac63_30",ie={navbar:hn,main:fn,block:mn,active:xn},vn=()=>{const{activeBlock:t,setActiveBlock:e}=r.useNavbarStore(),{setActiveBlock:n}=r.useBlocksStore(),{setCurrentBlock:s}=r.useLayersStore(),{setActiveBlock:o}=r.useThemeSettingsStore();function i(a){n(null),e(a),s(null),o(null)}return r.jsxRuntimeExports.jsxs("div",{className:ie.navbar,children:[r.jsxRuntimeExports.jsx(pn,{}),r.jsxRuntimeExports.jsx("div",{className:ie.main,children:r.navbarBlocks.map(a=>r.jsxRuntimeExports.jsxs("div",{className:r.clx(ie.block,{[ie.active]:t.icon===a.icon}),onClick:()=>i(a),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:a.icon,fill:t.icon===a.icon?"#252525":"#757575"}),r.jsxRuntimeExports.jsx("span",{children:a.name})]},a.icon))})]})},jn="_preview_jui5n_1",En="_main_jui5n_9",_n="_content_jui5n_19",bn="_loading_jui5n_26",Sn="_loader_jui5n_34",yn="_spin_jui5n_1",ee={preview:jn,main:En,content:_n,loading:bn,loader:Sn,spin:yn},wn="_header_1t64j_1",Dn="_circles_1t64j_14",Rn="_circle_1t64j_14",Cn="_red_1t64j_30",On="_green_1t64j_34",In="_yellow_1t64j_38",Tn="_input_1t64j_42",Nn="_main_1t64j_51",kn="_text_1t64j_59",U={header:wn,circles:Dn,circle:Rn,red:Cn,green:On,yellow:In,input:Tn,main:Nn,text:kn},Pn="data:image/svg+xml,%3csvg%20width='17'%20height='16'%20viewBox='0%200%2017%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3crect%20x='0.5'%20width='16'%20height='16'%20fill='url(%23pattern0_4042_718)'/%3e%3cdefs%3e%3cpattern%20id='pattern0_4042_718'%20patternContentUnits='objectBoundingBox'%20width='1'%20height='1'%3e%3cuse%20xlink:href='%23image0_4042_718'%20transform='scale(0.015625)'/%3e%3c/pattern%3e%3cimage%20id='image0_4042_718'%20width='64'%20height='64'%20xlink:href='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAONJREFUeF7t20EOhEAIRFG4/6F7DvEnYeFzryQIv6pBd2behOu9dPvsbog+k+NLgArQAqmJcw9iAAhSgZKB3IJkkAySQTJ4CiE+gA8oBeg0mH3Ai084P89HhqwEqIA209ICsQdjAeaZIgaAYKxBDMCAYy8fXwAIgiAIcoJpJEYGI4VjB3YrbC9gL2AvkCB43cM5PgZgAAZgQFnNZAhdGykQBEEQBEEQDBmgAm2glM/z+QUYisYUGoldO7kY32IEAzCg6RgIRgjFAsw+AgRBMNYgBmCAT2TCYfoPPz/HCqQCX1eBHzHnv7C7WhBSAAAAAElFTkSuQmCC'/%3e%3c/defs%3e%3c/svg%3e",$n=["red","yellow","green"],Mn=()=>r.jsxRuntimeExports.jsxs("div",{className:U.header,children:[r.jsxRuntimeExports.jsx("div",{className:U.circles,children:$n.map(t=>r.jsxRuntimeExports.jsx("div",{className:r.clx(U.circle,{[U.red]:t==="red",[U.yellow]:t==="yellow",[U.green]:t==="green"})},t))}),r.jsxRuntimeExports.jsxs("div",{className:U.input,children:[r.jsxRuntimeExports.jsxs("div",{className:U.main,children:[r.jsxRuntimeExports.jsx("img",{src:Pn,alt:""}),r.jsxRuntimeExports.jsx("span",{className:U.text,children:"lorem.ipsum"}),r.jsxRuntimeExports.jsx(r.Icon,{name:"lock",fill:"#757575",width:15,height:16})]}),r.jsxRuntimeExports.jsx(r.Icon,{name:"copy",width:20,height:20})]})]}),An="_content_92dk8_1",Bn="_block_92dk8_6",Ln="_active_92dk8_13",Hn="_name_92dk8_17",Fn="_empty_92dk8_31",Un="_icon_92dk8_42",qn="_title_92dk8_53",zn="_text_92dk8_59",Vn="_sections_92dk8_65",Yn="_section_92dk8_65",ae={content:An,block:Bn,active:Ln,name:Hn,empty:Fn,icon:Un,title:qn,text:zn,sections:Vn,section:Yn},Gn="_sidebar_1f3hk_1",Xn="_content_1f3hk_12",Wn="_button_1f3hk_22",Qn="_moveButton_1f3hk_30",Zn="_border_1f3hk_34",Jn="_deleteButton_1f3hk_38",I={sidebar:Gn,content:Xn,button:Wn,moveButton:Qn,border:Zn,deleteButton:Jn},Kn=()=>{const{activeBlock:t}=r.usePreviewStore(),{blocks:e,removeBlock:n,moveBlock:s,duplicateBlock:o}=r.useLayersStore(),{currentPage:i,pages:a}=r.usePagesStore(),c=Object.keys(e[a[i].name]),u=c.indexOf(t),h=()=>{u>0&&s(a[i].name,u,u-1)},f=()=>{u<c.length-1&&s(a[i].name,u,u+1)},l=()=>{o(a[i].name,t)};return r.jsxRuntimeExports.jsx("div",{className:I.sidebar,children:r.jsxRuntimeExports.jsxs("div",{className:I.content,children:[r.jsxRuntimeExports.jsx("button",{onClick:h,className:r.clx(I.button,I.moveButton),disabled:u===0,children:r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-preview-up"})}),r.jsxRuntimeExports.jsx("button",{onClick:f,className:r.clx(I.button,I.moveButton),disabled:u===c.length-1,children:r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-preview-down"})}),r.jsxRuntimeExports.jsx("div",{className:I.border}),r.jsxRuntimeExports.jsx("button",{onClick:l,className:r.clx(I.button,I.moveButton),children:r.jsxRuntimeExports.jsx(r.Icon,{name:"copy"})}),r.jsxRuntimeExports.jsx("div",{className:I.border}),r.jsxRuntimeExports.jsx("button",{onClick:()=>n(a[i].name,t),className:r.clx(I.button,I.deleteButton),children:r.jsxRuntimeExports.jsx(r.Icon,{name:"trash",hoverable:!0})})]})})},nt=({render:t,block:e})=>t(e),er=()=>{const{footer:t}=r.useLayersStore(),{settings:e}=r.useSettingsStore(),{pageContext:n}=r.usePagesStore();return t==null?void 0:t.renderBlock(e,n)},tr=()=>{const{header:t}=r.useLayersStore(),{settings:e}=r.useSettingsStore(),{pageContext:n}=r.usePagesStore();return t==null?void 0:t.renderBlock(e,n)},nr=m.memo(()=>{const{setActiveBlock:t,activeBlock:e}=r.usePreviewStore(),{blocks:n}=r.useBlocksStore(),{blocks:s}=r.useLayersStore(),{settings:o}=r.useSettingsStore(),{currentPage:i,pages:a,setIsOpenSelectModal:c}=r.usePagesStore(),u=l=>{const p=n[l.name],d=l.value;for(const x in d)p[x]=d[x];return p.renderBlock(o)},h=m.useRef(e);m.useEffect(()=>{h.current=e},[e]),m.useEffect(()=>{const l=()=>{h.current&&t(null)};return document.body.addEventListener("click",l),()=>{document.body.removeEventListener("click",l)}},[]);const f=m.useCallback(l=>u(l),[s]);return r.jsxRuntimeExports.jsxs("div",{onClick:l=>{l.stopPropagation(),c(!1)},className:ae.content,children:[r.jsxRuntimeExports.jsx(tr,{}),s[a[i].name]&&Object.keys(s[a[i].name]).map(l=>r.jsxRuntimeExports.jsxs("div",{onClick:()=>t(l),className:r.clx(ae.block,{[ae.active]:e===l}),children:[e===l&&r.jsxRuntimeExports.jsx("div",{className:ae.name,children:s[a[i].name][l].name}),e===l&&r.jsxRuntimeExports.jsx(Kn,{}),r.jsxRuntimeExports.jsx(nt,{render:f,block:s[a[i].name][l]})]})),r.jsxRuntimeExports.jsx(er,{})]})}),rr="_results_f488n_1",sr="_name_f488n_8",or="_product_f488n_15",ce={results:rr,name:sr,product:or},ir="_search_1s0qp_1",ar="_input_1s0qp_12",He={search:ir,input:ar},cr=()=>r.jsxRuntimeExports.jsxs("label",{className:He.search,children:[r.jsxRuntimeExports.jsx("input",{type:"text",placeholder:"Search for sections",className:He.input}),r.jsxRuntimeExports.jsx(r.Icon,{name:"search",fill:"#757575"})]}),rt=()=>{const{blocks:t,setActiveBlock:e}=r.useBlocksStore(),{hideModal:n}=r.useSubmodalStore();function s(o){e(o),n()}return r.jsxRuntimeExports.jsxs("div",{className:ce.add,children:[r.jsxRuntimeExports.jsx(cr,{}),r.jsxRuntimeExports.jsx("div",{className:ce.results,children:Object.keys(t).map(o=>r.jsxRuntimeExports.jsxs("div",{className:ce.product,onClick:()=>s(o),children:[r.jsxRuntimeExports.jsx("span",{className:ce.name,children:o}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-right"})]},o))})]})},ur=()=>{const{modalPosition:t,color:e,initialColor:n,setShowModal:s,hue:o,saturation:i,brightness:a,dragging:c,setDragging:u,setHue:h,setSaturation:f,setBrightness:l,colorChange:p,setColor:d,update:x}=r.useColorPickerStore(),g=E=>{const{offsetX:w,offsetY:R}=E.nativeEvent;u(!0),b(w,R,E.currentTarget)},v=E=>{if(c){const w=document.querySelector(`.${r.styles.colorMap}`),{left:R,top:C}=w.getBoundingClientRect(),y=E.clientX-R,z=E.clientY-C;b(y,z,w)}},_=()=>{u(!1)},b=(E,w,R)=>{const{width:C,height:y}=R.getBoundingClientRect(),z=Math.max(0,Math.min(E/C*100,100)),re=Math.max(0,Math.min(100-w/y*100,100));f(z),l(re),S(z,re)},S=(E,w)=>{const R=A(o,E,w);p(R),d(R)},D=(E,w,R)=>{w/=100,R/=100;const C=se=>(se+E/60)%6,y=se=>R*(1-w*Math.max(0,Math.min(C(se),4-C(se),1))),z=Math.round(255*y(5)),re=Math.round(255*y(3)),yt=Math.round(255*y(1));return{r:z,g:re,b:yt}},M=(E,w,R)=>{const C=y=>y.toString(16).padStart(2,"0");return`#${C(E)}${C(w)}${C(R)}`},A=(E,w,R)=>{const{r:C,g:y,b:z}=D(E,w,R);return M(C,y,z)};m.useEffect(()=>{const E=R=>v(R),w=()=>_();return c?(document.addEventListener("mousemove",E),document.addEventListener("mouseup",w)):(document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",w)),()=>{document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",w)}},[c]);function O(){x(e),s(!1)}function H(){s(!1),p(n)}return r.jsxRuntimeExports.jsxs("div",{className:r.styles.modal,onClick:E=>E.stopPropagation(),style:{top:`${t.top}px`,left:`${t.left}px`},children:[r.jsxRuntimeExports.jsx("div",{children:"Color"}),r.jsxRuntimeExports.jsx("div",{className:r.styles.colorMap,onMouseDown:g,style:{background:`
1
+ (function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode('@charset "UTF-8";@import"https://fonts.googleapis.com/css2?family=Archivo:ital,wght@0,100..900;1,100..900&display=swap";._icon_21b8w_1 path{fill:var(--icon-fill)}._hoverable_21b8w_5{cursor:pointer}._button_rcjso_1{background-color:#ff3f19;padding:10px 16px;color:#fff;border-radius:12px;cursor:pointer;font-size:16px}._button_rcjso_1:disabled{opacity:.7;cursor:auto}._wrapper_1q8v6_1{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%}._label_1q8v6_9{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._input_1q8v6_17{width:100%;background-color:var(--background-color);border-radius:12px;padding:7px 11px;font-size:16px;line-height:24px;border:1px solid var(--background-color)}._input_1q8v6_17::placeholder{color:#c2c2c2}._input_1q8v6_17:disabled{background-color:var(--background-color);opacity:.7}._required_1q8v6_36{border:1px solid #ff3f19}._paddingless_1q8v6_40{padding:0}._content_1q8v6_44{display:flex;align-items:center;gap:8px}._wrapper_1v1ye_1{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%}._label_1v1ye_9{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._select_1v1ye_17{width:100%;background-color:var(--background-color);border-radius:12px;padding:10px 12px;font-size:14px;line-height:20px;display:flex;align-items:center;justify-content:space-between;cursor:pointer}._icon_1v1ye_30{transition:.2s}._rotate_1v1ye_34{transform:rotate(180deg)}._content_1v1ye_38{position:relative}._options_1v1ye_42{position:absolute;top:45px;width:100%;background-color:var(--background-color);border-radius:12px;font-size:14px;line-height:20px;display:flex;flex-direction:column;max-height:200px;z-index:10;overflow-y:scroll;cursor:pointer}._option_1v1ye_42{padding:10px 12px;border-radius:12px}._option_1v1ye_42:hover{background-color:#e6e6e6}._addon_1v1ye_66{display:flex;align-items:center;gap:6px}._wrapper_3w2ni_1{display:flex;width:fit-content;gap:8px;align-items:center;border-radius:12px;line-height:20px;color:#252525;font-size:14px;font-weight:400}._switch_3w2ni_13{width:40px;height:24px;background-color:#ccc;border-radius:25px;display:flex;align-items:center;padding:2px;cursor:pointer;transition:background-color .2s}._switch_3w2ni_13._active_3w2ni_24{background:#ff3f19}._switch_3w2ni_13 ._toggle_3w2ni_27{width:14px;height:14px;background-color:#fff;border-radius:16px;transition:transform .2s;transform:translate(2px)}._switch_3w2ni_13._active_3w2ni_24 ._toggle_3w2ni_27{transform:translate(18px)}._background_3w2ni_39{background-color:#f8f8f8}._padding_3w2ni_43{padding:8px}._wrapper_1inu5_1{border:var(--default-border);width:fit-content;height:fit-content;max-height:500px;max-width:500px;min-width:300px;padding:10px;left:10px;top:10px;position:absolute;z-index:1000;background-color:#fff;display:flex;border-radius:8px;justify-content:center;align-items:center;overflow:hidden}._blocks_1op3c_1{display:flex;align-items:center;gap:8px}._block_1op3c_1{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_1op3c_18{border:1px solid #ff3f19}._applyButton_1cqw4_2{flex:0 1 50%;font-weight:400}._cancelButton_1cqw4_7{background-color:#f8f8f8;color:var(--accent-color)}._content_1cqw4_12{display:flex;flex-direction:column;width:100%}._label_1cqw4_18{padding:8px 12px;border-radius:8px;display:flex;align-items:center;position:relative;gap:8px;width:100%;background-color:var(--background-color);cursor:pointer}._colorValue_1cqw4_30{width:20px;height:20px;padding:2.5px;border-radius:2px}._modal_1cqw4_37{left:15px;width:288px;overflow-y:auto;z-index:100000000;position:fixed;background-color:#fff;border-radius:12px;padding:10px;border:1px solid #e6e6e6;height:400px;display:flex;flex-direction:column;gap:10px;font-size:16px;line-height:24px;font-weight:700}._colorMap_1cqw4_56{position:relative;width:100%;height:300px;cursor:pointer;border-radius:4px}._indicator_1cqw4_64{position:absolute;width:20px;height:20px;border:4px solid white;border-radius:50%;pointer-events:none}._hueSlider_1cqw4_73{width:80%;left:30px;height:8px;position:absolute;bottom:80px;background:linear-gradient(to right,red,#ff0,#0f0,#0ff,#00f,#f0f,red,red);border-radius:5px}input[type=range]{-webkit-appearance:none;height:8px;outline:none;border-radius:5px;position:relative;display:flex;justify-content:center}input[type=range]::-webkit-slider-thumb{-webkit-appearance:none;width:20px;height:20px;border:5px solid #fff;border-radius:50%;cursor:pointer}._slider_1cqw4_102{width:100%;cursor:pointer}._buttons_1cqw4_107{display:flex;gap:5px;width:100%}._name_1cqw4_113{line-height:20px;padding:0 4px 4px}._secondary_1cqw4_118{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._input_1cqw4_126{line-height:20px;font-size:14px;font-weight:400}._modal_1qb2a_1{position:fixed;top:0;left:0;right:0;bottom:0;background:#2525253d;z-index:100000;display:flex;padding:20px;justify-content:center;align-items:center;overflow:hidden}._wrapper_1qvfi_1{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%;position:relative}._label_1qvfi_10{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._textarea_1qvfi_18{width:100%;background-color:var(--background-color);border-radius:12px;padding:8px 12px;font-size:16px;line-height:24px;resize:none;min-height:80px}._textarea_1qvfi_18::placeholder{color:#c2c2c2}._length_1qvfi_33{position:absolute;bottom:12px;right:12px;color:#c2c2c2;line-height:20px}._wrapper_1fcne_2{display:flex;flex-direction:column;gap:6px;justify-content:start;width:100%}._label_1fcne_10{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._options_1fcne_18{display:flex;gap:20px}._radioLabel_1fcne_23{display:flex;align-items:center;cursor:pointer;position:relative}._radio_1fcne_23{position:absolute;opacity:0;cursor:pointer}._custom_1fcne_36{height:20px;width:20px;border-radius:50%;border:1px solid #e6e6e6;display:inline-block;margin-right:8px;position:relative}._radio_1fcne_23:checked+._custom_1fcne_36{border-color:#ff3f19;background:#ffeae5}._custom_1fcne_36:after{content:"";position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:8px;height:8px;border-radius:50%;background-color:#e53e3e;opacity:0}._radio_1fcne_23:checked+._custom_1fcne_36:after{opacity:1}._option_1fcne_18{font-size:16px;line-height:24px;font-weight:400}._tip_pl6k0_1{display:flex;align-items:center;padding:8px;border-radius:12px;gap:8px}._text_pl6k0_9{flex:1 1 auto;line-height:20px;font-size:14px}._warning_pl6k0_15{background:#faf8e6;color:#c1972a}._error_pl6k0_20{background:#ffc3b7;color:#ff3f19}._hide_pl6k0_25{display:none}._customCheckbox_1b69m_1{display:inline-block;cursor:pointer;position:relative}._checkboxBox_1b69m_7{display:inline-block;width:20px;height:20px;border:1px solid #e6e6e6;border-radius:6px;position:relative}._checkboxBox_1b69m_7._checked_1b69m_16{background:#ffeae5;border:1px solid #ff3f19}._icon_1b69m_21{position:absolute;top:3px;left:3px}._wrapper_tm686_2{display:flex;flex-direction:column;gap:6px;width:100%}._label_tm686_9{color:#757575;font-weight:400;font-size:14px;line-height:20px}._icon_tm686_16{padding:4px;background-color:#fff;border:1px solid #f0f0f0;display:flex;justify-content:center;align-items:center;border-radius:6px}._text_tm686_26{font-weight:400;font-size:16px;line-height:24px;color:#ff3f19}._content_tm686_33{display:flex;align-items:center;gap:6px;cursor:pointer;background-color:#f8f8f8;border-radius:12px;padding:6px 8px}._modal_tm686_43{background-color:#f8f8f8;border:1px solid #f0f0f0;border-radius:16px;width:100%;max-width:640px}._top_tm686_51{padding:16px 24px;display:flex;align-items:center;justify-content:space-between}._title_tm686_58{color:#252525;font-weight:400;font-size:18px;line-height:24px}._modalContent_tm686_65{padding:16px 24px;border-top-left-radius:16px;border-top-right-radius:16px;border-top:1px solid #f0f0f0;border-bottom:1px solid #f0f0f0;background-color:#fff}._images_tm686_74{display:grid;grid-template-columns:repeat(3,1fr);align-items:center;gap:10px;overflow-y:scroll;max-height:390px}._add_tm686_83{display:flex;flex-direction:column;gap:8px;padding:43px 16px;border:1px dashed #e6e6e6;justify-content:center;align-items:center;border-radius:16px;aspect-ratio:1/1}._description_tm686_95{text-align:center;color:#252525;font-size:14px;line-height:20px}._description_tm686_95 span:last-child{padding-top:4px}._bottom_tm686_105{display:flex;justify-content:end;align-items:center;width:100%;background-color:#fff;border-bottom-left-radius:16px;border-bottom-right-radius:16px;padding:16px 24px 12px;gap:6px}._cancel_tm686_117{background-color:var(--background-color);color:var(--accent-color)}._highlight_tm686_122{color:#ff3f19;cursor:pointer}._accent_tm686_127{color:var(--accent-color)}._image_tm686_74{position:relative;padding:43px 16px;border:1px solid #e6e6e6;justify-content:center;align-items:center;border-radius:16px;aspect-ratio:1/1}._selected_tm686_141{border:1px solid #ff3f19}._checkbox_tm686_145{position:absolute;top:12px;left:12px}._loading_tm686_151{position:relative;padding:43px 16px;border:1px solid #e6e6e6;background-color:#f8f8f8;justify-content:center;align-items:center;display:flex;border-radius:16px;aspect-ratio:1/1}._spinner_tm686_163{width:24px;height:24px;border:2px solid #ff3f19;border-top-color:#f8f8f8;border-radius:50%;animation:_spin_tm686_163 1s linear infinite}@keyframes _spin_tm686_163{to{transform:rotate(360deg)}}._buttons_1gn8m_1{display:flex;align-items:center;gap:16px}._button_1gn8m_1{cursor:pointer;padding:10px}._devices_hxl12_1{display:flex;gap:4px;background:var(--background-color);padding:4px;border-radius:16px}._device_hxl12_1{padding:6px 8px;display:flex;align-items:center;justify-content:center;cursor:pointer;border-radius:12px;border:1px solid var(--background-color)}._device_hxl12_1:hover{border:var(--default-border);box-shadow:0 0 1px #dfdfdf}._active_hxl12_23{background-color:#fff}._active_hxl12_23:hover{border:1px solid var(--background-color);box-shadow:none}._header_wxpoz_1{position:absolute;top:0;left:0;width:100%;padding:11px 22px;line-height:20px;border-bottom:var(--default-border);display:flex;align-items:center;justify-content:space-between;gap:24px;z-index:50000}._left_wxpoz_16,._right_wxpoz_17{display:flex;align-items:center;gap:24px}._preview_vijvm_2{display:flex;align-items:center;gap:4px;color:var(--accent-color);line-height:20px;padding:10px 16px;cursor:pointer;border:1px solid #fff;border-radius:16px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}._preview_vijvm_2:hover{border:var(--default-border);box-shadow:0 0 1px #dfdfdf}._active_vijvm_22{background-color:var(--background-color)}._active_vijvm_22:hover{border:1px solid #fff;box-shadow:none}._settings_q79q3_1{display:flex;gap:20px;align-items:center;color:var(--accent-color)}._language_1mbvp_1{display:flex;align-items:center;gap:4px;background-color:var(--background-color);padding:10px 12px;border-radius:12px;cursor:pointer}._text_1mbvp_11{padding-right:4px;color:var(--main-color)}._pages_x8pw2_1{position:relative}._default_x8pw2_5{display:flex;align-items:center;gap:4px;padding:10px 12px;background-color:var(--background-color);border-radius:8px;cursor:pointer;position:relative}._text_x8pw2_16{padding-right:4px;color:var(--main-color);flex:1 1 auto}._modal_x8pw2_22{position:absolute;top:45px;width:320px;left:0;z-index:100;background-color:#fff;border:1px solid #e6e6e6;border-radius:8px;padding:8px 12px;display:flex;flex-direction:column}._page_x8pw2_1{display:flex;align-items:center;gap:8px;padding:12px 8px;border-radius:8px;cursor:pointer}._hoverable_x8pw2_45{background-color:var(--background-color)}._separator_x8pw2_49{border-bottom:1px solid #f0f0f0}._button_x8pw2_53{background:inherit;color:#ff3f19;display:flex;align-items:center;justify-content:start;gap:8px;padding:16px 8px 12px;transition:.2s}._button_x8pw2_53:hover{background-color:var(--background-color)}._zoom_a77cn_1{display:flex;align-items:center;gap:4px;background-color:var(--background-color);padding:10px 12px;border-radius:12px;cursor:pointer}._theme_3wxbf_1{display:flex;align-items:center;gap:4px;padding:9px 12px;background:#e5fadd;color:#338b13;border-radius:100px}._exit_2ce42_1{border-bottom:var(--default-border);display:flex;gap:8px;align-items:center;padding:22px;cursor:pointer}._text_2ce42_10{color:#252525;line-height:20px}._navbar_2ac63_1{width:100px;border-right:var(--default-border)}._main_2ac63_6{display:flex;flex-direction:column;gap:8px;padding:16px 12px}._block_2ac63_13{display:flex;align-items:center;flex-direction:column;gap:4px;color:var(--accent-color);line-height:20px;padding:12px 24px;cursor:pointer;border:1px solid #fff;border-radius:16px}._block_2ac63_13:hover{border:var(--default-border);box-shadow:0 0 1px #dfdfdf}._active_2ac63_30{background-color:var(--background-color);color:#252525}._active_2ac63_30:hover{border:1px solid #fff;box-shadow:none}._preview_jui5n_1{width:100%;background-color:var(--background-color);padding:16px 32px 0;position:relative;z-index:500}._main_jui5n_9{width:100%;display:flex;flex-direction:column;overflow-y:auto;height:100%;position:relative;z-index:1}._content_jui5n_19{background-color:#fff;border:var(--default-border);border-bottom:none;height:100%}._loading_jui5n_26{width:100%;height:100%;display:flex;justify-content:center;align-items:center}._loader_jui5n_34{border:4px solid rgba(0,0,0,.1);border-left-color:#fff;border-radius:50%;width:40px;height:40px;animation:_spin_jui5n_1 1s linear infinite}@keyframes _spin_jui5n_1{0%{transform:rotate(0)}to{transform:rotate(360deg)}}._header_1t64j_1{display:flex;width:100%;padding:18px;justify-content:center;border:var(--default-border);background-color:#fff;border-top-left-radius:16px;border-top-right-radius:16px;border-bottom:none;z-index:5}._circles_1t64j_14{left:28px;top:28px;position:absolute;display:flex;align-items:center;gap:8px}._circle_1t64j_14{width:12px;height:12px;border-radius:50%;border:.5px solid #e6e6e6}._red_1t64j_30{background:#ff5f57}._green_1t64j_34{background:#28c840}._yellow_1t64j_38{background:#febc2e}._input_1t64j_42{background-color:var(--background-color);padding:6px 8px;display:flex;max-width:480px;width:100%;border-radius:6px}._main_1t64j_51{flex:1 1 auto;display:flex;align-items:center;justify-content:center;gap:4px}._text_1t64j_59{font-weight:600;font-size:12px;line-height:16px;margin:0 0 0 4px}._content_92dk8_1{width:100%;height:100%}._block_92dk8_6{position:relative;cursor:pointer;border-left:1px solid #e6e6e6;border-right:1px solid #e6e6e6}._active_92dk8_13{border:2px solid #ff3f19}._name_92dk8_17{z-index:10;position:absolute;top:-28px;left:-2px;border-top-left-radius:8px;border-top-right-radius:8px;color:#fff;background:#ff3f19;padding:4px 12px;line-height:20px;text-align:center}._empty_92dk8_31{height:100%;width:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;text-align:center}._icon_92dk8_42{width:64px;height:64px;background-color:var(--background-color);display:flex;border-radius:50%;justify-content:center;align-items:center;margin:0 0 8px}._title_92dk8_53{font-weight:700;font-size:24px;line-height:32px}._text_92dk8_59{font-size:16px;line-height:24px;color:var(--accent-color)}._sections_92dk8_65{padding:0 20px;margin:20px 0 0;display:flex;flex-wrap:wrap;justify-content:center;gap:24px}._section_92dk8_65{cursor:pointer;display:flex;gap:10px;max-width:288px;width:100%;align-items:center;justify-content:space-between;padding:24px;background-color:var(--background-color);border-radius:24px;color:var(--accent-color)}._sidebar_1f3hk_1{position:absolute;display:flex;height:fit-content();flex-direction:column;right:10px;z-index:20;padding:10px;cursor:auto}._content_1f3hk_12{height:100%;border:1px solid #e6e6e6;border-radius:8px;background-color:#fff;padding:8px;max-width:60px;width:100%}._button_1f3hk_22{display:flex;align-items:center;border-radius:8px;padding:8px;transition:.2s background-color}._moveButton_1f3hk_30:hover{background-color:var(--background-color)}._border_1f3hk_34{border-bottom:var(--default-border)}._deleteButton_1f3hk_38:hover{background-color:#dd6363;color:#fff}._results_f488n_1{display:flex;flex-direction:column;padding:8px;gap:20px}._name_f488n_8{color:var(--main-color);font-weight:600;font-size:16px;line-height:24px}._product_f488n_15{display:flex;align-items:center;justify-content:space-between;cursor:pointer}._search_1s0qp_1{background:var(--background-color);padding:8px 12px;display:flex;align-items:center;border-radius:12px;width:100%;gap:10px;margin:8px 0}._input_1s0qp_12{width:100%;font-size:16px;line-height:24px;color:#252525}._input_1s0qp_12::placeholder{color:#c2c2c2}._sidebar_1r5sp_1{max-width:320px;width:100%;padding:16px;border-right:var(--default-border);height:100%;position:relative}._title_1r5sp_10{color:var(--main-color);font-weight:700;font-size:20px;line-height:24px;padding-bottom:8px}._active_1r5sp_18{display:flex;align-items:center;gap:8px}._layers_62wod_1{display:flex;flex-direction:column;position:relative;height:100%}._block_62wod_8{position:relative;display:flex;align-items:center;gap:4px;font-size:16px;line-height:24px;padding:8px 12px;border-radius:8px;cursor:pointer}._block_62wod_8:hover{background-color:var(--background-color)}._dragging_62wod_23{box-shadow:0 2.1px 4.36px #00000004;box-shadow:0 5.3px 10.22px #00000005;border:var(--default-border);box-shadow:0 10.81px 19.93px #00000006;cursor:grabbing}._active_62wod_31{background:#ffeae5}._add_62wod_35{z-index:2;position:absolute;display:flex;justify-content:center;align-items:center;bottom:0;left:0;border-bottom:2px solid #ff3f19;width:100%}._button_62wod_47{position:relative;display:flex;justify-content:center;align-items:center;top:12px;background-color:#ff3f19;width:24px;height:24px;border-radius:50%;padding:4px}._empty_62wod_60{display:flex;flex-direction:column;justify-content:center;height:100%;width:100%;align-items:center;text-align:center;gap:4px;color:var(--accent-color)}._title_62wod_72{font-size:16px;line-height:24px;font-weight:700;color:var(--accent-color)}._icon_62wod_79{margin:0 0 12px}._text_62wod_83{font-size:16px;font-weight:400;line-height:24px}._highlight_62wod_89{color:#ff3f19;cursor:pointer}._block_1d6lb_1{position:relative;display:flex;align-items:center;gap:4px;font-size:16px;line-height:24px;padding:8px 12px;border-radius:8px;cursor:pointer}._block_1d6lb_1:hover{background-color:var(--background-color)}._theme_1xj36_1{display:flex;flex-direction:column}._block_1xj36_6{justify-content:start;display:flex;align-items:center;gap:8px;width:100%;padding:16px 8px;cursor:pointer;border-radius:8px}._block_1xj36_6:hover{background-color:var(--background-color)}._name_1xj36_20{flex:1 1 auto}._back_14yda_1{display:flex;align-items:center;gap:8px;padding-bottom:8px}._render_14yda_8{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:501}._open_14yda_23{animation:.2s _open_14yda_23 forwards}@keyframes _open_14yda_23{0%{transform:translate(320px);z-index:1}99%{z-index:1}to{z-index:5000;transform:translate(0)}}@keyframes _close_14yda_50{0%{z-index:1;transform:translate(0)}to{z-index:1;transform:translate(320px)}}._close_14yda_50{animation:.2s _close_14yda_50 forwards}._clicked_14yda_54{opacity:0}._title_14yda_58{color:var(--main-color);font-weight:700;font-size:20px;line-height:24px}._button_14yda_65{align-self:center;flex:1}._loading_14yda_70{flex:1 1 auto}._settings_14yda_74{flex:1 1 auto;overflow-y:scroll;overflow-x:hidden}._buttons_14yda_80{justify-content:space-between;display:flex;gap:10px}._deleteButton_14yda_86{display:flex;align-items:center;border-radius:8px;padding:8px;transition:.2s background-color}._deleteButton_14yda_86:hover{background-color:#dd6363;color:#fff}._settings_1r85j_1{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:3}._open_1r85j_16{transform:translate(0)}._close_1r85j_20{transform:translate(320px)}._header_1r85j_24{display:flex;align-items:center;gap:8px}._title_1r85j_30{font-weight:700;font-size:20px;line-height:24px;flex:1 1 auto}._addButton_1r85j_37{color:#ff3f19;display:flex;align-items:center;gap:4px;cursor:pointer}._wrapper_n1a7x_1{overflow-y:scroll}._category_n1a7x_5{display:flex;flex-direction:column}._categoryTitle_n1a7x_10{font-weight:600;font-size:16px;line-height:24px}._color_n1a7x_16{display:flex;flex-direction:column}._color_n1a7x_16:not(:last-child){border-bottom:1px solid #f0f0f0}._content_n1a7x_24{padding:12px 0;gap:8px;display:flex;align-items:center;flex:1 1 auto}._preview_n1a7x_32{width:39px;height:39px;flex:0 0 39px;padding:5px;border-radius:50%;border:1px solid #e6e6e6}._wrapper_kb55x_2{overflow-y:scroll}._category_kb55x_6{display:flex;flex-direction:column}._categoryTitle_kb55x_11{font-weight:600;font-size:16px;line-height:24px}._color_kb55x_17{gap:8px;display:flex;flex-direction:column}._name_kb55x_23{line-height:20px;padding:0 4px 4px}._content_kb55x_28{display:flex;flex-direction:column;width:100%}._label_kb55x_34{padding:8px 12px;border-radius:12px;display:flex;align-items:center;gap:5px;width:100%;background-color:var(--background-color);cursor:pointer}._input_kb55x_45[type=color]{width:20px;height:20px;padding:1px}._input_kb55x_45{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;height:100%;border:none;padding:0;cursor:pointer;border-radius:50%}._input_kb55x_45::-webkit-color-swatch{border-radius:50%;border:none}._input_kb55x_45::-webkit-color-swatch-wrapper{padding:0;border-radius:50%}._title_kb55x_71{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._field_kb55x_79{display:flex;flex-direction:column;gap:10px;padding:16px 0}._field_kb55x_79:not(:last-child){border-bottom:1px solid #f0f0f0}._alignments_kb55x_89{display:flex;flex-direction:column;gap:10px}._lineField_kb55x_95{display:flex;justify-content:space-between;align-items:center}._style_kb55x_101{flex:1 0 50%;display:flex;flex-direction:column;gap:8px}._header_kb55x_108{display:flex;align-items:center;justify-content:space-between}._wrapper_k9on2_1{overflow-y:scroll}._category_k9on2_5{display:flex;flex-direction:column}._categoryTitle_k9on2_10{font-weight:600;font-size:16px;line-height:24px}._font_k9on2_16{padding:12px 0;gap:8px;display:flex;align-items:center;position:relative;flex:1 1 auto;cursor:pointer}._font_k9on2_16:hover{background-color:#f8f8f8;border-radius:8px}._font_k9on2_16:not(:last-child){border-bottom:var(--default-border)}._font_k9on2_16:not(:last-child):hover{border-bottom:1px solid #f8f8f8}._content_k9on2_36{display:flex;flex-direction:column;width:100%}._icon_k9on2_42{padding:8px;border-radius:8px;background-color:#f8f8f8;display:flex;align-items:center;justify-content:center}._paragraph_k9on2_51{padding:12px}._deleteIcon_k9on2_55{position:absolute;right:10px;width:20px;height:20px}._iconButton_k9on2_62{width:32px;height:32px}._wrapper_94fpv_1{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:5}._open_94fpv_16{transform:translate(0)}._close_94fpv_20{transform:translate(320px)}._header_94fpv_24{display:flex;align-items:center;gap:8px;margin:0 0 10px}._title_94fpv_31{font-weight:700;font-size:20px;line-height:24px}._options_94fpv_37{display:flex;flex-direction:column;gap:10px;flex:1 1 auto}._clicked_94fpv_44{opacity:0}._wrapper_1j33r_1{display:flex;flex-direction:column;gap:8px;height:100%;transition:.2s transform;position:absolute;top:0;left:0;padding:16px;width:100%;background:#fff;z-index:5}._open_1j33r_16{transform:translate(0)}._close_1j33r_20{transform:translate(320px)}._header_1j33r_24{display:flex;align-items:center;gap:8px;margin:0 0 10px}._title_1j33r_31{font-weight:700;font-size:20px;line-height:24px}._options_1j33r_37{display:flex;flex-direction:column;gap:10px;flex:1 1 auto}._clicked_1j33r_44{opacity:0}._label_1j33r_48{font-size:14px;font-weight:400;line-height:20px;color:var(--accent-color)}._alignments_1j33r_55{display:flex;flex-direction:column;gap:10px}._blocks_1j33r_61{display:flex;align-items:center;gap:8px}._alignment_1j33r_55{padding:8px;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_1j33r_75{border:1px solid #ff3f19}._wrapper_jjfwh_1{display:flex;flex-direction:column;gap:20px;background:#fff;max-width:640px;width:100%;padding:16px 24px;border-radius:16px}._header_jjfwh_12{display:flex;justify-content:space-between;align-items:center;font-size:24px;font-weight:700;line-height:32px}._content_jjfwh_21{display:flex;flex-direction:column;gap:10px;overflow-y:scroll;max-height:500px}._buttons_jjfwh_29{display:flex;justify-content:end;gap:12px}._cancel_jjfwh_35{background-color:var(--background-color);color:var(--accent-color)}._label_jjfwh_40,._description_jjfwh_41{width:100%;color:var(--accent-color);line-height:20px;font-size:14px;font-weight:400}._preview_jjfwh_49{display:flex;flex-direction:column;gap:10px}._block_jjfwh_55{padding:24px;display:flex;flex-direction:column;border:1px solid var(--background-color);border-radius:8px}._slug_jjfwh_63{line-height:20px;color:#ff3f19;margin-bottom:4px}._title_jjfwh_69{font-weight:600;font-size:16px;line-height:24px}._layout_kjedu_1{width:100%;height:100%;display:flex;position:relative}._main_kjedu_8{display:flex;flex-direction:column;width:100%;position:relative}._content_kjedu_15{position:relative;padding-top:64px;height:100%;display:flex}*{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Noto Sans,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"}*{padding:0;margin:0;border:0}*,*:before,*:after{box-sizing:border-box}:focus,:active{outline:none}a:focus,a:active{outline:none}nav,footer,header,aside{display:block}html,body{width:100%;line-height:1;font-size:16px;-ms-text-size-adjust:100%;-moz-text-size-adjust:100%;-webkit-text-size-adjust:100%}input,button,textarea{font-family:inherit}input::-ms-clear{display:none}button{background-color:transparent;cursor:pointer}button::-moz-focus-inner{padding:0;border:0}a,a:visited,a:hover{text-decoration:none}ul li{list-style:none}img{vertical-align:top}h1,h2,h3,h4,h5,h6,a{font-size:inherit}a{color:inherit}*{-webkit-tap-highlight-color:transparent}input{border:none;background:none;outline:none;padding:0}input[type=color]{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:40px;height:40px;border:none;background:transparent}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}*{-ms-overflow-style:none;scrollbar-width:none}* ::-webkit-scrollbar{display:none}:root{--default-border: 1px solid #f0f0f0;--accent-color: #757575;--main-color: #252525;--background-color: #f8f8f8}#root{height:100vh}body,html{background-color:#fff;font-family:Archivo,sans-serif;max-height:100vh;overflow:hidden}._wrapper_o1bnv_2{display:flex;flex-direction:column;gap:10px}._alignmentBlock_o1bnv_8{padding:10px 0 16px;display:flex;flex-direction:column;gap:6px;border-bottom:1px solid #f0f0f0}._title_o1bnv_16{font-weight:700;line-height:24px;font-size:16px;color:#252525}._subtitle_o1bnv_23{color:#757575;font-size:14px;line-height:20px;font-weight:400}._alignmentContent_o1bnv_30{display:flex;justify-content:space-between;align-items:stretch;gap:8px}._alignments_o1bnv_37{border-radius:12px;background:#f8f8f8;display:grid;gap:4px;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(3,1fr);flex:0 0 50%}._alignment_o1bnv_8{cursor:pointer;display:flex;height:100%;width:100%;align-items:center;justify-content:center}._circle_o1bnv_56{width:6px;height:6px;border-radius:50%;background-color:#c2c2c2}._paddings_o1bnv_63{border-radius:12px;display:grid;gap:4px;grid-template-columns:repeat(2,1fr);grid-template-rows:repeat(2,1fr)}._padding_o1bnv_63{width:68px;display:flex;align-items:center;gap:4px;background:#f8f8f8;border-radius:12px;padding:10px 8px}._input_o1bnv_81{width:100%}._subtitle_2zbxx_1{color:#757575;font-size:14px;line-height:20px;font-weight:400}._header_2zbxx_8,._text_2zbxx_9{padding:10px 0 16px;display:flex;flex-direction:column;border-bottom:1px solid #f0f0f0}._top_2zbxx_16{display:flex;justify-content:space-between;align-items:center;margin:0 0 8px}._itemsBlock_2zbxx_23{display:flex;flex-direction:column;gap:6px}._typeTexts_3zlec_1{display:flex;align-items:center;gap:8px}._block_3zlec_7{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_3zlec_18{border:1px solid #ff3f19}._subtitle_2l7ty_1{color:#757575;font-size:14px;line-height:20px;font-weight:400}._header_2l7ty_8,._text_2l7ty_9,._productsBlock_2l7ty_10{padding:10px 0 16px;display:flex;flex-direction:column;border-bottom:1px solid #f0f0f0;width:100%}._productsBlock_2l7ty_10{position:relative}._top_2l7ty_22{display:flex;justify-content:space-between;align-items:center;margin:0 0 8px}._itemsBlock_2l7ty_29{display:flex;flex-direction:column;gap:6px}._typeTexts_2l7ty_35{display:flex;align-items:center;gap:8px}._block_2l7ty_41{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_2l7ty_52{border:1px solid #ff3f19}._products_2l7ty_10{width:100%;display:flex;flex-direction:column;gap:8px}._product_2l7ty_10{display:flex;align-items:center;gap:8px;width:100%}._button_2l7ty_70{background:inherit;color:#ff3f19;display:flex;align-items:center;justify-content:center;gap:6px;width:100%}._image_2l7ty_80{border-radius:8px;border:1px solid #f0f0f0;background-color:#fff;padding:4px}._info_2l7ty_87{border-radius:12px;display:flex;gap:4px;justify-content:space-between;align-items:center;flex:1 1 auto;background-color:#f8f8f8;padding:8px 12px}._name_2l7ty_98{flex:1 1 100%}._buttons_2l7ty_102{display:flex;align-items:center;gap:8px}._modal_2l7ty_108{position:fixed;background-color:#fff;right:-300px;top:0;z-index:10000;max-width:276px;width:100%;padding:16px;border-radius:12px}._modal_2l7ty_108 ._top_2l7ty_22{display:flex;align-items:center;justify-content:space-between}._other_2l7ty_125{display:flex;flex-direction:column;gap:6px}._subtitle_1y5sw_1{color:#757575;font-size:14px;line-height:20px;font-weight:400}._header_1y5sw_8,._text_1y5sw_9,._productsBlock_1y5sw_10,._buttonsBlock_1y5sw_11{padding:10px 0 16px;display:flex;flex-direction:column;border-bottom:1px solid #f0f0f0}._buttonsBlock_1y5sw_11{position:relative}._top_1y5sw_22{display:flex;justify-content:space-between;align-items:center;margin:0 0 8px}._itemsBlock_1y5sw_29{display:flex;flex-direction:column;gap:6px}._typeTexts_1y5sw_35{display:flex;align-items:center;gap:8px}._block_1y5sw_41{padding:8px;display:flex;align-items:center;justify-content:center;border:1px solid #f8f8f8;background-color:#f8f8f8;border-radius:12px;cursor:pointer}._active_1y5sw_52{border:1px solid #ff3f19}._products_1y5sw_10{width:100%;display:flex;flex-direction:column;gap:8px}._product_1y5sw_10{display:flex;align-items:center;gap:8px;width:100%}._button_1y5sw_11{background:inherit;color:#ff3f19;display:flex;align-items:center;justify-content:center;gap:6px;width:100%}._image_1y5sw_80{border-radius:8px;border:1px solid #f0f0f0;background-color:#fff;padding:4px}._info_1y5sw_87{border-radius:12px;display:flex;gap:4px;justify-content:space-between;align-items:center;flex:1 1 auto;background-color:#f8f8f8;padding:8px 12px}._name_1y5sw_98{flex:1 1 100%}._buttons_1y5sw_11{display:flex;align-items:center;gap:8px}._modal_1y5sw_108{position:fixed;background-color:#fff;right:-300px;z-index:10000;max-width:276px;width:100%;bottom:20px;padding:16px;border-radius:12px}._modal_1y5sw_108 ._top_1y5sw_22{display:flex;align-items:center;justify-content:space-between}._other_1y5sw_125{display:flex;flex-direction:column;gap:6px}._options_1y5sw_131{display:flex;flex-direction:column;gap:15px}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-DSUcxVxJ.cjs"),m=require("react"),wt=["desktop","tablet","mobile"],Dt=[{icon:"paint",name:"Colors"},{icon:"font",name:"Fonts"},{icon:"corners-out",name:"Borders"},{icon:"arrow-square",name:"Buttons"},{icon:"textbox",name:"Inputs"}],Rt="https://g-api.billgang.com",Ct="https://www.googleapis.com/webfonts/v1/webfonts",Ot="_buttons_1gn8m_1",It="_button_1gn8m_1",Tt={buttons:Ot,button:It},Nt=()=>r.jsxRuntimeExports.jsxs("div",{className:Tt.buttons,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"undo",hoverable:!0,width:20,height:20}),r.jsxRuntimeExports.jsx(r.Icon,{name:"redo",hoverable:!0,width:20,height:20})]}),kt="_devices_hxl12_1",Pt="_device_hxl12_1",$t="_active_hxl12_23",xe={devices:kt,device:Pt,active:$t},Mt=()=>{const{currentDevice:t,setCurrentDevice:e}=r.useDeviceStore();return r.jsxRuntimeExports.jsx("div",{className:xe.devices,children:wt.map(n=>r.jsxRuntimeExports.jsx("div",{className:r.clx(xe.device,{[xe.active]:t===n}),onClick:()=>e(n),children:r.jsxRuntimeExports.jsx(r.Icon,{name:n,fill:t===n?"#252525":"#757575",width:20,height:20})},n))})},At="_header_wxpoz_1",Bt="_left_wxpoz_16",Lt="_right_wxpoz_17",oe={header:At,left:Bt,right:Lt},Ht="_preview_vijvm_2",Ft="_active_vijvm_22",ve={preview:Ht,active:Ft},Ut=()=>{const{onPreview:t,setOnPreview:e}=r.usePreviewStore();return r.jsxRuntimeExports.jsxs("div",{className:r.clx(ve.preview,{[ve.active]:t}),onClick:()=>e(!t),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-up-right",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:ve.text,children:"Preview"})]})},qt="_settings_q79q3_1",zt={settings:qt},Vt="_language_1mbvp_1",Yt="_text_1mbvp_11",Be={language:Vt,text:Yt},Gt=()=>r.jsxRuntimeExports.jsxs("div",{className:Be.language,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"globe",fill:"#252525",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:Be.text,children:"Default"}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-down",width:20,height:20})]}),Xt="_pages_x8pw2_1",Wt="_text_x8pw2_16",Qt="_modal_x8pw2_22",Zt="_page_x8pw2_1",Jt="_hoverable_x8pw2_45",Kt="_separator_x8pw2_49",en="_button_x8pw2_53",F={pages:Xt,default:"_default_x8pw2_5",text:Wt,modal:Qt,page:Zt,hoverable:Jt,separator:Kt,button:en},$=t=>t?t.replace(/_/g," ").split(" ").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" and "):"",tn=()=>{const{currentPage:t,setCurrentPage:e,setIsOpenModal:n,pages:s,setIsEdit:o,setEditedPage:i,deletePage:a,isOpenSelectModal:c,setIsOpenSelectModal:u}=r.usePagesStore(),{deletePage:h}=r.useLayersStore(),[f,l]=m.useState("");return m.useEffect(()=>{const p=()=>{u(!1)};return document.body.addEventListener("click",p),()=>{document.body.removeEventListener("click",p)}},[]),r.jsxRuntimeExports.jsxs("div",{className:F.pages,children:[r.jsxRuntimeExports.jsxs("div",{className:F.default,onClick:p=>{p.stopPropagation(),u(!c)},children:[r.jsxRuntimeExports.jsx(r.Icon,{name:s[t].icon,fill:"#252525",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:F.text,children:r.defaultPageNames.includes(s[t].name)?`${$(s[t].name)} page`:s[t].name}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-down",width:20,height:20})]}),c&&r.jsxRuntimeExports.jsxs("div",{className:F.modal,onClick:p=>p.stopPropagation(),children:[Object.keys(s).map(p=>{const d=s[p];return r.jsxRuntimeExports.jsxs("div",{className:r.clx(F.page,{[F.hoverable]:f===p}),onMouseEnter:()=>l(p),onMouseLeave:()=>l(""),onClick:()=>{l(""),o(!1),e(p),u(!1)},children:[r.jsxRuntimeExports.jsx(r.Icon,{name:d.icon,fill:"#252525"}),r.jsxRuntimeExports.jsx("span",{className:F.text,children:r.defaultPageNames.includes(d.name)?`${$(d.name)} page`:d.name}),f===p&&r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"settings",fill:"#757575",onClick:x=>{x.stopPropagation(),o(!0),i(p),n(!0)}}),!r.defaultPageNames.includes(d.name)&&r.jsxRuntimeExports.jsx(r.Icon,{name:"trash",fill:"#C12A2A",onClick:x=>{s[t].name===d.name&&e("home"),x.stopPropagation(),a(p),h(d.name)}})]}),s[t].name===d.name&&r.jsxRuntimeExports.jsx(r.Icon,{name:"check",fill:"#FF3F19"})]},p)}),r.jsxRuntimeExports.jsx("div",{className:F.separator}),r.jsxRuntimeExports.jsxs(r.Button,{className:F.button,onClick:p=>{p.stopPropagation(),n(!0)},size:"l",children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"plus",fill:"#ff3f19"}),r.jsxRuntimeExports.jsx("span",{children:"Create Page Blank"})]})]})]})},nn="_zoom_a77cn_1",rn={zoom:nn},sn=()=>{const[t,e]=m.useState(),n=()=>{e(Number(Math.round(window.devicePixelRatio*50).toFixed(0)))};return m.useEffect(()=>(n(),window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}),[]),r.jsxRuntimeExports.jsxs("div",{className:rn.zoom,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"zoom-minus",width:20,height:20}),r.jsxRuntimeExports.jsxs("span",{children:[t," %"]})]})},on=()=>r.jsxRuntimeExports.jsxs("div",{className:zt.settings,children:[r.jsxRuntimeExports.jsx(Gt,{}),r.jsxRuntimeExports.jsx(tn,{}),r.jsxRuntimeExports.jsx(sn,{})]}),an="_theme_3wxbf_1",cn={theme:an},un=()=>r.jsxRuntimeExports.jsxs("div",{className:cn.theme,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"check",width:18,height:18}),r.jsxRuntimeExports.jsx("div",{children:"Current Theme"})]}),ln=()=>{const{themeSettings:t}=r.useThemeSettingsStore(),{settings:e}=r.useSettingsStore(),[n,s]=m.useState(null),[o,i]=m.useState(!1),{pages:a}=r.usePagesStore(),{blocks:c}=r.useLayersStore();function u(d,x){return x.map(v=>Object.values(v.value).filter(_=>_.type===d).map(_=>_.value).flat()).flat()}function h(d,x){return u(d,x).some(v=>v)}function f(d,x){const g=u(d,x);return Array.isArray(g)&&g.length>0?Math.max(...g):0}function l(d){const x=Object.keys(a).find(g=>a[g].name===d);return x?a[x]:null}const p=()=>{if(o)n&&clearTimeout(n);else{const x=Object.keys(c).map(g=>{const v=l(g);return{name:v?v.name:g,path:g==="home"?"/":(v==null?void 0:v.path)||g,layout:{...c[g]},neededProductIds:[...u("ProductId",Object.values(c[g]))],neededCategoryIds:[...u("CategoryId",Object.values(c[g]))],neededAnnouncementIds:[...u("AnnouncementId",Object.values(c[g]))],neededListingIds:[...u("ListingId",Object.values(c[g]))],neededFaqs:h("Faqs",Object.values(c[g])),neededReviewCount:f("ReviewCount",Object.values(c[g])),seo:{pageTitle:v?v.seo.title:"",pageDescription:v?v.seo.description:""}}});r.updateSettings("POST","save",{themeSettings:t,settings:e,updatedPages:x})}i(!0);const d=setTimeout(()=>{i(!1)},2e3);s(d)};return r.jsxRuntimeExports.jsxs("div",{className:oe.header,children:[r.jsxRuntimeExports.jsxs("div",{className:oe.left,children:[r.jsxRuntimeExports.jsx(Mt,{}),r.jsxRuntimeExports.jsx(Ut,{})]}),r.jsxRuntimeExports.jsx("div",{className:oe.center,children:r.jsxRuntimeExports.jsx(on,{})}),r.jsxRuntimeExports.jsxs("div",{className:oe.right,children:[r.jsxRuntimeExports.jsx(un,{}),r.jsxRuntimeExports.jsx(Nt,{}),r.jsxRuntimeExports.jsx(r.Button,{onClick:p,children:"Save"})]})]})},dn="_exit_2ce42_1",gn="_text_2ce42_10",Le={exit:dn,text:gn},pn=()=>r.jsxRuntimeExports.jsxs("div",{className:Le.exit,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"sign-out",width:20,height:20}),r.jsxRuntimeExports.jsx("span",{className:Le.text,children:"Exit"})]}),hn="_navbar_2ac63_1",fn="_main_2ac63_6",mn="_block_2ac63_13",xn="_active_2ac63_30",ie={navbar:hn,main:fn,block:mn,active:xn},vn=()=>{const{activeBlock:t,setActiveBlock:e}=r.useNavbarStore(),{setActiveBlock:n}=r.useBlocksStore(),{setCurrentBlock:s}=r.useLayersStore(),{setActiveBlock:o}=r.useThemeSettingsStore();function i(a){n(null),e(a),s(null),o(null)}return r.jsxRuntimeExports.jsxs("div",{className:ie.navbar,children:[r.jsxRuntimeExports.jsx(pn,{}),r.jsxRuntimeExports.jsx("div",{className:ie.main,children:r.navbarBlocks.map(a=>r.jsxRuntimeExports.jsxs("div",{className:r.clx(ie.block,{[ie.active]:t.icon===a.icon}),onClick:()=>i(a),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:a.icon,fill:t.icon===a.icon?"#252525":"#757575"}),r.jsxRuntimeExports.jsx("span",{children:a.name})]},a.icon))})]})},jn="_preview_jui5n_1",En="_main_jui5n_9",_n="_content_jui5n_19",bn="_loading_jui5n_26",Sn="_loader_jui5n_34",yn="_spin_jui5n_1",ee={preview:jn,main:En,content:_n,loading:bn,loader:Sn,spin:yn},wn="_header_1t64j_1",Dn="_circles_1t64j_14",Rn="_circle_1t64j_14",Cn="_red_1t64j_30",On="_green_1t64j_34",In="_yellow_1t64j_38",Tn="_input_1t64j_42",Nn="_main_1t64j_51",kn="_text_1t64j_59",U={header:wn,circles:Dn,circle:Rn,red:Cn,green:On,yellow:In,input:Tn,main:Nn,text:kn},Pn="data:image/svg+xml,%3csvg%20width='17'%20height='16'%20viewBox='0%200%2017%2016'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3crect%20x='0.5'%20width='16'%20height='16'%20fill='url(%23pattern0_4042_718)'/%3e%3cdefs%3e%3cpattern%20id='pattern0_4042_718'%20patternContentUnits='objectBoundingBox'%20width='1'%20height='1'%3e%3cuse%20xlink:href='%23image0_4042_718'%20transform='scale(0.015625)'/%3e%3c/pattern%3e%3cimage%20id='image0_4042_718'%20width='64'%20height='64'%20xlink:href='data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAONJREFUeF7t20EOhEAIRFG4/6F7DvEnYeFzryQIv6pBd2behOu9dPvsbog+k+NLgArQAqmJcw9iAAhSgZKB3IJkkAySQTJ4CiE+gA8oBeg0mH3Ai084P89HhqwEqIA209ICsQdjAeaZIgaAYKxBDMCAYy8fXwAIgiAIcoJpJEYGI4VjB3YrbC9gL2AvkCB43cM5PgZgAAZgQFnNZAhdGykQBEEQBEEQDBmgAm2glM/z+QUYisYUGoldO7kY32IEAzCg6RgIRgjFAsw+AgRBMNYgBmCAT2TCYfoPPz/HCqQCX1eBHzHnv7C7WhBSAAAAAElFTkSuQmCC'/%3e%3c/defs%3e%3c/svg%3e",$n=["red","yellow","green"],Mn=()=>r.jsxRuntimeExports.jsxs("div",{className:U.header,children:[r.jsxRuntimeExports.jsx("div",{className:U.circles,children:$n.map(t=>r.jsxRuntimeExports.jsx("div",{className:r.clx(U.circle,{[U.red]:t==="red",[U.yellow]:t==="yellow",[U.green]:t==="green"})},t))}),r.jsxRuntimeExports.jsxs("div",{className:U.input,children:[r.jsxRuntimeExports.jsxs("div",{className:U.main,children:[r.jsxRuntimeExports.jsx("img",{src:Pn,alt:""}),r.jsxRuntimeExports.jsx("span",{className:U.text,children:"lorem.ipsum"}),r.jsxRuntimeExports.jsx(r.Icon,{name:"lock",fill:"#757575",width:15,height:16})]}),r.jsxRuntimeExports.jsx(r.Icon,{name:"copy",width:20,height:20})]})]}),An="_content_92dk8_1",Bn="_block_92dk8_6",Ln="_active_92dk8_13",Hn="_name_92dk8_17",Fn="_empty_92dk8_31",Un="_icon_92dk8_42",qn="_title_92dk8_53",zn="_text_92dk8_59",Vn="_sections_92dk8_65",Yn="_section_92dk8_65",ae={content:An,block:Bn,active:Ln,name:Hn,empty:Fn,icon:Un,title:qn,text:zn,sections:Vn,section:Yn},Gn="_sidebar_1f3hk_1",Xn="_content_1f3hk_12",Wn="_button_1f3hk_22",Qn="_moveButton_1f3hk_30",Zn="_border_1f3hk_34",Jn="_deleteButton_1f3hk_38",I={sidebar:Gn,content:Xn,button:Wn,moveButton:Qn,border:Zn,deleteButton:Jn},Kn=()=>{const{activeBlock:t}=r.usePreviewStore(),{blocks:e,removeBlock:n,moveBlock:s,duplicateBlock:o}=r.useLayersStore(),{currentPage:i,pages:a}=r.usePagesStore(),c=Object.keys(e[a[i].name]),u=c.indexOf(t),h=()=>{u>0&&s(a[i].name,u,u-1)},f=()=>{u<c.length-1&&s(a[i].name,u,u+1)},l=()=>{o(a[i].name,t)};return r.jsxRuntimeExports.jsx("div",{className:I.sidebar,children:r.jsxRuntimeExports.jsxs("div",{className:I.content,children:[r.jsxRuntimeExports.jsx("button",{onClick:h,className:r.clx(I.button,I.moveButton),disabled:u===0,children:r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-preview-up"})}),r.jsxRuntimeExports.jsx("button",{onClick:f,className:r.clx(I.button,I.moveButton),disabled:u===c.length-1,children:r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-preview-down"})}),r.jsxRuntimeExports.jsx("div",{className:I.border}),r.jsxRuntimeExports.jsx("button",{onClick:l,className:r.clx(I.button,I.moveButton),children:r.jsxRuntimeExports.jsx(r.Icon,{name:"copy"})}),r.jsxRuntimeExports.jsx("div",{className:I.border}),r.jsxRuntimeExports.jsx("button",{onClick:()=>n(a[i].name,t),className:r.clx(I.button,I.deleteButton),children:r.jsxRuntimeExports.jsx(r.Icon,{name:"trash",hoverable:!0})})]})})},nt=({render:t,block:e})=>t(e),er=()=>{const{footer:t}=r.useLayersStore(),{settings:e}=r.useSettingsStore(),{pageContext:n}=r.usePagesStore();return t==null?void 0:t.renderBlock(e,n)},tr=()=>{const{header:t}=r.useLayersStore(),{settings:e}=r.useSettingsStore(),{pageContext:n}=r.usePagesStore();return t==null?void 0:t.renderBlock(e,n)},nr=m.memo(()=>{const{setActiveBlock:t,activeBlock:e}=r.usePreviewStore(),{blocks:n}=r.useBlocksStore(),{blocks:s}=r.useLayersStore(),{settings:o}=r.useSettingsStore(),{currentPage:i,pages:a,setIsOpenSelectModal:c}=r.usePagesStore(),u=l=>{const p=n[l.name],d=l.value;for(const x in d)p[x]=d[x];return p.renderBlock(o)},h=m.useRef(e);m.useEffect(()=>{h.current=e},[e]),m.useEffect(()=>{const l=()=>{h.current&&t(null)};return document.body.addEventListener("click",l),()=>{document.body.removeEventListener("click",l)}},[]);const f=m.useCallback(l=>u(l),[s]);return r.jsxRuntimeExports.jsxs("div",{onClick:l=>{l.stopPropagation(),c(!1)},className:ae.content,children:[r.jsxRuntimeExports.jsx(tr,{}),s[a[i].name]&&Object.keys(s[a[i].name]).map(l=>r.jsxRuntimeExports.jsxs("div",{onClick:()=>t(l),className:r.clx(ae.block,{[ae.active]:e===l}),children:[e===l&&r.jsxRuntimeExports.jsx("div",{className:ae.name,children:s[a[i].name][l].name}),e===l&&r.jsxRuntimeExports.jsx(Kn,{}),r.jsxRuntimeExports.jsx(nt,{render:f,block:s[a[i].name][l]})]})),r.jsxRuntimeExports.jsx(er,{})]})}),rr="_results_f488n_1",sr="_name_f488n_8",or="_product_f488n_15",ce={results:rr,name:sr,product:or},ir="_search_1s0qp_1",ar="_input_1s0qp_12",He={search:ir,input:ar},cr=()=>r.jsxRuntimeExports.jsxs("label",{className:He.search,children:[r.jsxRuntimeExports.jsx("input",{type:"text",placeholder:"Search for sections",className:He.input}),r.jsxRuntimeExports.jsx(r.Icon,{name:"search",fill:"#757575"})]}),rt=()=>{const{blocks:t,setActiveBlock:e}=r.useBlocksStore(),{hideModal:n}=r.useSubmodalStore();function s(o){e(o),n()}return r.jsxRuntimeExports.jsxs("div",{className:ce.add,children:[r.jsxRuntimeExports.jsx(cr,{}),r.jsxRuntimeExports.jsx("div",{className:ce.results,children:Object.keys(t).map(o=>r.jsxRuntimeExports.jsxs("div",{className:ce.product,onClick:()=>s(o),children:[r.jsxRuntimeExports.jsx("span",{className:ce.name,children:o}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-right"})]},o))})]})},ur=()=>{const{modalPosition:t,color:e,initialColor:n,setShowModal:s,hue:o,saturation:i,brightness:a,dragging:c,setDragging:u,setHue:h,setSaturation:f,setBrightness:l,colorChange:p,setColor:d,update:x}=r.useColorPickerStore(),g=E=>{const{offsetX:w,offsetY:R}=E.nativeEvent;u(!0),b(w,R,E.currentTarget)},v=E=>{if(c){const w=document.querySelector(`.${r.styles.colorMap}`),{left:R,top:C}=w.getBoundingClientRect(),y=E.clientX-R,z=E.clientY-C;b(y,z,w)}},_=()=>{u(!1)},b=(E,w,R)=>{const{width:C,height:y}=R.getBoundingClientRect(),z=Math.max(0,Math.min(E/C*100,100)),re=Math.max(0,Math.min(100-w/y*100,100));f(z),l(re),S(z,re)},S=(E,w)=>{const R=A(o,E,w);p(R),d(R)},D=(E,w,R)=>{w/=100,R/=100;const C=se=>(se+E/60)%6,y=se=>R*(1-w*Math.max(0,Math.min(C(se),4-C(se),1))),z=Math.round(255*y(5)),re=Math.round(255*y(3)),yt=Math.round(255*y(1));return{r:z,g:re,b:yt}},M=(E,w,R)=>{const C=y=>y.toString(16).padStart(2,"0");return`#${C(E)}${C(w)}${C(R)}`},A=(E,w,R)=>{const{r:C,g:y,b:z}=D(E,w,R);return M(C,y,z)};m.useEffect(()=>{const E=R=>v(R),w=()=>_();return c?(document.addEventListener("mousemove",E),document.addEventListener("mouseup",w)):(document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",w)),()=>{document.removeEventListener("mousemove",E),document.removeEventListener("mouseup",w)}},[c]);function O(){x(e),s(!1)}function H(){s(!1),p(n)}return r.jsxRuntimeExports.jsxs("div",{className:r.styles.modal,onClick:E=>E.stopPropagation(),style:{top:`${t.top}px`,left:`${t.left}px`},children:[r.jsxRuntimeExports.jsx("div",{children:"Color"}),r.jsxRuntimeExports.jsx("div",{className:r.styles.colorMap,onMouseDown:g,style:{background:`
3
3
  linear-gradient(to top, black, transparent),
4
4
  linear-gradient(to right, hsl(${o}, 100%, 100%), hsl(${o}, 100%, 50%))
5
5
  `},children:r.jsxRuntimeExports.jsx("div",{className:r.styles.indicator,style:{position:"absolute",left:`${i}%`,top:`${100-a}%`,transform:"translate(-50%, -50%)"}})}),r.jsxRuntimeExports.jsx("div",{className:r.styles.hueSlider,children:r.jsxRuntimeExports.jsx("input",{type:"range",min:"0",max:"360",value:o,onChange:E=>{h(Number(E.target.value)),S(i,a)},className:r.styles.slider})}),r.jsxRuntimeExports.jsxs("div",{className:r.styles.buttons,children:[r.jsxRuntimeExports.jsx(r.Button,{onClick:H,className:r.clx(r.styles.applyButton,r.styles.cancelButton),children:"Cancel"}),r.jsxRuntimeExports.jsx(r.Button,{onClick:O,className:r.styles.applyButton,children:"Apply"})]})]})},lr=()=>{const{onPreview:t}=r.usePreviewStore(),{hoverBlockId:e,isModalVisible:n,isPreviewVisible:s}=r.useSubmodalStore(),{settings:o}=r.useSettingsStore(),{blocks:i}=r.useBlocksStore(),{blocks:a}=r.useLayersStore(),{currentPage:c,pages:u}=r.usePagesStore(),{showModal:h}=r.useColorPickerStore(),[f,l]=m.useState(!0);m.useEffect(()=>{t&&setTimeout(()=>{l(!1)},100)},[t]);const p=d=>{if(!d)return;const x=i[d.name],g=d.value;for(const v in g)x[v]=g[v];return x.renderBlock(o)};return r.jsxRuntimeExports.jsxs("div",{className:ee.preview,children:[n&&r.jsxRuntimeExports.jsx(r.Submodal,{children:r.jsxRuntimeExports.jsx(rt,{})}),s&&e&&r.jsxRuntimeExports.jsx(r.Submodal,{children:r.jsxRuntimeExports.jsx(nt,{render:p,block:a[u[c].name][e]})}),h&&r.jsxRuntimeExports.jsx(ur,{}),t&&r.jsxRuntimeExports.jsxs("div",{className:ee.main,children:[r.jsxRuntimeExports.jsx(Mn,{}),r.jsxRuntimeExports.jsx("div",{className:ee.content,children:f?r.jsxRuntimeExports.jsx("div",{className:ee.loading,children:r.jsxRuntimeExports.jsx("div",{className:ee.loader})}):r.jsxRuntimeExports.jsx(nr,{})})]})]})},dr="_sidebar_1r5sp_1",gr="_title_1r5sp_10",pr="_active_1r5sp_18",Fe={sidebar:dr,title:gr,active:pr},st=m.createContext({dragDropManager:void 0});function T(t){return"Minified Redux error #"+t+"; visit https://redux.js.org/Errors?code="+t+" for the full message or use the non-minified dev environment for full errors. "}var Ue=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),je=function(){return Math.random().toString(36).substring(7).split("").join(".")},qe={INIT:"@@redux/INIT"+je(),REPLACE:"@@redux/REPLACE"+je(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+je()}};function hr(t){if(typeof t!="object"||t===null)return!1;for(var e=t;Object.getPrototypeOf(e)!==null;)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function fr(t){if(t===void 0)return"undefined";if(t===null)return"null";var e=typeof t;switch(e){case"boolean":case"string":case"number":case"symbol":case"function":return e}if(Array.isArray(t))return"array";if(vr(t))return"date";if(xr(t))return"error";var n=mr(t);switch(n){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return n}return e.slice(8,-1).toLowerCase().replace(/\s/g,"")}function mr(t){return typeof t.constructor=="function"?t.constructor.name:null}function xr(t){return t instanceof Error||typeof t.message=="string"&&t.constructor&&typeof t.constructor.stackTraceLimit=="number"}function vr(t){return t instanceof Date?!0:typeof t.toDateString=="function"&&typeof t.getDate=="function"&&typeof t.setDate=="function"}function Y(t){var e=typeof t;return process.env.NODE_ENV!=="production"&&(e=fr(t)),e}function ot(t,e,n){var s;if(typeof e=="function"&&typeof n=="function"||typeof n=="function"&&typeof arguments[3]=="function")throw new Error(process.env.NODE_ENV==="production"?T(0):"It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if(typeof e=="function"&&typeof n>"u"&&(n=e,e=void 0),typeof n<"u"){if(typeof n!="function")throw new Error(process.env.NODE_ENV==="production"?T(1):"Expected the enhancer to be a function. Instead, received: '"+Y(n)+"'");return n(ot)(t,e)}if(typeof t!="function")throw new Error(process.env.NODE_ENV==="production"?T(2):"Expected the root reducer to be a function. Instead, received: '"+Y(t)+"'");var o=t,i=e,a=[],c=a,u=!1;function h(){c===a&&(c=a.slice())}function f(){if(u)throw new Error(process.env.NODE_ENV==="production"?T(3):"You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return i}function l(g){if(typeof g!="function")throw new Error(process.env.NODE_ENV==="production"?T(4):"Expected the listener to be a function. Instead, received: '"+Y(g)+"'");if(u)throw new Error(process.env.NODE_ENV==="production"?T(5):"You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");var v=!0;return h(),c.push(g),function(){if(v){if(u)throw new Error(process.env.NODE_ENV==="production"?T(6):"You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");v=!1,h();var b=c.indexOf(g);c.splice(b,1),a=null}}}function p(g){if(!hr(g))throw new Error(process.env.NODE_ENV==="production"?T(7):"Actions must be plain objects. Instead, the actual type was: '"+Y(g)+"'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.");if(typeof g.type>"u")throw new Error(process.env.NODE_ENV==="production"?T(8):'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if(u)throw new Error(process.env.NODE_ENV==="production"?T(9):"Reducers may not dispatch actions.");try{u=!0,i=o(i,g)}finally{u=!1}for(var v=a=c,_=0;_<v.length;_++){var b=v[_];b()}return g}function d(g){if(typeof g!="function")throw new Error(process.env.NODE_ENV==="production"?T(10):"Expected the nextReducer to be a function. Instead, received: '"+Y(g));o=g,p({type:qe.REPLACE})}function x(){var g,v=l;return g={subscribe:function(b){if(typeof b!="object"||b===null)throw new Error(process.env.NODE_ENV==="production"?T(11):"Expected the observer to be an object. Instead, received: '"+Y(b)+"'");function S(){b.next&&b.next(f())}S();var D=v(S);return{unsubscribe:D}}},g[Ue]=function(){return this},g}return p({type:qe.INIT}),s={dispatch:p,subscribe:l,getState:f,replaceReducer:d},s[Ue]=x,s}function j(t,e,...n){if(jr()&&e===void 0)throw new Error("invariant requires an error message argument");if(!t){let s;if(e===void 0)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{let o=0;s=new Error(e.replace(/%s/g,function(){return n[o++]})),s.name="Invariant Violation"}throw s.framesToPop=1,s}}function jr(){return typeof process<"u"&&process.env.NODE_ENV==="production"}function Er(t,e,n){return e.split(".").reduce((s,o)=>s&&s[o]?s[o]:n||null,t)}function _r(t,e){return t.filter(n=>n!==e)}function it(t){return typeof t=="object"}function br(t,e){const n=new Map,s=i=>{n.set(i,n.has(i)?n.get(i)+1:1)};t.forEach(s),e.forEach(s);const o=[];return n.forEach((i,a)=>{i===1&&o.push(a)}),o}function Sr(t,e){return t.filter(n=>e.indexOf(n)>-1)}const Ne="dnd-core/INIT_COORDS",ge="dnd-core/BEGIN_DRAG",ke="dnd-core/PUBLISH_DRAG_SOURCE",pe="dnd-core/HOVER",he="dnd-core/DROP",fe="dnd-core/END_DRAG";function ze(t,e){return{type:Ne,payload:{sourceClientOffset:e||null,clientOffset:t||null}}}const yr={type:Ne,payload:{clientOffset:null,sourceClientOffset:null}};function wr(t){return function(n=[],s={publishSource:!0}){const{publishSource:o=!0,clientOffset:i,getSourceClientOffset:a}=s,c=t.getMonitor(),u=t.getRegistry();t.dispatch(ze(i)),Dr(n,c,u);const h=Or(n,c);if(h==null){t.dispatch(yr);return}let f=null;if(i){if(!a)throw new Error("getSourceClientOffset must be defined");Rr(a),f=a(h)}t.dispatch(ze(i,f));const p=u.getSource(h).beginDrag(c,h);if(p==null)return;Cr(p),u.pinSource(h);const d=u.getSourceType(h);return{type:ge,payload:{itemType:d,item:p,sourceId:h,clientOffset:i||null,sourceClientOffset:f||null,isSourcePublic:!!o}}}}function Dr(t,e,n){j(!e.isDragging(),"Cannot call beginDrag while dragging."),t.forEach(function(s){j(n.getSource(s),"Expected sourceIds to be registered.")})}function Rr(t){j(typeof t=="function","When clientOffset is provided, getSourceClientOffset must be a function.")}function Cr(t){j(it(t),"Item must be an object.")}function Or(t,e){let n=null;for(let s=t.length-1;s>=0;s--)if(e.canDragSource(t[s])){n=t[s];break}return n}function Ir(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Tr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{},s=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(s=s.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),s.forEach(function(o){Ir(t,o,n[o])})}return t}function Nr(t){return function(n={}){const s=t.getMonitor(),o=t.getRegistry();kr(s),Mr(s).forEach((a,c)=>{const u=Pr(a,c,o,s),h={type:he,payload:{dropResult:Tr({},n,u)}};t.dispatch(h)})}}function kr(t){j(t.isDragging(),"Cannot call drop while not dragging."),j(!t.didDrop(),"Cannot call drop twice during one drag operation.")}function Pr(t,e,n,s){const o=n.getTarget(t);let i=o?o.drop(s,t):void 0;return $r(i),typeof i>"u"&&(i=e===0?{}:s.getDropResult()),i}function $r(t){j(typeof t>"u"||it(t),"Drop result must either be an object or undefined.")}function Mr(t){const e=t.getTargetIds().filter(t.canDropOnTarget,t);return e.reverse(),e}function Ar(t){return function(){const n=t.getMonitor(),s=t.getRegistry();Br(n);const o=n.getSourceId();return o!=null&&(s.getSource(o,!0).endDrag(n,o),s.unpinSource()),{type:fe}}}function Br(t){j(t.isDragging(),"Cannot call endDrag while not dragging.")}function Re(t,e){return e===null?t===null:Array.isArray(t)?t.some(n=>n===e):t===e}function Lr(t){return function(n,{clientOffset:s}={}){Hr(n);const o=n.slice(0),i=t.getMonitor(),a=t.getRegistry(),c=i.getItemType();return Ur(o,a,c),Fr(o,i,a),qr(o,i,a),{type:pe,payload:{targetIds:o,clientOffset:s||null}}}}function Hr(t){j(Array.isArray(t),"Expected targetIds to be an array.")}function Fr(t,e,n){j(e.isDragging(),"Cannot call hover while not dragging."),j(!e.didDrop(),"Cannot call hover after drop.");for(let s=0;s<t.length;s++){const o=t[s];j(t.lastIndexOf(o)===s,"Expected targetIds to be unique in the passed array.");const i=n.getTarget(o);j(i,"Expected targetIds to be registered.")}}function Ur(t,e,n){for(let s=t.length-1;s>=0;s--){const o=t[s],i=e.getTargetType(o);Re(i,n)||t.splice(s,1)}}function qr(t,e,n){t.forEach(function(s){n.getTarget(s).hover(e,s)})}function zr(t){return function(){if(t.getMonitor().isDragging())return{type:ke}}}function Vr(t){return{beginDrag:wr(t),publishDragSource:zr(t),hover:Lr(t),drop:Nr(t),endDrag:Ar(t)}}class Yr{receiveBackend(e){this.backend=e}getMonitor(){return this.monitor}getBackend(){return this.backend}getRegistry(){return this.monitor.registry}getActions(){const e=this,{dispatch:n}=this.store;function s(i){return(...a)=>{const c=i.apply(e,a);typeof c<"u"&&n(c)}}const o=Vr(this);return Object.keys(o).reduce((i,a)=>{const c=o[a];return i[a]=s(c),i},{})}dispatch(e){this.store.dispatch(e)}constructor(e,n){this.isSetUp=!1,this.handleRefCountChange=()=>{const s=this.store.getState().refCount>0;this.backend&&(s&&!this.isSetUp?(this.backend.setup(),this.isSetUp=!0):!s&&this.isSetUp&&(this.backend.teardown(),this.isSetUp=!1))},this.store=e,this.monitor=n,e.subscribe(this.handleRefCountChange)}}function Gr(t,e){return{x:t.x+e.x,y:t.y+e.y}}function at(t,e){return{x:t.x-e.x,y:t.y-e.y}}function Xr(t){const{clientOffset:e,initialClientOffset:n,initialSourceClientOffset:s}=t;return!e||!n||!s?null:at(Gr(e,s),n)}function Wr(t){const{clientOffset:e,initialClientOffset:n}=t;return!e||!n?null:at(e,n)}const ne=[],Pe=[];ne.__IS_NONE__=!0;Pe.__IS_ALL__=!0;function Qr(t,e){return t===ne?!1:t===Pe||typeof e>"u"?!0:Sr(e,t).length>0}class Zr{subscribeToStateChange(e,n={}){const{handlerIds:s}=n;j(typeof e=="function","listener must be a function."),j(typeof s>"u"||Array.isArray(s),"handlerIds, when specified, must be an array of strings.");let o=this.store.getState().stateId;const i=()=>{const a=this.store.getState(),c=a.stateId;try{c===o||c===o+1&&!Qr(a.dirtyHandlerIds,s)||e()}finally{o=c}};return this.store.subscribe(i)}subscribeToOffsetChange(e){j(typeof e=="function","listener must be a function.");let n=this.store.getState().dragOffset;const s=()=>{const o=this.store.getState().dragOffset;o!==n&&(n=o,e())};return this.store.subscribe(s)}canDragSource(e){if(!e)return!1;const n=this.registry.getSource(e);return j(n,`Expected to find a valid source. sourceId=${e}`),this.isDragging()?!1:n.canDrag(this,e)}canDropOnTarget(e){if(!e)return!1;const n=this.registry.getTarget(e);if(j(n,`Expected to find a valid target. targetId=${e}`),!this.isDragging()||this.didDrop())return!1;const s=this.registry.getTargetType(e),o=this.getItemType();return Re(s,o)&&n.canDrop(this,e)}isDragging(){return!!this.getItemType()}isDraggingSource(e){if(!e)return!1;const n=this.registry.getSource(e,!0);if(j(n,`Expected to find a valid source. sourceId=${e}`),!this.isDragging()||!this.isSourcePublic())return!1;const s=this.registry.getSourceType(e),o=this.getItemType();return s!==o?!1:n.isDragging(this,e)}isOverTarget(e,n={shallow:!1}){if(!e)return!1;const{shallow:s}=n;if(!this.isDragging())return!1;const o=this.registry.getTargetType(e),i=this.getItemType();if(i&&!Re(o,i))return!1;const a=this.getTargetIds();if(!a.length)return!1;const c=a.indexOf(e);return s?c===a.length-1:c>-1}getItemType(){return this.store.getState().dragOperation.itemType}getItem(){return this.store.getState().dragOperation.item}getSourceId(){return this.store.getState().dragOperation.sourceId}getTargetIds(){return this.store.getState().dragOperation.targetIds}getDropResult(){return this.store.getState().dragOperation.dropResult}didDrop(){return this.store.getState().dragOperation.didDrop}isSourcePublic(){return!!this.store.getState().dragOperation.isSourcePublic}getInitialClientOffset(){return this.store.getState().dragOffset.initialClientOffset}getInitialSourceClientOffset(){return this.store.getState().dragOffset.initialSourceClientOffset}getClientOffset(){return this.store.getState().dragOffset.clientOffset}getSourceClientOffset(){return Xr(this.store.getState().dragOffset)}getDifferenceFromInitialOffset(){return Wr(this.store.getState().dragOffset)}constructor(e,n){this.store=e,this.registry=n}}const Ve=typeof global<"u"?global:self,ct=Ve.MutationObserver||Ve.WebKitMutationObserver;function ut(t){return function(){const n=setTimeout(o,0),s=setInterval(o,50);function o(){clearTimeout(n),clearInterval(s),t()}}}function Jr(t){let e=1;const n=new ct(t),s=document.createTextNode("");return n.observe(s,{characterData:!0}),function(){e=-e,s.data=e}}const Kr=typeof ct=="function"?Jr:ut;class es{enqueueTask(e){const{queue:n,requestFlush:s}=this;n.length||(s(),this.flushing=!0),n[n.length]=e}constructor(){this.queue=[],this.pendingErrors=[],this.flushing=!1,this.index=0,this.capacity=1024,this.flush=()=>{const{queue:e}=this;for(;this.index<e.length;){const n=this.index;if(this.index++,e[n].call(),this.index>this.capacity){for(let s=0,o=e.length-this.index;s<o;s++)e[s]=e[s+this.index];e.length-=this.index,this.index=0}}e.length=0,this.index=0,this.flushing=!1},this.registerPendingError=e=>{this.pendingErrors.push(e),this.requestErrorThrow()},this.requestFlush=Kr(this.flush),this.requestErrorThrow=ut(()=>{if(this.pendingErrors.length)throw this.pendingErrors.shift()})}}class ts{call(){try{this.task&&this.task()}catch(e){this.onError(e)}finally{this.task=null,this.release(this)}}constructor(e,n){this.onError=e,this.release=n,this.task=null}}class ns{create(e){const n=this.freeTasks,s=n.length?n.pop():new ts(this.onError,o=>n[n.length]=o);return s.task=e,s}constructor(e){this.onError=e,this.freeTasks=[]}}const lt=new es,rs=new ns(lt.registerPendingError);function ss(t){lt.enqueueTask(rs.create(t))}const $e="dnd-core/ADD_SOURCE",Me="dnd-core/ADD_TARGET",Ae="dnd-core/REMOVE_SOURCE",me="dnd-core/REMOVE_TARGET";function os(t){return{type:$e,payload:{sourceId:t}}}function is(t){return{type:Me,payload:{targetId:t}}}function as(t){return{type:Ae,payload:{sourceId:t}}}function cs(t){return{type:me,payload:{targetId:t}}}function us(t){j(typeof t.canDrag=="function","Expected canDrag to be a function."),j(typeof t.beginDrag=="function","Expected beginDrag to be a function."),j(typeof t.endDrag=="function","Expected endDrag to be a function.")}function ls(t){j(typeof t.canDrop=="function","Expected canDrop to be a function."),j(typeof t.hover=="function","Expected hover to be a function."),j(typeof t.drop=="function","Expected beginDrag to be a function.")}function Ce(t,e){if(e&&Array.isArray(t)){t.forEach(n=>Ce(n,!1));return}j(typeof t=="string"||typeof t=="symbol",e?"Type can only be a string, a symbol, or an array of either.":"Type can only be a string or a symbol.")}var N;(function(t){t.SOURCE="SOURCE",t.TARGET="TARGET"})(N||(N={}));let ds=0;function gs(){return ds++}function ps(t){const e=gs().toString();switch(t){case N.SOURCE:return`S${e}`;case N.TARGET:return`T${e}`;default:throw new Error(`Unknown Handler Role: ${t}`)}}function Ye(t){switch(t[0]){case"S":return N.SOURCE;case"T":return N.TARGET;default:throw new Error(`Cannot parse handler ID: ${t}`)}}function Ge(t,e){const n=t.entries();let s=!1;do{const{done:o,value:[,i]}=n.next();if(i===e)return!0;s=!!o}while(!s);return!1}class hs{addSource(e,n){Ce(e),us(n);const s=this.addHandler(N.SOURCE,e,n);return this.store.dispatch(os(s)),s}addTarget(e,n){Ce(e,!0),ls(n);const s=this.addHandler(N.TARGET,e,n);return this.store.dispatch(is(s)),s}containsHandler(e){return Ge(this.dragSources,e)||Ge(this.dropTargets,e)}getSource(e,n=!1){return j(this.isSourceId(e),"Expected a valid source ID."),n&&e===this.pinnedSourceId?this.pinnedSource:this.dragSources.get(e)}getTarget(e){return j(this.isTargetId(e),"Expected a valid target ID."),this.dropTargets.get(e)}getSourceType(e){return j(this.isSourceId(e),"Expected a valid source ID."),this.types.get(e)}getTargetType(e){return j(this.isTargetId(e),"Expected a valid target ID."),this.types.get(e)}isSourceId(e){return Ye(e)===N.SOURCE}isTargetId(e){return Ye(e)===N.TARGET}removeSource(e){j(this.getSource(e),"Expected an existing source."),this.store.dispatch(as(e)),ss(()=>{this.dragSources.delete(e),this.types.delete(e)})}removeTarget(e){j(this.getTarget(e),"Expected an existing target."),this.store.dispatch(cs(e)),this.dropTargets.delete(e),this.types.delete(e)}pinSource(e){const n=this.getSource(e);j(n,"Expected an existing source."),this.pinnedSourceId=e,this.pinnedSource=n}unpinSource(){j(this.pinnedSource,"No source is pinned at the time."),this.pinnedSourceId=null,this.pinnedSource=null}addHandler(e,n,s){const o=ps(e);return this.types.set(o,n),e===N.SOURCE?this.dragSources.set(o,s):e===N.TARGET&&this.dropTargets.set(o,s),o}constructor(e){this.types=new Map,this.dragSources=new Map,this.dropTargets=new Map,this.pinnedSourceId=null,this.pinnedSource=null,this.store=e}}const fs=(t,e)=>t===e;function ms(t,e){return!t&&!e?!0:!t||!e?!1:t.x===e.x&&t.y===e.y}function xs(t,e,n=fs){if(t.length!==e.length)return!1;for(let s=0;s<t.length;++s)if(!n(t[s],e[s]))return!1;return!0}function vs(t=ne,e){switch(e.type){case pe:break;case $e:case Me:case me:case Ae:return ne;case ge:case ke:case fe:case he:default:return Pe}const{targetIds:n=[],prevTargetIds:s=[]}=e.payload,o=br(n,s);if(!(o.length>0||!xs(n,s)))return ne;const a=s[s.length-1],c=n[n.length-1];return a!==c&&(a&&o.push(a),c&&o.push(c)),o}function js(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Es(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{},s=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(s=s.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),s.forEach(function(o){js(t,o,n[o])})}return t}const Xe={initialSourceClientOffset:null,initialClientOffset:null,clientOffset:null};function _s(t=Xe,e){const{payload:n}=e;switch(e.type){case Ne:case ge:return{initialSourceClientOffset:n.sourceClientOffset,initialClientOffset:n.clientOffset,clientOffset:n.clientOffset};case pe:return ms(t.clientOffset,n.clientOffset)?t:Es({},t,{clientOffset:n.clientOffset});case fe:case he:return Xe;default:return t}}function bs(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function G(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{},s=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(s=s.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),s.forEach(function(o){bs(t,o,n[o])})}return t}const Ss={itemType:null,item:null,sourceId:null,targetIds:[],dropResult:null,didDrop:!1,isSourcePublic:null};function ys(t=Ss,e){const{payload:n}=e;switch(e.type){case ge:return G({},t,{itemType:n.itemType,item:n.item,sourceId:n.sourceId,isSourcePublic:n.isSourcePublic,dropResult:null,didDrop:!1});case ke:return G({},t,{isSourcePublic:!0});case pe:return G({},t,{targetIds:n.targetIds});case me:return t.targetIds.indexOf(n.targetId)===-1?t:G({},t,{targetIds:_r(t.targetIds,n.targetId)});case he:return G({},t,{dropResult:n.dropResult,didDrop:!0,targetIds:[]});case fe:return G({},t,{itemType:null,item:null,sourceId:null,dropResult:null,didDrop:!1,isSourcePublic:null,targetIds:[]});default:return t}}function ws(t=0,e){switch(e.type){case $e:case Me:return t+1;case Ae:case me:return t-1;default:return t}}function Ds(t=0){return t+1}function Rs(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Cs(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{},s=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(s=s.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),s.forEach(function(o){Rs(t,o,n[o])})}return t}function Os(t={},e){return{dirtyHandlerIds:vs(t.dirtyHandlerIds,{type:e.type,payload:Cs({},e.payload,{prevTargetIds:Er(t,"dragOperation.targetIds",[])})}),dragOffset:_s(t.dragOffset,e),refCount:ws(t.refCount,e),dragOperation:ys(t.dragOperation,e),stateId:Ds(t.stateId)}}function Is(t,e=void 0,n={},s=!1){const o=Ts(s),i=new Zr(o,new hs(o)),a=new Yr(o,i),c=t(a,e,n);return a.receiveBackend(c),a}function Ts(t){const e=typeof window<"u"&&window.__REDUX_DEVTOOLS_EXTENSION__;return ot(Os,t&&e&&e({name:"dnd-core",instanceId:"dnd-core"}))}function Ns(t,e){if(t==null)return{};var n=ks(t,e),s,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);for(o=0;o<i.length;o++)s=i[o],!(e.indexOf(s)>=0)&&Object.prototype.propertyIsEnumerable.call(t,s)&&(n[s]=t[s])}return n}function ks(t,e){if(t==null)return{};var n={},s=Object.keys(t),o,i;for(i=0;i<s.length;i++)o=s[i],!(e.indexOf(o)>=0)&&(n[o]=t[o]);return n}let We=0;const de=Symbol.for("__REACT_DND_CONTEXT_INSTANCE__");var Ps=m.memo(function(e){var{children:n}=e,s=Ns(e,["children"]);const[o,i]=$s(s);return m.useEffect(()=>{if(i){const a=dt();return++We,()=>{--We===0&&(a[de]=null)}}},[]),r.jsxRuntimeExports.jsx(st.Provider,{value:o,children:n})});function $s(t){if("manager"in t)return[{dragDropManager:t.manager},!1];const e=Ms(t.backend,t.context,t.options,t.debugMode),n=!t.context;return[e,n]}function Ms(t,e=dt(),n,s){const o=e;return o[de]||(o[de]={dragDropManager:Is(t,e,n,s)}),o[de]}function dt(){return typeof global<"u"?global:window}var As=function t(e,n){if(e===n)return!0;if(e&&n&&typeof e=="object"&&typeof n=="object"){if(e.constructor!==n.constructor)return!1;var s,o,i;if(Array.isArray(e)){if(s=e.length,s!=n.length)return!1;for(o=s;o--!==0;)if(!t(e[o],n[o]))return!1;return!0}if(e.constructor===RegExp)return e.source===n.source&&e.flags===n.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===n.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===n.toString();if(i=Object.keys(e),s=i.length,s!==Object.keys(n).length)return!1;for(o=s;o--!==0;)if(!Object.prototype.hasOwnProperty.call(n,i[o]))return!1;for(o=s;o--!==0;){var a=i[o];if(!t(e[a],n[a]))return!1}return!0}return e!==e&&n!==n};const Bs=r.getDefaultExportFromCjs(As),V=typeof window<"u"?m.useLayoutEffect:m.useEffect;function Ls(t,e,n){const[s,o]=m.useState(()=>e(t)),i=m.useCallback(()=>{const a=e(t);Bs(s,a)||(o(a),n&&n())},[s,t,n]);return V(i),[s,i]}function Hs(t,e,n){const[s,o]=Ls(t,e,n);return V(function(){const a=t.getHandlerId();if(a!=null)return t.subscribeToStateChange(o,{handlerIds:[a]})},[t,o]),s}function gt(t,e,n){return Hs(e,t||(()=>({})),()=>n.reconnect())}function pt(t,e){const n=[];return typeof t!="function"&&n.push(t),m.useMemo(()=>typeof t=="function"?t():t,n)}function Fs(t){return m.useMemo(()=>t.hooks.dragSource(),[t])}function Us(t){return m.useMemo(()=>t.hooks.dragPreview(),[t])}let Ee=!1,_e=!1;class qs{receiveHandlerId(e){this.sourceId=e}getHandlerId(){return this.sourceId}canDrag(){j(!Ee,"You may not call monitor.canDrag() inside your canDrag() implementation. Read more: http://react-dnd.github.io/react-dnd/docs/api/drag-source-monitor");try{return Ee=!0,this.internalMonitor.canDragSource(this.sourceId)}finally{Ee=!1}}isDragging(){if(!this.sourceId)return!1;j(!_e,"You may not call monitor.isDragging() inside your isDragging() implementation. Read more: http://react-dnd.github.io/react-dnd/docs/api/drag-source-monitor");try{return _e=!0,this.internalMonitor.isDraggingSource(this.sourceId)}finally{_e=!1}}subscribeToStateChange(e,n){return this.internalMonitor.subscribeToStateChange(e,n)}isDraggingSource(e){return this.internalMonitor.isDraggingSource(e)}isOverTarget(e,n){return this.internalMonitor.isOverTarget(e,n)}getTargetIds(){return this.internalMonitor.getTargetIds()}isSourcePublic(){return this.internalMonitor.isSourcePublic()}getSourceId(){return this.internalMonitor.getSourceId()}subscribeToOffsetChange(e){return this.internalMonitor.subscribeToOffsetChange(e)}canDragSource(e){return this.internalMonitor.canDragSource(e)}canDropOnTarget(e){return this.internalMonitor.canDropOnTarget(e)}getItemType(){return this.internalMonitor.getItemType()}getItem(){return this.internalMonitor.getItem()}getDropResult(){return this.internalMonitor.getDropResult()}didDrop(){return this.internalMonitor.didDrop()}getInitialClientOffset(){return this.internalMonitor.getInitialClientOffset()}getInitialSourceClientOffset(){return this.internalMonitor.getInitialSourceClientOffset()}getSourceClientOffset(){return this.internalMonitor.getSourceClientOffset()}getClientOffset(){return this.internalMonitor.getClientOffset()}getDifferenceFromInitialOffset(){return this.internalMonitor.getDifferenceFromInitialOffset()}constructor(e){this.sourceId=null,this.internalMonitor=e.getMonitor()}}let be=!1;class zs{receiveHandlerId(e){this.targetId=e}getHandlerId(){return this.targetId}subscribeToStateChange(e,n){return this.internalMonitor.subscribeToStateChange(e,n)}canDrop(){if(!this.targetId)return!1;j(!be,"You may not call monitor.canDrop() inside your canDrop() implementation. Read more: http://react-dnd.github.io/react-dnd/docs/api/drop-target-monitor");try{return be=!0,this.internalMonitor.canDropOnTarget(this.targetId)}finally{be=!1}}isOver(e){return this.targetId?this.internalMonitor.isOverTarget(this.targetId,e):!1}getItemType(){return this.internalMonitor.getItemType()}getItem(){return this.internalMonitor.getItem()}getDropResult(){return this.internalMonitor.getDropResult()}didDrop(){return this.internalMonitor.didDrop()}getInitialClientOffset(){return this.internalMonitor.getInitialClientOffset()}getInitialSourceClientOffset(){return this.internalMonitor.getInitialSourceClientOffset()}getSourceClientOffset(){return this.internalMonitor.getSourceClientOffset()}getClientOffset(){return this.internalMonitor.getClientOffset()}getDifferenceFromInitialOffset(){return this.internalMonitor.getDifferenceFromInitialOffset()}constructor(e){this.targetId=null,this.internalMonitor=e.getMonitor()}}function Vs(t,e,n){const s=n.getRegistry(),o=s.addTarget(t,e);return[o,()=>s.removeTarget(o)]}function Ys(t,e,n){const s=n.getRegistry(),o=s.addSource(t,e);return[o,()=>s.removeSource(o)]}function Oe(t,e,n,s){let o;if(o!==void 0)return!!o;if(t===e)return!0;if(typeof t!="object"||!t||typeof e!="object"||!e)return!1;const i=Object.keys(t),a=Object.keys(e);if(i.length!==a.length)return!1;const c=Object.prototype.hasOwnProperty.bind(e);for(let u=0;u<i.length;u++){const h=i[u];if(!c(h))return!1;const f=t[h],l=e[h];if(o=void 0,o===!1||o===void 0&&f!==l)return!1}return!0}function Ie(t){return t!==null&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}function Gs(t){if(typeof t.type=="string")return;const e=t.type.displayName||t.type.name||"the component";throw new Error(`Only native element nodes can now be passed to React DnD connectors.You can either wrap ${e} into a <div>, or turn it into a drag source or a drop target itself.`)}function Xs(t){return(e=null,n=null)=>{if(!m.isValidElement(e)){const i=e;return t(i,n),i}const s=e;return Gs(s),Ws(s,n?i=>t(i,n):t)}}function ht(t){const e={};return Object.keys(t).forEach(n=>{const s=t[n];if(n.endsWith("Ref"))e[n]=t[n];else{const o=Xs(s);e[n]=()=>o}}),e}function Qe(t,e){typeof t=="function"?t(e):t.current=e}function Ws(t,e){const n=t.ref;return j(typeof n!="string","Cannot connect React DnD to an element with an existing string ref. Please convert it to use a callback ref instead, or wrap it into a <span> or <div>. Read more: https://reactjs.org/docs/refs-and-the-dom.html#callback-refs"),n?m.cloneElement(t,{ref:s=>{Qe(n,s),Qe(e,s)}}):m.cloneElement(t,{ref:e})}class Qs{receiveHandlerId(e){this.handlerId!==e&&(this.handlerId=e,this.reconnect())}get connectTarget(){return this.dragSource}get dragSourceOptions(){return this.dragSourceOptionsInternal}set dragSourceOptions(e){this.dragSourceOptionsInternal=e}get dragPreviewOptions(){return this.dragPreviewOptionsInternal}set dragPreviewOptions(e){this.dragPreviewOptionsInternal=e}reconnect(){const e=this.reconnectDragSource();this.reconnectDragPreview(e)}reconnectDragSource(){const e=this.dragSource,n=this.didHandlerIdChange()||this.didConnectedDragSourceChange()||this.didDragSourceOptionsChange();return n&&this.disconnectDragSource(),this.handlerId?e?(n&&(this.lastConnectedHandlerId=this.handlerId,this.lastConnectedDragSource=e,this.lastConnectedDragSourceOptions=this.dragSourceOptions,this.dragSourceUnsubscribe=this.backend.connectDragSource(this.handlerId,e,this.dragSourceOptions)),n):(this.lastConnectedDragSource=e,n):n}reconnectDragPreview(e=!1){const n=this.dragPreview,s=e||this.didHandlerIdChange()||this.didConnectedDragPreviewChange()||this.didDragPreviewOptionsChange();if(s&&this.disconnectDragPreview(),!!this.handlerId){if(!n){this.lastConnectedDragPreview=n;return}s&&(this.lastConnectedHandlerId=this.handlerId,this.lastConnectedDragPreview=n,this.lastConnectedDragPreviewOptions=this.dragPreviewOptions,this.dragPreviewUnsubscribe=this.backend.connectDragPreview(this.handlerId,n,this.dragPreviewOptions))}}didHandlerIdChange(){return this.lastConnectedHandlerId!==this.handlerId}didConnectedDragSourceChange(){return this.lastConnectedDragSource!==this.dragSource}didConnectedDragPreviewChange(){return this.lastConnectedDragPreview!==this.dragPreview}didDragSourceOptionsChange(){return!Oe(this.lastConnectedDragSourceOptions,this.dragSourceOptions)}didDragPreviewOptionsChange(){return!Oe(this.lastConnectedDragPreviewOptions,this.dragPreviewOptions)}disconnectDragSource(){this.dragSourceUnsubscribe&&(this.dragSourceUnsubscribe(),this.dragSourceUnsubscribe=void 0)}disconnectDragPreview(){this.dragPreviewUnsubscribe&&(this.dragPreviewUnsubscribe(),this.dragPreviewUnsubscribe=void 0,this.dragPreviewNode=null,this.dragPreviewRef=null)}get dragSource(){return this.dragSourceNode||this.dragSourceRef&&this.dragSourceRef.current}get dragPreview(){return this.dragPreviewNode||this.dragPreviewRef&&this.dragPreviewRef.current}clearDragSource(){this.dragSourceNode=null,this.dragSourceRef=null}clearDragPreview(){this.dragPreviewNode=null,this.dragPreviewRef=null}constructor(e){this.hooks=ht({dragSource:(n,s)=>{this.clearDragSource(),this.dragSourceOptions=s||null,Ie(n)?this.dragSourceRef=n:this.dragSourceNode=n,this.reconnectDragSource()},dragPreview:(n,s)=>{this.clearDragPreview(),this.dragPreviewOptions=s||null,Ie(n)?this.dragPreviewRef=n:this.dragPreviewNode=n,this.reconnectDragPreview()}}),this.handlerId=null,this.dragSourceRef=null,this.dragSourceOptionsInternal=null,this.dragPreviewRef=null,this.dragPreviewOptionsInternal=null,this.lastConnectedHandlerId=null,this.lastConnectedDragSource=null,this.lastConnectedDragSourceOptions=null,this.lastConnectedDragPreview=null,this.lastConnectedDragPreviewOptions=null,this.backend=e}}class Zs{get connectTarget(){return this.dropTarget}reconnect(){const e=this.didHandlerIdChange()||this.didDropTargetChange()||this.didOptionsChange();e&&this.disconnectDropTarget();const n=this.dropTarget;if(this.handlerId){if(!n){this.lastConnectedDropTarget=n;return}e&&(this.lastConnectedHandlerId=this.handlerId,this.lastConnectedDropTarget=n,this.lastConnectedDropTargetOptions=this.dropTargetOptions,this.unsubscribeDropTarget=this.backend.connectDropTarget(this.handlerId,n,this.dropTargetOptions))}}receiveHandlerId(e){e!==this.handlerId&&(this.handlerId=e,this.reconnect())}get dropTargetOptions(){return this.dropTargetOptionsInternal}set dropTargetOptions(e){this.dropTargetOptionsInternal=e}didHandlerIdChange(){return this.lastConnectedHandlerId!==this.handlerId}didDropTargetChange(){return this.lastConnectedDropTarget!==this.dropTarget}didOptionsChange(){return!Oe(this.lastConnectedDropTargetOptions,this.dropTargetOptions)}disconnectDropTarget(){this.unsubscribeDropTarget&&(this.unsubscribeDropTarget(),this.unsubscribeDropTarget=void 0)}get dropTarget(){return this.dropTargetNode||this.dropTargetRef&&this.dropTargetRef.current}clearDropTarget(){this.dropTargetRef=null,this.dropTargetNode=null}constructor(e){this.hooks=ht({dropTarget:(n,s)=>{this.clearDropTarget(),this.dropTargetOptions=s,Ie(n)?this.dropTargetRef=n:this.dropTargetNode=n,this.reconnect()}}),this.handlerId=null,this.dropTargetRef=null,this.dropTargetOptionsInternal=null,this.lastConnectedHandlerId=null,this.lastConnectedDropTarget=null,this.lastConnectedDropTargetOptions=null,this.backend=e}}function K(){const{dragDropManager:t}=m.useContext(st);return j(t!=null,"Expected drag drop context"),t}function Js(t,e){const n=K(),s=m.useMemo(()=>new Qs(n.getBackend()),[n]);return V(()=>(s.dragSourceOptions=t||null,s.reconnect(),()=>s.disconnectDragSource()),[s,t]),V(()=>(s.dragPreviewOptions=e||null,s.reconnect(),()=>s.disconnectDragPreview()),[s,e]),s}function Ks(){const t=K();return m.useMemo(()=>new qs(t),[t])}class eo{beginDrag(){const e=this.spec,n=this.monitor;let s=null;return typeof e.item=="object"?s=e.item:typeof e.item=="function"?s=e.item(n):s={},s??null}canDrag(){const e=this.spec,n=this.monitor;return typeof e.canDrag=="boolean"?e.canDrag:typeof e.canDrag=="function"?e.canDrag(n):!0}isDragging(e,n){const s=this.spec,o=this.monitor,{isDragging:i}=s;return i?i(o):n===e.getSourceId()}endDrag(){const e=this.spec,n=this.monitor,s=this.connector,{end:o}=e;o&&o(n.getItem(),n),s.reconnect()}constructor(e,n,s){this.spec=e,this.monitor=n,this.connector=s}}function to(t,e,n){const s=m.useMemo(()=>new eo(t,e,n),[e,n]);return m.useEffect(()=>{s.spec=t},[t]),s}function no(t){return m.useMemo(()=>{const e=t.type;return j(e!=null,"spec.type must be defined"),e},[t])}function ro(t,e,n){const s=K(),o=to(t,e,n),i=no(t);V(function(){if(i!=null){const[c,u]=Ys(i,o,s);return e.receiveHandlerId(c),n.receiveHandlerId(c),u}},[s,e,n,o,i])}function so(t,e){const n=pt(t);j(!n.begin,"useDrag::spec.begin was deprecated in v14. Replace spec.begin() with spec.item(). (see more here - https://react-dnd.github.io/react-dnd/docs/api/use-drag)");const s=Ks(),o=Js(n.options,n.previewOptions);return ro(n,s,o),[gt(n.collect,s,o),Fs(o),Us(o)]}function oo(t){return m.useMemo(()=>t.hooks.dropTarget(),[t])}function io(t){const e=K(),n=m.useMemo(()=>new Zs(e.getBackend()),[e]);return V(()=>(n.dropTargetOptions=t||null,n.reconnect(),()=>n.disconnectDropTarget()),[t]),n}function ao(){const t=K();return m.useMemo(()=>new zs(t),[t])}function co(t){const{accept:e}=t;return m.useMemo(()=>(j(t.accept!=null,"accept must be defined"),Array.isArray(e)?e:[e]),[e])}class uo{canDrop(){const e=this.spec,n=this.monitor;return e.canDrop?e.canDrop(n.getItem(),n):!0}hover(){const e=this.spec,n=this.monitor;e.hover&&e.hover(n.getItem(),n)}drop(){const e=this.spec,n=this.monitor;if(e.drop)return e.drop(n.getItem(),n)}constructor(e,n){this.spec=e,this.monitor=n}}function lo(t,e){const n=m.useMemo(()=>new uo(t,e),[e]);return m.useEffect(()=>{n.spec=t},[t]),n}function go(t,e,n){const s=K(),o=lo(t,e),i=co(t);V(function(){const[c,u]=Vs(i,o,s);return e.receiveHandlerId(c),n.receiveHandlerId(c),u},[s,e,o,n,i.map(a=>a.toString()).join("|")])}function po(t,e){const n=pt(t),s=ao(),o=io(n.options);return go(n,s,o),[gt(n.collect,s,o),oo(o)]}function ft(t){let e=null;return()=>(e==null&&(e=t()),e)}function ho(t,e){return t.filter(n=>n!==e)}function fo(t,e){const n=new Set,s=i=>n.add(i);t.forEach(s),e.forEach(s);const o=[];return n.forEach(i=>o.push(i)),o}class mo{enter(e){const n=this.entered.length,s=o=>this.isNodeInDocument(o)&&(!o.contains||o.contains(e));return this.entered=fo(this.entered.filter(s),[e]),n===0&&this.entered.length>0}leave(e){const n=this.entered.length;return this.entered=ho(this.entered.filter(this.isNodeInDocument),e),n>0&&this.entered.length===0}reset(){this.entered=[]}constructor(e){this.entered=[],this.isNodeInDocument=e}}class xo{initializeExposedProperties(){Object.keys(this.config.exposeProperties).forEach(e=>{Object.defineProperty(this.item,e,{configurable:!0,enumerable:!0,get(){return console.warn(`Browser doesn't allow reading "${e}" until the drop event.`),null}})})}loadDataTransfer(e){if(e){const n={};Object.keys(this.config.exposeProperties).forEach(s=>{const o=this.config.exposeProperties[s];o!=null&&(n[s]={value:o(e,this.config.matchesTypes),configurable:!0,enumerable:!0})}),Object.defineProperties(this.item,n)}}canDrag(){return!0}beginDrag(){return this.item}isDragging(e,n){return n===e.getSourceId()}endDrag(){}constructor(e){this.config=e,this.item={},this.initializeExposedProperties()}}const mt="__NATIVE_FILE__",xt="__NATIVE_URL__",vt="__NATIVE_TEXT__",jt="__NATIVE_HTML__",Ze=Object.freeze(Object.defineProperty({__proto__:null,FILE:mt,HTML:jt,TEXT:vt,URL:xt},Symbol.toStringTag,{value:"Module"}));function Se(t,e,n){const s=e.reduce((o,i)=>o||t.getData(i),"");return s??n}const Te={[mt]:{exposeProperties:{files:t=>Array.prototype.slice.call(t.files),items:t=>t.items,dataTransfer:t=>t},matchesTypes:["Files"]},[jt]:{exposeProperties:{html:(t,e)=>Se(t,e,""),dataTransfer:t=>t},matchesTypes:["Html","text/html"]},[xt]:{exposeProperties:{urls:(t,e)=>Se(t,e,"").split(`
6
- `),dataTransfer:t=>t},matchesTypes:["Url","text/uri-list"]},[vt]:{exposeProperties:{text:(t,e)=>Se(t,e,""),dataTransfer:t=>t},matchesTypes:["Text","text/plain"]}};function vo(t,e){const n=Te[t];if(!n)throw new Error(`native type ${t} has no configuration`);const s=new xo(n);return s.loadDataTransfer(e),s}function ye(t){if(!t)return null;const e=Array.prototype.slice.call(t.types||[]);return Object.keys(Te).filter(n=>{const s=Te[n];return s!=null&&s.matchesTypes?s.matchesTypes.some(o=>e.indexOf(o)>-1):!1})[0]||null}const jo=ft(()=>/firefox/i.test(navigator.userAgent)),Et=ft(()=>!!window.safari);class Je{interpolate(e){const{xs:n,ys:s,c1s:o,c2s:i,c3s:a}=this;let c=n.length-1;if(e===n[c])return s[c];let u=0,h=a.length-1,f;for(;u<=h;){f=Math.floor(.5*(u+h));const d=n[f];if(d<e)u=f+1;else if(d>e)h=f-1;else return s[f]}c=Math.max(0,h);const l=e-n[c],p=l*l;return s[c]+o[c]*l+i[c]*p+a[c]*l*p}constructor(e,n){const{length:s}=e,o=[];for(let d=0;d<s;d++)o.push(d);o.sort((d,x)=>e[d]<e[x]?-1:1);const i=[],a=[];let c,u;for(let d=0;d<s-1;d++)c=e[d+1]-e[d],u=n[d+1]-n[d],i.push(c),a.push(u/c);const h=[a[0]];for(let d=0;d<i.length-1;d++){const x=a[d],g=a[d+1];if(x*g<=0)h.push(0);else{c=i[d];const v=i[d+1],_=c+v;h.push(3*_/((_+v)/x+(_+c)/g))}}h.push(a[a.length-1]);const f=[],l=[];let p;for(let d=0;d<h.length-1;d++){p=a[d];const x=h[d],g=1/i[d],v=x+h[d+1]-p-p;f.push((p-x-v)*g),l.push(v*g*g)}this.xs=e,this.ys=n,this.c1s=h,this.c2s=f,this.c3s=l}}const Eo=1;function _t(t){const e=t.nodeType===Eo?t:t.parentElement;if(!e)return null;const{top:n,left:s}=e.getBoundingClientRect();return{x:s,y:n}}function ue(t){return{x:t.clientX,y:t.clientY}}function _o(t){var e;return t.nodeName==="IMG"&&(jo()||!(!((e=document.documentElement)===null||e===void 0)&&e.contains(t)))}function bo(t,e,n,s){let o=t?e.width:n,i=t?e.height:s;return Et()&&t&&(i/=window.devicePixelRatio,o/=window.devicePixelRatio),{dragPreviewWidth:o,dragPreviewHeight:i}}function So(t,e,n,s,o){const i=_o(e),c=_t(i?t:e),u={x:n.x-c.x,y:n.y-c.y},{offsetWidth:h,offsetHeight:f}=t,{anchorX:l,anchorY:p}=s,{dragPreviewWidth:d,dragPreviewHeight:x}=bo(i,e,h,f),g=()=>{let A=new Je([0,.5,1],[u.y,u.y/f*x,u.y+x-f]).interpolate(p);return Et()&&i&&(A+=(window.devicePixelRatio-1)*x),A},v=()=>new Je([0,.5,1],[u.x,u.x/h*d,u.x+d-h]).interpolate(l),{offsetX:_,offsetY:b}=o,S=_===0||_,D=b===0||b;return{x:S?_:v(),y:D?b:g()}}class yo{get window(){if(this.globalContext)return this.globalContext;if(typeof window<"u")return window}get document(){var e;return!((e=this.globalContext)===null||e===void 0)&&e.document?this.globalContext.document:this.window?this.window.document:void 0}get rootElement(){var e;return((e=this.optionsArgs)===null||e===void 0?void 0:e.rootElement)||this.window}constructor(e,n){this.ownerDocument=null,this.globalContext=e,this.optionsArgs=n}}function wo(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ke(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{},s=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(s=s.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),s.forEach(function(o){wo(t,o,n[o])})}return t}class Do{profile(){var e,n;return{sourcePreviewNodes:this.sourcePreviewNodes.size,sourcePreviewNodeOptions:this.sourcePreviewNodeOptions.size,sourceNodeOptions:this.sourceNodeOptions.size,sourceNodes:this.sourceNodes.size,dragStartSourceIds:((e=this.dragStartSourceIds)===null||e===void 0?void 0:e.length)||0,dropTargetIds:this.dropTargetIds.length,dragEnterTargetIds:this.dragEnterTargetIds.length,dragOverTargetIds:((n=this.dragOverTargetIds)===null||n===void 0?void 0:n.length)||0}}get window(){return this.options.window}get document(){return this.options.document}get rootElement(){return this.options.rootElement}setup(){const e=this.rootElement;if(e!==void 0){if(e.__isReactDndBackendSetUp)throw new Error("Cannot have two HTML5 backends at the same time.");e.__isReactDndBackendSetUp=!0,this.addEventListeners(e)}}teardown(){const e=this.rootElement;if(e!==void 0&&(e.__isReactDndBackendSetUp=!1,this.removeEventListeners(this.rootElement),this.clearCurrentDragSourceNode(),this.asyncEndDragFrameId)){var n;(n=this.window)===null||n===void 0||n.cancelAnimationFrame(this.asyncEndDragFrameId)}}connectDragPreview(e,n,s){return this.sourcePreviewNodeOptions.set(e,s),this.sourcePreviewNodes.set(e,n),()=>{this.sourcePreviewNodes.delete(e),this.sourcePreviewNodeOptions.delete(e)}}connectDragSource(e,n,s){this.sourceNodes.set(e,n),this.sourceNodeOptions.set(e,s);const o=a=>this.handleDragStart(a,e),i=a=>this.handleSelectStart(a);return n.setAttribute("draggable","true"),n.addEventListener("dragstart",o),n.addEventListener("selectstart",i),()=>{this.sourceNodes.delete(e),this.sourceNodeOptions.delete(e),n.removeEventListener("dragstart",o),n.removeEventListener("selectstart",i),n.setAttribute("draggable","false")}}connectDropTarget(e,n){const s=a=>this.handleDragEnter(a,e),o=a=>this.handleDragOver(a,e),i=a=>this.handleDrop(a,e);return n.addEventListener("dragenter",s),n.addEventListener("dragover",o),n.addEventListener("drop",i),()=>{n.removeEventListener("dragenter",s),n.removeEventListener("dragover",o),n.removeEventListener("drop",i)}}addEventListeners(e){e.addEventListener&&(e.addEventListener("dragstart",this.handleTopDragStart),e.addEventListener("dragstart",this.handleTopDragStartCapture,!0),e.addEventListener("dragend",this.handleTopDragEndCapture,!0),e.addEventListener("dragenter",this.handleTopDragEnter),e.addEventListener("dragenter",this.handleTopDragEnterCapture,!0),e.addEventListener("dragleave",this.handleTopDragLeaveCapture,!0),e.addEventListener("dragover",this.handleTopDragOver),e.addEventListener("dragover",this.handleTopDragOverCapture,!0),e.addEventListener("drop",this.handleTopDrop),e.addEventListener("drop",this.handleTopDropCapture,!0))}removeEventListeners(e){e.removeEventListener&&(e.removeEventListener("dragstart",this.handleTopDragStart),e.removeEventListener("dragstart",this.handleTopDragStartCapture,!0),e.removeEventListener("dragend",this.handleTopDragEndCapture,!0),e.removeEventListener("dragenter",this.handleTopDragEnter),e.removeEventListener("dragenter",this.handleTopDragEnterCapture,!0),e.removeEventListener("dragleave",this.handleTopDragLeaveCapture,!0),e.removeEventListener("dragover",this.handleTopDragOver),e.removeEventListener("dragover",this.handleTopDragOverCapture,!0),e.removeEventListener("drop",this.handleTopDrop),e.removeEventListener("drop",this.handleTopDropCapture,!0))}getCurrentSourceNodeOptions(){const e=this.monitor.getSourceId(),n=this.sourceNodeOptions.get(e);return Ke({dropEffect:this.altKeyPressed?"copy":"move"},n||{})}getCurrentDropEffect(){return this.isDraggingNativeItem()?"copy":this.getCurrentSourceNodeOptions().dropEffect}getCurrentSourcePreviewNodeOptions(){const e=this.monitor.getSourceId(),n=this.sourcePreviewNodeOptions.get(e);return Ke({anchorX:.5,anchorY:.5,captureDraggingState:!1},n||{})}isDraggingNativeItem(){const e=this.monitor.getItemType();return Object.keys(Ze).some(n=>Ze[n]===e)}beginDragNativeItem(e,n){this.clearCurrentDragSourceNode(),this.currentNativeSource=vo(e,n),this.currentNativeHandle=this.registry.addSource(e,this.currentNativeSource),this.actions.beginDrag([this.currentNativeHandle])}setCurrentDragSourceNode(e){this.clearCurrentDragSourceNode(),this.currentDragSourceNode=e;const n=1e3;this.mouseMoveTimeoutTimer=setTimeout(()=>{var s;return(s=this.rootElement)===null||s===void 0?void 0:s.addEventListener("mousemove",this.endDragIfSourceWasRemovedFromDOM,!0)},n)}clearCurrentDragSourceNode(){if(this.currentDragSourceNode){if(this.currentDragSourceNode=null,this.rootElement){var e;(e=this.window)===null||e===void 0||e.clearTimeout(this.mouseMoveTimeoutTimer||void 0),this.rootElement.removeEventListener("mousemove",this.endDragIfSourceWasRemovedFromDOM,!0)}return this.mouseMoveTimeoutTimer=null,!0}return!1}handleDragStart(e,n){e.defaultPrevented||(this.dragStartSourceIds||(this.dragStartSourceIds=[]),this.dragStartSourceIds.unshift(n))}handleDragEnter(e,n){this.dragEnterTargetIds.unshift(n)}handleDragOver(e,n){this.dragOverTargetIds===null&&(this.dragOverTargetIds=[]),this.dragOverTargetIds.unshift(n)}handleDrop(e,n){this.dropTargetIds.unshift(n)}constructor(e,n,s){this.sourcePreviewNodes=new Map,this.sourcePreviewNodeOptions=new Map,this.sourceNodes=new Map,this.sourceNodeOptions=new Map,this.dragStartSourceIds=null,this.dropTargetIds=[],this.dragEnterTargetIds=[],this.currentNativeSource=null,this.currentNativeHandle=null,this.currentDragSourceNode=null,this.altKeyPressed=!1,this.mouseMoveTimeoutTimer=null,this.asyncEndDragFrameId=null,this.dragOverTargetIds=null,this.lastClientOffset=null,this.hoverRafId=null,this.getSourceClientOffset=o=>{const i=this.sourceNodes.get(o);return i&&_t(i)||null},this.endDragNativeItem=()=>{this.isDraggingNativeItem()&&(this.actions.endDrag(),this.currentNativeHandle&&this.registry.removeSource(this.currentNativeHandle),this.currentNativeHandle=null,this.currentNativeSource=null)},this.isNodeInDocument=o=>!!(o&&this.document&&this.document.body&&this.document.body.contains(o)),this.endDragIfSourceWasRemovedFromDOM=()=>{const o=this.currentDragSourceNode;o==null||this.isNodeInDocument(o)||(this.clearCurrentDragSourceNode()&&this.monitor.isDragging()&&this.actions.endDrag(),this.cancelHover())},this.scheduleHover=o=>{this.hoverRafId===null&&typeof requestAnimationFrame<"u"&&(this.hoverRafId=requestAnimationFrame(()=>{this.monitor.isDragging()&&this.actions.hover(o||[],{clientOffset:this.lastClientOffset}),this.hoverRafId=null}))},this.cancelHover=()=>{this.hoverRafId!==null&&typeof cancelAnimationFrame<"u"&&(cancelAnimationFrame(this.hoverRafId),this.hoverRafId=null)},this.handleTopDragStartCapture=()=>{this.clearCurrentDragSourceNode(),this.dragStartSourceIds=[]},this.handleTopDragStart=o=>{if(o.defaultPrevented)return;const{dragStartSourceIds:i}=this;this.dragStartSourceIds=null;const a=ue(o);this.monitor.isDragging()&&(this.actions.endDrag(),this.cancelHover()),this.actions.beginDrag(i||[],{publishSource:!1,getSourceClientOffset:this.getSourceClientOffset,clientOffset:a});const{dataTransfer:c}=o,u=ye(c);if(this.monitor.isDragging()){if(c&&typeof c.setDragImage=="function"){const f=this.monitor.getSourceId(),l=this.sourceNodes.get(f),p=this.sourcePreviewNodes.get(f)||l;if(p){const{anchorX:d,anchorY:x,offsetX:g,offsetY:v}=this.getCurrentSourcePreviewNodeOptions(),S=So(l,p,a,{anchorX:d,anchorY:x},{offsetX:g,offsetY:v});c.setDragImage(p,S.x,S.y)}}try{c==null||c.setData("application/json",{})}catch{}this.setCurrentDragSourceNode(o.target);const{captureDraggingState:h}=this.getCurrentSourcePreviewNodeOptions();h?this.actions.publishDragSource():setTimeout(()=>this.actions.publishDragSource(),0)}else if(u)this.beginDragNativeItem(u);else{if(c&&!c.types&&(o.target&&!o.target.hasAttribute||!o.target.hasAttribute("draggable")))return;o.preventDefault()}},this.handleTopDragEndCapture=()=>{this.clearCurrentDragSourceNode()&&this.monitor.isDragging()&&this.actions.endDrag(),this.cancelHover()},this.handleTopDragEnterCapture=o=>{if(this.dragEnterTargetIds=[],this.isDraggingNativeItem()){var i;(i=this.currentNativeSource)===null||i===void 0||i.loadDataTransfer(o.dataTransfer)}if(!this.enterLeaveCounter.enter(o.target)||this.monitor.isDragging())return;const{dataTransfer:c}=o,u=ye(c);u&&this.beginDragNativeItem(u,c)},this.handleTopDragEnter=o=>{const{dragEnterTargetIds:i}=this;if(this.dragEnterTargetIds=[],!this.monitor.isDragging())return;this.altKeyPressed=o.altKey,i.length>0&&this.actions.hover(i,{clientOffset:ue(o)}),i.some(c=>this.monitor.canDropOnTarget(c))&&(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect=this.getCurrentDropEffect()))},this.handleTopDragOverCapture=o=>{if(this.dragOverTargetIds=[],this.isDraggingNativeItem()){var i;(i=this.currentNativeSource)===null||i===void 0||i.loadDataTransfer(o.dataTransfer)}},this.handleTopDragOver=o=>{const{dragOverTargetIds:i}=this;if(this.dragOverTargetIds=[],!this.monitor.isDragging()){o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect="none");return}this.altKeyPressed=o.altKey,this.lastClientOffset=ue(o),this.scheduleHover(i),(i||[]).some(c=>this.monitor.canDropOnTarget(c))?(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect=this.getCurrentDropEffect())):this.isDraggingNativeItem()?o.preventDefault():(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect="none"))},this.handleTopDragLeaveCapture=o=>{this.isDraggingNativeItem()&&o.preventDefault(),this.enterLeaveCounter.leave(o.target)&&(this.isDraggingNativeItem()&&setTimeout(()=>this.endDragNativeItem(),0),this.cancelHover())},this.handleTopDropCapture=o=>{if(this.dropTargetIds=[],this.isDraggingNativeItem()){var i;o.preventDefault(),(i=this.currentNativeSource)===null||i===void 0||i.loadDataTransfer(o.dataTransfer)}else ye(o.dataTransfer)&&o.preventDefault();this.enterLeaveCounter.reset()},this.handleTopDrop=o=>{const{dropTargetIds:i}=this;this.dropTargetIds=[],this.actions.hover(i,{clientOffset:ue(o)}),this.actions.drop({dropEffect:this.getCurrentDropEffect()}),this.isDraggingNativeItem()?this.endDragNativeItem():this.monitor.isDragging()&&this.actions.endDrag(),this.cancelHover()},this.handleSelectStart=o=>{const i=o.target;typeof i.dragDrop=="function"&&(i.tagName==="INPUT"||i.tagName==="SELECT"||i.tagName==="TEXTAREA"||i.isContentEditable||(o.preventDefault(),i.dragDrop()))},this.options=new yo(n,s),this.actions=e.getActions(),this.monitor=e.getMonitor(),this.registry=e.getRegistry(),this.enterLeaveCounter=new mo(this.isNodeInDocument)}}const Ro=function(e,n,s){return new Do(e,n,s)},Co="_layers_62wod_1",Oo="_block_62wod_8",Io="_dragging_62wod_23",To="_active_62wod_31",No="_add_62wod_35",ko="_button_62wod_47",Po="_empty_62wod_60",$o="_title_62wod_72",Mo="_icon_62wod_79",Ao="_text_62wod_83",Bo="_highlight_62wod_89",J={layers:Co,block:Oo,dragging:Io,active:To,add:No,button:ko,empty:Po,title:$o,icon:Mo,text:Ao,highlight:Bo},Lo="_block_1d6lb_1",et={block:Lo},Ho=()=>{const{setCurrentBlock:t}=r.useLayersStore(),{activeBlock:e}=r.usePreviewStore();function n(s){t(s)}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(et.block,{[et.active]:e==="header"}),onClick:()=>n("header"),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"cards"}),r.jsxRuntimeExports.jsx("span",{children:"Header"})]})},Fo="_block_1d6lb_1",tt={block:Fo},Uo=()=>{const{activeBlock:t}=r.usePreviewStore(),{setCurrentBlock:e}=r.useLayersStore();function n(s){e(s)}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(tt.block,{[tt.active]:t==="footer"}),onClick:()=>n("footer"),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"cards"}),r.jsxRuntimeExports.jsx("span",{children:"Footer"})]})},qo=({id:t,name:e,index:n,moveBlock:s,onClick:o})=>{const{currentPage:i,pages:a}=r.usePagesStore(),{activeBlock:c}=r.usePreviewStore(),{showPreview:u,hidePreview:h,showModal:f,hideModal:l,clearHideTimeout:p,startHideTimeout:d,hoverBlockId:x,isModalVisible:g}=r.useSubmodalStore(),{setPositionBlock:v}=r.useLayersStore(),[_,b]=m.useState(!1),S=()=>{g&&l(),u(t),b(!0),p()},D=E=>{E.stopPropagation(),h(),f(t),p(),v(n+1)},M=()=>{g?d():(b(!1),h())};m.useEffect(()=>{g||b(!1)},[g]);const[,A]=po({accept:"block",hover(E){E.index!==n&&(s(a[i].name,E.index,n),E.index=n)}}),[{isDragging:O},H]=so({type:"block",item:{id:t,index:n},collect:E=>({isDragging:E.isDragging()})});return r.jsxRuntimeExports.jsxs("div",{ref:E=>H(A(E)),className:r.clx(J.block,{[J.dragging]:O,[J.active]:!O&&c===t}),onClick:()=>o(t),onMouseEnter:S,onMouseLeave:M,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"cards"}),r.jsxRuntimeExports.jsx("span",{children:e}),(_||x===t)&&!O&&r.jsxRuntimeExports.jsx("div",{className:J.add,children:r.jsxRuntimeExports.jsx("button",{className:J.button,onClick:E=>D(E),children:r.jsxRuntimeExports.jsx(r.Icon,{name:"plus",fill:"#fff"})})})]})},zo=()=>{const{blocks:t,setCurrentBlock:e,moveBlock:n}=r.useLayersStore(),{currentPage:s,pages:o}=r.usePagesStore();function i(a){e(a)}return r.jsxRuntimeExports.jsxs("div",{className:J.layers,children:[r.jsxRuntimeExports.jsx(Ho,{}),r.jsxRuntimeExports.jsx(Ps,{backend:Ro,children:r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:t[o[s].name]&&Object.keys(t[o[s].name]).map((a,c)=>r.jsxRuntimeExports.jsx(qo,{id:a,name:t[o[s].name][a].name,index:c,moveBlock:n,onClick:i},a))})}),r.jsxRuntimeExports.jsx(Uo,{})]})},Vo=({isHeader:t})=>{const{header:e,footer:n}=r.useLayersStore(),{pageContext:s}=r.usePagesStore();return console.log(e),t?e==null?void 0:e.renderSettings(s):n==null?void 0:n.renderSettings(s)},Yo=()=>{const{settings:t}=r.useSettingsStore();return t==null?void 0:t.renderSettings()},Go="_theme_1xj36_1",Xo="_block_1xj36_6",Wo="_name_1xj36_20",we={theme:Go,block:Xo,name:Wo},Qo=()=>{const{setActiveBlock:t}=r.useThemeSettingsStore();function e(n){t(n)}return r.jsxRuntimeExports.jsx("div",{className:we.theme,children:Dt.map(n=>r.jsxRuntimeExports.jsxs("div",{onClick:()=>e(n),className:r.clx(we.block),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:n.icon}),r.jsxRuntimeExports.jsx("span",{className:we.name,children:n.name}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-right"})]},n.icon))})},Zo="_back_14yda_1",Jo="_render_14yda_8",Ko="_open_14yda_23",ei="_close_14yda_50",ti="_clicked_14yda_54",ni="_title_14yda_58",ri="_button_14yda_65",si="_loading_14yda_70",oi="_settings_14yda_74",ii="_buttons_14yda_80",ai="_deleteButton_14yda_86",B={back:Zo,render:Jo,open:Ko,close:ei,clicked:ti,title:ni,button:ri,loading:si,settings:oi,buttons:ii,deleteButton:ai},ci=({block:t})=>{if(!t)return;const{blocks:e,sourceBlocks:n,activeBlock:s}=r.useBlocksStore(),{currentBlock:o}=r.useLayersStore();if(!s&&!o)return null;if(t!=null&&t.name){const i=e[t.name],a={...t.value};for(const c in a)i[c]=a[c];return i.renderSettings()}else{const i=n[s];for(const a in i)t[a]={...i[a]};return t.renderSettings()}},ui=t=>{var H;const{isAdd:e}=t,[n,s]=m.useState(!1),{setActiveBlock:o}=r.useNavbarStore(),{blocks:i,activeBlock:a,setActiveBlock:c}=r.useBlocksStore(),{blocks:u,addBlock:h,editBlock:f,currentBlock:l,setCurrentBlock:p,removeBlock:d,setPositionBlock:x,setHeader:g,setFooter:v,header:_,footer:b}=r.useLayersStore(),{currentPage:S,pages:D}=r.usePagesStore();function M(){c(null),p(null),setTimeout(()=>{s(!1)},150)}function A(){M(),o({name:"Layers",icon:"layers"})}function O(){return e?i[a]:i[u[D[S].name]&&u[D[S].name][l]?u[D[S].name][l].name:"null"]}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(B.render,{[B.open]:l,[B.close]:!l,[B.clicked]:n}),children:[r.jsxRuntimeExports.jsxs("div",{className:B.back,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:M}),r.jsxRuntimeExports.jsx("h3",{className:B.title,children:a||u[D[S].name]&&((H=u[D[S].name][l])==null?void 0:H.name)||l&&$(l)||"Loading"})]}),r.jsxRuntimeExports.jsxs("div",{className:B.settings,children:[l&&O()&&r.jsxRuntimeExports.jsx(ci,{block:e?O():u[D[S].name][l]}),l&&["header","footer"].includes(l)&&r.jsxRuntimeExports.jsx(Vo,{isHeader:l==="header"}),!l&&r.jsxRuntimeExports.jsx("div",{className:B.loading,children:"Loading"})]}),r.jsxRuntimeExports.jsxs("div",{className:B.buttons,children:[r.jsxRuntimeExports.jsx(r.Button,{style:{width:"100%"},onClick:()=>{if(s(!0),["header","active"].includes(l))l==="header"?g(_):v(b);else{const E=O();e?(h(D[S].name,{name:a,value:{...E}}),x(null)):f(D[S].name,l,{name:u[D[S].name][l].name,value:{...E}})}A()},children:e?"Add Section":"Edit Section"}),!e&&!["header","footer"].includes(l)&&r.jsxRuntimeExports.jsx("button",{onClick:()=>{s(!0),d(D[S].name,l),setTimeout(()=>{s(!1)},150)},className:B.deleteButton,children:r.jsxRuntimeExports.jsx(r.Icon,{name:"trash",hoverable:!0})})]})]})},li="_settings_1r85j_1",di="_open_1r85j_16",gi="_close_1r85j_20",pi="_header_1r85j_24",hi="_title_1r85j_30",fi="_addButton_1r85j_37",te={settings:li,open:di,close:gi,header:pi,title:hi,addButton:fi},mi="_wrapper_n1a7x_1",xi="_category_n1a7x_5",vi="_categoryTitle_n1a7x_10",ji="_color_n1a7x_16",Ei="_content_n1a7x_24",_i="_preview_n1a7x_32",X={wrapper:mi,category:xi,categoryTitle:vi,color:ji,content:Ei,preview:_i},bi=()=>{const{themeSettings:t,updateColor:e}=r.useThemeSettingsStore();async function n(o,i,a){e(o,i,a)}const s=m.useMemo(()=>{const o={};return Object.entries(t.colors).forEach(([i,a])=>{Object.entries(a).forEach(([c,u])=>{o[u]||(o[u]=[]),o[u].push(`${i}-${c}`)})}),Object.keys(o).filter(i=>o[i].length>1)},[t.colors]);return r.jsxRuntimeExports.jsx("div",{className:X.wrapper,children:Object.entries(t.colors).map(([o,i])=>r.jsxRuntimeExports.jsxs("div",{className:X.category,children:[r.jsxRuntimeExports.jsx("h2",{className:X.categoryTitle,children:$(o)}),Object.entries(i).map(([a,c])=>r.jsxRuntimeExports.jsxs("div",{className:X.color,children:[r.jsxRuntimeExports.jsxs("div",{className:X.content,children:[r.jsxRuntimeExports.jsx("div",{className:X.preview,style:{background:c}}),r.jsxRuntimeExports.jsx(r.ColorPicker,{title:$(a),initialColor:c,onChange:u=>n(o,a,u)})]}),s.includes(c)&&r.jsxRuntimeExports.jsx(r.Tip,{type:"warning",message:"To avoid contrast problems, please use a different color",style:{marginBottom:12}})]},a))]},o))})},Si="_wrapper_kb55x_2",yi="_category_kb55x_6",wi="_categoryTitle_kb55x_11",Di="_color_kb55x_17",Ri="_name_kb55x_23",Ci="_content_kb55x_28",Oi="_label_kb55x_34",Ii="_input_kb55x_45",Ti="_title_kb55x_71",Ni="_field_kb55x_79",ki="_alignments_kb55x_89",Pi="_lineField_kb55x_95",$i="_style_kb55x_101",Mi="_header_kb55x_108",L={wrapper:Si,category:yi,categoryTitle:wi,color:Di,name:Ri,content:Ci,label:Oi,input:Ii,title:Ti,field:Ni,alignments:ki,lineField:Pi,style:$i,header:Mi},Ai=["left","center","right"],Bi=["solid","dashed"],le=t=>{const{title:e,children:n,rightAddon:s}=t;return r.jsxRuntimeExports.jsxs("div",{className:L.field,children:[r.jsxRuntimeExports.jsxs("div",{className:L.header,children:[r.jsxRuntimeExports.jsx("h4",{children:e}),s]}),n]})},Li=()=>{const{themeSettings:t,updateInput:e}=r.useThemeSettingsStore(),n=m.useMemo(()=>t.inputs,[t]),s=(i,a,c)=>{e(i,a,c)},o=i=>a=>{e(i,a,"color")};return r.jsxRuntimeExports.jsxs("div",{className:L.wrapper,children:[r.jsxRuntimeExports.jsxs(le,{title:"General",children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Height (px)",value:String(n.general.height),onChange:i=>s("general",i,"height"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Input,{label:"Style name",value:n.general.name,onChange:i=>s("general",i,"name")}),r.jsxRuntimeExports.jsx(r.Select,{label:"Font Size (px)",onChange:i=>s("general",i,"size"),value:String(n.general.size),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.general.color),onChange:o("general"),title:"Font Color",labelStyle:"secondary"})]}),r.jsxRuntimeExports.jsxs(le,{title:"Field Fill",rightAddon:r.jsxRuntimeExports.jsx("div",{className:L.switch,children:r.jsxRuntimeExports.jsx(r.Switch,{onChange:i=>s("field",i,"active"),current:n.field.active})}),children:[r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.field.color),onChange:o("field"),title:"Color",labelStyle:"secondary"}),r.jsxRuntimeExports.jsx(r.Input,{label:"Opacity (%)",value:String(n.field.opacity),onChange:i=>s("field",i,"opacity"),type:"number",min:0})]}),r.jsxRuntimeExports.jsxs(le,{title:"Border",rightAddon:r.jsxRuntimeExports.jsx("div",{className:L.switch,children:r.jsxRuntimeExports.jsx(r.Switch,{onChange:i=>s("border",i,"active"),current:n.border.active})}),children:[r.jsxRuntimeExports.jsxs("div",{className:L.lineField,children:[r.jsxRuntimeExports.jsxs("div",{className:L.style,children:[r.jsxRuntimeExports.jsx("span",{className:L.title,children:"Style"}),r.jsxRuntimeExports.jsx(r.Picker,{items:Bi,selectedItem:n.border.style,onSelect:i=>s("border",i,"style"),getIconName:i=>`border-${i}`})]}),r.jsxRuntimeExports.jsx(r.Input,{label:"Radius (px)",value:String(n.border.radius),onChange:i=>s("border",i,"radius"),type:"number",min:0})]}),r.jsxRuntimeExports.jsx(r.Input,{label:"Thickness (px)",value:String(n.border.thickness),onChange:i=>s("border",i,"thickness"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.border.color),onChange:o("border"),title:"Color",labelStyle:"secondary"})]}),r.jsxRuntimeExports.jsxs(le,{title:"Label",children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Line Height (px)",value:String(n.label.height),onChange:i=>s("label",i,"height"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Select,{label:"Font Size (px)",onChange:i=>s("label",i,"size"),value:String(n.label.size),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.label.color),onChange:o("label"),title:"Color",labelStyle:"secondary"}),r.jsxRuntimeExports.jsxs("div",{className:L.alignments,children:[r.jsxRuntimeExports.jsx("h4",{className:L.title,children:"Alignment Type"}),r.jsxRuntimeExports.jsx(r.Picker,{items:Ai,selectedItem:n.label.alignment,onSelect:i=>s("label",i,"alignment"),getIconName:i=>`align-${i}`})]})]})]})},Hi="_wrapper_k9on2_1",Fi="_category_k9on2_5",Ui="_categoryTitle_k9on2_10",qi="_font_k9on2_16",zi="_content_k9on2_36",Vi="_icon_k9on2_42",Yi="_paragraph_k9on2_51",Gi="_deleteIcon_k9on2_55",Xi="_iconButton_k9on2_62",q={wrapper:Hi,category:Fi,categoryTitle:Ui,font:qi,content:zi,icon:Vi,paragraph:Yi,deleteIcon:Gi,iconButton:Xi},Wi=t=>{const{font:e,size:n,id:s,category:o}=t,{setActiveFont:i}=r.useThemeSettingsStore();return r.jsxRuntimeExports.jsxs("div",{className:q.font,onClick:()=>i(s),children:[r.jsxRuntimeExports.jsx("div",{className:r.clx(q.icon,{[q.paragraph]:o==="paragraph"}),children:r.jsxRuntimeExports.jsx(r.Icon,{name:o})}),r.jsxRuntimeExports.jsxs("div",{className:q.content,children:[r.jsxRuntimeExports.jsx("h2",{className:q.categoryTitle,children:$(s)}),r.jsxRuntimeExports.jsx("span",{className:q.value,children:`${e}, ${n}px`})]})]})},Qi=()=>{const{themeSettings:t,setActiveFont:e,activeBlock:n}=r.useThemeSettingsStore();m.useEffect(()=>(s(),()=>{s()}),[]);function s(){e(null)}if(n!=null&&n.name)return r.jsxRuntimeExports.jsx("div",{className:q.wrapper,children:Object.entries(t.fonts).map(([o,i])=>r.jsxRuntimeExports.jsxs("div",{className:q.category,children:[r.jsxRuntimeExports.jsx("h2",{className:q.categoryTitle,children:$(o)}),Object.entries(i).map(([a,c])=>r.jsxRuntimeExports.jsx(Wi,{id:a,category:o,...c},a))]},o))})},Zi="_wrapper_94fpv_1",Ji="_open_94fpv_16",Ki="_close_94fpv_20",ea="_header_94fpv_24",ta="_title_94fpv_31",na="_options_94fpv_37",ra="_clicked_94fpv_44",W={wrapper:Zi,open:Ji,close:Ki,header:ea,title:ta,options:na,clicked:ra},sa=()=>{const{activeBlock:t,setActiveFont:e,activeFont:n,themeSettings:s,updateFont:o}=r.useThemeSettingsStore(),{fonts:i}=r.useFontsStore(),[a,c]=m.useState(null);function u(){e(null)}function h(l,p){a&&n&&o(a,n,p,l)}const f=m.useMemo(()=>n?s.fonts.heading[n]?(c("heading"),s.fonts.heading[n]):s.fonts.paragraph[n]?(c("paragraph"),s.fonts.paragraph[n]):(c(null),null):null,[n,s]);return r.jsxRuntimeExports.jsxs("div",{className:r.clx(W.wrapper,{[W.open]:(t==null?void 0:t.name)==="Fonts"&&n,[W.close]:(t==null?void 0:t.name)!=="Fonts"||!n}),children:[r.jsxRuntimeExports.jsxs("div",{className:W.header,onClick:u,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0}),r.jsxRuntimeExports.jsx("span",{className:W.title,children:"Font Style"})]}),n&&f&&r.jsxRuntimeExports.jsxs("div",{className:W.options,children:[r.jsxRuntimeExports.jsx(r.Select,{label:"Font",value:f.font,onChange:l=>h(l,"font"),options:[...i.filter(l=>l!==f.font)]}),r.jsxRuntimeExports.jsx(r.Select,{label:"Size",value:String(f.size),onChange:l=>h(l,"size"),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.Select,{label:"Weight",value:String(f.weight),onChange:l=>h(l,"weight"),options:r.weightOptions})]})]})},oa="_wrapper_94fpv_1",ia="_open_94fpv_16",aa="_close_94fpv_20",ca="_header_94fpv_24",ua="_title_94fpv_31",la="_options_94fpv_37",da="_clicked_94fpv_44",Q={wrapper:oa,open:ia,close:aa,header:ca,title:ua,options:la,clicked:da},bt=()=>{const{activeBlock:t,themeSettings:e,updateBorder:n,setActiveBlock:s}=r.useThemeSettingsStore();function o(c,u){n(u,c)}function i(){s(null)}const a=m.useMemo(()=>e.borders,[e]);return r.jsxRuntimeExports.jsxs("div",{className:r.clx(Q.wrapper,{[Q.open]:(t==null?void 0:t.name)==="Borders",[Q.close]:(t==null?void 0:t.name)!=="Borders"}),children:[r.jsxRuntimeExports.jsxs("div",{className:Q.header,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:i}),r.jsxRuntimeExports.jsx("span",{className:Q.title,children:"Borders Style"})]}),r.jsxRuntimeExports.jsxs("div",{className:Q.options,children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Border Radius (px)",value:String(a.radius),onChange:c=>o(Number(c),"radius"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Input,{label:"Border Thickness (px)",value:String(a.thickness),onChange:c=>o(Number(c),"thickness"),type:"number",min:0})]})]})},ga="_wrapper_1j33r_1",pa="_open_1j33r_16",ha="_close_1j33r_20",fa="_header_1j33r_24",ma="_title_1j33r_31",xa="_options_1j33r_37",va="_clicked_1j33r_44",ja="_label_1j33r_48",Ea="_alignments_1j33r_55",_a="_blocks_1j33r_61",ba="_alignment_1j33r_55",Sa="_active_1j33r_75",k={wrapper:ga,open:pa,close:ha,header:fa,title:ma,options:xa,clicked:va,label:ja,alignments:Ea,blocks:_a,alignment:ba,active:Sa},ya=["left","center","right"],St=()=>{const{activeBlock:t,themeSettings:e,updateButton:n,setActiveBlock:s}=r.useThemeSettingsStore();function o(c,u){n(u,c)}function i(){s(null)}const a=m.useMemo(()=>e.buttons,[e]);return r.jsxRuntimeExports.jsxs("div",{className:r.clx(k.wrapper,{[k.open]:(t==null?void 0:t.name)==="Buttons",[k.close]:(t==null?void 0:t.name)!=="Buttons"}),children:[r.jsxRuntimeExports.jsxs("div",{className:k.header,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:i}),r.jsxRuntimeExports.jsx("span",{className:k.title,children:"Buttons Style"})]}),a&&r.jsxRuntimeExports.jsxs("div",{className:k.options,children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Height (px)",value:String(a.height),onChange:c=>o(c,"height"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Select,{label:"Font Size (px)",value:String(a.size),onChange:c=>o(c,"size"),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.Input,{label:"Border Radius (px)",value:String(a.radius),onChange:c=>o(Number(c),"radius"),type:"number",min:0}),r.jsxRuntimeExports.jsxs("div",{className:k.alignments,children:[r.jsxRuntimeExports.jsx("h4",{className:k.label,children:"Alignment Type"}),r.jsxRuntimeExports.jsx("div",{className:k.blocks,children:ya.map(c=>r.jsxRuntimeExports.jsx("div",{className:r.clx(k.alignment,{[k.active]:a.alignment===c}),onClick:()=>{o(c,"alignment")},children:r.jsxRuntimeExports.jsx(r.Icon,{name:`align-${c}`,fill:a.alignment===c?"#252525":"#757575"})},c))})]})]})]})},wa=()=>{const{activeBlock:t}=r.useThemeSettingsStore();return r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[(t==null?void 0:t.name)==="Fonts"&&r.jsxRuntimeExports.jsx(sa,{}),(t==null?void 0:t.name)==="Borders"&&r.jsxRuntimeExports.jsx(bt,{}),(t==null?void 0:t.name)==="Buttons"&&r.jsxRuntimeExports.jsx(St,{})]})},Da=()=>{const{activeBlock:t,setActiveBlock:e}=r.useThemeSettingsStore(),{activeBlock:n}=r.useNavbarStore();function s(){e(null)}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(te.settings,{[te.open]:t,[te.close]:!t||n.name!=="Theme"}),children:[r.jsxRuntimeExports.jsxs("div",{className:te.header,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:s}),r.jsxRuntimeExports.jsx("span",{className:te.title,children:t==null?void 0:t.name})]}),(t==null?void 0:t.name)==="Fonts"&&r.jsxRuntimeExports.jsx(Qi,{}),(t==null?void 0:t.name)==="Colors"&&r.jsxRuntimeExports.jsx(bi,{}),(t==null?void 0:t.name)==="Inputs"&&r.jsxRuntimeExports.jsx(Li,{}),(t==null?void 0:t.name)==="Borders"&&r.jsxRuntimeExports.jsx(bt,{}),(t==null?void 0:t.name)==="Borders"&&r.jsxRuntimeExports.jsx(St,{}),r.jsxRuntimeExports.jsx(wa,{})]})},Ra=()=>{const{activeBlock:t}=r.useNavbarStore(),{activeBlock:e}=r.useBlocksStore();function n(){switch(t.name){case"Layers":return"Layers";case"Add":return"Add Sections";case"Theme":return"Theme Settings";case"Settings":return"Settings"}}return r.jsxRuntimeExports.jsxs("div",{className:Fe.sidebar,children:[r.jsxRuntimeExports.jsx("h3",{className:Fe.title,children:n()}),t.name==="Layers"&&r.jsxRuntimeExports.jsx(zo,{}),t.name==="Add"&&r.jsxRuntimeExports.jsx(rt,{}),r.jsxRuntimeExports.jsx(ui,{isAdd:!!e}),r.jsxRuntimeExports.jsx(Da,{}),t.name==="Theme"&&r.jsxRuntimeExports.jsx(Qo,{}),t.name==="Settings"&&r.jsxRuntimeExports.jsx(Yo,{})]})},Ca="_wrapper_jjfwh_1",Oa="_header_jjfwh_12",Ia="_content_jjfwh_21",Ta="_buttons_jjfwh_29",Na="_cancel_jjfwh_35",ka="_label_jjfwh_40",Pa="_description_jjfwh_41",$a="_preview_jjfwh_49",Ma="_block_jjfwh_55",Aa="_slug_jjfwh_63",Ba="_title_jjfwh_69",P={wrapper:Ca,header:Oa,content:Ia,buttons:Ta,cancel:Na,label:ka,description:Pa,preview:$a,block:Ma,slug:Aa,title:Ba},La=()=>{var O,H,E,w,R,C;const{setIsOpenModal:t,pages:e,createPage:n,updatePage:s,isEdit:o,setIsEdit:i,editedPage:a,setEditedPage:c}=r.usePagesStore(),{createPage:u,updatePage:h}=r.useLayersStore(),[f,l]=m.useState(a?(O=e[a])==null?void 0:O.path:""),[p,d]=m.useState(a?(H=e[a])==null?void 0:H.name:""),[x,g]=m.useState(a?(E=e[a])==null?void 0:E.seo.description:""),[v,_]=m.useState(a?(w=e[a])==null?void 0:w.visibility:"public");function b(){l(""),d(""),g(""),_("public"),i(!1),c(null)}function S(){b(),t(!1)}function D(y){return y[0]==="/"?y:"/"+y}function M(){n({path:D(f),name:p||f,icon:"file",seo:{title:p,description:x},visibility:v}),u(p),S()}function A(){h(e[a].name,p||f),s(a,{path:D(f),name:p||f,icon:e[a].icon||"file",seo:{title:p,description:x},visibility:v}),S()}return r.jsxRuntimeExports.jsxs("div",{className:P.wrapper,onClick:y=>y.stopPropagation(),children:[r.jsxRuntimeExports.jsxs("div",{className:P.header,children:[r.jsxRuntimeExports.jsxs("h2",{children:[o?"Edit":"Create"," Blank Page"]}),r.jsxRuntimeExports.jsx(r.Icon,{name:"x",fill:"#757575",hoverable:!0,onClick:S})]}),r.jsxRuntimeExports.jsxs("div",{className:P.content,children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Page Slug",onChange:y=>l(y),value:f,placeholder:"path-to-page",disabled:!!(a&&((R=e[a])!=null&&R.name)&&r.defaultPageNames.includes(e[a].name)),required:!0,regex:"^.+$"}),r.jsxRuntimeExports.jsx(r.Input,{label:"Page Title",onChange:y=>d(y),value:p,placeholder:"Contact us",disabled:!!(a&&((C=e[a])!=null&&C.name)&&r.defaultPageNames.includes(e[a].name))}),r.jsxRuntimeExports.jsx(r.Textarea,{label:"Description",onChange:y=>g(y),value:x,placeholder:"Contact us at any time of the day or night. You are always welcome",maxLength:150}),r.jsxRuntimeExports.jsx(r.Radio,{label:"Visibility",defaultValue:v,options:[{value:"public",label:"Public"},{value:"private",label:"Private"}],onChange:y=>_(y)}),r.jsxRuntimeExports.jsxs("div",{className:P.preview,children:[r.jsxRuntimeExports.jsx("span",{className:P.label,children:"Preview"}),r.jsxRuntimeExports.jsxs("div",{className:P.block,children:[r.jsxRuntimeExports.jsx("span",{className:P.slug,children:f||"yoursite.url"}),r.jsxRuntimeExports.jsx("span",{className:P.title,children:p||"My Blank Page"}),r.jsxRuntimeExports.jsx("span",{className:P.description,children:x||"It is My Description"})]})]})]}),r.jsxRuntimeExports.jsxs("div",{className:P.buttons,children:[r.jsxRuntimeExports.jsx(r.Button,{className:P.cancel,onClick:S,children:"Cancel"}),r.jsxRuntimeExports.jsx(r.Button,{onClick:o?A:M,disabled:f.length===0,children:o?"Update":"Create"})]})]})},Ha="_layout_kjedu_1",Fa="_main_kjedu_8",Ua="_content_kjedu_15",De={layout:Ha,main:Fa,content:Ua},qa=()=>{const{isOpenModal:t,setIsOpenModal:e}=r.usePagesStore(),{openModal:n,setOpenModal:s}=r.useChooseImageStore();return r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsxs("div",{className:De.layout,children:[r.jsxRuntimeExports.jsx(vn,{}),r.jsxRuntimeExports.jsxs("main",{className:De.main,children:[r.jsxRuntimeExports.jsx(ln,{}),r.jsxRuntimeExports.jsxs("div",{className:De.content,children:[r.jsxRuntimeExports.jsx(Ra,{}),r.jsxRuntimeExports.jsx(lr,{})]})]})]}),t&&r.jsxRuntimeExports.jsx(r.Modal,{close:e,children:r.jsxRuntimeExports.jsx(La,{})}),n&&r.jsxRuntimeExports.jsx(r.Modal,{close:s,children:r.jsxRuntimeExports.jsx(r.ChooseImageModal,{})})]})};async function Z(t,e){const n=localStorage.getItem("shopId")||void 0,s=`${Rt}/${t}/builder/shops/${n}/${e}`,o=localStorage.getItem("accessToken")||void 0;return(await r.axios.get(s,{headers:{Authorization:`Bearer ${o}`}})).data}async function za(){try{const[t,e,n,s,o,i]=await Promise.allSettled([Z("v1","general"),Z("v1","faqs"),Z("v1","listings"),Z("v1","products"),Z("v1","reviews"),Z("v1","categories")]);return{general:t,faqs:e,listings:n,products:s,reviews:o,categories:i}}catch(t){throw console.error("Error fetching page data:",t),t}}async function Va(){try{const{data:t}=await r.axios.get(`${Ct}?key=undefined`);return t.items}catch(t){throw console.error("Error fetching page data:",t),t}}const Ya=t=>{const{blocks:e,settings:n,header:s,footer:o}=t,{setBlocks:i,setSourceBlocks:a}=r.useBlocksStore(),{fonts:c,setFonts:u}=r.useFontsStore(),{setSettings:h}=r.useSettingsStore(),{setPageContext:f}=r.usePagesStore(),{setHeader:l,setFooter:p}=r.useLayersStore();return m.useEffect(()=>{const d={};Object.keys(e).map(g=>{d[g]={...e[g]}}),l(s),p(o),h(n),a(d),i(e),(async()=>{if(c.length===0){const _=await Va();u([..._.map(b=>b.family)])}let g={listings:void 0,products:void 0,reviews:void 0,categories:void 0,faqs:void 0,general:void 0};const v=await za();Object.keys(v).map(_=>{const b=_;g[b]=v[b].value.data}),f(g)})()},[]),r.jsxRuntimeExports.jsx(qa,{})};exports.Builder=Ya;
6
+ `),dataTransfer:t=>t},matchesTypes:["Url","text/uri-list"]},[vt]:{exposeProperties:{text:(t,e)=>Se(t,e,""),dataTransfer:t=>t},matchesTypes:["Text","text/plain"]}};function vo(t,e){const n=Te[t];if(!n)throw new Error(`native type ${t} has no configuration`);const s=new xo(n);return s.loadDataTransfer(e),s}function ye(t){if(!t)return null;const e=Array.prototype.slice.call(t.types||[]);return Object.keys(Te).filter(n=>{const s=Te[n];return s!=null&&s.matchesTypes?s.matchesTypes.some(o=>e.indexOf(o)>-1):!1})[0]||null}const jo=ft(()=>/firefox/i.test(navigator.userAgent)),Et=ft(()=>!!window.safari);class Je{interpolate(e){const{xs:n,ys:s,c1s:o,c2s:i,c3s:a}=this;let c=n.length-1;if(e===n[c])return s[c];let u=0,h=a.length-1,f;for(;u<=h;){f=Math.floor(.5*(u+h));const d=n[f];if(d<e)u=f+1;else if(d>e)h=f-1;else return s[f]}c=Math.max(0,h);const l=e-n[c],p=l*l;return s[c]+o[c]*l+i[c]*p+a[c]*l*p}constructor(e,n){const{length:s}=e,o=[];for(let d=0;d<s;d++)o.push(d);o.sort((d,x)=>e[d]<e[x]?-1:1);const i=[],a=[];let c,u;for(let d=0;d<s-1;d++)c=e[d+1]-e[d],u=n[d+1]-n[d],i.push(c),a.push(u/c);const h=[a[0]];for(let d=0;d<i.length-1;d++){const x=a[d],g=a[d+1];if(x*g<=0)h.push(0);else{c=i[d];const v=i[d+1],_=c+v;h.push(3*_/((_+v)/x+(_+c)/g))}}h.push(a[a.length-1]);const f=[],l=[];let p;for(let d=0;d<h.length-1;d++){p=a[d];const x=h[d],g=1/i[d],v=x+h[d+1]-p-p;f.push((p-x-v)*g),l.push(v*g*g)}this.xs=e,this.ys=n,this.c1s=h,this.c2s=f,this.c3s=l}}const Eo=1;function _t(t){const e=t.nodeType===Eo?t:t.parentElement;if(!e)return null;const{top:n,left:s}=e.getBoundingClientRect();return{x:s,y:n}}function ue(t){return{x:t.clientX,y:t.clientY}}function _o(t){var e;return t.nodeName==="IMG"&&(jo()||!(!((e=document.documentElement)===null||e===void 0)&&e.contains(t)))}function bo(t,e,n,s){let o=t?e.width:n,i=t?e.height:s;return Et()&&t&&(i/=window.devicePixelRatio,o/=window.devicePixelRatio),{dragPreviewWidth:o,dragPreviewHeight:i}}function So(t,e,n,s,o){const i=_o(e),c=_t(i?t:e),u={x:n.x-c.x,y:n.y-c.y},{offsetWidth:h,offsetHeight:f}=t,{anchorX:l,anchorY:p}=s,{dragPreviewWidth:d,dragPreviewHeight:x}=bo(i,e,h,f),g=()=>{let A=new Je([0,.5,1],[u.y,u.y/f*x,u.y+x-f]).interpolate(p);return Et()&&i&&(A+=(window.devicePixelRatio-1)*x),A},v=()=>new Je([0,.5,1],[u.x,u.x/h*d,u.x+d-h]).interpolate(l),{offsetX:_,offsetY:b}=o,S=_===0||_,D=b===0||b;return{x:S?_:v(),y:D?b:g()}}class yo{get window(){if(this.globalContext)return this.globalContext;if(typeof window<"u")return window}get document(){var e;return!((e=this.globalContext)===null||e===void 0)&&e.document?this.globalContext.document:this.window?this.window.document:void 0}get rootElement(){var e;return((e=this.optionsArgs)===null||e===void 0?void 0:e.rootElement)||this.window}constructor(e,n){this.ownerDocument=null,this.globalContext=e,this.optionsArgs=n}}function wo(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ke(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{},s=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(s=s.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),s.forEach(function(o){wo(t,o,n[o])})}return t}class Do{profile(){var e,n;return{sourcePreviewNodes:this.sourcePreviewNodes.size,sourcePreviewNodeOptions:this.sourcePreviewNodeOptions.size,sourceNodeOptions:this.sourceNodeOptions.size,sourceNodes:this.sourceNodes.size,dragStartSourceIds:((e=this.dragStartSourceIds)===null||e===void 0?void 0:e.length)||0,dropTargetIds:this.dropTargetIds.length,dragEnterTargetIds:this.dragEnterTargetIds.length,dragOverTargetIds:((n=this.dragOverTargetIds)===null||n===void 0?void 0:n.length)||0}}get window(){return this.options.window}get document(){return this.options.document}get rootElement(){return this.options.rootElement}setup(){const e=this.rootElement;if(e!==void 0){if(e.__isReactDndBackendSetUp)throw new Error("Cannot have two HTML5 backends at the same time.");e.__isReactDndBackendSetUp=!0,this.addEventListeners(e)}}teardown(){const e=this.rootElement;if(e!==void 0&&(e.__isReactDndBackendSetUp=!1,this.removeEventListeners(this.rootElement),this.clearCurrentDragSourceNode(),this.asyncEndDragFrameId)){var n;(n=this.window)===null||n===void 0||n.cancelAnimationFrame(this.asyncEndDragFrameId)}}connectDragPreview(e,n,s){return this.sourcePreviewNodeOptions.set(e,s),this.sourcePreviewNodes.set(e,n),()=>{this.sourcePreviewNodes.delete(e),this.sourcePreviewNodeOptions.delete(e)}}connectDragSource(e,n,s){this.sourceNodes.set(e,n),this.sourceNodeOptions.set(e,s);const o=a=>this.handleDragStart(a,e),i=a=>this.handleSelectStart(a);return n.setAttribute("draggable","true"),n.addEventListener("dragstart",o),n.addEventListener("selectstart",i),()=>{this.sourceNodes.delete(e),this.sourceNodeOptions.delete(e),n.removeEventListener("dragstart",o),n.removeEventListener("selectstart",i),n.setAttribute("draggable","false")}}connectDropTarget(e,n){const s=a=>this.handleDragEnter(a,e),o=a=>this.handleDragOver(a,e),i=a=>this.handleDrop(a,e);return n.addEventListener("dragenter",s),n.addEventListener("dragover",o),n.addEventListener("drop",i),()=>{n.removeEventListener("dragenter",s),n.removeEventListener("dragover",o),n.removeEventListener("drop",i)}}addEventListeners(e){e.addEventListener&&(e.addEventListener("dragstart",this.handleTopDragStart),e.addEventListener("dragstart",this.handleTopDragStartCapture,!0),e.addEventListener("dragend",this.handleTopDragEndCapture,!0),e.addEventListener("dragenter",this.handleTopDragEnter),e.addEventListener("dragenter",this.handleTopDragEnterCapture,!0),e.addEventListener("dragleave",this.handleTopDragLeaveCapture,!0),e.addEventListener("dragover",this.handleTopDragOver),e.addEventListener("dragover",this.handleTopDragOverCapture,!0),e.addEventListener("drop",this.handleTopDrop),e.addEventListener("drop",this.handleTopDropCapture,!0))}removeEventListeners(e){e.removeEventListener&&(e.removeEventListener("dragstart",this.handleTopDragStart),e.removeEventListener("dragstart",this.handleTopDragStartCapture,!0),e.removeEventListener("dragend",this.handleTopDragEndCapture,!0),e.removeEventListener("dragenter",this.handleTopDragEnter),e.removeEventListener("dragenter",this.handleTopDragEnterCapture,!0),e.removeEventListener("dragleave",this.handleTopDragLeaveCapture,!0),e.removeEventListener("dragover",this.handleTopDragOver),e.removeEventListener("dragover",this.handleTopDragOverCapture,!0),e.removeEventListener("drop",this.handleTopDrop),e.removeEventListener("drop",this.handleTopDropCapture,!0))}getCurrentSourceNodeOptions(){const e=this.monitor.getSourceId(),n=this.sourceNodeOptions.get(e);return Ke({dropEffect:this.altKeyPressed?"copy":"move"},n||{})}getCurrentDropEffect(){return this.isDraggingNativeItem()?"copy":this.getCurrentSourceNodeOptions().dropEffect}getCurrentSourcePreviewNodeOptions(){const e=this.monitor.getSourceId(),n=this.sourcePreviewNodeOptions.get(e);return Ke({anchorX:.5,anchorY:.5,captureDraggingState:!1},n||{})}isDraggingNativeItem(){const e=this.monitor.getItemType();return Object.keys(Ze).some(n=>Ze[n]===e)}beginDragNativeItem(e,n){this.clearCurrentDragSourceNode(),this.currentNativeSource=vo(e,n),this.currentNativeHandle=this.registry.addSource(e,this.currentNativeSource),this.actions.beginDrag([this.currentNativeHandle])}setCurrentDragSourceNode(e){this.clearCurrentDragSourceNode(),this.currentDragSourceNode=e;const n=1e3;this.mouseMoveTimeoutTimer=setTimeout(()=>{var s;return(s=this.rootElement)===null||s===void 0?void 0:s.addEventListener("mousemove",this.endDragIfSourceWasRemovedFromDOM,!0)},n)}clearCurrentDragSourceNode(){if(this.currentDragSourceNode){if(this.currentDragSourceNode=null,this.rootElement){var e;(e=this.window)===null||e===void 0||e.clearTimeout(this.mouseMoveTimeoutTimer||void 0),this.rootElement.removeEventListener("mousemove",this.endDragIfSourceWasRemovedFromDOM,!0)}return this.mouseMoveTimeoutTimer=null,!0}return!1}handleDragStart(e,n){e.defaultPrevented||(this.dragStartSourceIds||(this.dragStartSourceIds=[]),this.dragStartSourceIds.unshift(n))}handleDragEnter(e,n){this.dragEnterTargetIds.unshift(n)}handleDragOver(e,n){this.dragOverTargetIds===null&&(this.dragOverTargetIds=[]),this.dragOverTargetIds.unshift(n)}handleDrop(e,n){this.dropTargetIds.unshift(n)}constructor(e,n,s){this.sourcePreviewNodes=new Map,this.sourcePreviewNodeOptions=new Map,this.sourceNodes=new Map,this.sourceNodeOptions=new Map,this.dragStartSourceIds=null,this.dropTargetIds=[],this.dragEnterTargetIds=[],this.currentNativeSource=null,this.currentNativeHandle=null,this.currentDragSourceNode=null,this.altKeyPressed=!1,this.mouseMoveTimeoutTimer=null,this.asyncEndDragFrameId=null,this.dragOverTargetIds=null,this.lastClientOffset=null,this.hoverRafId=null,this.getSourceClientOffset=o=>{const i=this.sourceNodes.get(o);return i&&_t(i)||null},this.endDragNativeItem=()=>{this.isDraggingNativeItem()&&(this.actions.endDrag(),this.currentNativeHandle&&this.registry.removeSource(this.currentNativeHandle),this.currentNativeHandle=null,this.currentNativeSource=null)},this.isNodeInDocument=o=>!!(o&&this.document&&this.document.body&&this.document.body.contains(o)),this.endDragIfSourceWasRemovedFromDOM=()=>{const o=this.currentDragSourceNode;o==null||this.isNodeInDocument(o)||(this.clearCurrentDragSourceNode()&&this.monitor.isDragging()&&this.actions.endDrag(),this.cancelHover())},this.scheduleHover=o=>{this.hoverRafId===null&&typeof requestAnimationFrame<"u"&&(this.hoverRafId=requestAnimationFrame(()=>{this.monitor.isDragging()&&this.actions.hover(o||[],{clientOffset:this.lastClientOffset}),this.hoverRafId=null}))},this.cancelHover=()=>{this.hoverRafId!==null&&typeof cancelAnimationFrame<"u"&&(cancelAnimationFrame(this.hoverRafId),this.hoverRafId=null)},this.handleTopDragStartCapture=()=>{this.clearCurrentDragSourceNode(),this.dragStartSourceIds=[]},this.handleTopDragStart=o=>{if(o.defaultPrevented)return;const{dragStartSourceIds:i}=this;this.dragStartSourceIds=null;const a=ue(o);this.monitor.isDragging()&&(this.actions.endDrag(),this.cancelHover()),this.actions.beginDrag(i||[],{publishSource:!1,getSourceClientOffset:this.getSourceClientOffset,clientOffset:a});const{dataTransfer:c}=o,u=ye(c);if(this.monitor.isDragging()){if(c&&typeof c.setDragImage=="function"){const f=this.monitor.getSourceId(),l=this.sourceNodes.get(f),p=this.sourcePreviewNodes.get(f)||l;if(p){const{anchorX:d,anchorY:x,offsetX:g,offsetY:v}=this.getCurrentSourcePreviewNodeOptions(),S=So(l,p,a,{anchorX:d,anchorY:x},{offsetX:g,offsetY:v});c.setDragImage(p,S.x,S.y)}}try{c==null||c.setData("application/json",{})}catch{}this.setCurrentDragSourceNode(o.target);const{captureDraggingState:h}=this.getCurrentSourcePreviewNodeOptions();h?this.actions.publishDragSource():setTimeout(()=>this.actions.publishDragSource(),0)}else if(u)this.beginDragNativeItem(u);else{if(c&&!c.types&&(o.target&&!o.target.hasAttribute||!o.target.hasAttribute("draggable")))return;o.preventDefault()}},this.handleTopDragEndCapture=()=>{this.clearCurrentDragSourceNode()&&this.monitor.isDragging()&&this.actions.endDrag(),this.cancelHover()},this.handleTopDragEnterCapture=o=>{if(this.dragEnterTargetIds=[],this.isDraggingNativeItem()){var i;(i=this.currentNativeSource)===null||i===void 0||i.loadDataTransfer(o.dataTransfer)}if(!this.enterLeaveCounter.enter(o.target)||this.monitor.isDragging())return;const{dataTransfer:c}=o,u=ye(c);u&&this.beginDragNativeItem(u,c)},this.handleTopDragEnter=o=>{const{dragEnterTargetIds:i}=this;if(this.dragEnterTargetIds=[],!this.monitor.isDragging())return;this.altKeyPressed=o.altKey,i.length>0&&this.actions.hover(i,{clientOffset:ue(o)}),i.some(c=>this.monitor.canDropOnTarget(c))&&(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect=this.getCurrentDropEffect()))},this.handleTopDragOverCapture=o=>{if(this.dragOverTargetIds=[],this.isDraggingNativeItem()){var i;(i=this.currentNativeSource)===null||i===void 0||i.loadDataTransfer(o.dataTransfer)}},this.handleTopDragOver=o=>{const{dragOverTargetIds:i}=this;if(this.dragOverTargetIds=[],!this.monitor.isDragging()){o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect="none");return}this.altKeyPressed=o.altKey,this.lastClientOffset=ue(o),this.scheduleHover(i),(i||[]).some(c=>this.monitor.canDropOnTarget(c))?(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect=this.getCurrentDropEffect())):this.isDraggingNativeItem()?o.preventDefault():(o.preventDefault(),o.dataTransfer&&(o.dataTransfer.dropEffect="none"))},this.handleTopDragLeaveCapture=o=>{this.isDraggingNativeItem()&&o.preventDefault(),this.enterLeaveCounter.leave(o.target)&&(this.isDraggingNativeItem()&&setTimeout(()=>this.endDragNativeItem(),0),this.cancelHover())},this.handleTopDropCapture=o=>{if(this.dropTargetIds=[],this.isDraggingNativeItem()){var i;o.preventDefault(),(i=this.currentNativeSource)===null||i===void 0||i.loadDataTransfer(o.dataTransfer)}else ye(o.dataTransfer)&&o.preventDefault();this.enterLeaveCounter.reset()},this.handleTopDrop=o=>{const{dropTargetIds:i}=this;this.dropTargetIds=[],this.actions.hover(i,{clientOffset:ue(o)}),this.actions.drop({dropEffect:this.getCurrentDropEffect()}),this.isDraggingNativeItem()?this.endDragNativeItem():this.monitor.isDragging()&&this.actions.endDrag(),this.cancelHover()},this.handleSelectStart=o=>{const i=o.target;typeof i.dragDrop=="function"&&(i.tagName==="INPUT"||i.tagName==="SELECT"||i.tagName==="TEXTAREA"||i.isContentEditable||(o.preventDefault(),i.dragDrop()))},this.options=new yo(n,s),this.actions=e.getActions(),this.monitor=e.getMonitor(),this.registry=e.getRegistry(),this.enterLeaveCounter=new mo(this.isNodeInDocument)}}const Ro=function(e,n,s){return new Do(e,n,s)},Co="_layers_62wod_1",Oo="_block_62wod_8",Io="_dragging_62wod_23",To="_active_62wod_31",No="_add_62wod_35",ko="_button_62wod_47",Po="_empty_62wod_60",$o="_title_62wod_72",Mo="_icon_62wod_79",Ao="_text_62wod_83",Bo="_highlight_62wod_89",J={layers:Co,block:Oo,dragging:Io,active:To,add:No,button:ko,empty:Po,title:$o,icon:Mo,text:Ao,highlight:Bo},Lo="_block_1d6lb_1",et={block:Lo},Ho=()=>{const{setCurrentBlock:t}=r.useLayersStore(),{activeBlock:e}=r.usePreviewStore();function n(s){t(s)}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(et.block,{[et.active]:e==="header"}),onClick:()=>n("header"),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"cards"}),r.jsxRuntimeExports.jsx("span",{children:"Header"})]})},Fo="_block_1d6lb_1",tt={block:Fo},Uo=()=>{const{activeBlock:t}=r.usePreviewStore(),{setCurrentBlock:e}=r.useLayersStore();function n(s){e(s)}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(tt.block,{[tt.active]:t==="footer"}),onClick:()=>n("footer"),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"cards"}),r.jsxRuntimeExports.jsx("span",{children:"Footer"})]})},qo=({id:t,name:e,index:n,moveBlock:s,onClick:o})=>{const{currentPage:i,pages:a}=r.usePagesStore(),{activeBlock:c}=r.usePreviewStore(),{showPreview:u,hidePreview:h,showModal:f,hideModal:l,clearHideTimeout:p,startHideTimeout:d,hoverBlockId:x,isModalVisible:g}=r.useSubmodalStore(),{setPositionBlock:v}=r.useLayersStore(),[_,b]=m.useState(!1),S=()=>{g&&l(),u(t),b(!0),p()},D=E=>{E.stopPropagation(),h(),f(t),p(),v(n+1)},M=()=>{g?d():(b(!1),h())};m.useEffect(()=>{g||b(!1)},[g]);const[,A]=po({accept:"block",hover(E){E.index!==n&&(s(a[i].name,E.index,n),E.index=n)}}),[{isDragging:O},H]=so({type:"block",item:{id:t,index:n},collect:E=>({isDragging:E.isDragging()})});return r.jsxRuntimeExports.jsxs("div",{ref:E=>H(A(E)),className:r.clx(J.block,{[J.dragging]:O,[J.active]:!O&&c===t}),onClick:()=>o(t),onMouseEnter:S,onMouseLeave:M,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"cards"}),r.jsxRuntimeExports.jsx("span",{children:e}),(_||x===t)&&!O&&r.jsxRuntimeExports.jsx("div",{className:J.add,children:r.jsxRuntimeExports.jsx("button",{className:J.button,onClick:E=>D(E),children:r.jsxRuntimeExports.jsx(r.Icon,{name:"plus",fill:"#fff"})})})]})},zo=()=>{const{blocks:t,setCurrentBlock:e,moveBlock:n}=r.useLayersStore(),{currentPage:s,pages:o}=r.usePagesStore();function i(a){e(a)}return r.jsxRuntimeExports.jsxs("div",{className:J.layers,children:[r.jsxRuntimeExports.jsx(Ho,{}),r.jsxRuntimeExports.jsx(Ps,{backend:Ro,children:r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:t[o[s].name]&&Object.keys(t[o[s].name]).map((a,c)=>r.jsxRuntimeExports.jsx(qo,{id:a,name:t[o[s].name][a].name,index:c,moveBlock:n,onClick:i},a))})}),r.jsxRuntimeExports.jsx(Uo,{})]})},Vo=({isHeader:t})=>{const{header:e,footer:n}=r.useLayersStore(),{pageContext:s}=r.usePagesStore();return t?e==null?void 0:e.renderSettings(s):n==null?void 0:n.renderSettings(s)},Yo=()=>{const{settings:t}=r.useSettingsStore();return t==null?void 0:t.renderSettings()},Go="_theme_1xj36_1",Xo="_block_1xj36_6",Wo="_name_1xj36_20",we={theme:Go,block:Xo,name:Wo},Qo=()=>{const{setActiveBlock:t}=r.useThemeSettingsStore();function e(n){t(n)}return r.jsxRuntimeExports.jsx("div",{className:we.theme,children:Dt.map(n=>r.jsxRuntimeExports.jsxs("div",{onClick:()=>e(n),className:r.clx(we.block),children:[r.jsxRuntimeExports.jsx(r.Icon,{name:n.icon}),r.jsxRuntimeExports.jsx("span",{className:we.name,children:n.name}),r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-right"})]},n.icon))})},Zo="_back_14yda_1",Jo="_render_14yda_8",Ko="_open_14yda_23",ei="_close_14yda_50",ti="_clicked_14yda_54",ni="_title_14yda_58",ri="_button_14yda_65",si="_loading_14yda_70",oi="_settings_14yda_74",ii="_buttons_14yda_80",ai="_deleteButton_14yda_86",B={back:Zo,render:Jo,open:Ko,close:ei,clicked:ti,title:ni,button:ri,loading:si,settings:oi,buttons:ii,deleteButton:ai},ci=({block:t})=>{if(!t)return;const{blocks:e,sourceBlocks:n,activeBlock:s}=r.useBlocksStore(),{currentBlock:o}=r.useLayersStore();if(!s&&!o)return null;if(t!=null&&t.name){const i=e[t.name],a={...t.value};for(const c in a)i[c]=a[c];return i.renderSettings()}else{const i=n[s];for(const a in i)t[a]={...i[a]};return t.renderSettings()}},ui=t=>{var H;const{isAdd:e}=t,[n,s]=m.useState(!1),{setActiveBlock:o}=r.useNavbarStore(),{blocks:i,activeBlock:a,setActiveBlock:c}=r.useBlocksStore(),{blocks:u,addBlock:h,editBlock:f,currentBlock:l,setCurrentBlock:p,removeBlock:d,setPositionBlock:x,setHeader:g,setFooter:v,header:_,footer:b}=r.useLayersStore(),{currentPage:S,pages:D}=r.usePagesStore();function M(){c(null),p(null),setTimeout(()=>{s(!1)},150)}function A(){M(),o({name:"Layers",icon:"layers"})}function O(){return e?i[a]:i[u[D[S].name]&&u[D[S].name][l]?u[D[S].name][l].name:"null"]}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(B.render,{[B.open]:l,[B.close]:!l,[B.clicked]:n}),children:[r.jsxRuntimeExports.jsxs("div",{className:B.back,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:M}),r.jsxRuntimeExports.jsx("h3",{className:B.title,children:a||u[D[S].name]&&((H=u[D[S].name][l])==null?void 0:H.name)||l&&$(l)||"Loading"})]}),r.jsxRuntimeExports.jsxs("div",{className:B.settings,children:[l&&O()&&r.jsxRuntimeExports.jsx(ci,{block:e?O():u[D[S].name][l]}),l&&["header","footer"].includes(l)&&r.jsxRuntimeExports.jsx(Vo,{isHeader:l==="header"}),!l&&r.jsxRuntimeExports.jsx("div",{className:B.loading,children:"Loading"})]}),r.jsxRuntimeExports.jsxs("div",{className:B.buttons,children:[r.jsxRuntimeExports.jsx(r.Button,{style:{width:"100%"},onClick:()=>{if(s(!0),["header","footer"].includes(l))l==="header"?g(_):v(b);else{const E=O();e?(h(D[S].name,{name:a,value:{...E}}),x(null)):f(D[S].name,l,{name:u[D[S].name][l].name,value:{...E}})}A()},children:e?"Add Section":"Edit Section"}),!e&&!["header","footer"].includes(l)&&r.jsxRuntimeExports.jsx("button",{onClick:()=>{s(!0),d(D[S].name,l),setTimeout(()=>{s(!1)},150)},className:B.deleteButton,children:r.jsxRuntimeExports.jsx(r.Icon,{name:"trash",hoverable:!0})})]})]})},li="_settings_1r85j_1",di="_open_1r85j_16",gi="_close_1r85j_20",pi="_header_1r85j_24",hi="_title_1r85j_30",fi="_addButton_1r85j_37",te={settings:li,open:di,close:gi,header:pi,title:hi,addButton:fi},mi="_wrapper_n1a7x_1",xi="_category_n1a7x_5",vi="_categoryTitle_n1a7x_10",ji="_color_n1a7x_16",Ei="_content_n1a7x_24",_i="_preview_n1a7x_32",X={wrapper:mi,category:xi,categoryTitle:vi,color:ji,content:Ei,preview:_i},bi=()=>{const{themeSettings:t,updateColor:e}=r.useThemeSettingsStore();async function n(o,i,a){e(o,i,a)}const s=m.useMemo(()=>{const o={};return Object.entries(t.colors).forEach(([i,a])=>{Object.entries(a).forEach(([c,u])=>{o[u]||(o[u]=[]),o[u].push(`${i}-${c}`)})}),Object.keys(o).filter(i=>o[i].length>1)},[t.colors]);return r.jsxRuntimeExports.jsx("div",{className:X.wrapper,children:Object.entries(t.colors).map(([o,i])=>r.jsxRuntimeExports.jsxs("div",{className:X.category,children:[r.jsxRuntimeExports.jsx("h2",{className:X.categoryTitle,children:$(o)}),Object.entries(i).map(([a,c])=>r.jsxRuntimeExports.jsxs("div",{className:X.color,children:[r.jsxRuntimeExports.jsxs("div",{className:X.content,children:[r.jsxRuntimeExports.jsx("div",{className:X.preview,style:{background:c}}),r.jsxRuntimeExports.jsx(r.ColorPicker,{title:$(a),initialColor:c,onChange:u=>n(o,a,u)})]}),s.includes(c)&&r.jsxRuntimeExports.jsx(r.Tip,{type:"warning",message:"To avoid contrast problems, please use a different color",style:{marginBottom:12}})]},a))]},o))})},Si="_wrapper_kb55x_2",yi="_category_kb55x_6",wi="_categoryTitle_kb55x_11",Di="_color_kb55x_17",Ri="_name_kb55x_23",Ci="_content_kb55x_28",Oi="_label_kb55x_34",Ii="_input_kb55x_45",Ti="_title_kb55x_71",Ni="_field_kb55x_79",ki="_alignments_kb55x_89",Pi="_lineField_kb55x_95",$i="_style_kb55x_101",Mi="_header_kb55x_108",L={wrapper:Si,category:yi,categoryTitle:wi,color:Di,name:Ri,content:Ci,label:Oi,input:Ii,title:Ti,field:Ni,alignments:ki,lineField:Pi,style:$i,header:Mi},Ai=["left","center","right"],Bi=["solid","dashed"],le=t=>{const{title:e,children:n,rightAddon:s}=t;return r.jsxRuntimeExports.jsxs("div",{className:L.field,children:[r.jsxRuntimeExports.jsxs("div",{className:L.header,children:[r.jsxRuntimeExports.jsx("h4",{children:e}),s]}),n]})},Li=()=>{const{themeSettings:t,updateInput:e}=r.useThemeSettingsStore(),n=m.useMemo(()=>t.inputs,[t]),s=(i,a,c)=>{e(i,a,c)},o=i=>a=>{e(i,a,"color")};return r.jsxRuntimeExports.jsxs("div",{className:L.wrapper,children:[r.jsxRuntimeExports.jsxs(le,{title:"General",children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Height (px)",value:String(n.general.height),onChange:i=>s("general",i,"height"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Input,{label:"Style name",value:n.general.name,onChange:i=>s("general",i,"name")}),r.jsxRuntimeExports.jsx(r.Select,{label:"Font Size (px)",onChange:i=>s("general",i,"size"),value:String(n.general.size),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.general.color),onChange:o("general"),title:"Font Color",labelStyle:"secondary"})]}),r.jsxRuntimeExports.jsxs(le,{title:"Field Fill",rightAddon:r.jsxRuntimeExports.jsx("div",{className:L.switch,children:r.jsxRuntimeExports.jsx(r.Switch,{onChange:i=>s("field",i,"active"),current:n.field.active})}),children:[r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.field.color),onChange:o("field"),title:"Color",labelStyle:"secondary"}),r.jsxRuntimeExports.jsx(r.Input,{label:"Opacity (%)",value:String(n.field.opacity),onChange:i=>s("field",i,"opacity"),type:"number",min:0})]}),r.jsxRuntimeExports.jsxs(le,{title:"Border",rightAddon:r.jsxRuntimeExports.jsx("div",{className:L.switch,children:r.jsxRuntimeExports.jsx(r.Switch,{onChange:i=>s("border",i,"active"),current:n.border.active})}),children:[r.jsxRuntimeExports.jsxs("div",{className:L.lineField,children:[r.jsxRuntimeExports.jsxs("div",{className:L.style,children:[r.jsxRuntimeExports.jsx("span",{className:L.title,children:"Style"}),r.jsxRuntimeExports.jsx(r.Picker,{items:Bi,selectedItem:n.border.style,onSelect:i=>s("border",i,"style"),getIconName:i=>`border-${i}`})]}),r.jsxRuntimeExports.jsx(r.Input,{label:"Radius (px)",value:String(n.border.radius),onChange:i=>s("border",i,"radius"),type:"number",min:0})]}),r.jsxRuntimeExports.jsx(r.Input,{label:"Thickness (px)",value:String(n.border.thickness),onChange:i=>s("border",i,"thickness"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.border.color),onChange:o("border"),title:"Color",labelStyle:"secondary"})]}),r.jsxRuntimeExports.jsxs(le,{title:"Label",children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Line Height (px)",value:String(n.label.height),onChange:i=>s("label",i,"height"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Select,{label:"Font Size (px)",onChange:i=>s("label",i,"size"),value:String(n.label.size),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.ColorPicker,{initialColor:$(n.label.color),onChange:o("label"),title:"Color",labelStyle:"secondary"}),r.jsxRuntimeExports.jsxs("div",{className:L.alignments,children:[r.jsxRuntimeExports.jsx("h4",{className:L.title,children:"Alignment Type"}),r.jsxRuntimeExports.jsx(r.Picker,{items:Ai,selectedItem:n.label.alignment,onSelect:i=>s("label",i,"alignment"),getIconName:i=>`align-${i}`})]})]})]})},Hi="_wrapper_k9on2_1",Fi="_category_k9on2_5",Ui="_categoryTitle_k9on2_10",qi="_font_k9on2_16",zi="_content_k9on2_36",Vi="_icon_k9on2_42",Yi="_paragraph_k9on2_51",Gi="_deleteIcon_k9on2_55",Xi="_iconButton_k9on2_62",q={wrapper:Hi,category:Fi,categoryTitle:Ui,font:qi,content:zi,icon:Vi,paragraph:Yi,deleteIcon:Gi,iconButton:Xi},Wi=t=>{const{font:e,size:n,id:s,category:o}=t,{setActiveFont:i}=r.useThemeSettingsStore();return r.jsxRuntimeExports.jsxs("div",{className:q.font,onClick:()=>i(s),children:[r.jsxRuntimeExports.jsx("div",{className:r.clx(q.icon,{[q.paragraph]:o==="paragraph"}),children:r.jsxRuntimeExports.jsx(r.Icon,{name:o})}),r.jsxRuntimeExports.jsxs("div",{className:q.content,children:[r.jsxRuntimeExports.jsx("h2",{className:q.categoryTitle,children:$(s)}),r.jsxRuntimeExports.jsx("span",{className:q.value,children:`${e}, ${n}px`})]})]})},Qi=()=>{const{themeSettings:t,setActiveFont:e,activeBlock:n}=r.useThemeSettingsStore();m.useEffect(()=>(s(),()=>{s()}),[]);function s(){e(null)}if(n!=null&&n.name)return r.jsxRuntimeExports.jsx("div",{className:q.wrapper,children:Object.entries(t.fonts).map(([o,i])=>r.jsxRuntimeExports.jsxs("div",{className:q.category,children:[r.jsxRuntimeExports.jsx("h2",{className:q.categoryTitle,children:$(o)}),Object.entries(i).map(([a,c])=>r.jsxRuntimeExports.jsx(Wi,{id:a,category:o,...c},a))]},o))})},Zi="_wrapper_94fpv_1",Ji="_open_94fpv_16",Ki="_close_94fpv_20",ea="_header_94fpv_24",ta="_title_94fpv_31",na="_options_94fpv_37",ra="_clicked_94fpv_44",W={wrapper:Zi,open:Ji,close:Ki,header:ea,title:ta,options:na,clicked:ra},sa=()=>{const{activeBlock:t,setActiveFont:e,activeFont:n,themeSettings:s,updateFont:o}=r.useThemeSettingsStore(),{fonts:i}=r.useFontsStore(),[a,c]=m.useState(null);function u(){e(null)}function h(l,p){a&&n&&o(a,n,p,l)}const f=m.useMemo(()=>n?s.fonts.heading[n]?(c("heading"),s.fonts.heading[n]):s.fonts.paragraph[n]?(c("paragraph"),s.fonts.paragraph[n]):(c(null),null):null,[n,s]);return r.jsxRuntimeExports.jsxs("div",{className:r.clx(W.wrapper,{[W.open]:(t==null?void 0:t.name)==="Fonts"&&n,[W.close]:(t==null?void 0:t.name)!=="Fonts"||!n}),children:[r.jsxRuntimeExports.jsxs("div",{className:W.header,onClick:u,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0}),r.jsxRuntimeExports.jsx("span",{className:W.title,children:"Font Style"})]}),n&&f&&r.jsxRuntimeExports.jsxs("div",{className:W.options,children:[r.jsxRuntimeExports.jsx(r.Select,{label:"Font",value:f.font,onChange:l=>h(l,"font"),options:[...i.filter(l=>l!==f.font)]}),r.jsxRuntimeExports.jsx(r.Select,{label:"Size",value:String(f.size),onChange:l=>h(l,"size"),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.Select,{label:"Weight",value:String(f.weight),onChange:l=>h(l,"weight"),options:r.weightOptions})]})]})},oa="_wrapper_94fpv_1",ia="_open_94fpv_16",aa="_close_94fpv_20",ca="_header_94fpv_24",ua="_title_94fpv_31",la="_options_94fpv_37",da="_clicked_94fpv_44",Q={wrapper:oa,open:ia,close:aa,header:ca,title:ua,options:la,clicked:da},bt=()=>{const{activeBlock:t,themeSettings:e,updateBorder:n,setActiveBlock:s}=r.useThemeSettingsStore();function o(c,u){n(u,c)}function i(){s(null)}const a=m.useMemo(()=>e.borders,[e]);return r.jsxRuntimeExports.jsxs("div",{className:r.clx(Q.wrapper,{[Q.open]:(t==null?void 0:t.name)==="Borders",[Q.close]:(t==null?void 0:t.name)!=="Borders"}),children:[r.jsxRuntimeExports.jsxs("div",{className:Q.header,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:i}),r.jsxRuntimeExports.jsx("span",{className:Q.title,children:"Borders Style"})]}),r.jsxRuntimeExports.jsxs("div",{className:Q.options,children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Border Radius (px)",value:String(a.radius),onChange:c=>o(Number(c),"radius"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Input,{label:"Border Thickness (px)",value:String(a.thickness),onChange:c=>o(Number(c),"thickness"),type:"number",min:0})]})]})},ga="_wrapper_1j33r_1",pa="_open_1j33r_16",ha="_close_1j33r_20",fa="_header_1j33r_24",ma="_title_1j33r_31",xa="_options_1j33r_37",va="_clicked_1j33r_44",ja="_label_1j33r_48",Ea="_alignments_1j33r_55",_a="_blocks_1j33r_61",ba="_alignment_1j33r_55",Sa="_active_1j33r_75",k={wrapper:ga,open:pa,close:ha,header:fa,title:ma,options:xa,clicked:va,label:ja,alignments:Ea,blocks:_a,alignment:ba,active:Sa},ya=["left","center","right"],St=()=>{const{activeBlock:t,themeSettings:e,updateButton:n,setActiveBlock:s}=r.useThemeSettingsStore();function o(c,u){n(u,c)}function i(){s(null)}const a=m.useMemo(()=>e.buttons,[e]);return r.jsxRuntimeExports.jsxs("div",{className:r.clx(k.wrapper,{[k.open]:(t==null?void 0:t.name)==="Buttons",[k.close]:(t==null?void 0:t.name)!=="Buttons"}),children:[r.jsxRuntimeExports.jsxs("div",{className:k.header,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:i}),r.jsxRuntimeExports.jsx("span",{className:k.title,children:"Buttons Style"})]}),a&&r.jsxRuntimeExports.jsxs("div",{className:k.options,children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Height (px)",value:String(a.height),onChange:c=>o(c,"height"),type:"number",min:0}),r.jsxRuntimeExports.jsx(r.Select,{label:"Font Size (px)",value:String(a.size),onChange:c=>o(c,"size"),options:r.sizeOptions}),r.jsxRuntimeExports.jsx(r.Input,{label:"Border Radius (px)",value:String(a.radius),onChange:c=>o(Number(c),"radius"),type:"number",min:0}),r.jsxRuntimeExports.jsxs("div",{className:k.alignments,children:[r.jsxRuntimeExports.jsx("h4",{className:k.label,children:"Alignment Type"}),r.jsxRuntimeExports.jsx("div",{className:k.blocks,children:ya.map(c=>r.jsxRuntimeExports.jsx("div",{className:r.clx(k.alignment,{[k.active]:a.alignment===c}),onClick:()=>{o(c,"alignment")},children:r.jsxRuntimeExports.jsx(r.Icon,{name:`align-${c}`,fill:a.alignment===c?"#252525":"#757575"})},c))})]})]})]})},wa=()=>{const{activeBlock:t}=r.useThemeSettingsStore();return r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[(t==null?void 0:t.name)==="Fonts"&&r.jsxRuntimeExports.jsx(sa,{}),(t==null?void 0:t.name)==="Borders"&&r.jsxRuntimeExports.jsx(bt,{}),(t==null?void 0:t.name)==="Buttons"&&r.jsxRuntimeExports.jsx(St,{})]})},Da=()=>{const{activeBlock:t,setActiveBlock:e}=r.useThemeSettingsStore(),{activeBlock:n}=r.useNavbarStore();function s(){e(null)}return r.jsxRuntimeExports.jsxs("div",{className:r.clx(te.settings,{[te.open]:t,[te.close]:!t||n.name!=="Theme"}),children:[r.jsxRuntimeExports.jsxs("div",{className:te.header,children:[r.jsxRuntimeExports.jsx(r.Icon,{name:"arrow-left",hoverable:!0,onClick:s}),r.jsxRuntimeExports.jsx("span",{className:te.title,children:t==null?void 0:t.name})]}),(t==null?void 0:t.name)==="Fonts"&&r.jsxRuntimeExports.jsx(Qi,{}),(t==null?void 0:t.name)==="Colors"&&r.jsxRuntimeExports.jsx(bi,{}),(t==null?void 0:t.name)==="Inputs"&&r.jsxRuntimeExports.jsx(Li,{}),(t==null?void 0:t.name)==="Borders"&&r.jsxRuntimeExports.jsx(bt,{}),(t==null?void 0:t.name)==="Borders"&&r.jsxRuntimeExports.jsx(St,{}),r.jsxRuntimeExports.jsx(wa,{})]})},Ra=()=>{const{activeBlock:t}=r.useNavbarStore(),{activeBlock:e}=r.useBlocksStore();function n(){switch(t.name){case"Layers":return"Layers";case"Add":return"Add Sections";case"Theme":return"Theme Settings";case"Settings":return"Settings"}}return r.jsxRuntimeExports.jsxs("div",{className:Fe.sidebar,children:[r.jsxRuntimeExports.jsx("h3",{className:Fe.title,children:n()}),t.name==="Layers"&&r.jsxRuntimeExports.jsx(zo,{}),t.name==="Add"&&r.jsxRuntimeExports.jsx(rt,{}),r.jsxRuntimeExports.jsx(ui,{isAdd:!!e}),r.jsxRuntimeExports.jsx(Da,{}),t.name==="Theme"&&r.jsxRuntimeExports.jsx(Qo,{}),t.name==="Settings"&&r.jsxRuntimeExports.jsx(Yo,{})]})},Ca="_wrapper_jjfwh_1",Oa="_header_jjfwh_12",Ia="_content_jjfwh_21",Ta="_buttons_jjfwh_29",Na="_cancel_jjfwh_35",ka="_label_jjfwh_40",Pa="_description_jjfwh_41",$a="_preview_jjfwh_49",Ma="_block_jjfwh_55",Aa="_slug_jjfwh_63",Ba="_title_jjfwh_69",P={wrapper:Ca,header:Oa,content:Ia,buttons:Ta,cancel:Na,label:ka,description:Pa,preview:$a,block:Ma,slug:Aa,title:Ba},La=()=>{var O,H,E,w,R,C;const{setIsOpenModal:t,pages:e,createPage:n,updatePage:s,isEdit:o,setIsEdit:i,editedPage:a,setEditedPage:c}=r.usePagesStore(),{createPage:u,updatePage:h}=r.useLayersStore(),[f,l]=m.useState(a?(O=e[a])==null?void 0:O.path:""),[p,d]=m.useState(a?(H=e[a])==null?void 0:H.name:""),[x,g]=m.useState(a?(E=e[a])==null?void 0:E.seo.description:""),[v,_]=m.useState(a?(w=e[a])==null?void 0:w.visibility:"public");function b(){l(""),d(""),g(""),_("public"),i(!1),c(null)}function S(){b(),t(!1)}function D(y){return y[0]==="/"?y:"/"+y}function M(){n({path:D(f),name:p||f,icon:"file",seo:{title:p,description:x},visibility:v}),u(p),S()}function A(){h(e[a].name,p||f),s(a,{path:D(f),name:p||f,icon:e[a].icon||"file",seo:{title:p,description:x},visibility:v}),S()}return r.jsxRuntimeExports.jsxs("div",{className:P.wrapper,onClick:y=>y.stopPropagation(),children:[r.jsxRuntimeExports.jsxs("div",{className:P.header,children:[r.jsxRuntimeExports.jsxs("h2",{children:[o?"Edit":"Create"," Blank Page"]}),r.jsxRuntimeExports.jsx(r.Icon,{name:"x",fill:"#757575",hoverable:!0,onClick:S})]}),r.jsxRuntimeExports.jsxs("div",{className:P.content,children:[r.jsxRuntimeExports.jsx(r.Input,{label:"Page Slug",onChange:y=>l(y),value:f,placeholder:"path-to-page",disabled:!!(a&&((R=e[a])!=null&&R.name)&&r.defaultPageNames.includes(e[a].name)),required:!0,regex:"^.+$"}),r.jsxRuntimeExports.jsx(r.Input,{label:"Page Title",onChange:y=>d(y),value:p,placeholder:"Contact us",disabled:!!(a&&((C=e[a])!=null&&C.name)&&r.defaultPageNames.includes(e[a].name))}),r.jsxRuntimeExports.jsx(r.Textarea,{label:"Description",onChange:y=>g(y),value:x,placeholder:"Contact us at any time of the day or night. You are always welcome",maxLength:150}),r.jsxRuntimeExports.jsx(r.Radio,{label:"Visibility",defaultValue:v,options:[{value:"public",label:"Public"},{value:"private",label:"Private"}],onChange:y=>_(y)}),r.jsxRuntimeExports.jsxs("div",{className:P.preview,children:[r.jsxRuntimeExports.jsx("span",{className:P.label,children:"Preview"}),r.jsxRuntimeExports.jsxs("div",{className:P.block,children:[r.jsxRuntimeExports.jsx("span",{className:P.slug,children:f||"yoursite.url"}),r.jsxRuntimeExports.jsx("span",{className:P.title,children:p||"My Blank Page"}),r.jsxRuntimeExports.jsx("span",{className:P.description,children:x||"It is My Description"})]})]})]}),r.jsxRuntimeExports.jsxs("div",{className:P.buttons,children:[r.jsxRuntimeExports.jsx(r.Button,{className:P.cancel,onClick:S,children:"Cancel"}),r.jsxRuntimeExports.jsx(r.Button,{onClick:o?A:M,disabled:f.length===0,children:o?"Update":"Create"})]})]})},Ha="_layout_kjedu_1",Fa="_main_kjedu_8",Ua="_content_kjedu_15",De={layout:Ha,main:Fa,content:Ua},qa=()=>{const{isOpenModal:t,setIsOpenModal:e}=r.usePagesStore(),{openModal:n,setOpenModal:s}=r.useChooseImageStore();return r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsxs("div",{className:De.layout,children:[r.jsxRuntimeExports.jsx(vn,{}),r.jsxRuntimeExports.jsxs("main",{className:De.main,children:[r.jsxRuntimeExports.jsx(ln,{}),r.jsxRuntimeExports.jsxs("div",{className:De.content,children:[r.jsxRuntimeExports.jsx(Ra,{}),r.jsxRuntimeExports.jsx(lr,{})]})]})]}),t&&r.jsxRuntimeExports.jsx(r.Modal,{close:e,children:r.jsxRuntimeExports.jsx(La,{})}),n&&r.jsxRuntimeExports.jsx(r.Modal,{close:s,children:r.jsxRuntimeExports.jsx(r.ChooseImageModal,{})})]})};async function Z(t,e){const n=localStorage.getItem("shopId")||void 0,s=`${Rt}/${t}/builder/shops/${n}/${e}`,o=localStorage.getItem("accessToken")||void 0;return(await r.axios.get(s,{headers:{Authorization:`Bearer ${o}`}})).data}async function za(){try{const[t,e,n,s,o,i]=await Promise.allSettled([Z("v1","general"),Z("v1","faqs"),Z("v1","listings"),Z("v1","products"),Z("v1","reviews"),Z("v1","categories")]);return{general:t,faqs:e,listings:n,products:s,reviews:o,categories:i}}catch(t){throw console.error("Error fetching page data:",t),t}}async function Va(){try{const{data:t}=await r.axios.get(`${Ct}?key=undefined`);return t.items}catch(t){throw console.error("Error fetching page data:",t),t}}const Ya=t=>{const{blocks:e,settings:n,header:s,footer:o}=t,{setBlocks:i,setSourceBlocks:a}=r.useBlocksStore(),{fonts:c,setFonts:u}=r.useFontsStore(),{setSettings:h}=r.useSettingsStore(),{setPageContext:f}=r.usePagesStore(),{setHeader:l,setFooter:p}=r.useLayersStore();return m.useEffect(()=>{const d={};Object.keys(e).map(g=>{d[g]={...e[g]}}),l(s),p(o),h(n),a(d),i(e),(async()=>{if(c.length===0){const _=await Va();u([..._.map(b=>b.family)])}let g={listings:void 0,products:void 0,reviews:void 0,categories:void 0,faqs:void 0,general:void 0};const v=await za();Object.keys(v).map(_=>{const b=_;g[b]=v[b].value.data}),f(g)})()},[]),r.jsxRuntimeExports.jsx(qa,{})};exports.Builder=Ya;