tanya-chatbot 0.4.2 → 0.4.4
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.
package/dist/tanya-chatbot.es.js
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import { useEffect as
|
|
1
|
+
import { useEffect as it, useState as z, useRef as Ft } from "react";
|
|
2
2
|
import { jsx as a, jsxs as u, Fragment as re } from "react/jsx-runtime";
|
|
3
|
-
import { createHttpLink as
|
|
4
|
-
import { Provider as
|
|
5
|
-
import { createSlice as De, configureStore as
|
|
6
|
-
import * as
|
|
3
|
+
import { createHttpLink as sr, ApolloClient as lr, InMemoryCache as cr, ApolloProvider as dr } from "@apollo/client";
|
|
4
|
+
import { Provider as ur, useDispatch as je, useSelector as Ht } from "react-redux";
|
|
5
|
+
import { createSlice as De, configureStore as pr } from "@reduxjs/toolkit";
|
|
6
|
+
import * as Le from "@radix-ui/react-popover";
|
|
7
7
|
import "clsx";
|
|
8
8
|
import "tailwind-merge";
|
|
9
9
|
import T from "axios";
|
|
10
10
|
import "crypto-js";
|
|
11
|
-
import { Icon as
|
|
11
|
+
import { Icon as ge } from "@iconify/react";
|
|
12
12
|
import { toast as M } from "react-toastify";
|
|
13
|
-
const ur = '*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.container{width:100%}@media(min-width:640px){.container{max-width:640px}}@media(min-width:768px){.container{max-width:768px}}@media(min-width:1024px){.container{max-width:1024px}}@media(min-width:1280px){.container{max-width:1280px}}@media(min-width:1536px){.container{max-width:1536px}}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-0{bottom:0}.left-0{left:0}.right-0{right:0}.top-0{top:0}.top-full{top:100%}.z-40{z-index:40}.z-50{z-index:50}.m-1{margin:.25rem}.m-3{margin:.75rem}.mx-3{margin-left:.75rem;margin-right:.75rem}.my-2{margin-top:.5rem;margin-bottom:.5rem}.my-5{margin-top:1.25rem;margin-bottom:1.25rem}.mb-1{margin-bottom:.25rem}.mb-16{margin-bottom:4rem}.mb-2{margin-bottom:.5rem}.mb-20{margin-bottom:5rem}.mb-24{margin-bottom:6rem}.mb-4{margin-bottom:1rem}.mb-8{margin-bottom:2rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.line-clamp-1{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.h-12{height:3rem}.h-28{height:7rem}.h-3{height:.75rem}.h-6{height:1.5rem}.h-\\[120px\\]{height:120px}.h-\\[200px\\]{height:200px}.h-\\[60px\\]{height:60px}.h-\\[90vh\\]{height:90vh}.h-fit{height:-moz-fit-content;height:fit-content}.h-full{height:100%}.h-screen{height:100vh}.w-28{width:7rem}.w-3{width:.75rem}.w-5\\/6{width:83.333333%}.w-6{width:1.5rem}.w-72{width:18rem}.w-\\[100vw\\]{width:100vw}.w-\\[120px\\]{width:120px}.w-\\[150px\\]{width:150px}.w-\\[60px\\]{width:60px}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-max{width:-moz-max-content;width:max-content}.max-w-\\[200px\\]{max-width:200px}.max-w-\\[75\\%\\]{max-width:75%}.flex-1{flex:1 1 0%}.flex-shrink-0{flex-shrink:0}.flex-grow{flex-grow:1}.translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-full{--tw-translate-y: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize{resize:both}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-5{gap:1.25rem}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-scroll{overflow-y:scroll}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.text-ellipsis{text-overflow:ellipsis}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-\\[10px\\]{border-radius:10px}.rounded-\\[20px\\]{border-radius:20px}.rounded-\\[5px\\]{border-radius:5px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-xl{border-radius:.75rem}.rounded-l-\\[20px\\]{border-top-left-radius:20px;border-bottom-left-radius:20px}.rounded-l-xl{border-top-left-radius:.75rem;border-bottom-left-radius:.75rem}.rounded-r-xl{border-top-right-radius:.75rem;border-bottom-right-radius:.75rem}.rounded-bl-2xl{border-bottom-left-radius:1rem}.rounded-br-xl{border-bottom-right-radius:.75rem}.rounded-tr-\\[20px\\]{border-top-right-radius:20px}.rounded-tr-\\[5px\\]{border-top-right-radius:5px}.border{border-width:1px}.border-0{border-width:0px}.border-b-2{border-bottom-width:2px}.border-l-2{border-left-width:2px}.border-t-2{border-top-width:2px}.border-none{border-style:none}.border-\\[\\#C9C2DE\\]{--tw-border-opacity: 1;border-color:rgb(201 194 222 / var(--tw-border-opacity, 1))}.border-\\[\\#E5E5E5\\]{--tw-border-opacity: 1;border-color:rgb(229 229 229 / var(--tw-border-opacity, 1))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity, 1))}.bg-\\[\\#553D94\\]{--tw-bg-opacity: 1;background-color:rgb(85 61 148 / var(--tw-bg-opacity, 1))}.bg-\\[\\#6851C6\\]{--tw-bg-opacity: 1;background-color:rgb(104 81 198 / var(--tw-bg-opacity, 1))}.bg-\\[\\#804C9E0D\\]{background-color:#804c9e0d}.bg-\\[\\#A21CAF\\]{--tw-bg-opacity: 1;background-color:rgb(162 28 175 / var(--tw-bg-opacity, 1))}.bg-\\[\\#AB192D\\]{--tw-bg-opacity: 1;background-color:rgb(171 25 45 / var(--tw-bg-opacity, 1))}.bg-\\[\\#E2DBFF\\]{--tw-bg-opacity: 1;background-color:rgb(226 219 255 / var(--tw-bg-opacity, 1))}.bg-\\[\\#E3DEEF\\]{--tw-bg-opacity: 1;background-color:rgb(227 222 239 / var(--tw-bg-opacity, 1))}.bg-\\[\\#F3F3F3\\]{--tw-bg-opacity: 1;background-color:rgb(243 243 243 / var(--tw-bg-opacity, 1))}.bg-\\[\\#FFFFFF\\],.bg-\\[\\#ffffff\\]{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-black\\/30{background-color:#0000004d}.bg-indigo-300{--tw-bg-opacity: 1;background-color:rgb(165 180 252 / var(--tw-bg-opacity, 1))}.bg-popover{background-color:hsl(var(--popover))}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0{padding:0}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-\\[1px\\]{padding:1px}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-7{padding-left:1.75rem;padding-right:1.75rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-4{padding-top:1rem;padding-bottom:1rem}.pb-2{padding-bottom:.5rem}.pl-2{padding-left:.5rem}.pr-5{padding-right:1.25rem}.text-left{text-align:left}.text-center{text-align:center}.font-nunitoSans{font-family:Nunito Sans}.text-\\[12px\\]{font-size:12px}.text-\\[14px\\]{font-size:14px}.text-\\[15px\\]{font-size:15px}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.italic{font-style:italic}.leading-snug{line-height:1.375}.text-\\[\\#000000\\]{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity, 1))}.text-\\[\\#14121F\\]{--tw-text-opacity: 1;color:rgb(20 18 31 / var(--tw-text-opacity, 1))}.text-\\[\\#18181B\\]{--tw-text-opacity: 1;color:rgb(24 24 27 / var(--tw-text-opacity, 1))}.text-\\[\\#232323\\]{--tw-text-opacity: 1;color:rgb(35 35 35 / var(--tw-text-opacity, 1))}.text-\\[\\#323135\\]{--tw-text-opacity: 1;color:rgb(50 49 53 / var(--tw-text-opacity, 1))}.text-\\[\\#494949\\]{--tw-text-opacity: 1;color:rgb(73 73 73 / var(--tw-text-opacity, 1))}.text-\\[\\#555555\\]{--tw-text-opacity: 1;color:rgb(85 85 85 / var(--tw-text-opacity, 1))}.text-\\[\\#5B5B5B\\]{--tw-text-opacity: 1;color:rgb(91 91 91 / var(--tw-text-opacity, 1))}.text-\\[\\#68656E\\]{--tw-text-opacity: 1;color:rgb(104 101 110 / var(--tw-text-opacity, 1))}.text-\\[\\#959595\\]{--tw-text-opacity: 1;color:rgb(149 149 149 / var(--tw-text-opacity, 1))}.text-\\[\\#EC5050\\]{--tw-text-opacity: 1;color:rgb(236 80 80 / var(--tw-text-opacity, 1))}.text-\\[\\#FBFBFC\\]{--tw-text-opacity: 1;color:rgb(251 251 252 / var(--tw-text-opacity, 1))}.text-\\[\\#FFFFFF\\]{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-black{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity, 1))}.text-gray-300{--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-popover-foreground{color:hsl(var(--popover-foreground))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity, 1))}.line-through{text-decoration-line:line-through}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-80{opacity:.8}.shadow-\\[0px_2px_2px_0px_\\#9292BC40\\]{--tw-shadow: 0px 2px 2px 0px #9292BC40;--tw-shadow-colored: 0px 2px 2px 0px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\\[0px_4px_10px_0px_\\#5F499840\\]{--tw-shadow: 0px 4px 10px 0px #5F499840;--tw-shadow-colored: 0px 4px 10px 0px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-300{transition-duration:.3s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}.duration-300{animation-duration:.3s}.ease-in-out{animation-timing-function:cubic-bezier(.4,0,.2,1)}.running{animation-play-state:running}html,body,#root{margin:0;padding:0}:root{line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;padding:0}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;cursor:pointer;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}@media(prefers-color-scheme:light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.hover\\:scale-125:hover{--tw-scale-x: 1.25;--tw-scale-y: 1.25;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:text-\\[\\#6952C7\\]:hover{--tw-text-opacity: 1;color:rgb(105 82 199 / var(--tw-text-opacity, 1))}.hover\\:opacity-90:hover{opacity:.9}.group:hover .group-hover\\:opacity-100{opacity:1}.data-\\[state\\=open\\]\\:animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.data-\\[state\\=closed\\]\\:animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.data-\\[state\\=closed\\]\\:fade-out-0[data-state=closed]{--tw-exit-opacity: 0}.data-\\[state\\=open\\]\\:fade-in-0[data-state=open]{--tw-enter-opacity: 0}.data-\\[state\\=closed\\]\\:zoom-out-95[data-state=closed]{--tw-exit-scale: .95}.data-\\[state\\=open\\]\\:zoom-in-95[data-state=open]{--tw-enter-scale: .95}.data-\\[side\\=bottom\\]\\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y: -.5rem}.data-\\[side\\=left\\]\\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x: .5rem}.data-\\[side\\=right\\]\\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x: -.5rem}.data-\\[side\\=top\\]\\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y: .5rem}@media(min-width:640px){.sm\\:w-\\[80vw\\]{width:80vw}}@media(min-width:768px){.md\\:h-\\[100vh\\]{height:100vh}.md\\:w-1\\/2{width:50%}.md\\:w-\\[770px\\]{width:770px}.md\\:translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.md\\:translate-x-full{--tw-translate-x: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.md\\:translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.md\\:flex-row{flex-direction:row}}@media(min-width:1024px){.lg\\:h-\\[100vh\\]{height:100vh}.lg\\:w-1\\/2{width:50%}.lg\\:w-2\\/3{width:66.666667%}.lg\\:translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:translate-x-full{--tw-translate-x: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:flex-row{flex-direction:row}.lg\\:rounded-l-xl{border-top-left-radius:.75rem;border-bottom-left-radius:.75rem}.lg\\:rounded-bl-xl{border-bottom-left-radius:.75rem}}';
|
|
14
|
-
function
|
|
15
|
-
return
|
|
13
|
+
const fr = '*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.container{width:100%}@media(min-width:640px){.container{max-width:640px}}@media(min-width:768px){.container{max-width:768px}}@media(min-width:1024px){.container{max-width:1024px}}@media(min-width:1280px){.container{max-width:1280px}}@media(min-width:1536px){.container{max-width:1536px}}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-0{bottom:0}.left-0{left:0}.right-0{right:0}.top-0{top:0}.top-full{top:100%}.z-40{z-index:40}.z-50{z-index:50}.m-1{margin:.25rem}.m-3{margin:.75rem}.mx-3{margin-left:.75rem;margin-right:.75rem}.my-2{margin-top:.5rem;margin-bottom:.5rem}.my-5{margin-top:1.25rem;margin-bottom:1.25rem}.mb-1{margin-bottom:.25rem}.mb-16{margin-bottom:4rem}.mb-2{margin-bottom:.5rem}.mb-20{margin-bottom:5rem}.mb-24{margin-bottom:6rem}.mb-4{margin-bottom:1rem}.mb-8{margin-bottom:2rem}.mt-1{margin-top:.25rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.line-clamp-1{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.h-12{height:3rem}.h-28{height:7rem}.h-3{height:.75rem}.h-6{height:1.5rem}.h-\\[120px\\]{height:120px}.h-\\[200px\\]{height:200px}.h-\\[60px\\]{height:60px}.h-\\[90vh\\]{height:90vh}.h-fit{height:-moz-fit-content;height:fit-content}.h-full{height:100%}.h-screen{height:100vh}.w-28{width:7rem}.w-3{width:.75rem}.w-5\\/6{width:83.333333%}.w-6{width:1.5rem}.w-72{width:18rem}.w-\\[100vw\\]{width:100vw}.w-\\[120px\\]{width:120px}.w-\\[150px\\]{width:150px}.w-\\[60px\\]{width:60px}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-max{width:-moz-max-content;width:max-content}.max-w-\\[200px\\]{max-width:200px}.max-w-\\[75\\%\\]{max-width:75%}.flex-1{flex:1 1 0%}.flex-shrink-0{flex-shrink:0}.flex-grow{flex-grow:1}.translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-full{--tw-translate-y: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize{resize:both}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-5{gap:1.25rem}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-scroll{overflow-y:scroll}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.text-ellipsis{text-overflow:ellipsis}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-\\[10px\\]{border-radius:10px}.rounded-\\[20px\\]{border-radius:20px}.rounded-\\[5px\\]{border-radius:5px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-xl{border-radius:.75rem}.rounded-l-\\[20px\\]{border-top-left-radius:20px;border-bottom-left-radius:20px}.rounded-l-xl{border-top-left-radius:.75rem;border-bottom-left-radius:.75rem}.rounded-r-xl{border-top-right-radius:.75rem;border-bottom-right-radius:.75rem}.rounded-bl-2xl{border-bottom-left-radius:1rem}.rounded-br-xl{border-bottom-right-radius:.75rem}.rounded-tr-\\[20px\\]{border-top-right-radius:20px}.rounded-tr-\\[5px\\]{border-top-right-radius:5px}.border{border-width:1px}.border-0{border-width:0px}.border-b-2{border-bottom-width:2px}.border-l-2{border-left-width:2px}.border-t-2{border-top-width:2px}.border-none{border-style:none}.border-\\[\\#C9C2DE\\]{--tw-border-opacity: 1;border-color:rgb(201 194 222 / var(--tw-border-opacity, 1))}.border-\\[\\#E5E5E5\\]{--tw-border-opacity: 1;border-color:rgb(229 229 229 / var(--tw-border-opacity, 1))}.border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity, 1))}.bg-\\[\\#553D94\\]{--tw-bg-opacity: 1;background-color:rgb(85 61 148 / var(--tw-bg-opacity, 1))}.bg-\\[\\#6851C6\\]{--tw-bg-opacity: 1;background-color:rgb(104 81 198 / var(--tw-bg-opacity, 1))}.bg-\\[\\#804C9E0D\\]{background-color:#804c9e0d}.bg-\\[\\#A21CAF\\]{--tw-bg-opacity: 1;background-color:rgb(162 28 175 / var(--tw-bg-opacity, 1))}.bg-\\[\\#AB192D\\]{--tw-bg-opacity: 1;background-color:rgb(171 25 45 / var(--tw-bg-opacity, 1))}.bg-\\[\\#E2DBFF\\]{--tw-bg-opacity: 1;background-color:rgb(226 219 255 / var(--tw-bg-opacity, 1))}.bg-\\[\\#E3DEEF\\]{--tw-bg-opacity: 1;background-color:rgb(227 222 239 / var(--tw-bg-opacity, 1))}.bg-\\[\\#F3F3F3\\]{--tw-bg-opacity: 1;background-color:rgb(243 243 243 / var(--tw-bg-opacity, 1))}.bg-\\[\\#FFFFFF\\],.bg-\\[\\#ffffff\\]{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-black\\/30{background-color:#0000004d}.bg-indigo-300{--tw-bg-opacity: 1;background-color:rgb(165 180 252 / var(--tw-bg-opacity, 1))}.bg-popover{background-color:hsl(var(--popover))}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0{padding:0}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-\\[1px\\]{padding:1px}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-7{padding-left:1.75rem;padding-right:1.75rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-4{padding-top:1rem;padding-bottom:1rem}.pb-2{padding-bottom:.5rem}.pl-2{padding-left:.5rem}.pr-5{padding-right:1.25rem}.text-left{text-align:left}.text-center{text-align:center}.font-nunitoSans{font-family:Nunito Sans}.text-\\[12px\\]{font-size:12px}.text-\\[14px\\]{font-size:14px}.text-\\[15px\\]{font-size:15px}.text-base{font-size:1rem;line-height:1.5rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.italic{font-style:italic}.leading-snug{line-height:1.375}.text-\\[\\#000000\\]{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity, 1))}.text-\\[\\#14121F\\]{--tw-text-opacity: 1;color:rgb(20 18 31 / var(--tw-text-opacity, 1))}.text-\\[\\#18181B\\]{--tw-text-opacity: 1;color:rgb(24 24 27 / var(--tw-text-opacity, 1))}.text-\\[\\#232323\\]{--tw-text-opacity: 1;color:rgb(35 35 35 / var(--tw-text-opacity, 1))}.text-\\[\\#323135\\]{--tw-text-opacity: 1;color:rgb(50 49 53 / var(--tw-text-opacity, 1))}.text-\\[\\#494949\\]{--tw-text-opacity: 1;color:rgb(73 73 73 / var(--tw-text-opacity, 1))}.text-\\[\\#555555\\]{--tw-text-opacity: 1;color:rgb(85 85 85 / var(--tw-text-opacity, 1))}.text-\\[\\#5B5B5B\\]{--tw-text-opacity: 1;color:rgb(91 91 91 / var(--tw-text-opacity, 1))}.text-\\[\\#68656E\\]{--tw-text-opacity: 1;color:rgb(104 101 110 / var(--tw-text-opacity, 1))}.text-\\[\\#959595\\]{--tw-text-opacity: 1;color:rgb(149 149 149 / var(--tw-text-opacity, 1))}.text-\\[\\#EC5050\\]{--tw-text-opacity: 1;color:rgb(236 80 80 / var(--tw-text-opacity, 1))}.text-\\[\\#FBFBFC\\]{--tw-text-opacity: 1;color:rgb(251 251 252 / var(--tw-text-opacity, 1))}.text-\\[\\#FFFFFF\\]{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-black{--tw-text-opacity: 1;color:rgb(0 0 0 / var(--tw-text-opacity, 1))}.text-gray-300{--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity, 1))}.text-gray-500{--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity, 1))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-popover-foreground{color:hsl(var(--popover-foreground))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.text-yellow-500{--tw-text-opacity: 1;color:rgb(234 179 8 / var(--tw-text-opacity, 1))}.line-through{text-decoration-line:line-through}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-80{opacity:.8}.shadow-\\[0px_2px_2px_0px_\\#9292BC40\\]{--tw-shadow: 0px 2px 2px 0px #9292BC40;--tw-shadow-colored: 0px 2px 2px 0px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-\\[0px_4px_10px_0px_\\#5F499840\\]{--tw-shadow: 0px 4px 10px 0px #5F499840;--tw-shadow-colored: 0px 4px 10px 0px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-300{transition-duration:.3s}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}.duration-300{animation-duration:.3s}.ease-in-out{animation-timing-function:cubic-bezier(.4,0,.2,1)}.running{animation-play-state:running}html,body,#root{margin:0;padding:0}:root{line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;padding:0}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;cursor:pointer;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}@media(prefers-color-scheme:light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.hover\\:scale-125:hover{--tw-scale-x: 1.25;--tw-scale-y: 1.25;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:text-\\[\\#6952C7\\]:hover{--tw-text-opacity: 1;color:rgb(105 82 199 / var(--tw-text-opacity, 1))}.hover\\:opacity-90:hover{opacity:.9}.group:hover .group-hover\\:opacity-100{opacity:1}.data-\\[state\\=open\\]\\:animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.data-\\[state\\=closed\\]\\:animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.data-\\[state\\=closed\\]\\:fade-out-0[data-state=closed]{--tw-exit-opacity: 0}.data-\\[state\\=open\\]\\:fade-in-0[data-state=open]{--tw-enter-opacity: 0}.data-\\[state\\=closed\\]\\:zoom-out-95[data-state=closed]{--tw-exit-scale: .95}.data-\\[state\\=open\\]\\:zoom-in-95[data-state=open]{--tw-enter-scale: .95}.data-\\[side\\=bottom\\]\\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y: -.5rem}.data-\\[side\\=left\\]\\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x: .5rem}.data-\\[side\\=right\\]\\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x: -.5rem}.data-\\[side\\=top\\]\\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y: .5rem}@media(min-width:640px){.sm\\:w-\\[80vw\\]{width:80vw}}@media(min-width:768px){.md\\:h-\\[100vh\\]{height:100vh}.md\\:w-1\\/2{width:50%}.md\\:w-\\[770px\\]{width:770px}.md\\:translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.md\\:translate-x-full{--tw-translate-x: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.md\\:translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.md\\:flex-row{flex-direction:row}}@media(min-width:1024px){.lg\\:h-\\[100vh\\]{height:100vh}.lg\\:w-1\\/2{width:50%}.lg\\:w-2\\/3{width:66.666667%}.lg\\:translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:translate-x-full{--tw-translate-x: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\\:flex-row{flex-direction:row}.lg\\:rounded-l-xl{border-top-left-radius:.75rem;border-bottom-left-radius:.75rem}.lg\\:rounded-bl-xl{border-bottom-left-radius:.75rem}}';
|
|
14
|
+
function vo() {
|
|
15
|
+
return it(() => {
|
|
16
16
|
if (typeof document < "u") {
|
|
17
17
|
const t = document.createElement("style");
|
|
18
|
-
return t.textContent =
|
|
18
|
+
return t.textContent = fr, document.head.appendChild(t), () => {
|
|
19
19
|
document.head.removeChild(t);
|
|
20
20
|
};
|
|
21
21
|
}
|
|
22
22
|
}, []), null;
|
|
23
23
|
}
|
|
24
|
-
const
|
|
24
|
+
const hr = {
|
|
25
25
|
store: {
|
|
26
26
|
storeCode: "",
|
|
27
27
|
storeName: "",
|
|
@@ -55,30 +55,30 @@ const pr = {
|
|
|
55
55
|
mobile: []
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
|
-
},
|
|
58
|
+
}, Be = De({
|
|
59
59
|
name: "store",
|
|
60
|
-
initialState:
|
|
60
|
+
initialState: hr,
|
|
61
61
|
reducers: {
|
|
62
62
|
setStore: (t, e) => {
|
|
63
63
|
t.store = e.payload;
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
|
-
}), { setStore:
|
|
66
|
+
}), { setStore: ko } = Be.actions, mr = Be.reducer, wr = {
|
|
67
67
|
product: null
|
|
68
|
-
},
|
|
68
|
+
}, Ue = De({
|
|
69
69
|
name: "product",
|
|
70
|
-
initialState:
|
|
70
|
+
initialState: wr,
|
|
71
71
|
reducers: {
|
|
72
72
|
setProduct: (t, e) => {
|
|
73
73
|
t.product = e.payload;
|
|
74
74
|
}
|
|
75
75
|
}
|
|
76
|
-
}), { setProduct: oe } =
|
|
76
|
+
}), { setProduct: oe } = Ue.actions, gr = Ue.reducer, br = pr({
|
|
77
77
|
reducer: {
|
|
78
|
-
store:
|
|
79
|
-
product:
|
|
78
|
+
store: mr,
|
|
79
|
+
product: gr
|
|
80
80
|
}
|
|
81
|
-
}),
|
|
81
|
+
}), xr = ({ children: t }) => /* @__PURE__ */ a(ur, { store: br, children: t }), Vt = (t) => {
|
|
82
82
|
const e = new CustomEvent("reactCartUpdated", {
|
|
83
83
|
detail: {
|
|
84
84
|
cartUpdated: !0,
|
|
@@ -87,31 +87,31 @@ const pr = {
|
|
|
87
87
|
});
|
|
88
88
|
window.dispatchEvent(e);
|
|
89
89
|
};
|
|
90
|
-
function
|
|
90
|
+
function yr({
|
|
91
91
|
...t
|
|
92
92
|
}) {
|
|
93
|
-
return /* @__PURE__ */ a(
|
|
93
|
+
return /* @__PURE__ */ a(Le.Root, { "data-slot": "popover", ...t });
|
|
94
94
|
}
|
|
95
|
-
function
|
|
95
|
+
function vr({
|
|
96
96
|
...t
|
|
97
97
|
}) {
|
|
98
|
-
return /* @__PURE__ */ a(
|
|
98
|
+
return /* @__PURE__ */ a(Le.Trigger, { "data-slot": "popover-trigger", ...t });
|
|
99
99
|
}
|
|
100
|
-
const
|
|
100
|
+
const lt = () => ({ aiConversationUrl: "https://mdv3qwfi2j.execute-api.us-east-1.amazonaws.com/dev/api/bedrock/invoke/stream", xAPIKey: "BJBtjpPkqGatuoa3qJqdR8aHXSsHkgvGaootbubi", serverUrl: "https://tanya-sfcc-server.vercel.app/", basePath: "sc-api" }), qe = async () => {
|
|
101
101
|
const t = "https://tanya-sfcc-server.vercel.app/";
|
|
102
102
|
try {
|
|
103
103
|
const e = await T.post(
|
|
104
|
-
`${t}api/auth/token-bm-grant?baseUrl=${
|
|
104
|
+
`${t}api/auth/token-bm-grant?baseUrl=${Q()}&siteId=${H()}`
|
|
105
105
|
);
|
|
106
106
|
return e.status === 200 && e.data.access_token ? e.data.access_token : (console.error("Failed to fetch token:", e.data), null);
|
|
107
107
|
} catch (e) {
|
|
108
108
|
return T.isAxiosError(e) ? console.error("Error fetching token:", e.response || e.message) : console.error("Unexpected error:", e), null;
|
|
109
109
|
}
|
|
110
|
-
},
|
|
110
|
+
}, Me = async (t) => {
|
|
111
111
|
const e = "https://tanya-sfcc-server.vercel.app/";
|
|
112
112
|
try {
|
|
113
113
|
const r = JSON.parse(sessionStorage.getItem("customerData") || "{}").dwsid, o = await T.post(
|
|
114
|
-
`${e}api/auth/token-existing-guest-customer?dwsid=${r}&baseUrl=${
|
|
114
|
+
`${e}api/auth/token-existing-guest-customer?dwsid=${r}&baseUrl=${Q()}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
115
115
|
{},
|
|
116
116
|
{
|
|
117
117
|
headers: {
|
|
@@ -125,45 +125,42 @@ const yt = () => ({ aiConversationUrl: "https://mdv3qwfi2j.execute-api.us-east-1
|
|
|
125
125
|
return T.isAxiosError(r) ? console.error("Error creating basket:", r.response || r.message) : console.error("Unexpected error:", r), null;
|
|
126
126
|
}
|
|
127
127
|
};
|
|
128
|
-
async function
|
|
129
|
-
var
|
|
130
|
-
const t =
|
|
128
|
+
async function Ot() {
|
|
129
|
+
var b;
|
|
130
|
+
const t = H(), e = "access_token_" + t, r = "expires_in_" + t, o = localStorage.getItem(r), n = localStorage.getItem(e);
|
|
131
131
|
console.log(n);
|
|
132
|
-
const
|
|
132
|
+
const d = ((b = JSON.parse(sessionStorage.getItem("customerData") || "{}")) == null ? void 0 : b.isGuest) || !0;
|
|
133
133
|
if (o && n && (/* @__PURE__ */ new Date()).getTime() < parseInt(o))
|
|
134
134
|
return console.log("access token found in local storage"), { access_token: n, expires_in: o };
|
|
135
|
-
const { serverUrl:
|
|
135
|
+
const { serverUrl: s } = lt(), l = JSON.parse(
|
|
136
136
|
sessionStorage.getItem("customerData") || "{}"
|
|
137
137
|
).dwsid, i = JSON.parse(
|
|
138
138
|
sessionStorage.getItem("customerData") || "{}"
|
|
139
139
|
).usrRef;
|
|
140
140
|
try {
|
|
141
|
-
const
|
|
142
|
-
|
|
141
|
+
const m = d ? "unregister-auth" : "register-auth";
|
|
142
|
+
return (await T.get(
|
|
143
|
+
`${s}sc-api/${m}?dwsid=${l}&email=${i}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}&siteId=${H()}&token=true`,
|
|
143
144
|
{
|
|
144
145
|
withCredentials: !0
|
|
145
146
|
}
|
|
146
|
-
);
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
String((/* @__PURE__ */ new Date()).getTime() + S.data.expires_in * 1e3)
|
|
150
|
-
), localStorage.setItem("isGuest", l ? "true" : "false"), S.data;
|
|
151
|
-
} catch (h) {
|
|
152
|
-
console.log(h);
|
|
147
|
+
)).data;
|
|
148
|
+
} catch (m) {
|
|
149
|
+
console.log(m);
|
|
153
150
|
}
|
|
154
151
|
}
|
|
155
|
-
const
|
|
152
|
+
const Q = () => sessionStorage.getItem("Host"), H = () => sessionStorage.getItem("SiteId"), Z = () => sessionStorage.getItem("pubCfg"), tt = () => sessionStorage.getItem("envRef"), et = () => sessionStorage.getItem("orgRef"), be = async (t) => {
|
|
156
153
|
console.log("fetching results");
|
|
157
|
-
const { serverUrl: e, basePath: r } =
|
|
154
|
+
const { serverUrl: e, basePath: r } = lt();
|
|
158
155
|
let o = "";
|
|
159
156
|
{
|
|
160
|
-
const n = await
|
|
157
|
+
const n = await Ot();
|
|
161
158
|
console.log("the token from getSearchResults", n), o = n.access_token;
|
|
162
159
|
}
|
|
163
160
|
try {
|
|
164
|
-
const n =
|
|
161
|
+
const n = Q();
|
|
165
162
|
return (await T.get(
|
|
166
|
-
`${e}${r}/search-sfcc?baseUrl=${n}&query=${t}&siteId=${
|
|
163
|
+
`${e}${r}/search-sfcc?baseUrl=${n}&query=${t}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
167
164
|
{
|
|
168
165
|
headers: {
|
|
169
166
|
"Content-Type": "application/json",
|
|
@@ -174,13 +171,13 @@ const rt = () => sessionStorage.getItem("Host"), R = () => sessionStorage.getIte
|
|
|
174
171
|
} catch (n) {
|
|
175
172
|
throw console.error("Error fetching search results:", n), n;
|
|
176
173
|
}
|
|
177
|
-
},
|
|
174
|
+
}, He = async (t) => {
|
|
178
175
|
if (!t) throw new Error("Product ID is required");
|
|
179
|
-
const { serverUrl: e, basePath: r } =
|
|
176
|
+
const { serverUrl: e, basePath: r } = lt(), o = Q();
|
|
180
177
|
console.log("calling access");
|
|
181
|
-
const { access_token: n } = await
|
|
178
|
+
const { access_token: n } = await Ot();
|
|
182
179
|
return console.log(n), (await T.get(
|
|
183
|
-
`${e}${r}/product-sfcc/${t}?baseUrl=${o}&siteId=${
|
|
180
|
+
`${e}${r}/product-sfcc/${t}?baseUrl=${o}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
184
181
|
{
|
|
185
182
|
headers: {
|
|
186
183
|
"Content-Type": "application/json",
|
|
@@ -188,24 +185,24 @@ const rt = () => sessionStorage.getItem("Host"), R = () => sessionStorage.getIte
|
|
|
188
185
|
}
|
|
189
186
|
}
|
|
190
187
|
)).data;
|
|
191
|
-
},
|
|
188
|
+
}, kr = async (t) => {
|
|
192
189
|
if (!t) throw new Error("customerId is required");
|
|
193
|
-
const e = await
|
|
190
|
+
const e = await qe(), { customer_token: r } = await Me(
|
|
194
191
|
e
|
|
195
|
-
), { serverUrl: o, basePath: n } =
|
|
192
|
+
), { serverUrl: o, basePath: n } = lt(), s = (await Ot()).access_token;
|
|
196
193
|
return (await T.get(
|
|
197
|
-
`${o}${n}/get-interest?baseUrl=${
|
|
194
|
+
`${o}${n}/get-interest?baseUrl=${Q()}&customerId=${t}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
198
195
|
{
|
|
199
196
|
headers: {
|
|
200
197
|
"Content-Type": "application/json",
|
|
201
|
-
Authorization: `Bearer ${
|
|
198
|
+
Authorization: `Bearer ${s}`
|
|
202
199
|
}
|
|
203
200
|
}
|
|
204
201
|
)).data;
|
|
205
|
-
}, xe = (t) => String(typeof t == "string" ? t : t["en-US"] || t),
|
|
202
|
+
}, xe = (t) => String(typeof t == "string" ? t : t["en-US"] || t), ye = (t) => t != null && t.image ? [t.image] : "variants" in t ? t.variants[0].images : t.masterVariant.images.map((e) => e.url), Sr = (t, e) => t.toLocaleString("en-US", {
|
|
206
203
|
style: "currency",
|
|
207
204
|
currency: e || "USD"
|
|
208
|
-
}),
|
|
205
|
+
}), ve = (t) => {
|
|
209
206
|
var e, r, o;
|
|
210
207
|
return "variants" in t ? {
|
|
211
208
|
centAmount: (e = t.variants[0]) == null ? void 0 : e.prices.EUR.max,
|
|
@@ -214,37 +211,37 @@ const rt = () => sessionStorage.getItem("Host"), R = () => sessionStorage.getIte
|
|
|
214
211
|
centAmount: (r = t.masterVariant) == null ? void 0 : r.prices[0].value.centAmount,
|
|
215
212
|
currencyCode: (o = t.masterVariant) == null ? void 0 : o.prices[0].value.currencyCode
|
|
216
213
|
};
|
|
217
|
-
},
|
|
214
|
+
}, Cr = (t) => t.charAt(0).toUpperCase() + t.slice(1), ke = (t, e) => t.length < e ? t : t.slice(0, e) + "...", Xt = (t) => t.split("\\n").map((e, r) => {
|
|
218
215
|
const o = e.match(/^(\d+)\.\s(.+)/);
|
|
219
216
|
return o ? `<p key=${r} class="mb-2"><strong>${o[1]}.</strong> ${o[2]}</p>` : e.trim() ? `<p key=${r} class="mb-2">${e}</p>` : "<br/>";
|
|
220
217
|
}).join("");
|
|
221
|
-
function
|
|
222
|
-
const t = () => window.innerWidth < 425 ? 1 : window.innerWidth < 768 ? 2 : 4, [e, r] =
|
|
223
|
-
return
|
|
218
|
+
function _r() {
|
|
219
|
+
const t = () => window.innerWidth < 425 ? 1 : window.innerWidth < 768 ? 2 : 4, [e, r] = z(t);
|
|
220
|
+
return it(() => {
|
|
224
221
|
const o = () => r(t());
|
|
225
222
|
return window.addEventListener("resize", o), () => window.removeEventListener("resize", o);
|
|
226
223
|
}, []), e;
|
|
227
224
|
}
|
|
228
|
-
const
|
|
225
|
+
const Fr = ({
|
|
229
226
|
product: t
|
|
230
227
|
}) => {
|
|
231
|
-
const e = je(), r =
|
|
228
|
+
const e = je(), r = _r(), [o, n] = z(0), d = () => {
|
|
232
229
|
n(
|
|
233
230
|
(i) => i + r >= t.length ? 0 : i + r
|
|
234
231
|
);
|
|
235
|
-
},
|
|
232
|
+
}, s = () => {
|
|
236
233
|
n(
|
|
237
234
|
(i) => i - r < 0 ? t.length - (t.length % r || r) : i - r
|
|
238
235
|
);
|
|
239
|
-
},
|
|
240
|
-
const
|
|
241
|
-
e(oe(
|
|
236
|
+
}, l = async (i) => {
|
|
237
|
+
const b = await He(i);
|
|
238
|
+
e(oe(b));
|
|
242
239
|
};
|
|
243
240
|
return /* @__PURE__ */ a("div", { className: "mt-2 overflow-x-hidden", children: /* @__PURE__ */ u("div", { className: "flex items-center justify-center gap-4 relative", children: [
|
|
244
241
|
(t == null ? void 0 : t.length) > r && /* @__PURE__ */ a(
|
|
245
242
|
"button",
|
|
246
243
|
{
|
|
247
|
-
onClick:
|
|
244
|
+
onClick: s,
|
|
248
245
|
className: "absolute z-50 left-0 text-[#000000] bg-[#ffffff] rounded-full p-2 flex items-center h-fit",
|
|
249
246
|
style: {
|
|
250
247
|
height: "30px",
|
|
@@ -255,19 +252,19 @@ const Cr = ({
|
|
|
255
252
|
}
|
|
256
253
|
),
|
|
257
254
|
/* @__PURE__ */ a("div", { className: "flex gap-5 justify-center flex-1 overflow-hidden", children: t.slice(o, o + r).map((i) => {
|
|
258
|
-
var
|
|
255
|
+
var b, m, S, _;
|
|
259
256
|
return /* @__PURE__ */ u(
|
|
260
257
|
"div",
|
|
261
258
|
{
|
|
262
259
|
className: "flex-shrink-0 flex flex-col w-[150px] h-[200px] p-2 items-center justify-between cursor-pointer bg-[#FFFFFF] rounded-[10px] shadow-[0px_2px_2px_0px_#9292BC40]",
|
|
263
260
|
onClick: () => {
|
|
264
|
-
|
|
261
|
+
l(i.product_id ?? i.productId);
|
|
265
262
|
},
|
|
266
263
|
children: [
|
|
267
264
|
/* @__PURE__ */ a("div", { className: "w-full p-2 flex items-center justify-center bg-white", children: /* @__PURE__ */ a(
|
|
268
265
|
"img",
|
|
269
266
|
{
|
|
270
|
-
src: ((
|
|
267
|
+
src: ((b = ye(i)[0]) == null ? void 0 : b.link) || ye(i)[0] || // fallback if it's a string
|
|
271
268
|
"https://via.placeholder.com/120",
|
|
272
269
|
alt: i != null && i.productName ? i.productName : "Product",
|
|
273
270
|
className: "w-28 h-28 rounded-[10px] transition-transform duration-300 hover:scale-125 object-cover"
|
|
@@ -279,8 +276,8 @@ const Cr = ({
|
|
|
279
276
|
className: "text-white w-full p-2 text-[12px] text-center h-[60px]",
|
|
280
277
|
children: [
|
|
281
278
|
/* @__PURE__ */ u("div", { className: "relative inline-block group", children: [
|
|
282
|
-
/* @__PURE__ */ a("div", { className: "w-full line-clamp-1 overflow-hidden text-ellipsis text-[#000000] font-medium font-nunitoSans", children: i != null && i.productName ? i.productName : i != null && i.product_name ? i.product_name :
|
|
283
|
-
xe((
|
|
279
|
+
/* @__PURE__ */ a("div", { className: "w-full line-clamp-1 overflow-hidden text-ellipsis text-[#000000] font-medium font-nunitoSans", children: i != null && i.productName ? i.productName : i != null && i.product_name ? i.product_name : ke(
|
|
280
|
+
xe((m = i == null ? void 0 : i.name) == null ? void 0 : m["en-US"]),
|
|
284
281
|
60
|
|
285
282
|
) || "Product" }),
|
|
286
283
|
/* @__PURE__ */ a(
|
|
@@ -294,7 +291,7 @@ const Cr = ({
|
|
|
294
291
|
marginBottom: "5px",
|
|
295
292
|
zIndex: 50
|
|
296
293
|
},
|
|
297
|
-
children: i != null && i.productName ? i.productName : i != null && i.product_name ? i.product_name :
|
|
294
|
+
children: i != null && i.productName ? i.productName : i != null && i.product_name ? i.product_name : ke(
|
|
298
295
|
xe((S = i == null ? void 0 : i.name) == null ? void 0 : S["en-US"]),
|
|
299
296
|
60
|
|
300
297
|
) || "Product"
|
|
@@ -302,9 +299,9 @@ const Cr = ({
|
|
|
302
299
|
)
|
|
303
300
|
] }),
|
|
304
301
|
/* @__PURE__ */ u("div", { className: " flex text-center items-center gap-2 text-[14px] text-[#14121F] font-bold font-nunitoSans text-base mb-1", children: [
|
|
305
|
-
/* @__PURE__ */ a("p", { children:
|
|
306
|
-
i != null && i.price ? Number(i == null ? void 0 : i.price) :
|
|
307
|
-
(_ =
|
|
302
|
+
/* @__PURE__ */ a("p", { children: Sr(
|
|
303
|
+
i != null && i.price ? Number(i == null ? void 0 : i.price) : ve(i).centAmount || 0,
|
|
304
|
+
(_ = ve(i)) == null ? void 0 : _.currencyCode
|
|
308
305
|
) }),
|
|
309
306
|
/* @__PURE__ */ u("p", { className: "text-[#14121F] font-normal line-through text-sm font-nunitoSans truncate", children: [
|
|
310
307
|
"$",
|
|
@@ -322,7 +319,7 @@ const Cr = ({
|
|
|
322
319
|
(t == null ? void 0 : t.length) > r && /* @__PURE__ */ a(
|
|
323
320
|
"button",
|
|
324
321
|
{
|
|
325
|
-
onClick:
|
|
322
|
+
onClick: d,
|
|
326
323
|
className: "absolute z-50 right-0 text-[#000000] bg-[#ffffff] rounded-full p-2 flex items-center h-fit",
|
|
327
324
|
style: {
|
|
328
325
|
height: "30px",
|
|
@@ -333,7 +330,7 @@ const Cr = ({
|
|
|
333
330
|
}
|
|
334
331
|
)
|
|
335
332
|
] }) });
|
|
336
|
-
},
|
|
333
|
+
}, Ir = ({ chat: t, storeDetails: e }) => /* @__PURE__ */ a("div", { className: "bg-[#FFFFFF] px-7 py-4 rounded-r-xl rounded-bl-2xl w-full", children: t.map((r, o) => /* @__PURE__ */ u(
|
|
337
334
|
"div",
|
|
338
335
|
{
|
|
339
336
|
className: "mb-4 p-3 rounded-xl",
|
|
@@ -346,11 +343,11 @@ const Cr = ({
|
|
|
346
343
|
"div",
|
|
347
344
|
{
|
|
348
345
|
className: "font-nunitoSans font-bold text-sm text-[#494949] p-2 w-fit rounded-[20px]",
|
|
349
|
-
children:
|
|
346
|
+
children: Cr(r.keyword) || "No keyword"
|
|
350
347
|
}
|
|
351
348
|
),
|
|
352
349
|
/* @__PURE__ */ a(
|
|
353
|
-
|
|
350
|
+
Fr,
|
|
354
351
|
{
|
|
355
352
|
product: r.items,
|
|
356
353
|
storeDetails: e
|
|
@@ -359,13 +356,14 @@ const Cr = ({
|
|
|
359
356
|
]
|
|
360
357
|
},
|
|
361
358
|
o
|
|
362
|
-
)) }),
|
|
363
|
-
|
|
359
|
+
)) }), Ve = async (t, e) => {
|
|
360
|
+
var d, s;
|
|
361
|
+
const { serverUrl: r, basePath: o } = lt(), n = `${r}`;
|
|
364
362
|
console.log(`customer_token
|
|
365
363
|
`, t);
|
|
366
364
|
try {
|
|
367
|
-
|
|
368
|
-
`${n}${o}/basket/create?baseUrl=${
|
|
365
|
+
const l = await T.post(
|
|
366
|
+
`${n}${o}/basket/create?baseUrl=${Q()}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
369
367
|
e,
|
|
370
368
|
{
|
|
371
369
|
headers: {
|
|
@@ -373,15 +371,22 @@ const Cr = ({
|
|
|
373
371
|
Authorization: t
|
|
374
372
|
}
|
|
375
373
|
}
|
|
376
|
-
)
|
|
374
|
+
);
|
|
375
|
+
return window.postMessage(
|
|
376
|
+
{
|
|
377
|
+
type: "WIDGET_CREATED_BASKET",
|
|
378
|
+
basketId: ((d = l.data) == null ? void 0 : d.basket_id) || ((s = l.data) == null ? void 0 : s.basketId)
|
|
379
|
+
},
|
|
380
|
+
"*"
|
|
381
|
+
), l.data;
|
|
377
382
|
} catch (l) {
|
|
378
383
|
return T.isAxiosError(l) ? console.error("Error creating basket:", l.response || l.message) : console.error("Unexpected error:", l), null;
|
|
379
384
|
}
|
|
380
|
-
},
|
|
381
|
-
const { serverUrl: o, basePath: n } =
|
|
385
|
+
}, Rt = async (t, e, r) => {
|
|
386
|
+
const { serverUrl: o, basePath: n } = lt(), d = `${o}`;
|
|
382
387
|
try {
|
|
383
|
-
const
|
|
384
|
-
`${
|
|
388
|
+
const s = await T.post(
|
|
389
|
+
`${d}${n}/basket/add-product/${t}?baseUrl=${Q()}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
385
390
|
e,
|
|
386
391
|
{
|
|
387
392
|
headers: {
|
|
@@ -390,42 +395,62 @@ const Cr = ({
|
|
|
390
395
|
}
|
|
391
396
|
}
|
|
392
397
|
);
|
|
393
|
-
return
|
|
394
|
-
} catch (
|
|
395
|
-
return T.isAxiosError(
|
|
398
|
+
return s.status === 200 && s.data ? s.data : null;
|
|
399
|
+
} catch (s) {
|
|
400
|
+
return T.isAxiosError(s) ? console.error(
|
|
396
401
|
"Error adding products to basket:",
|
|
397
|
-
|
|
398
|
-
) : console.error("Unexpected error:",
|
|
402
|
+
s.response || s.message
|
|
403
|
+
) : console.error("Unexpected error:", s), null;
|
|
404
|
+
}
|
|
405
|
+
}, Re = async ({
|
|
406
|
+
basketId: t,
|
|
407
|
+
customer_token: e
|
|
408
|
+
}) => {
|
|
409
|
+
var d;
|
|
410
|
+
const { serverUrl: r, basePath: o } = lt(), n = `${r}`;
|
|
411
|
+
try {
|
|
412
|
+
const s = await T.get(
|
|
413
|
+
`${n}${o}/basket/${t}?baseUrl=${Q()}&siteId=${H()}&pubCfg=${Z()}&envRef=${tt()}&orgRef=${et()}`,
|
|
414
|
+
{
|
|
415
|
+
headers: {
|
|
416
|
+
"Content-Type": "application/json",
|
|
417
|
+
Authorization: e
|
|
418
|
+
}
|
|
419
|
+
}
|
|
420
|
+
);
|
|
421
|
+
return { status: s.status, data: s.data };
|
|
422
|
+
} catch (s) {
|
|
423
|
+
return T.isAxiosError(s) ? { status: (d = s.response) == null ? void 0 : d.status, data: null } : { status: null, data: null };
|
|
399
424
|
}
|
|
400
|
-
}, Yt = "sfcc_basket_id",
|
|
401
|
-
const
|
|
425
|
+
}, Yt = "sfcc_basket_id", Se = "sfcc_customer_token", Tt = "sfcc_token_expiry", Nr = 300 * 1e3, It = "1.0.0";
|
|
426
|
+
const st = (t) => {
|
|
402
427
|
try {
|
|
403
428
|
t ? localStorage.setItem(Yt, t) : localStorage.removeItem(Yt);
|
|
404
429
|
} catch (e) {
|
|
405
430
|
console.error("Error saving basket ID to storage:", e);
|
|
406
431
|
}
|
|
407
|
-
},
|
|
432
|
+
}, Kt = (t) => {
|
|
408
433
|
try {
|
|
409
434
|
if (t) {
|
|
410
|
-
localStorage.setItem(
|
|
411
|
-
const e = Date.now() +
|
|
412
|
-
localStorage.setItem(
|
|
435
|
+
localStorage.setItem(Se, t);
|
|
436
|
+
const e = Date.now() + Nr;
|
|
437
|
+
localStorage.setItem(Tt, e.toString());
|
|
413
438
|
} else
|
|
414
|
-
localStorage.removeItem(
|
|
439
|
+
localStorage.removeItem(Se);
|
|
415
440
|
} catch (e) {
|
|
416
441
|
console.error("Error storing token:", e);
|
|
417
442
|
}
|
|
418
|
-
},
|
|
419
|
-
var
|
|
420
|
-
const t = je(), e =
|
|
421
|
-
if (
|
|
443
|
+
}, Ce = 300, Er = () => {
|
|
444
|
+
var l, i, b, m, S, _;
|
|
445
|
+
const t = je(), e = Ht((F) => F.product.product), r = Ht((F) => F.store.store), [o, n] = z(!!e);
|
|
446
|
+
if (it(() => {
|
|
422
447
|
n(!!e);
|
|
423
448
|
}, [e]), !e) return null;
|
|
424
|
-
const
|
|
425
|
-
var F,
|
|
449
|
+
const d = async () => {
|
|
450
|
+
var F, j, K, ct, V, dt, kt, Pt, rt, St, Ct, ut, $t, zt, _t, P;
|
|
426
451
|
console.log(e, "the prod");
|
|
427
452
|
try {
|
|
428
|
-
if (!((
|
|
453
|
+
if (!((j = (F = e == null ? void 0 : e.variants) == null ? void 0 : F[0]) != null && j.product_id) && !(e.type.item || e.type.bundle) && !((ct = (K = e == null ? void 0 : e.variants) == null ? void 0 : K[0]) != null && ct.productId)) {
|
|
429
454
|
M.error("Variants not available", {
|
|
430
455
|
position: "bottom-right",
|
|
431
456
|
autoClose: 1e3
|
|
@@ -434,92 +459,97 @@ const et = (t) => {
|
|
|
434
459
|
}
|
|
435
460
|
const C = [
|
|
436
461
|
{
|
|
437
|
-
product_id: ((
|
|
462
|
+
product_id: ((V = e.variants) == null ? void 0 : V[0].product_id) || ((dt = e.variants) == null ? void 0 : dt[0].productId) || (e == null ? void 0 : e.id),
|
|
438
463
|
quantity: 1
|
|
439
464
|
}
|
|
440
465
|
];
|
|
441
466
|
console.log(C, "the product data");
|
|
442
467
|
const k = JSON.parse(
|
|
443
468
|
sessionStorage.getItem("customerData") || "{}"
|
|
444
|
-
),
|
|
445
|
-
if (!
|
|
446
|
-
let
|
|
469
|
+
), ot = (k == null ? void 0 : k.basketId) || localStorage.getItem(Yt), Wt = !1, At = localStorage.getItem(Tt), jt = Date.now();
|
|
470
|
+
if (!Wt || !At || jt >= parseInt(At)) {
|
|
471
|
+
let $ = "";
|
|
447
472
|
{
|
|
448
|
-
const
|
|
449
|
-
console.log("token from auth data"),
|
|
473
|
+
const ft = await Ot();
|
|
474
|
+
console.log("token from auth data"), $ = "Bearer " + ft.access_token;
|
|
450
475
|
}
|
|
451
|
-
if (
|
|
476
|
+
if (!$) {
|
|
452
477
|
console.error("Failed to get customer_token");
|
|
453
478
|
return;
|
|
454
479
|
}
|
|
455
|
-
const
|
|
456
|
-
if (
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
480
|
+
const pt = jt + 300 * 1e3;
|
|
481
|
+
if (Kt($), localStorage.setItem(Tt, pt.toString()), ot) {
|
|
482
|
+
const ft = await Re({
|
|
483
|
+
basketId: ot,
|
|
484
|
+
customer_token: $
|
|
485
|
+
});
|
|
486
|
+
if (console.log(ot, "basket id from customer"), ft.status === 200 && ft) {
|
|
487
|
+
const D = await Rt(
|
|
488
|
+
ot,
|
|
489
|
+
C,
|
|
490
|
+
$
|
|
491
|
+
);
|
|
492
|
+
(((kt = D == null ? void 0 : D.product_items) == null ? void 0 : kt.length) > 0 || ((Pt = D == null ? void 0 : D.productItems) == null ? void 0 : Pt.length) > 0) && (M.success("Added to cart", {
|
|
493
|
+
position: "bottom-right",
|
|
494
|
+
autoClose: 3e3,
|
|
495
|
+
hideProgressBar: !1,
|
|
496
|
+
closeOnClick: !0,
|
|
497
|
+
pauseOnHover: !0,
|
|
498
|
+
draggable: !0
|
|
499
|
+
}), Vt(ot));
|
|
500
|
+
return;
|
|
501
|
+
}
|
|
472
502
|
}
|
|
473
503
|
const Dt = {
|
|
474
504
|
productItems: [
|
|
475
505
|
{
|
|
476
|
-
productId: ((
|
|
506
|
+
productId: ((rt = e.variants) == null ? void 0 : rt[0].product_id) || ((St = e.variants) == null ? void 0 : St[0].productId) || (e == null ? void 0 : e.id),
|
|
477
507
|
quantity: 1
|
|
478
508
|
}
|
|
479
509
|
]
|
|
480
510
|
};
|
|
481
511
|
console.log("before create basket");
|
|
482
|
-
const
|
|
512
|
+
const h = await Ve($, Dt);
|
|
483
513
|
if (console.log(
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
514
|
+
h,
|
|
515
|
+
h == null ? void 0 : h.basket_id,
|
|
516
|
+
h == null ? void 0 : h.basketId,
|
|
487
517
|
"the basket response"
|
|
488
|
-
), !(
|
|
518
|
+
), !(h != null && h.basket_id) && !(h != null && h.basketId)) {
|
|
489
519
|
console.error("Failed to create basket");
|
|
490
520
|
return;
|
|
491
521
|
}
|
|
492
522
|
console.log(
|
|
493
523
|
"setting stored id",
|
|
494
|
-
(
|
|
495
|
-
),
|
|
496
|
-
(
|
|
524
|
+
(h == null ? void 0 : h.basket_id) || (h == null ? void 0 : h.basketId)
|
|
525
|
+
), st(
|
|
526
|
+
(h == null ? void 0 : h.basket_id) || (h == null ? void 0 : h.basketId)
|
|
497
527
|
), console.log("adding product to basket");
|
|
498
|
-
const J = await
|
|
499
|
-
(
|
|
528
|
+
const J = await Rt(
|
|
529
|
+
(h == null ? void 0 : h.basket_id) || (h == null ? void 0 : h.basketId),
|
|
500
530
|
C,
|
|
501
|
-
|
|
531
|
+
$
|
|
502
532
|
);
|
|
503
|
-
console.log("object added to basket"), (((
|
|
533
|
+
console.log("object added to basket"), (((Ct = J == null ? void 0 : J.product_items) == null ? void 0 : Ct.length) > 0 || ((ut = J == null ? void 0 : J.productItems) == null ? void 0 : ut.length) > 0) && M.success("Added to cart", {
|
|
504
534
|
position: "bottom-right",
|
|
505
535
|
autoClose: 3e3,
|
|
506
536
|
hideProgressBar: !1,
|
|
507
537
|
closeOnClick: !0,
|
|
508
538
|
pauseOnHover: !0,
|
|
509
539
|
draggable: !0
|
|
510
|
-
}),
|
|
540
|
+
}), Vt(h.basket_id || (h == null ? void 0 : h.basketId));
|
|
511
541
|
}
|
|
512
542
|
} catch (C) {
|
|
513
543
|
console.error("Error adding to cart:", C), M.error("Failed to add product to cart", {
|
|
514
544
|
position: "bottom-right",
|
|
515
545
|
autoClose: 3e3
|
|
516
|
-
}), ((
|
|
517
|
-
((
|
|
546
|
+
}), (($t = C == null ? void 0 : C.response) == null ? void 0 : $t.status) === 404 || // Basket not found
|
|
547
|
+
((zt = C == null ? void 0 : C.response) == null ? void 0 : zt.status) === 401 ? (((_t = C == null ? void 0 : C.response) == null ? void 0 : _t.status) === 404 && st(null), ((P = C == null ? void 0 : C.response) == null ? void 0 : P.status) === 401 && (st(null), Kt(null))) : (console.error("Failed to add product to basket:", C.message), M.error("Failed to add product to cart", {
|
|
518
548
|
position: "bottom-right",
|
|
519
549
|
autoClose: 3e3
|
|
520
550
|
}));
|
|
521
551
|
}
|
|
522
|
-
},
|
|
552
|
+
}, s = () => {
|
|
523
553
|
e && (window.location.href = e.c_pdpUrl);
|
|
524
554
|
};
|
|
525
555
|
return console.log(e, "the prod"), /* @__PURE__ */ u(re, { children: [
|
|
@@ -528,7 +558,7 @@ const et = (t) => {
|
|
|
528
558
|
{
|
|
529
559
|
className: "fixed inset-0 z-40 bg-black/30",
|
|
530
560
|
onClick: () => {
|
|
531
|
-
n(!1), setTimeout(() => t(oe(null)),
|
|
561
|
+
n(!1), setTimeout(() => t(oe(null)), Ce);
|
|
532
562
|
}
|
|
533
563
|
}
|
|
534
564
|
),
|
|
@@ -546,14 +576,14 @@ const et = (t) => {
|
|
|
546
576
|
/* @__PURE__ */ u("div", { className: "mt-3 flex flex-row justify-between w-full ", children: [
|
|
547
577
|
/* @__PURE__ */ a("div", { children: /* @__PURE__ */ a("p", { className: "text-[#000000] font-bold font-nunitoSans", children: e.name }) }),
|
|
548
578
|
/* @__PURE__ */ a("div", { children: /* @__PURE__ */ a(
|
|
549
|
-
|
|
579
|
+
ge,
|
|
550
580
|
{
|
|
551
581
|
icon: "mdi:close",
|
|
552
582
|
className: "text-[#555555] w-6 h-6 cursor-pointer",
|
|
553
583
|
onClick: () => {
|
|
554
584
|
n(!1), setTimeout(
|
|
555
585
|
() => t(oe(null)),
|
|
556
|
-
|
|
586
|
+
Ce
|
|
557
587
|
);
|
|
558
588
|
}
|
|
559
589
|
}
|
|
@@ -563,20 +593,20 @@ const et = (t) => {
|
|
|
563
593
|
/* @__PURE__ */ a("div", { className: "flex flex-row items-center justify-center w-[120px] h-[120px] my-5", children: /* @__PURE__ */ a(
|
|
564
594
|
"img",
|
|
565
595
|
{
|
|
566
|
-
src: (
|
|
596
|
+
src: (m = (b = (i = (l = e.imageGroups) == null ? void 0 : l[0]) == null ? void 0 : i.images) == null ? void 0 : b[0]) == null ? void 0 : m.link,
|
|
567
597
|
alt: e.name,
|
|
568
598
|
className: "rounded-[10px]"
|
|
569
599
|
}
|
|
570
600
|
) }),
|
|
571
601
|
/* @__PURE__ */ a("div", { className: "flex flex-col items-center gap-2", children: e.imageGroups.slice(1, 2).map(
|
|
572
|
-
(F) => F.images.slice(1, 2).map((
|
|
602
|
+
(F) => F.images.slice(1, 2).map((j) => /* @__PURE__ */ a(
|
|
573
603
|
"img",
|
|
574
604
|
{
|
|
575
|
-
src:
|
|
605
|
+
src: j.link,
|
|
576
606
|
alt: e.name,
|
|
577
607
|
className: "rounded-[10px] w-[60px] h-[60px]"
|
|
578
608
|
},
|
|
579
|
-
|
|
609
|
+
j.link
|
|
580
610
|
))
|
|
581
611
|
) })
|
|
582
612
|
] }),
|
|
@@ -623,19 +653,19 @@ const et = (t) => {
|
|
|
623
653
|
" ratings"
|
|
624
654
|
] })
|
|
625
655
|
] }) }),
|
|
626
|
-
/* @__PURE__ */ a("div", { className: "mt-2 flex flex-row items-center gap-2", children: Array.from({ length: 5 }).map((F,
|
|
656
|
+
/* @__PURE__ */ a("div", { className: "mt-2 flex flex-row items-center gap-2", children: Array.from({ length: 5 }).map((F, j) => {
|
|
627
657
|
var K;
|
|
628
658
|
return /* @__PURE__ */ a(
|
|
629
|
-
|
|
659
|
+
ge,
|
|
630
660
|
{
|
|
631
661
|
icon: "mdi:star",
|
|
632
662
|
width: "20",
|
|
633
663
|
height: "20",
|
|
634
664
|
className: `text-yellow-500
|
|
635
|
-
${((K = e == null ? void 0 : e.rating) == null ? void 0 : K.rate) >
|
|
665
|
+
${((K = e == null ? void 0 : e.rating) == null ? void 0 : K.rate) > j ? "text-yellow-500" : "text-gray-300"}
|
|
636
666
|
`
|
|
637
667
|
},
|
|
638
|
-
|
|
668
|
+
j
|
|
639
669
|
);
|
|
640
670
|
}) })
|
|
641
671
|
] }),
|
|
@@ -650,7 +680,7 @@ const et = (t) => {
|
|
|
650
680
|
{
|
|
651
681
|
className: "rounded-[5px] shadow-sm text-[#FBFBFC] bg-[#6851C6] p-2 w-full text-center cursor-pointer",
|
|
652
682
|
style: { backgroundColor: r.tanyaThemeColor },
|
|
653
|
-
onClick:
|
|
683
|
+
onClick: d,
|
|
654
684
|
children: "Add to Cart"
|
|
655
685
|
}
|
|
656
686
|
),
|
|
@@ -659,7 +689,7 @@ const et = (t) => {
|
|
|
659
689
|
{
|
|
660
690
|
className: "rounded-[5px] shadow-sm text-[#FBFBFC] bg-[#6851C6] p-2 w-full text-center cursor-pointer mb-16",
|
|
661
691
|
style: { backgroundColor: r.tanyaThemeColor },
|
|
662
|
-
onClick:
|
|
692
|
+
onClick: s,
|
|
663
693
|
children: "View more"
|
|
664
694
|
}
|
|
665
695
|
)
|
|
@@ -670,7 +700,7 @@ const et = (t) => {
|
|
|
670
700
|
}
|
|
671
701
|
)
|
|
672
702
|
] });
|
|
673
|
-
},
|
|
703
|
+
}, Tr = ({
|
|
674
704
|
tanyaConfig: t,
|
|
675
705
|
basketId: e
|
|
676
706
|
}) => {
|
|
@@ -688,36 +718,36 @@ const et = (t) => {
|
|
|
688
718
|
"Niece/Nephew": "his/her niece/nephew",
|
|
689
719
|
"My Friends": "his/her friends",
|
|
690
720
|
Others: "others"
|
|
691
|
-
}, n =
|
|
692
|
-
id:
|
|
693
|
-
title:
|
|
694
|
-
image:
|
|
695
|
-
price:
|
|
696
|
-
}), [
|
|
721
|
+
}, n = Ft(null), d = Ft(null), s = Ft(null), l = Ft(null), [i, b] = z(null), [m, S] = z(!1), [_, F] = z(!1), [j, K] = z(!1), [ct, V] = z(!1), [dt, kt] = z(!1), [Pt, rt] = z(!1), [St, Ct] = z(""), [ut, $t] = z(""), zt = (c) => ({
|
|
722
|
+
id: c.id,
|
|
723
|
+
title: c.name,
|
|
724
|
+
image: c.image ?? "",
|
|
725
|
+
price: c.price ?? 0
|
|
726
|
+
}), [_t, P] = z([]), C = Ft(null), k = Ht((c) => c.store.store), ot = Ht((c) => c.product.product), Wt = () => {
|
|
697
727
|
K(!0), setTimeout(() => F(!0), 10);
|
|
698
|
-
},
|
|
728
|
+
}, At = () => {
|
|
699
729
|
F(!1), setTimeout(() => K(!1), 300);
|
|
700
730
|
};
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
}, [
|
|
704
|
-
const jt = (
|
|
705
|
-
|
|
731
|
+
it(() => {
|
|
732
|
+
m ? Wt() : At();
|
|
733
|
+
}, [m]);
|
|
734
|
+
const jt = (c) => {
|
|
735
|
+
$t(o[c]);
|
|
706
736
|
};
|
|
707
|
-
|
|
737
|
+
it(() => {
|
|
708
738
|
C.current && (C.current.scrollTop += 150);
|
|
709
|
-
}, [
|
|
710
|
-
let
|
|
739
|
+
}, [_t]);
|
|
740
|
+
let $ = null, pt = null;
|
|
711
741
|
const Dt = async () => {
|
|
712
|
-
if (
|
|
713
|
-
return
|
|
742
|
+
if ($ && pt && Date.now() < pt)
|
|
743
|
+
return $;
|
|
714
744
|
try {
|
|
715
|
-
const
|
|
745
|
+
const c = "https://us-east-1lsr29ln3u.auth.us-east-1.amazoncognito.com/oauth2/token", v = new URLSearchParams({
|
|
716
746
|
grant_type: "client_credentials",
|
|
717
747
|
client_id: "4i8rd70sgt961tc4dhskgf08c",
|
|
718
748
|
client_secret: "bnsfq1220loh2cn2cm2ttn8fdhdpt0u8m1fgj8vfk2rn61aurjg",
|
|
719
749
|
scope: "default-m2m-resource-server-8xzfzo/read"
|
|
720
|
-
}), w = await fetch(
|
|
750
|
+
}), w = await fetch(c, {
|
|
721
751
|
method: "POST",
|
|
722
752
|
headers: {
|
|
723
753
|
"Content-Type": "application/x-www-form-urlencoded"
|
|
@@ -728,71 +758,71 @@ const et = (t) => {
|
|
|
728
758
|
throw new Error(
|
|
729
759
|
`Token request failed! status: ${w.status}`
|
|
730
760
|
);
|
|
731
|
-
const
|
|
732
|
-
|
|
733
|
-
const p =
|
|
734
|
-
return
|
|
735
|
-
} catch (
|
|
736
|
-
return console.error("Error obtaining JWT token:",
|
|
761
|
+
const x = await w.json();
|
|
762
|
+
$ = x.access_token;
|
|
763
|
+
const p = x.expires_in || 3600;
|
|
764
|
+
return pt = Date.now() + (p - 60) * 1e3, $;
|
|
765
|
+
} catch (c) {
|
|
766
|
+
return console.error("Error obtaining JWT token:", c), $ = null, pt = null, null;
|
|
737
767
|
}
|
|
738
|
-
},
|
|
739
|
-
const
|
|
740
|
-
|
|
768
|
+
}, h = async () => {
|
|
769
|
+
const c = await Ot();
|
|
770
|
+
c != null && b(c);
|
|
741
771
|
};
|
|
742
|
-
|
|
772
|
+
it(() => {
|
|
743
773
|
if (t != null && t.siteId) {
|
|
744
|
-
const { clientID:
|
|
745
|
-
sessionStorage.setItem("Host", v), sessionStorage.setItem("SiteId", p), sessionStorage.setItem("pubCfg", btoa(
|
|
774
|
+
const { clientID: c, host: v, organizationID: w, shortCode: x, siteId: p } = t;
|
|
775
|
+
sessionStorage.setItem("Host", v), sessionStorage.setItem("SiteId", p), sessionStorage.setItem("pubCfg", btoa(c)), sessionStorage.setItem("envRef", x), sessionStorage.setItem("orgRef", w);
|
|
746
776
|
}
|
|
747
|
-
|
|
748
|
-
}, []),
|
|
749
|
-
e && (console.log("setting the basket id", e),
|
|
777
|
+
h(), console.log("scapi environment v1");
|
|
778
|
+
}, []), it(() => {
|
|
779
|
+
e && (console.log("setting the basket id", e), st(e));
|
|
750
780
|
}, [e]);
|
|
751
781
|
const J = async () => {
|
|
752
|
-
const
|
|
782
|
+
const c = JSON.parse(
|
|
753
783
|
sessionStorage.getItem("customerData") || "{}"
|
|
754
784
|
).customerId;
|
|
755
|
-
return (await
|
|
756
|
-
},
|
|
757
|
-
console.log("in secondary flow",
|
|
785
|
+
return (await kr(c || "")).c_interests;
|
|
786
|
+
}, ft = async (c, v) => {
|
|
787
|
+
console.log("in secondary flow", It);
|
|
758
788
|
const w = await J();
|
|
759
|
-
if (console.log(w, "interests of customer",
|
|
789
|
+
if (console.log(w, "interests of customer", It), !!w)
|
|
760
790
|
try {
|
|
761
|
-
|
|
791
|
+
P(
|
|
762
792
|
(U) => U.map(
|
|
763
|
-
(
|
|
793
|
+
(R, Y) => Y === U.length - 1 ? { ...R, secondaryLoading: !0 } : R
|
|
764
794
|
)
|
|
765
795
|
);
|
|
766
|
-
const
|
|
767
|
-
if (!
|
|
768
|
-
const p = localStorage.getItem("customerNumber"), g = localStorage.getItem("isLoggedIn"),
|
|
796
|
+
const x = await Dt();
|
|
797
|
+
if (!x) throw new Error("Failed to fetch token");
|
|
798
|
+
const p = localStorage.getItem("customerNumber"), g = localStorage.getItem("isLoggedIn"), ht = `https://tanya.aspiresystems.com/api/bedrock/invoke/stream?${new URLSearchParams({
|
|
769
799
|
registered: String(g || !1),
|
|
770
800
|
userId: String(p || (/* @__PURE__ */ new Date()).getTime())
|
|
771
|
-
}).toString()}`,
|
|
801
|
+
}).toString()}`, mt = JSON.stringify({
|
|
772
802
|
flowId: "Q166PR519W",
|
|
773
803
|
flowAliasId: "HKFUVLWVH2",
|
|
774
804
|
input: {
|
|
775
805
|
loyaltyPoints: "",
|
|
776
|
-
productName:
|
|
806
|
+
productName: c,
|
|
777
807
|
productPoints: String(v || 0),
|
|
778
808
|
interests: w
|
|
779
809
|
}
|
|
780
|
-
}), L = await fetch(
|
|
810
|
+
}), L = await fetch(ht, {
|
|
781
811
|
signal: AbortSignal.timeout(3e4),
|
|
782
812
|
method: "POST",
|
|
783
813
|
headers: {
|
|
784
814
|
"Content-Type": "application/json",
|
|
785
|
-
Authorization: `Bearer ${
|
|
815
|
+
Authorization: `Bearer ${x}`
|
|
786
816
|
},
|
|
787
|
-
body:
|
|
817
|
+
body: mt
|
|
788
818
|
});
|
|
789
819
|
if (!L.body) throw new Error("Readable stream not supported");
|
|
790
|
-
const
|
|
820
|
+
const wt = L.body.getReader(), gt = new TextDecoder();
|
|
791
821
|
let B = "";
|
|
792
822
|
for (; ; ) {
|
|
793
|
-
const { done: U, value:
|
|
823
|
+
const { done: U, value: R } = await wt.read();
|
|
794
824
|
if (U) break;
|
|
795
|
-
B +=
|
|
825
|
+
B += gt.decode(R, { stream: !0 });
|
|
796
826
|
const Y = B.split(`
|
|
797
827
|
`);
|
|
798
828
|
B = Y.pop() || "";
|
|
@@ -801,31 +831,31 @@ const et = (t) => {
|
|
|
801
831
|
const f = W.slice(5).trim();
|
|
802
832
|
try {
|
|
803
833
|
const q = JSON.parse(f);
|
|
804
|
-
q.index === 0 &&
|
|
834
|
+
q.index === 0 && P(
|
|
805
835
|
(I) => I.map(
|
|
806
|
-
(
|
|
807
|
-
...
|
|
836
|
+
(O, G) => G === I.length - 1 ? {
|
|
837
|
+
...O,
|
|
808
838
|
secondaryResponse: q.data,
|
|
809
839
|
secondaryLoading: !1
|
|
810
|
-
} :
|
|
840
|
+
} : O
|
|
811
841
|
)
|
|
812
842
|
);
|
|
813
843
|
} catch (q) {
|
|
814
|
-
|
|
844
|
+
P(
|
|
815
845
|
(I) => I.map(
|
|
816
|
-
(
|
|
846
|
+
(O, G) => G === I.length - 1 ? { ...O, secondaryLoading: !1 } : O
|
|
817
847
|
)
|
|
818
848
|
), console.error("Secondary flow JSON parse error:", q);
|
|
819
849
|
}
|
|
820
850
|
}
|
|
821
851
|
}
|
|
822
|
-
} catch (
|
|
823
|
-
console.error("Secondary flow error:",
|
|
852
|
+
} catch (x) {
|
|
853
|
+
console.error("Secondary flow error:", x);
|
|
824
854
|
}
|
|
825
|
-
},
|
|
826
|
-
const v =
|
|
855
|
+
}, D = async (c) => {
|
|
856
|
+
const v = c || St.trim();
|
|
827
857
|
if (v) {
|
|
828
|
-
|
|
858
|
+
kt(!0), Ct(""), n.current = null, d.current = null, s.current = null, l.current = null, P((w) => [
|
|
829
859
|
...w,
|
|
830
860
|
{
|
|
831
861
|
query: v,
|
|
@@ -836,38 +866,38 @@ const et = (t) => {
|
|
|
836
866
|
}
|
|
837
867
|
]);
|
|
838
868
|
try {
|
|
839
|
-
const w =
|
|
869
|
+
const w = ut, x = localStorage.getItem("customerNumber"), p = localStorage.getItem("isLoggedIn"), g = await Dt();
|
|
840
870
|
if (!g)
|
|
841
871
|
throw new Error("Failed to obtain access token");
|
|
842
|
-
const
|
|
872
|
+
const ht = `https://tanya.aspiresystems.com/api/bedrock/invoke/stream?${new URLSearchParams({
|
|
843
873
|
registered: String(p || !1),
|
|
844
|
-
userId: String(
|
|
845
|
-
}).toString()}`,
|
|
874
|
+
userId: String(x || (/* @__PURE__ */ new Date()).getTime())
|
|
875
|
+
}).toString()}`, mt = JSON.stringify({
|
|
846
876
|
flowId: "MMHQKYI1NE",
|
|
847
877
|
flowAliasId: "SZF9ZK1ATE",
|
|
848
878
|
input: {
|
|
849
879
|
userPrompt: v,
|
|
850
880
|
whom: w
|
|
851
881
|
}
|
|
852
|
-
}), L = await fetch(
|
|
882
|
+
}), L = await fetch(ht, {
|
|
853
883
|
signal: AbortSignal.timeout(3e4),
|
|
854
884
|
method: "POST",
|
|
855
885
|
headers: {
|
|
856
886
|
"Content-Type": "application/json",
|
|
857
887
|
Authorization: `Bearer ${g}`
|
|
858
888
|
},
|
|
859
|
-
body:
|
|
889
|
+
body: mt
|
|
860
890
|
});
|
|
861
891
|
if (!L.ok)
|
|
862
892
|
throw new Error(`HTTP error! status: ${L.status}`);
|
|
863
893
|
if (!L.body) throw new Error("Readable stream not supported");
|
|
864
|
-
const
|
|
894
|
+
const wt = L.body.getReader(), gt = new TextDecoder();
|
|
865
895
|
let B = "", U = "";
|
|
866
896
|
for (; ; ) {
|
|
867
|
-
|
|
868
|
-
const { done:
|
|
869
|
-
if (
|
|
870
|
-
B +=
|
|
897
|
+
rt(!0);
|
|
898
|
+
const { done: R, value: Y } = await wt.read();
|
|
899
|
+
if (R) break;
|
|
900
|
+
B += gt.decode(Y, { stream: !0 });
|
|
871
901
|
const W = B.split(`
|
|
872
902
|
`);
|
|
873
903
|
B = W.pop() || "";
|
|
@@ -876,9 +906,9 @@ const et = (t) => {
|
|
|
876
906
|
const q = f.slice(5).trim();
|
|
877
907
|
try {
|
|
878
908
|
const I = JSON.parse(q);
|
|
879
|
-
I.index == 1 && (U = I.data),
|
|
880
|
-
(
|
|
881
|
-
(G,
|
|
909
|
+
I.index == 1 && (U = I.data), P(
|
|
910
|
+
(O) => O.map(
|
|
911
|
+
(G, Lt) => Lt === O.length - 1 ? {
|
|
882
912
|
...G,
|
|
883
913
|
[I.index == 0 ? "response" : I.index == 1 ? "keywords" : I.index == 2 ? "potentialQuestions" : "end"]: I.data
|
|
884
914
|
} : G
|
|
@@ -889,47 +919,47 @@ const et = (t) => {
|
|
|
889
919
|
}
|
|
890
920
|
}
|
|
891
921
|
}
|
|
892
|
-
|
|
922
|
+
rr(er(U));
|
|
893
923
|
} catch (w) {
|
|
894
924
|
console.error("Error sending message to Tanya:", w);
|
|
895
925
|
} finally {
|
|
896
|
-
|
|
926
|
+
kt(!1);
|
|
897
927
|
}
|
|
898
928
|
}
|
|
899
|
-
},
|
|
900
|
-
const v =
|
|
929
|
+
}, er = (c) => {
|
|
930
|
+
const v = c.match(
|
|
901
931
|
/top five relevant product or category names are: (.*)/i
|
|
902
|
-
), p = (v ? v[1] :
|
|
932
|
+
), p = (v ? v[1] : c).split(", ").map((A) => A.replace(/\s*(Toys|Bags|Miniature|etc\.*)\s*/gi, "").trim());
|
|
903
933
|
return [...new Set(p)].filter(Boolean).join(",");
|
|
904
|
-
},
|
|
905
|
-
if (typeof
|
|
906
|
-
console.log(
|
|
907
|
-
const v =
|
|
934
|
+
}, rr = async (c) => {
|
|
935
|
+
if (typeof c == "string") {
|
|
936
|
+
console.log(c, "keywords");
|
|
937
|
+
const v = c.split(",");
|
|
908
938
|
for (const w of v) {
|
|
909
|
-
const
|
|
910
|
-
if (
|
|
939
|
+
const x = await be(w);
|
|
940
|
+
if (rt(!1), (x == null ? void 0 : x.length) > 0 && (P(
|
|
911
941
|
(p) => p.map(
|
|
912
|
-
(g,
|
|
942
|
+
(g, A) => A === p.length - 1 ? {
|
|
913
943
|
...g,
|
|
914
944
|
products: [
|
|
915
945
|
...g.products || [],
|
|
916
|
-
{ keyword: w, items:
|
|
946
|
+
{ keyword: w, items: x, loading: !1 }
|
|
917
947
|
]
|
|
918
948
|
} : g
|
|
919
949
|
)
|
|
920
|
-
), !n.current ||
|
|
921
|
-
const p =
|
|
922
|
-
n.current = String((p == null ? void 0 : p.product_name) ?? ""),
|
|
950
|
+
), !n.current || d.current == null)) {
|
|
951
|
+
const p = x[0];
|
|
952
|
+
n.current = String((p == null ? void 0 : p.product_name) ?? ""), s.current = p.image.link, d.current = p.product_id;
|
|
923
953
|
const g = typeof (p == null ? void 0 : p.price) == "number" ? p.price : void 0;
|
|
924
|
-
|
|
954
|
+
l.current = typeof g == "number" && Number.isFinite(g) ? g : null;
|
|
925
955
|
}
|
|
926
956
|
}
|
|
927
957
|
} else
|
|
928
|
-
for (const v of
|
|
929
|
-
const w = await
|
|
930
|
-
|
|
931
|
-
(
|
|
932
|
-
(p, g) => g ===
|
|
958
|
+
for (const v of c) {
|
|
959
|
+
const w = await be(v);
|
|
960
|
+
rt(!1), (w == null ? void 0 : w.length) > 0 && P(
|
|
961
|
+
(x) => x.map(
|
|
962
|
+
(p, g) => g === x.length - 1 ? {
|
|
933
963
|
...p,
|
|
934
964
|
products: [
|
|
935
965
|
...p.products || [],
|
|
@@ -940,34 +970,34 @@ const et = (t) => {
|
|
|
940
970
|
);
|
|
941
971
|
}
|
|
942
972
|
if (n.current) {
|
|
943
|
-
|
|
973
|
+
P(
|
|
944
974
|
(w) => w.map(
|
|
945
|
-
(
|
|
946
|
-
...
|
|
975
|
+
(x, p) => p === w.length - 1 ? {
|
|
976
|
+
...x,
|
|
947
977
|
productSnapshot: {
|
|
948
|
-
id:
|
|
978
|
+
id: d.current,
|
|
949
979
|
name: n.current,
|
|
950
|
-
image:
|
|
951
|
-
price:
|
|
980
|
+
image: s.current,
|
|
981
|
+
price: l.current ?? null,
|
|
952
982
|
points: 0,
|
|
953
983
|
quantity: 1
|
|
954
984
|
}
|
|
955
|
-
} :
|
|
985
|
+
} : x
|
|
956
986
|
)
|
|
957
987
|
);
|
|
958
988
|
const v = JSON.parse(
|
|
959
989
|
sessionStorage.getItem("customerData") || "{}"
|
|
960
990
|
);
|
|
961
|
-
(v == null ? void 0 : v.isGuest) == !1 ? (console.log("running secondary flow",
|
|
991
|
+
(v == null ? void 0 : v.isGuest) == !1 ? (console.log("running secondary flow", It), ft(n.current, 0)) : console.log("not running secondary flow", It);
|
|
962
992
|
}
|
|
963
|
-
|
|
964
|
-
},
|
|
965
|
-
var w,
|
|
966
|
-
|
|
993
|
+
rt(!1);
|
|
994
|
+
}, or = async (c, v) => {
|
|
995
|
+
var w, x, p, g, A, ht, mt, L, wt, gt, B, U, R, Y, W;
|
|
996
|
+
V(!0);
|
|
967
997
|
try {
|
|
968
|
-
const f = await
|
|
969
|
-
if (!((
|
|
970
|
-
|
|
998
|
+
const f = await He(c.id);
|
|
999
|
+
if (!((x = (w = f == null ? void 0 : f.variants) == null ? void 0 : w[0]) != null && x.product_id || (g = (p = f == null ? void 0 : f.variants) == null ? void 0 : p[0]) != null && g.productId) && !(f.type.item || f.type.bundle)) {
|
|
1000
|
+
V(!1), M.error("Variants not found", {
|
|
971
1001
|
position: "bottom-right",
|
|
972
1002
|
autoClose: 1e3
|
|
973
1003
|
}), console.error("No product variant found");
|
|
@@ -975,89 +1005,95 @@ const et = (t) => {
|
|
|
975
1005
|
}
|
|
976
1006
|
const q = [
|
|
977
1007
|
{
|
|
978
|
-
product_id: ((
|
|
1008
|
+
product_id: ((A = f.variants) == null ? void 0 : A[0].product_id) || ((ht = f.variants) == null ? void 0 : ht[0].productId) || (f == null ? void 0 : f.id),
|
|
979
1009
|
quantity: v
|
|
980
1010
|
}
|
|
981
1011
|
];
|
|
982
|
-
console.log(q, "product data", "app version",
|
|
1012
|
+
console.log(q, "product data", "app version", It);
|
|
983
1013
|
const I = JSON.parse(
|
|
984
1014
|
sessionStorage.getItem("customerData") || "{}"
|
|
985
|
-
),
|
|
986
|
-
if (!G || !
|
|
987
|
-
const
|
|
988
|
-
let { customer_token:
|
|
989
|
-
|
|
1015
|
+
), O = (I == null ? void 0 : I.basketId) || localStorage.getItem(Yt), G = !1, Lt = localStorage.getItem(Tt), me = Date.now();
|
|
1016
|
+
if (!G || !Lt || me >= parseInt(Lt)) {
|
|
1017
|
+
const nr = await qe();
|
|
1018
|
+
let { customer_token: nt } = await Me(
|
|
1019
|
+
nr
|
|
990
1020
|
);
|
|
991
|
-
if (
|
|
1021
|
+
if (nt = "Bearer " + i.access_token, !nt) {
|
|
992
1022
|
console.error("Failed to get customer_token");
|
|
993
1023
|
return;
|
|
994
1024
|
}
|
|
995
|
-
const
|
|
996
|
-
if (
|
|
997
|
-
const
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
)
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1025
|
+
const ar = me + 300 * 1e3;
|
|
1026
|
+
if (Kt(nt), localStorage.setItem(Tt, ar.toString()), console.log(O, "basketIdFromCustomer"), O) {
|
|
1027
|
+
const we = await Re({
|
|
1028
|
+
basketId: O,
|
|
1029
|
+
customer_token: nt
|
|
1030
|
+
});
|
|
1031
|
+
if (we.status === 200 && we) {
|
|
1032
|
+
const Gt = await Rt(
|
|
1033
|
+
O,
|
|
1034
|
+
q,
|
|
1035
|
+
nt
|
|
1036
|
+
);
|
|
1037
|
+
((mt = Gt == null ? void 0 : Gt.product_items) == null ? void 0 : mt.length) > 0 && (M.success("Added to cart", {
|
|
1038
|
+
position: "bottom-right",
|
|
1039
|
+
autoClose: 3e3,
|
|
1040
|
+
hideProgressBar: !1,
|
|
1041
|
+
closeOnClick: !0,
|
|
1042
|
+
pauseOnHover: !0,
|
|
1043
|
+
draggable: !0
|
|
1044
|
+
}), Vt(O), V(!1));
|
|
1045
|
+
return;
|
|
1046
|
+
}
|
|
1011
1047
|
}
|
|
1012
|
-
const
|
|
1048
|
+
const ir = {
|
|
1013
1049
|
productItems: [
|
|
1014
1050
|
{
|
|
1015
|
-
productId: ((L = f.variants) == null ? void 0 : L[0].product_id) || ((
|
|
1051
|
+
productId: ((L = f.variants) == null ? void 0 : L[0].product_id) || ((wt = f.variants) == null ? void 0 : wt[0].productId) || (f == null ? void 0 : f.id),
|
|
1016
1052
|
quantity: 1
|
|
1017
1053
|
}
|
|
1018
1054
|
]
|
|
1019
|
-
}, y = await
|
|
1055
|
+
}, y = await Ve(nt, ir);
|
|
1020
1056
|
if (console.log(
|
|
1021
1057
|
y,
|
|
1022
1058
|
y == null ? void 0 : y.basket_id,
|
|
1023
1059
|
y == null ? void 0 : y.basketId,
|
|
1024
1060
|
"the basket response"
|
|
1025
1061
|
), !(y != null && y.basket_id || !(y != null && y.basketId))) {
|
|
1026
|
-
|
|
1062
|
+
V(!1), console.error("Failed to create basket");
|
|
1027
1063
|
return;
|
|
1028
1064
|
}
|
|
1029
|
-
|
|
1065
|
+
st(
|
|
1030
1066
|
(y == null ? void 0 : y.basket_id) || (y == null ? void 0 : y.basketId)
|
|
1031
1067
|
);
|
|
1032
|
-
const
|
|
1068
|
+
const bt = await Rt(
|
|
1033
1069
|
(y == null ? void 0 : y.basket_id) || (y == null ? void 0 : y.basketId),
|
|
1034
1070
|
q,
|
|
1035
|
-
|
|
1071
|
+
nt
|
|
1036
1072
|
);
|
|
1037
|
-
(((
|
|
1073
|
+
(((gt = bt == null ? void 0 : bt.product_items) == null ? void 0 : gt.length) > 0 || ((B = bt == null ? void 0 : bt.productItems) == null ? void 0 : B.length) > 0) && M.success("Added to cart", {
|
|
1038
1074
|
position: "bottom-right",
|
|
1039
1075
|
autoClose: 3e3,
|
|
1040
1076
|
hideProgressBar: !1,
|
|
1041
1077
|
closeOnClick: !0,
|
|
1042
1078
|
pauseOnHover: !0,
|
|
1043
1079
|
draggable: !0
|
|
1044
|
-
}),
|
|
1080
|
+
}), Vt(y.basket_id || (y == null ? void 0 : y.basketId));
|
|
1045
1081
|
}
|
|
1046
1082
|
} catch (f) {
|
|
1047
|
-
|
|
1083
|
+
V(!1), console.error("Error adding to cart:", f), M.error("Failed to add product to cart", {
|
|
1048
1084
|
position: "bottom-right",
|
|
1049
1085
|
autoClose: 3e3
|
|
1050
1086
|
}), ((U = f == null ? void 0 : f.response) == null ? void 0 : U.status) === 404 || // Basket not found
|
|
1051
|
-
((
|
|
1087
|
+
((R = f == null ? void 0 : f.response) == null ? void 0 : R.status) === 401 ? (((Y = f == null ? void 0 : f.response) == null ? void 0 : Y.status) === 404 && st(null), ((W = f == null ? void 0 : f.response) == null ? void 0 : W.status) === 401 && (st(null), Kt(null))) : (console.error("Failed to add product to basket:", f.message), M.error("Failed to add product to cart", {
|
|
1052
1088
|
position: "bottom-right",
|
|
1053
1089
|
autoClose: 3e3
|
|
1054
1090
|
}));
|
|
1055
1091
|
}
|
|
1056
|
-
|
|
1092
|
+
V(!1);
|
|
1057
1093
|
};
|
|
1058
|
-
return /* @__PURE__ */ a("div", { className: "relative flex justify-center", children: /* @__PURE__ */ u(
|
|
1094
|
+
return /* @__PURE__ */ a("div", { className: "relative flex justify-center", children: /* @__PURE__ */ u(yr, { open: m, onOpenChange: S, children: [
|
|
1059
1095
|
/* @__PURE__ */ a(
|
|
1060
|
-
|
|
1096
|
+
vr,
|
|
1061
1097
|
{
|
|
1062
1098
|
onClick: () => S(!0),
|
|
1063
1099
|
style: {
|
|
@@ -1119,7 +1155,7 @@ const et = (t) => {
|
|
|
1119
1155
|
) })
|
|
1120
1156
|
}
|
|
1121
1157
|
),
|
|
1122
|
-
|
|
1158
|
+
j && /* @__PURE__ */ u(re, { children: [
|
|
1123
1159
|
/* @__PURE__ */ a(
|
|
1124
1160
|
"div",
|
|
1125
1161
|
{
|
|
@@ -1267,7 +1303,7 @@ const et = (t) => {
|
|
|
1267
1303
|
/* @__PURE__ */ u(
|
|
1268
1304
|
"div",
|
|
1269
1305
|
{
|
|
1270
|
-
className: `flex flex-col h-full ${
|
|
1306
|
+
className: `flex flex-col h-full ${ot ? "lg:w-2/3 w-full" : "w-full"}`,
|
|
1271
1307
|
children: [
|
|
1272
1308
|
/* @__PURE__ */ u(
|
|
1273
1309
|
"div",
|
|
@@ -1281,32 +1317,32 @@ const et = (t) => {
|
|
|
1281
1317
|
className: "mx-3 p-3 rounded-2xl bg-[#FFFFFF]",
|
|
1282
1318
|
children: [
|
|
1283
1319
|
/* @__PURE__ */ a("div", { className: "flex gap-2 bg-[#FFFFFF]", children: /* @__PURE__ */ a("p", { className: "font-bold font-nunitoSans text-[#494949]", children: "Is this for you or someone else?" }) }),
|
|
1284
|
-
/* @__PURE__ */ a("div", { className: "flex flex-wrap gap-2 mt-2", children: r.map((
|
|
1320
|
+
/* @__PURE__ */ a("div", { className: "flex flex-wrap gap-2 mt-2", children: r.map((c) => /* @__PURE__ */ a(
|
|
1285
1321
|
"button",
|
|
1286
1322
|
{
|
|
1287
|
-
onClick: () => jt(
|
|
1323
|
+
onClick: () => jt(c),
|
|
1288
1324
|
className: "px-2 py-2 font-semibold text-xs text-[#18181B] bg-[#F3F3F3] rounded-2xl",
|
|
1289
1325
|
style: {
|
|
1290
|
-
backgroundColor:
|
|
1291
|
-
borderColor:
|
|
1326
|
+
backgroundColor: ut === o[c] ? "#FFFFFF" : "#F3F3F3",
|
|
1327
|
+
borderColor: ut === o[c] ? "#BBB3DD" : ""
|
|
1292
1328
|
},
|
|
1293
|
-
children:
|
|
1329
|
+
children: c
|
|
1294
1330
|
},
|
|
1295
|
-
|
|
1331
|
+
c
|
|
1296
1332
|
)) })
|
|
1297
1333
|
]
|
|
1298
1334
|
}
|
|
1299
1335
|
),
|
|
1300
|
-
|
|
1301
|
-
var w,
|
|
1336
|
+
_t.map((c, v) => {
|
|
1337
|
+
var w, x;
|
|
1302
1338
|
return /* @__PURE__ */ u("div", { children: [
|
|
1303
|
-
/* @__PURE__ */ a("div", { className: "flex justify-end", children: /* @__PURE__ */ a("p", { className: "text-sm font-nunitoSans font-bold text-[#000000] bg-[#E2DBFF] border border-[#C9C2DE] rounded-l-xl p-2 m-3 mb-4 rounded-br-xl max-w-[75%]", children:
|
|
1304
|
-
|
|
1339
|
+
/* @__PURE__ */ a("div", { className: "flex justify-end", children: /* @__PURE__ */ a("p", { className: "text-sm font-nunitoSans font-bold text-[#000000] bg-[#E2DBFF] border border-[#C9C2DE] rounded-l-xl p-2 m-3 mb-4 rounded-br-xl max-w-[75%]", children: c.query }) }),
|
|
1340
|
+
c.response && c.response.includes("Thinking") ? /* @__PURE__ */ a("div", { children: /* @__PURE__ */ a(
|
|
1305
1341
|
"div",
|
|
1306
1342
|
{
|
|
1307
1343
|
className: "font-nunitoSans animate-pulse font-bold text-sm text-[#494949] bg-[#FFFFFF] px-7 py-1 rounded-r-xl rounded-bl-2xl w-full",
|
|
1308
1344
|
dangerouslySetInnerHTML: {
|
|
1309
|
-
__html: Xt(
|
|
1345
|
+
__html: Xt(c.response)
|
|
1310
1346
|
}
|
|
1311
1347
|
}
|
|
1312
1348
|
) }) : /* @__PURE__ */ a("div", { children: /* @__PURE__ */ a(
|
|
@@ -1314,19 +1350,19 @@ const et = (t) => {
|
|
|
1314
1350
|
{
|
|
1315
1351
|
className: "font-nunitoSans font-bold text-sm text-[#494949] bg-[#FFFFFF] px-7 py-1 rounded-r-xl rounded-bl-2xl w-full",
|
|
1316
1352
|
dangerouslySetInnerHTML: {
|
|
1317
|
-
__html: Xt(
|
|
1353
|
+
__html: Xt(c.response)
|
|
1318
1354
|
}
|
|
1319
1355
|
}
|
|
1320
1356
|
) }),
|
|
1321
|
-
|
|
1322
|
-
(
|
|
1323
|
-
|
|
1357
|
+
Pt && !c.response.includes("Thinking") && ((w = c.products) == null ? void 0 : w.length) == 0 && /* @__PURE__ */ a("div", { children: /* @__PURE__ */ a("p", { className: "text-sm animate-pulse font-nunitoSans font-bold text-[#000000] bg-[#E2DBFF] border border-[#C9C2DE] rounded-l-xl p-2 m-3 mb-4 rounded-br-xl max-w-[75%]", children: "Finding best products for you" }) }),
|
|
1358
|
+
(c == null ? void 0 : c.products) && ((x = c == null ? void 0 : c.products) == null ? void 0 : x.length) > 0 && /* @__PURE__ */ a(
|
|
1359
|
+
Ir,
|
|
1324
1360
|
{
|
|
1325
|
-
chat:
|
|
1361
|
+
chat: c.products,
|
|
1326
1362
|
storeDetails: k
|
|
1327
1363
|
}
|
|
1328
1364
|
),
|
|
1329
|
-
|
|
1365
|
+
c.potentialQuestions.length > 0 && /* @__PURE__ */ u("div", { className: "my-2 px-4 text-sm text-gray-700", children: [
|
|
1330
1366
|
/* @__PURE__ */ a(
|
|
1331
1367
|
"p",
|
|
1332
1368
|
{
|
|
@@ -1335,11 +1371,11 @@ const et = (t) => {
|
|
|
1335
1371
|
children: "Why not explore these inquiries..."
|
|
1336
1372
|
}
|
|
1337
1373
|
),
|
|
1338
|
-
|
|
1374
|
+
c.potentialQuestions.split(",").map((p, g) => /* @__PURE__ */ a(
|
|
1339
1375
|
"button",
|
|
1340
1376
|
{
|
|
1341
1377
|
className: `cursor-pointer font-nunitoSans font-semibold text-[#232323] border bg-[#804C9E0D] border-${k.themeDarkColor} m-1 rounded-xl px-2 py-1`,
|
|
1342
|
-
onClick: () =>
|
|
1378
|
+
onClick: () => D(p),
|
|
1343
1379
|
style: {
|
|
1344
1380
|
backgroundColor: k.tanyaThemeColorLight
|
|
1345
1381
|
},
|
|
@@ -1348,7 +1384,7 @@ const et = (t) => {
|
|
|
1348
1384
|
g
|
|
1349
1385
|
))
|
|
1350
1386
|
] }),
|
|
1351
|
-
|
|
1387
|
+
c.secondaryLoading && /* @__PURE__ */ a("div", { className: "mt-3 mb-4 px-4", children: /* @__PURE__ */ u(
|
|
1352
1388
|
"div",
|
|
1353
1389
|
{
|
|
1354
1390
|
className: "tanya-surprise-wrapper bg-indigo-300 text-sm px-7 py-4 rounded-r-xl rounded-bl-2xl w-full relative overflow-hidden",
|
|
@@ -1381,7 +1417,7 @@ const et = (t) => {
|
|
|
1381
1417
|
]
|
|
1382
1418
|
}
|
|
1383
1419
|
) }),
|
|
1384
|
-
|
|
1420
|
+
c.secondaryResponse && /* @__PURE__ */ a(re, { children: /* @__PURE__ */ u("div", { className: "mt-3 mb-8 px-4 bg-indigo-300 rounded-tr-[5px]", children: [
|
|
1385
1421
|
/* @__PURE__ */ a(
|
|
1386
1422
|
"div",
|
|
1387
1423
|
{
|
|
@@ -1391,12 +1427,12 @@ const et = (t) => {
|
|
|
1391
1427
|
},
|
|
1392
1428
|
dangerouslySetInnerHTML: {
|
|
1393
1429
|
__html: Xt(
|
|
1394
|
-
|
|
1430
|
+
c.secondaryResponse
|
|
1395
1431
|
)
|
|
1396
1432
|
}
|
|
1397
1433
|
}
|
|
1398
1434
|
),
|
|
1399
|
-
|
|
1435
|
+
c.productSnapshot && // chat.productSnapshot.points > 0 &&
|
|
1400
1436
|
/* @__PURE__ */ a("div", { className: "mt-4 w-full", children: /* @__PURE__ */ u(
|
|
1401
1437
|
"div",
|
|
1402
1438
|
{
|
|
@@ -1414,11 +1450,11 @@ const et = (t) => {
|
|
|
1414
1450
|
height: 112,
|
|
1415
1451
|
borderColor: "#eee"
|
|
1416
1452
|
},
|
|
1417
|
-
children:
|
|
1453
|
+
children: c.productSnapshot.image ? /* @__PURE__ */ a(
|
|
1418
1454
|
"img",
|
|
1419
1455
|
{
|
|
1420
|
-
src:
|
|
1421
|
-
alt:
|
|
1456
|
+
src: c.productSnapshot.image,
|
|
1457
|
+
alt: c.productSnapshot.name,
|
|
1422
1458
|
className: "w-full h-full object-cover"
|
|
1423
1459
|
}
|
|
1424
1460
|
) : /* @__PURE__ */ a("div", { className: "w-full h-full flex items-center justify-center text-xs text-gray-500", children: "No Image" })
|
|
@@ -1426,18 +1462,18 @@ const et = (t) => {
|
|
|
1426
1462
|
),
|
|
1427
1463
|
/* @__PURE__ */ u("div", { className: "flex flex-col flex-1 justify-between", children: [
|
|
1428
1464
|
/* @__PURE__ */ u("div", { children: [
|
|
1429
|
-
/* @__PURE__ */ a("p", { className: "font-semibold text-[15px] leading-snug", children:
|
|
1430
|
-
/* @__PURE__ */ a("p", { className: "mt-1 text-[14px] font-medium", children:
|
|
1465
|
+
/* @__PURE__ */ a("p", { className: "font-semibold text-[15px] leading-snug", children: c.productSnapshot.name }),
|
|
1466
|
+
/* @__PURE__ */ a("p", { className: "mt-1 text-[14px] font-medium", children: c.productSnapshot.price != null ? new Intl.NumberFormat(void 0, {
|
|
1431
1467
|
style: "currency",
|
|
1432
1468
|
currency: (k == null ? void 0 : k.currency) || "USD"
|
|
1433
1469
|
}).format(
|
|
1434
|
-
|
|
1470
|
+
c.productSnapshot.price
|
|
1435
1471
|
) : "" }),
|
|
1436
|
-
|
|
1472
|
+
c.productSnapshot.points > 0 && /* @__PURE__ */ u("p", { className: "mt-1 text-xs opacity-80", children: [
|
|
1437
1473
|
"You will earn",
|
|
1438
1474
|
" ",
|
|
1439
1475
|
/* @__PURE__ */ u("strong", { children: [
|
|
1440
|
-
|
|
1476
|
+
c.productSnapshot.points,
|
|
1441
1477
|
" ",
|
|
1442
1478
|
"points"
|
|
1443
1479
|
] })
|
|
@@ -1449,9 +1485,9 @@ const et = (t) => {
|
|
|
1449
1485
|
"button",
|
|
1450
1486
|
{
|
|
1451
1487
|
className: "px-3 py-1 text-sm",
|
|
1452
|
-
onClick: () =>
|
|
1488
|
+
onClick: () => P(
|
|
1453
1489
|
(p) => p.map(
|
|
1454
|
-
(g,
|
|
1490
|
+
(g, A) => A === v && g.productSnapshot ? {
|
|
1455
1491
|
...g,
|
|
1456
1492
|
productSnapshot: {
|
|
1457
1493
|
...g.productSnapshot,
|
|
@@ -1470,14 +1506,14 @@ const et = (t) => {
|
|
|
1470
1506
|
children: "−"
|
|
1471
1507
|
}
|
|
1472
1508
|
),
|
|
1473
|
-
/* @__PURE__ */ a("div", { className: "px-3 py-1 text-sm select-none", children:
|
|
1509
|
+
/* @__PURE__ */ a("div", { className: "px-3 py-1 text-sm select-none", children: c.productSnapshot.quantity }),
|
|
1474
1510
|
/* @__PURE__ */ a(
|
|
1475
1511
|
"button",
|
|
1476
1512
|
{
|
|
1477
1513
|
className: "px-3 py-1 text-sm",
|
|
1478
|
-
onClick: () =>
|
|
1514
|
+
onClick: () => P(
|
|
1479
1515
|
(p) => p.map(
|
|
1480
|
-
(g,
|
|
1516
|
+
(g, A) => A === v && g.productSnapshot ? {
|
|
1481
1517
|
...g,
|
|
1482
1518
|
productSnapshot: {
|
|
1483
1519
|
...g.productSnapshot,
|
|
@@ -1498,21 +1534,21 @@ const et = (t) => {
|
|
|
1498
1534
|
"button",
|
|
1499
1535
|
{
|
|
1500
1536
|
onClick: () => {
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1537
|
+
or(
|
|
1538
|
+
zt(
|
|
1539
|
+
c.productSnapshot
|
|
1504
1540
|
),
|
|
1505
|
-
|
|
1541
|
+
c.productSnapshot.quantity
|
|
1506
1542
|
);
|
|
1507
1543
|
},
|
|
1508
|
-
disabled:
|
|
1544
|
+
disabled: ct,
|
|
1509
1545
|
className: "px-4 py-2 rounded-full font-medium",
|
|
1510
1546
|
style: {
|
|
1511
1547
|
background: k.tanyaThemeColor,
|
|
1512
1548
|
color: (k == null ? void 0 : k.tanyaThemeContrastColor) || "#fff",
|
|
1513
|
-
opacity:
|
|
1549
|
+
opacity: ct ? 0.8 : 1
|
|
1514
1550
|
},
|
|
1515
|
-
children:
|
|
1551
|
+
children: ct ? "Adding..." : "Add to cart"
|
|
1516
1552
|
}
|
|
1517
1553
|
)
|
|
1518
1554
|
] })
|
|
@@ -1540,11 +1576,11 @@ const et = (t) => {
|
|
|
1540
1576
|
{
|
|
1541
1577
|
className: "flex-1 bg-[#FFFFFF] text-[#232323] outline-none border-none px-2 py-2 text-sm",
|
|
1542
1578
|
placeholder: "How can I help you...",
|
|
1543
|
-
value:
|
|
1579
|
+
value: St,
|
|
1544
1580
|
autoFocus: !0,
|
|
1545
|
-
onChange: (
|
|
1546
|
-
onKeyDown: (
|
|
1547
|
-
|
|
1581
|
+
onChange: (c) => Ct(c.target.value),
|
|
1582
|
+
onKeyDown: (c) => {
|
|
1583
|
+
c.key === "Enter" && !dt && D();
|
|
1548
1584
|
}
|
|
1549
1585
|
}
|
|
1550
1586
|
),
|
|
@@ -1552,10 +1588,10 @@ const et = (t) => {
|
|
|
1552
1588
|
"button",
|
|
1553
1589
|
{
|
|
1554
1590
|
type: "submit",
|
|
1555
|
-
disabled:
|
|
1591
|
+
disabled: dt,
|
|
1556
1592
|
className: "p-3",
|
|
1557
|
-
onClick: () =>
|
|
1558
|
-
children:
|
|
1593
|
+
onClick: () => D(),
|
|
1594
|
+
children: dt ? /* @__PURE__ */ a(
|
|
1559
1595
|
"div",
|
|
1560
1596
|
{
|
|
1561
1597
|
className: "p-3 animate-spin rounded-full h-3 w-3 border-b-2",
|
|
@@ -1589,7 +1625,7 @@ const et = (t) => {
|
|
|
1589
1625
|
]
|
|
1590
1626
|
}
|
|
1591
1627
|
),
|
|
1592
|
-
/* @__PURE__ */ a(
|
|
1628
|
+
/* @__PURE__ */ a(Er, {})
|
|
1593
1629
|
] })
|
|
1594
1630
|
]
|
|
1595
1631
|
}
|
|
@@ -1604,7 +1640,7 @@ var ne = function(t, e) {
|
|
|
1604
1640
|
for (var n in o) Object.prototype.hasOwnProperty.call(o, n) && (r[n] = o[n]);
|
|
1605
1641
|
}, ne(t, e);
|
|
1606
1642
|
};
|
|
1607
|
-
function
|
|
1643
|
+
function Or(t, e) {
|
|
1608
1644
|
if (typeof e != "function" && e !== null)
|
|
1609
1645
|
throw new TypeError("Class extends value " + String(e) + " is not a constructor or null");
|
|
1610
1646
|
ne(t, e);
|
|
@@ -1617,12 +1653,12 @@ var X = function() {
|
|
|
1617
1653
|
return X = Object.assign || function(e) {
|
|
1618
1654
|
for (var r, o = 1, n = arguments.length; o < n; o++) {
|
|
1619
1655
|
r = arguments[o];
|
|
1620
|
-
for (var
|
|
1656
|
+
for (var d in r) Object.prototype.hasOwnProperty.call(r, d) && (e[d] = r[d]);
|
|
1621
1657
|
}
|
|
1622
1658
|
return e;
|
|
1623
1659
|
}, X.apply(this, arguments);
|
|
1624
1660
|
};
|
|
1625
|
-
function
|
|
1661
|
+
function Pr(t, e) {
|
|
1626
1662
|
var r = {};
|
|
1627
1663
|
for (var o in t) Object.prototype.hasOwnProperty.call(t, o) && e.indexOf(o) < 0 && (r[o] = t[o]);
|
|
1628
1664
|
if (t != null && typeof Object.getOwnPropertySymbols == "function")
|
|
@@ -1630,50 +1666,50 @@ function Tr(t, e) {
|
|
|
1630
1666
|
e.indexOf(o[n]) < 0 && Object.prototype.propertyIsEnumerable.call(t, o[n]) && (r[o[n]] = t[o[n]]);
|
|
1631
1667
|
return r;
|
|
1632
1668
|
}
|
|
1633
|
-
var Qt = "Invariant Violation",
|
|
1669
|
+
var Qt = "Invariant Violation", _e = Object.setPrototypeOf, $r = _e === void 0 ? function(t, e) {
|
|
1634
1670
|
return t.__proto__ = e, t;
|
|
1635
|
-
} :
|
|
1671
|
+
} : _e, Ye = (
|
|
1636
1672
|
/** @class */
|
|
1637
1673
|
(function(t) {
|
|
1638
|
-
|
|
1674
|
+
Or(e, t);
|
|
1639
1675
|
function e(r) {
|
|
1640
1676
|
r === void 0 && (r = Qt);
|
|
1641
1677
|
var o = t.call(this, typeof r == "number" ? Qt + ": " + r + " (see https://github.com/apollographql/invariant-packages)" : r) || this;
|
|
1642
|
-
return o.framesToPop = 1, o.name = Qt,
|
|
1678
|
+
return o.framesToPop = 1, o.name = Qt, $r(o, e.prototype), o;
|
|
1643
1679
|
}
|
|
1644
1680
|
return e;
|
|
1645
1681
|
})(Error)
|
|
1646
1682
|
);
|
|
1647
|
-
function
|
|
1683
|
+
function at(t, e) {
|
|
1648
1684
|
if (!t)
|
|
1649
|
-
throw new
|
|
1685
|
+
throw new Ye(e);
|
|
1650
1686
|
}
|
|
1651
|
-
var
|
|
1652
|
-
function
|
|
1687
|
+
var Ke = ["debug", "log", "warn", "error", "silent"], zr = Ke.indexOf("log");
|
|
1688
|
+
function Bt(t) {
|
|
1653
1689
|
return function() {
|
|
1654
|
-
if (
|
|
1690
|
+
if (Ke.indexOf(t) >= zr) {
|
|
1655
1691
|
var e = console[t] || console.log;
|
|
1656
1692
|
return e.apply(console, arguments);
|
|
1657
1693
|
}
|
|
1658
1694
|
};
|
|
1659
1695
|
}
|
|
1660
1696
|
(function(t) {
|
|
1661
|
-
t.debug =
|
|
1662
|
-
})(
|
|
1663
|
-
var
|
|
1664
|
-
function
|
|
1697
|
+
t.debug = Bt("debug"), t.log = Bt("log"), t.warn = Bt("warn"), t.error = Bt("error");
|
|
1698
|
+
})(at || (at = {}));
|
|
1699
|
+
var Je = "3.14.0";
|
|
1700
|
+
function xt(t) {
|
|
1665
1701
|
try {
|
|
1666
1702
|
return t();
|
|
1667
1703
|
} catch {
|
|
1668
1704
|
}
|
|
1669
1705
|
}
|
|
1670
|
-
const ae =
|
|
1706
|
+
const ae = xt(function() {
|
|
1671
1707
|
return globalThis;
|
|
1672
|
-
}) ||
|
|
1708
|
+
}) || xt(function() {
|
|
1673
1709
|
return window;
|
|
1674
|
-
}) ||
|
|
1710
|
+
}) || xt(function() {
|
|
1675
1711
|
return self;
|
|
1676
|
-
}) ||
|
|
1712
|
+
}) || xt(function() {
|
|
1677
1713
|
return global;
|
|
1678
1714
|
}) || // We don't expect the Function constructor ever to be invoked at runtime, as
|
|
1679
1715
|
// long as at least one of globalThis, window, self, or global is defined, so
|
|
@@ -1681,21 +1717,21 @@ const ae = gt(function() {
|
|
|
1681
1717
|
// detect syntactic usage of the Function constructor. If you think you can
|
|
1682
1718
|
// improve your static analysis to detect this obfuscation, think again. This
|
|
1683
1719
|
// is an arms race you cannot win, at least not in JavaScript.
|
|
1684
|
-
|
|
1685
|
-
return
|
|
1720
|
+
xt(function() {
|
|
1721
|
+
return xt.constructor("return this")();
|
|
1686
1722
|
});
|
|
1687
|
-
var
|
|
1688
|
-
function
|
|
1689
|
-
var e =
|
|
1690
|
-
return
|
|
1723
|
+
var Fe = /* @__PURE__ */ new Map();
|
|
1724
|
+
function Ar(t) {
|
|
1725
|
+
var e = Fe.get(t) || 1;
|
|
1726
|
+
return Fe.set(t, e + 1), "".concat(t, ":").concat(e, ":").concat(Math.random().toString(36).slice(2));
|
|
1691
1727
|
}
|
|
1692
|
-
function
|
|
1693
|
-
var r =
|
|
1728
|
+
function jr(t, e) {
|
|
1729
|
+
var r = Ar("stringifyForDisplay");
|
|
1694
1730
|
return JSON.stringify(t, function(o, n) {
|
|
1695
1731
|
return n === void 0 ? r : n;
|
|
1696
1732
|
}, e).split(JSON.stringify(r)).join("<undefined>");
|
|
1697
1733
|
}
|
|
1698
|
-
function
|
|
1734
|
+
function Ut(t) {
|
|
1699
1735
|
return function(e) {
|
|
1700
1736
|
for (var r = [], o = 1; o < arguments.length; o++)
|
|
1701
1737
|
r[o - 1] = arguments[o];
|
|
@@ -1709,41 +1745,41 @@ function Bt(t) {
|
|
|
1709
1745
|
var Zt = Object.assign(function(e, r) {
|
|
1710
1746
|
for (var o = [], n = 2; n < arguments.length; n++)
|
|
1711
1747
|
o[n - 2] = arguments[n];
|
|
1712
|
-
e ||
|
|
1748
|
+
e || at(e, le(r, o) || ce(r, o));
|
|
1713
1749
|
}, {
|
|
1714
|
-
debug:
|
|
1715
|
-
log:
|
|
1716
|
-
warn:
|
|
1717
|
-
error:
|
|
1750
|
+
debug: Ut(at.debug),
|
|
1751
|
+
log: Ut(at.log),
|
|
1752
|
+
warn: Ut(at.warn),
|
|
1753
|
+
error: Ut(at.error)
|
|
1718
1754
|
});
|
|
1719
|
-
function
|
|
1755
|
+
function We(t) {
|
|
1720
1756
|
for (var e = [], r = 1; r < arguments.length; r++)
|
|
1721
1757
|
e[r - 1] = arguments[r];
|
|
1722
|
-
return new
|
|
1758
|
+
return new Ye(le(t, e) || ce(t, e));
|
|
1723
1759
|
}
|
|
1724
|
-
var
|
|
1725
|
-
function
|
|
1760
|
+
var Ie = Symbol.for("ApolloErrorMessageHandler_" + Je);
|
|
1761
|
+
function Ge(t) {
|
|
1726
1762
|
if (typeof t == "string")
|
|
1727
1763
|
return t;
|
|
1728
1764
|
try {
|
|
1729
|
-
return
|
|
1765
|
+
return jr(t, 2).slice(0, 1e3);
|
|
1730
1766
|
} catch {
|
|
1731
1767
|
return "<non-serializable>";
|
|
1732
1768
|
}
|
|
1733
1769
|
}
|
|
1734
1770
|
function le(t, e) {
|
|
1735
1771
|
if (e === void 0 && (e = []), !!t)
|
|
1736
|
-
return ae[
|
|
1772
|
+
return ae[Ie] && ae[Ie](t, e.map(Ge));
|
|
1737
1773
|
}
|
|
1738
1774
|
function ce(t, e) {
|
|
1739
1775
|
if (e === void 0 && (e = []), !!t)
|
|
1740
1776
|
return "An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#".concat(encodeURIComponent(JSON.stringify({
|
|
1741
|
-
version:
|
|
1777
|
+
version: Je,
|
|
1742
1778
|
message: t,
|
|
1743
|
-
args: e.map(
|
|
1779
|
+
args: e.map(Ge)
|
|
1744
1780
|
})));
|
|
1745
1781
|
}
|
|
1746
|
-
function
|
|
1782
|
+
function Dr(t) {
|
|
1747
1783
|
return t.definitions.filter(function(e) {
|
|
1748
1784
|
return e.kind === "OperationDefinition" && !!e.name;
|
|
1749
1785
|
}).map(function(e) {
|
|
@@ -1751,13 +1787,13 @@ function jr(t) {
|
|
|
1751
1787
|
})[0] || null;
|
|
1752
1788
|
}
|
|
1753
1789
|
let N = null;
|
|
1754
|
-
const
|
|
1755
|
-
let
|
|
1756
|
-
const
|
|
1790
|
+
const Ne = {};
|
|
1791
|
+
let Lr = 1;
|
|
1792
|
+
const Br = () => class {
|
|
1757
1793
|
constructor() {
|
|
1758
1794
|
this.id = [
|
|
1759
1795
|
"slot",
|
|
1760
|
-
|
|
1796
|
+
Lr++,
|
|
1761
1797
|
Date.now(),
|
|
1762
1798
|
Math.random().toString(36).slice(2)
|
|
1763
1799
|
].join(":");
|
|
@@ -1766,26 +1802,26 @@ const Ar = () => class {
|
|
|
1766
1802
|
for (let e = N; e; e = e.parent)
|
|
1767
1803
|
if (this.id in e.slots) {
|
|
1768
1804
|
const r = e.slots[this.id];
|
|
1769
|
-
if (r ===
|
|
1805
|
+
if (r === Ne)
|
|
1770
1806
|
break;
|
|
1771
1807
|
return e !== N && (N.slots[this.id] = r), !0;
|
|
1772
1808
|
}
|
|
1773
|
-
return N && (N.slots[this.id] =
|
|
1809
|
+
return N && (N.slots[this.id] = Ne), !1;
|
|
1774
1810
|
}
|
|
1775
1811
|
getValue() {
|
|
1776
1812
|
if (this.hasValue())
|
|
1777
1813
|
return N.slots[this.id];
|
|
1778
1814
|
}
|
|
1779
1815
|
withValue(e, r, o, n) {
|
|
1780
|
-
const
|
|
1816
|
+
const d = {
|
|
1781
1817
|
__proto__: null,
|
|
1782
1818
|
[this.id]: e
|
|
1783
|
-
},
|
|
1784
|
-
N = { parent:
|
|
1819
|
+
}, s = N;
|
|
1820
|
+
N = { parent: s, slots: d };
|
|
1785
1821
|
try {
|
|
1786
1822
|
return r.apply(n, o);
|
|
1787
1823
|
} finally {
|
|
1788
|
-
N =
|
|
1824
|
+
N = s;
|
|
1789
1825
|
}
|
|
1790
1826
|
}
|
|
1791
1827
|
// Capture the current context and wrap a callback function so that it
|
|
@@ -1814,27 +1850,27 @@ const Ar = () => class {
|
|
|
1814
1850
|
return e.apply(o, r);
|
|
1815
1851
|
}
|
|
1816
1852
|
};
|
|
1817
|
-
function
|
|
1853
|
+
function Ee(t) {
|
|
1818
1854
|
try {
|
|
1819
1855
|
return t();
|
|
1820
1856
|
} catch {
|
|
1821
1857
|
}
|
|
1822
1858
|
}
|
|
1823
|
-
const te = "@wry/context:Slot",
|
|
1859
|
+
const te = "@wry/context:Slot", Ur = (
|
|
1824
1860
|
// Prefer globalThis when available.
|
|
1825
1861
|
// https://github.com/benjamn/wryware/issues/347
|
|
1826
|
-
|
|
1862
|
+
Ee(() => globalThis) || // Fall back to global, which works in Node.js and may be converted by some
|
|
1827
1863
|
// bundlers to the appropriate identifier (window, self, ...) depending on the
|
|
1828
1864
|
// bundling target. https://github.com/endojs/endo/issues/576#issuecomment-1178515224
|
|
1829
|
-
|
|
1865
|
+
Ee(() => global) || // Otherwise, use a dummy host that's local to this module. We used to fall
|
|
1830
1866
|
// back to using the Array constructor as a namespace, but that was flagged in
|
|
1831
1867
|
// https://github.com/benjamn/wryware/issues/347, and can be avoided.
|
|
1832
1868
|
/* @__PURE__ */ Object.create(null)
|
|
1833
|
-
),
|
|
1869
|
+
), Te = Ur, de = Te[te] || // Earlier versions of this package stored the globalKey property on the Array
|
|
1834
1870
|
// constructor, so we check there as well, to prevent Slot class duplication.
|
|
1835
1871
|
Array[te] || (function(t) {
|
|
1836
1872
|
try {
|
|
1837
|
-
Object.defineProperty(
|
|
1873
|
+
Object.defineProperty(Te, te, {
|
|
1838
1874
|
value: t,
|
|
1839
1875
|
enumerable: !1,
|
|
1840
1876
|
writable: !1,
|
|
@@ -1849,12 +1885,12 @@ Array[te] || (function(t) {
|
|
|
1849
1885
|
} finally {
|
|
1850
1886
|
return t;
|
|
1851
1887
|
}
|
|
1852
|
-
})(
|
|
1888
|
+
})(Br()), { bind: Co, noContext: _o } = de;
|
|
1853
1889
|
new de();
|
|
1854
|
-
function
|
|
1890
|
+
function qr(t, e) {
|
|
1855
1891
|
var r = typeof Symbol < "u" && t[Symbol.iterator] || t["@@iterator"];
|
|
1856
1892
|
if (r) return (r = r.call(t)).next.bind(r);
|
|
1857
|
-
if (Array.isArray(t) || (r =
|
|
1893
|
+
if (Array.isArray(t) || (r = Mr(t)) || e) {
|
|
1858
1894
|
r && (t = r);
|
|
1859
1895
|
var o = 0;
|
|
1860
1896
|
return function() {
|
|
@@ -1864,96 +1900,96 @@ function Br(t, e) {
|
|
|
1864
1900
|
throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
1865
1901
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1866
1902
|
}
|
|
1867
|
-
function
|
|
1903
|
+
function Mr(t, e) {
|
|
1868
1904
|
if (t) {
|
|
1869
|
-
if (typeof t == "string") return
|
|
1905
|
+
if (typeof t == "string") return Oe(t, e);
|
|
1870
1906
|
var r = Object.prototype.toString.call(t).slice(8, -1);
|
|
1871
1907
|
if (r === "Object" && t.constructor && (r = t.constructor.name), r === "Map" || r === "Set") return Array.from(t);
|
|
1872
|
-
if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return
|
|
1908
|
+
if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return Oe(t, e);
|
|
1873
1909
|
}
|
|
1874
1910
|
}
|
|
1875
|
-
function
|
|
1911
|
+
function Oe(t, e) {
|
|
1876
1912
|
(e == null || e > t.length) && (e = t.length);
|
|
1877
1913
|
for (var r = 0, o = new Array(e); r < e; r++)
|
|
1878
1914
|
o[r] = t[r];
|
|
1879
1915
|
return o;
|
|
1880
1916
|
}
|
|
1881
|
-
function
|
|
1917
|
+
function Pe(t, e) {
|
|
1882
1918
|
for (var r = 0; r < e.length; r++) {
|
|
1883
1919
|
var o = e[r];
|
|
1884
1920
|
o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);
|
|
1885
1921
|
}
|
|
1886
1922
|
}
|
|
1887
1923
|
function ue(t, e, r) {
|
|
1888
|
-
return e &&
|
|
1924
|
+
return e && Pe(t.prototype, e), r && Pe(t, r), Object.defineProperty(t, "prototype", { writable: !1 }), t;
|
|
1889
1925
|
}
|
|
1890
1926
|
var pe = function() {
|
|
1891
1927
|
return typeof Symbol == "function";
|
|
1892
1928
|
}, fe = function(t) {
|
|
1893
1929
|
return pe() && !!Symbol[t];
|
|
1894
|
-
},
|
|
1930
|
+
}, he = function(t) {
|
|
1895
1931
|
return fe(t) ? Symbol[t] : "@@" + t;
|
|
1896
1932
|
};
|
|
1897
1933
|
pe() && !fe("observable") && (Symbol.observable = Symbol("observable"));
|
|
1898
|
-
var
|
|
1899
|
-
function
|
|
1934
|
+
var Hr = he("iterator"), ie = he("observable"), Xe = he("species");
|
|
1935
|
+
function Jt(t, e) {
|
|
1900
1936
|
var r = t[e];
|
|
1901
1937
|
if (r != null) {
|
|
1902
1938
|
if (typeof r != "function") throw new TypeError(r + " is not a function");
|
|
1903
1939
|
return r;
|
|
1904
1940
|
}
|
|
1905
1941
|
}
|
|
1906
|
-
function
|
|
1942
|
+
function Nt(t) {
|
|
1907
1943
|
var e = t.constructor;
|
|
1908
|
-
return e !== void 0 && (e = e[
|
|
1944
|
+
return e !== void 0 && (e = e[Xe], e === null && (e = void 0)), e !== void 0 ? e : E;
|
|
1909
1945
|
}
|
|
1910
|
-
function
|
|
1946
|
+
function Vr(t) {
|
|
1911
1947
|
return t instanceof E;
|
|
1912
1948
|
}
|
|
1913
|
-
function
|
|
1914
|
-
|
|
1949
|
+
function vt(t) {
|
|
1950
|
+
vt.log ? vt.log(t) : setTimeout(function() {
|
|
1915
1951
|
throw t;
|
|
1916
1952
|
});
|
|
1917
1953
|
}
|
|
1918
|
-
function
|
|
1954
|
+
function Mt(t) {
|
|
1919
1955
|
Promise.resolve().then(function() {
|
|
1920
1956
|
try {
|
|
1921
1957
|
t();
|
|
1922
1958
|
} catch (e) {
|
|
1923
|
-
|
|
1959
|
+
vt(e);
|
|
1924
1960
|
}
|
|
1925
1961
|
});
|
|
1926
1962
|
}
|
|
1927
|
-
function
|
|
1963
|
+
function Qe(t) {
|
|
1928
1964
|
var e = t._cleanup;
|
|
1929
1965
|
if (e !== void 0 && (t._cleanup = void 0, !!e))
|
|
1930
1966
|
try {
|
|
1931
1967
|
if (typeof e == "function")
|
|
1932
1968
|
e();
|
|
1933
1969
|
else {
|
|
1934
|
-
var r =
|
|
1970
|
+
var r = Jt(e, "unsubscribe");
|
|
1935
1971
|
r && r.call(e);
|
|
1936
1972
|
}
|
|
1937
1973
|
} catch (o) {
|
|
1938
|
-
|
|
1974
|
+
vt(o);
|
|
1939
1975
|
}
|
|
1940
1976
|
}
|
|
1941
1977
|
function se(t) {
|
|
1942
1978
|
t._observer = void 0, t._queue = void 0, t._state = "closed";
|
|
1943
1979
|
}
|
|
1944
|
-
function
|
|
1980
|
+
function Rr(t) {
|
|
1945
1981
|
var e = t._queue;
|
|
1946
1982
|
if (e) {
|
|
1947
1983
|
t._queue = void 0, t._state = "ready";
|
|
1948
|
-
for (var r = 0; r < e.length && (
|
|
1984
|
+
for (var r = 0; r < e.length && (Ze(t, e[r].type, e[r].value), t._state !== "closed"); ++r)
|
|
1949
1985
|
;
|
|
1950
1986
|
}
|
|
1951
1987
|
}
|
|
1952
|
-
function
|
|
1988
|
+
function Ze(t, e, r) {
|
|
1953
1989
|
t._state = "running";
|
|
1954
1990
|
var o = t._observer;
|
|
1955
1991
|
try {
|
|
1956
|
-
var n =
|
|
1992
|
+
var n = Jt(o, e);
|
|
1957
1993
|
switch (e) {
|
|
1958
1994
|
case "next":
|
|
1959
1995
|
n && n.call(o, r);
|
|
@@ -1966,10 +2002,10 @@ function Xe(t, e, r) {
|
|
|
1966
2002
|
se(t), n && n.call(o);
|
|
1967
2003
|
break;
|
|
1968
2004
|
}
|
|
1969
|
-
} catch (
|
|
1970
|
-
|
|
2005
|
+
} catch (d) {
|
|
2006
|
+
vt(d);
|
|
1971
2007
|
}
|
|
1972
|
-
t._state === "closed" ?
|
|
2008
|
+
t._state === "closed" ? Qe(t) : t._state === "running" && (t._state = "ready");
|
|
1973
2009
|
}
|
|
1974
2010
|
function ee(t, e, r) {
|
|
1975
2011
|
if (t._state !== "closed") {
|
|
@@ -1984,35 +2020,35 @@ function ee(t, e, r) {
|
|
|
1984
2020
|
t._state = "buffering", t._queue = [{
|
|
1985
2021
|
type: e,
|
|
1986
2022
|
value: r
|
|
1987
|
-
}],
|
|
1988
|
-
return
|
|
2023
|
+
}], Mt(function() {
|
|
2024
|
+
return Rr(t);
|
|
1989
2025
|
});
|
|
1990
2026
|
return;
|
|
1991
2027
|
}
|
|
1992
|
-
|
|
2028
|
+
Ze(t, e, r);
|
|
1993
2029
|
}
|
|
1994
2030
|
}
|
|
1995
|
-
var
|
|
2031
|
+
var Yr = /* @__PURE__ */ (function() {
|
|
1996
2032
|
function t(r, o) {
|
|
1997
2033
|
this._cleanup = void 0, this._observer = r, this._queue = void 0, this._state = "initializing";
|
|
1998
|
-
var n = new
|
|
2034
|
+
var n = new Kr(this);
|
|
1999
2035
|
try {
|
|
2000
2036
|
this._cleanup = o.call(void 0, n);
|
|
2001
|
-
} catch (
|
|
2002
|
-
n.error(
|
|
2037
|
+
} catch (d) {
|
|
2038
|
+
n.error(d);
|
|
2003
2039
|
}
|
|
2004
2040
|
this._state === "initializing" && (this._state = "ready");
|
|
2005
2041
|
}
|
|
2006
2042
|
var e = t.prototype;
|
|
2007
2043
|
return e.unsubscribe = function() {
|
|
2008
|
-
this._state !== "closed" && (se(this),
|
|
2044
|
+
this._state !== "closed" && (se(this), Qe(this));
|
|
2009
2045
|
}, ue(t, [{
|
|
2010
2046
|
key: "closed",
|
|
2011
2047
|
get: function() {
|
|
2012
2048
|
return this._state === "closed";
|
|
2013
2049
|
}
|
|
2014
2050
|
}]), t;
|
|
2015
|
-
})(),
|
|
2051
|
+
})(), Kr = /* @__PURE__ */ (function() {
|
|
2016
2052
|
function t(r) {
|
|
2017
2053
|
this._subscription = r;
|
|
2018
2054
|
}
|
|
@@ -2041,107 +2077,107 @@ var Vr = /* @__PURE__ */ (function() {
|
|
|
2041
2077
|
next: o,
|
|
2042
2078
|
error: arguments[1],
|
|
2043
2079
|
complete: arguments[2]
|
|
2044
|
-
}), new
|
|
2080
|
+
}), new Yr(o, this._subscriber);
|
|
2045
2081
|
}, e.forEach = function(o) {
|
|
2046
2082
|
var n = this;
|
|
2047
|
-
return new Promise(function(
|
|
2083
|
+
return new Promise(function(d, s) {
|
|
2048
2084
|
if (typeof o != "function") {
|
|
2049
|
-
|
|
2085
|
+
s(new TypeError(o + " is not a function"));
|
|
2050
2086
|
return;
|
|
2051
2087
|
}
|
|
2052
|
-
function
|
|
2053
|
-
i.unsubscribe(),
|
|
2088
|
+
function l() {
|
|
2089
|
+
i.unsubscribe(), d();
|
|
2054
2090
|
}
|
|
2055
2091
|
var i = n.subscribe({
|
|
2056
|
-
next: function(
|
|
2092
|
+
next: function(b) {
|
|
2057
2093
|
try {
|
|
2058
|
-
o(
|
|
2059
|
-
} catch (
|
|
2060
|
-
|
|
2094
|
+
o(b, l);
|
|
2095
|
+
} catch (m) {
|
|
2096
|
+
s(m), i.unsubscribe();
|
|
2061
2097
|
}
|
|
2062
2098
|
},
|
|
2063
|
-
error:
|
|
2064
|
-
complete:
|
|
2099
|
+
error: s,
|
|
2100
|
+
complete: d
|
|
2065
2101
|
});
|
|
2066
2102
|
});
|
|
2067
2103
|
}, e.map = function(o) {
|
|
2068
2104
|
var n = this;
|
|
2069
2105
|
if (typeof o != "function") throw new TypeError(o + " is not a function");
|
|
2070
|
-
var
|
|
2071
|
-
return new
|
|
2106
|
+
var d = Nt(this);
|
|
2107
|
+
return new d(function(s) {
|
|
2072
2108
|
return n.subscribe({
|
|
2073
|
-
next: function(
|
|
2109
|
+
next: function(l) {
|
|
2074
2110
|
try {
|
|
2075
|
-
|
|
2111
|
+
l = o(l);
|
|
2076
2112
|
} catch (i) {
|
|
2077
|
-
return
|
|
2113
|
+
return s.error(i);
|
|
2078
2114
|
}
|
|
2079
|
-
|
|
2115
|
+
s.next(l);
|
|
2080
2116
|
},
|
|
2081
|
-
error: function(
|
|
2082
|
-
|
|
2117
|
+
error: function(l) {
|
|
2118
|
+
s.error(l);
|
|
2083
2119
|
},
|
|
2084
2120
|
complete: function() {
|
|
2085
|
-
|
|
2121
|
+
s.complete();
|
|
2086
2122
|
}
|
|
2087
2123
|
});
|
|
2088
2124
|
});
|
|
2089
2125
|
}, e.filter = function(o) {
|
|
2090
2126
|
var n = this;
|
|
2091
2127
|
if (typeof o != "function") throw new TypeError(o + " is not a function");
|
|
2092
|
-
var
|
|
2093
|
-
return new
|
|
2128
|
+
var d = Nt(this);
|
|
2129
|
+
return new d(function(s) {
|
|
2094
2130
|
return n.subscribe({
|
|
2095
|
-
next: function(
|
|
2131
|
+
next: function(l) {
|
|
2096
2132
|
try {
|
|
2097
|
-
if (!o(
|
|
2133
|
+
if (!o(l)) return;
|
|
2098
2134
|
} catch (i) {
|
|
2099
|
-
return
|
|
2135
|
+
return s.error(i);
|
|
2100
2136
|
}
|
|
2101
|
-
|
|
2137
|
+
s.next(l);
|
|
2102
2138
|
},
|
|
2103
|
-
error: function(
|
|
2104
|
-
|
|
2139
|
+
error: function(l) {
|
|
2140
|
+
s.error(l);
|
|
2105
2141
|
},
|
|
2106
2142
|
complete: function() {
|
|
2107
|
-
|
|
2143
|
+
s.complete();
|
|
2108
2144
|
}
|
|
2109
2145
|
});
|
|
2110
2146
|
});
|
|
2111
2147
|
}, e.reduce = function(o) {
|
|
2112
2148
|
var n = this;
|
|
2113
2149
|
if (typeof o != "function") throw new TypeError(o + " is not a function");
|
|
2114
|
-
var
|
|
2115
|
-
return new
|
|
2150
|
+
var d = Nt(this), s = arguments.length > 1, l = !1, i = arguments[1], b = i;
|
|
2151
|
+
return new d(function(m) {
|
|
2116
2152
|
return n.subscribe({
|
|
2117
2153
|
next: function(S) {
|
|
2118
|
-
var _ = !
|
|
2119
|
-
if (
|
|
2154
|
+
var _ = !l;
|
|
2155
|
+
if (l = !0, !_ || s)
|
|
2120
2156
|
try {
|
|
2121
|
-
|
|
2157
|
+
b = o(b, S);
|
|
2122
2158
|
} catch (F) {
|
|
2123
|
-
return
|
|
2159
|
+
return m.error(F);
|
|
2124
2160
|
}
|
|
2125
2161
|
else
|
|
2126
|
-
|
|
2162
|
+
b = S;
|
|
2127
2163
|
},
|
|
2128
2164
|
error: function(S) {
|
|
2129
|
-
|
|
2165
|
+
m.error(S);
|
|
2130
2166
|
},
|
|
2131
2167
|
complete: function() {
|
|
2132
|
-
if (!
|
|
2133
|
-
|
|
2168
|
+
if (!l && !s) return m.error(new TypeError("Cannot reduce an empty sequence"));
|
|
2169
|
+
m.next(b), m.complete();
|
|
2134
2170
|
}
|
|
2135
2171
|
});
|
|
2136
2172
|
});
|
|
2137
2173
|
}, e.concat = function() {
|
|
2138
|
-
for (var o = this, n = arguments.length,
|
|
2139
|
-
|
|
2140
|
-
var
|
|
2141
|
-
return new
|
|
2142
|
-
var
|
|
2174
|
+
for (var o = this, n = arguments.length, d = new Array(n), s = 0; s < n; s++)
|
|
2175
|
+
d[s] = arguments[s];
|
|
2176
|
+
var l = Nt(this);
|
|
2177
|
+
return new l(function(i) {
|
|
2178
|
+
var b, m = 0;
|
|
2143
2179
|
function S(_) {
|
|
2144
|
-
|
|
2180
|
+
b = _.subscribe({
|
|
2145
2181
|
next: function(F) {
|
|
2146
2182
|
i.next(F);
|
|
2147
2183
|
},
|
|
@@ -2149,54 +2185,54 @@ var Vr = /* @__PURE__ */ (function() {
|
|
|
2149
2185
|
i.error(F);
|
|
2150
2186
|
},
|
|
2151
2187
|
complete: function() {
|
|
2152
|
-
|
|
2188
|
+
m === d.length ? (b = void 0, i.complete()) : S(l.from(d[m++]));
|
|
2153
2189
|
}
|
|
2154
2190
|
});
|
|
2155
2191
|
}
|
|
2156
2192
|
return S(o), function() {
|
|
2157
|
-
|
|
2193
|
+
b && (b.unsubscribe(), b = void 0);
|
|
2158
2194
|
};
|
|
2159
2195
|
});
|
|
2160
2196
|
}, e.flatMap = function(o) {
|
|
2161
2197
|
var n = this;
|
|
2162
2198
|
if (typeof o != "function") throw new TypeError(o + " is not a function");
|
|
2163
|
-
var
|
|
2164
|
-
return new
|
|
2165
|
-
var
|
|
2166
|
-
next: function(
|
|
2199
|
+
var d = Nt(this);
|
|
2200
|
+
return new d(function(s) {
|
|
2201
|
+
var l = [], i = n.subscribe({
|
|
2202
|
+
next: function(m) {
|
|
2167
2203
|
if (o)
|
|
2168
2204
|
try {
|
|
2169
|
-
|
|
2205
|
+
m = o(m);
|
|
2170
2206
|
} catch (_) {
|
|
2171
|
-
return
|
|
2207
|
+
return s.error(_);
|
|
2172
2208
|
}
|
|
2173
|
-
var S =
|
|
2209
|
+
var S = d.from(m).subscribe({
|
|
2174
2210
|
next: function(_) {
|
|
2175
|
-
|
|
2211
|
+
s.next(_);
|
|
2176
2212
|
},
|
|
2177
2213
|
error: function(_) {
|
|
2178
|
-
|
|
2214
|
+
s.error(_);
|
|
2179
2215
|
},
|
|
2180
2216
|
complete: function() {
|
|
2181
|
-
var _ =
|
|
2182
|
-
_ >= 0 &&
|
|
2217
|
+
var _ = l.indexOf(S);
|
|
2218
|
+
_ >= 0 && l.splice(_, 1), b();
|
|
2183
2219
|
}
|
|
2184
2220
|
});
|
|
2185
|
-
|
|
2221
|
+
l.push(S);
|
|
2186
2222
|
},
|
|
2187
|
-
error: function(
|
|
2188
|
-
|
|
2223
|
+
error: function(m) {
|
|
2224
|
+
s.error(m);
|
|
2189
2225
|
},
|
|
2190
2226
|
complete: function() {
|
|
2191
|
-
|
|
2227
|
+
b();
|
|
2192
2228
|
}
|
|
2193
2229
|
});
|
|
2194
|
-
function
|
|
2195
|
-
i.closed &&
|
|
2230
|
+
function b() {
|
|
2231
|
+
i.closed && l.length === 0 && s.complete();
|
|
2196
2232
|
}
|
|
2197
2233
|
return function() {
|
|
2198
|
-
|
|
2199
|
-
return
|
|
2234
|
+
l.forEach(function(m) {
|
|
2235
|
+
return m.unsubscribe();
|
|
2200
2236
|
}), i.unsubscribe();
|
|
2201
2237
|
};
|
|
2202
2238
|
});
|
|
@@ -2205,52 +2241,52 @@ var Vr = /* @__PURE__ */ (function() {
|
|
|
2205
2241
|
}, t.from = function(o) {
|
|
2206
2242
|
var n = typeof this == "function" ? this : t;
|
|
2207
2243
|
if (o == null) throw new TypeError(o + " is not an object");
|
|
2208
|
-
var
|
|
2209
|
-
if (
|
|
2210
|
-
var
|
|
2211
|
-
if (Object(
|
|
2212
|
-
return
|
|
2213
|
-
return
|
|
2244
|
+
var d = Jt(o, ie);
|
|
2245
|
+
if (d) {
|
|
2246
|
+
var s = d.call(o);
|
|
2247
|
+
if (Object(s) !== s) throw new TypeError(s + " is not an object");
|
|
2248
|
+
return Vr(s) && s.constructor === n ? s : new n(function(l) {
|
|
2249
|
+
return s.subscribe(l);
|
|
2214
2250
|
});
|
|
2215
2251
|
}
|
|
2216
|
-
if (fe("iterator") && (
|
|
2217
|
-
return new n(function(
|
|
2218
|
-
|
|
2219
|
-
if (!
|
|
2220
|
-
for (var i =
|
|
2221
|
-
var
|
|
2222
|
-
if (
|
|
2252
|
+
if (fe("iterator") && (d = Jt(o, Hr), d))
|
|
2253
|
+
return new n(function(l) {
|
|
2254
|
+
Mt(function() {
|
|
2255
|
+
if (!l.closed) {
|
|
2256
|
+
for (var i = qr(d.call(o)), b; !(b = i()).done; ) {
|
|
2257
|
+
var m = b.value;
|
|
2258
|
+
if (l.next(m), l.closed) return;
|
|
2223
2259
|
}
|
|
2224
|
-
|
|
2260
|
+
l.complete();
|
|
2225
2261
|
}
|
|
2226
2262
|
});
|
|
2227
2263
|
});
|
|
2228
2264
|
if (Array.isArray(o))
|
|
2229
|
-
return new n(function(
|
|
2230
|
-
|
|
2231
|
-
if (!
|
|
2265
|
+
return new n(function(l) {
|
|
2266
|
+
Mt(function() {
|
|
2267
|
+
if (!l.closed) {
|
|
2232
2268
|
for (var i = 0; i < o.length; ++i)
|
|
2233
|
-
if (
|
|
2234
|
-
|
|
2269
|
+
if (l.next(o[i]), l.closed) return;
|
|
2270
|
+
l.complete();
|
|
2235
2271
|
}
|
|
2236
2272
|
});
|
|
2237
2273
|
});
|
|
2238
2274
|
throw new TypeError(o + " is not observable");
|
|
2239
2275
|
}, t.of = function() {
|
|
2240
|
-
for (var o = arguments.length, n = new Array(o),
|
|
2241
|
-
n[
|
|
2242
|
-
var
|
|
2243
|
-
return new
|
|
2244
|
-
|
|
2245
|
-
if (!
|
|
2276
|
+
for (var o = arguments.length, n = new Array(o), d = 0; d < o; d++)
|
|
2277
|
+
n[d] = arguments[d];
|
|
2278
|
+
var s = typeof this == "function" ? this : t;
|
|
2279
|
+
return new s(function(l) {
|
|
2280
|
+
Mt(function() {
|
|
2281
|
+
if (!l.closed) {
|
|
2246
2282
|
for (var i = 0; i < n.length; ++i)
|
|
2247
|
-
if (
|
|
2248
|
-
|
|
2283
|
+
if (l.next(n[i]), l.closed) return;
|
|
2284
|
+
l.complete();
|
|
2249
2285
|
}
|
|
2250
2286
|
});
|
|
2251
2287
|
});
|
|
2252
2288
|
}, ue(t, null, [{
|
|
2253
|
-
key:
|
|
2289
|
+
key: Xe,
|
|
2254
2290
|
get: function() {
|
|
2255
2291
|
return this;
|
|
2256
2292
|
}
|
|
@@ -2259,11 +2295,11 @@ var Vr = /* @__PURE__ */ (function() {
|
|
|
2259
2295
|
pe() && Object.defineProperty(E, Symbol("extensions"), {
|
|
2260
2296
|
value: {
|
|
2261
2297
|
symbol: ie,
|
|
2262
|
-
hostReportError:
|
|
2298
|
+
hostReportError: vt
|
|
2263
2299
|
},
|
|
2264
2300
|
configurable: !0
|
|
2265
2301
|
});
|
|
2266
|
-
function
|
|
2302
|
+
function Jr(t) {
|
|
2267
2303
|
var e, r = t.Symbol;
|
|
2268
2304
|
if (typeof r == "function")
|
|
2269
2305
|
if (r.observable)
|
|
@@ -2279,14 +2315,14 @@ function Rr(t) {
|
|
|
2279
2315
|
e = "@@observable";
|
|
2280
2316
|
return e;
|
|
2281
2317
|
}
|
|
2282
|
-
var
|
|
2283
|
-
typeof self < "u" ?
|
|
2284
|
-
|
|
2285
|
-
var
|
|
2286
|
-
|
|
2318
|
+
var yt;
|
|
2319
|
+
typeof self < "u" ? yt = self : typeof window < "u" ? yt = window : typeof global < "u" ? yt = global : typeof module < "u" ? yt = module : yt = Function("return this")();
|
|
2320
|
+
Jr(yt);
|
|
2321
|
+
var $e = E.prototype, ze = "@@observable";
|
|
2322
|
+
$e[ze] || ($e[ze] = function() {
|
|
2287
2323
|
return this;
|
|
2288
2324
|
});
|
|
2289
|
-
function
|
|
2325
|
+
function Wr(t) {
|
|
2290
2326
|
for (var e = [
|
|
2291
2327
|
"query",
|
|
2292
2328
|
"operationName",
|
|
@@ -2296,13 +2332,13 @@ function Kr(t) {
|
|
|
2296
2332
|
], r = 0, o = Object.keys(t); r < o.length; r++) {
|
|
2297
2333
|
var n = o[r];
|
|
2298
2334
|
if (e.indexOf(n) < 0)
|
|
2299
|
-
throw
|
|
2335
|
+
throw We(58, n);
|
|
2300
2336
|
}
|
|
2301
2337
|
return t;
|
|
2302
2338
|
}
|
|
2303
|
-
function
|
|
2304
|
-
var r = X({}, t), o = function(
|
|
2305
|
-
typeof
|
|
2339
|
+
function Gr(t, e) {
|
|
2340
|
+
var r = X({}, t), o = function(d) {
|
|
2341
|
+
typeof d == "function" ? r = X(X({}, r), d(r)) : r = X(X({}, r), d);
|
|
2306
2342
|
}, n = function() {
|
|
2307
2343
|
return X({}, r);
|
|
2308
2344
|
};
|
|
@@ -2314,32 +2350,32 @@ function Jr(t, e) {
|
|
|
2314
2350
|
value: n
|
|
2315
2351
|
}), e;
|
|
2316
2352
|
}
|
|
2317
|
-
function
|
|
2353
|
+
function Xr(t) {
|
|
2318
2354
|
var e = {
|
|
2319
2355
|
variables: t.variables || {},
|
|
2320
2356
|
extensions: t.extensions || {},
|
|
2321
2357
|
operationName: t.operationName,
|
|
2322
2358
|
query: t.query
|
|
2323
2359
|
};
|
|
2324
|
-
return e.operationName || (e.operationName = typeof e.query != "string" ?
|
|
2360
|
+
return e.operationName || (e.operationName = typeof e.query != "string" ? Dr(e.query) || void 0 : ""), e;
|
|
2325
2361
|
}
|
|
2326
|
-
var
|
|
2327
|
-
function
|
|
2328
|
-
return
|
|
2362
|
+
var Qr = Symbol.for("apollo.deprecations"), Zr = ae, to = new de();
|
|
2363
|
+
function eo(t) {
|
|
2364
|
+
return Zr[Qr] || (to.getValue() || []).includes(t);
|
|
2329
2365
|
}
|
|
2330
|
-
function
|
|
2331
|
-
|
|
2366
|
+
function ro(t, e) {
|
|
2367
|
+
eo(t) || e();
|
|
2332
2368
|
}
|
|
2333
|
-
function
|
|
2369
|
+
function Ae(t, e) {
|
|
2334
2370
|
return e ? e(t) : E.of();
|
|
2335
2371
|
}
|
|
2336
|
-
function
|
|
2337
|
-
return typeof t == "function" ? new
|
|
2372
|
+
function Et(t) {
|
|
2373
|
+
return typeof t == "function" ? new tr(t) : t;
|
|
2338
2374
|
}
|
|
2339
|
-
function
|
|
2375
|
+
function qt(t) {
|
|
2340
2376
|
return t.request.length <= 1;
|
|
2341
2377
|
}
|
|
2342
|
-
var
|
|
2378
|
+
var tr = (
|
|
2343
2379
|
/** @class */
|
|
2344
2380
|
(function() {
|
|
2345
2381
|
function t(e) {
|
|
@@ -2350,40 +2386,40 @@ var Qe = (
|
|
|
2350
2386
|
return E.of();
|
|
2351
2387
|
});
|
|
2352
2388
|
}, t.from = function(e) {
|
|
2353
|
-
return e.length === 0 ? t.empty() : e.map(
|
|
2389
|
+
return e.length === 0 ? t.empty() : e.map(Et).reduce(function(r, o) {
|
|
2354
2390
|
return r.concat(o);
|
|
2355
2391
|
});
|
|
2356
2392
|
}, t.split = function(e, r, o) {
|
|
2357
|
-
var n =
|
|
2358
|
-
return
|
|
2359
|
-
return e(
|
|
2360
|
-
}) :
|
|
2361
|
-
return e(
|
|
2362
|
-
}), Object.assign(
|
|
2393
|
+
var n = Et(r), d = Et(o || new t(Ae)), s;
|
|
2394
|
+
return qt(n) && qt(d) ? s = new t(function(l) {
|
|
2395
|
+
return e(l) ? n.request(l) || E.of() : d.request(l) || E.of();
|
|
2396
|
+
}) : s = new t(function(l, i) {
|
|
2397
|
+
return e(l) ? n.request(l, i) || E.of() : d.request(l, i) || E.of();
|
|
2398
|
+
}), Object.assign(s, { left: n, right: d });
|
|
2363
2399
|
}, t.execute = function(e, r) {
|
|
2364
|
-
return e.request(
|
|
2400
|
+
return e.request(Gr(r.context, Xr(Wr(r)))) || E.of();
|
|
2365
2401
|
}, t.concat = function(e, r) {
|
|
2366
|
-
var o =
|
|
2367
|
-
if (
|
|
2402
|
+
var o = Et(e);
|
|
2403
|
+
if (qt(o))
|
|
2368
2404
|
return globalThis.__DEV__ !== !1 && Zt.warn(47, o), o;
|
|
2369
|
-
var n =
|
|
2370
|
-
return
|
|
2371
|
-
return o.request(
|
|
2372
|
-
return n.request(
|
|
2405
|
+
var n = Et(r), d;
|
|
2406
|
+
return qt(n) ? d = new t(function(s) {
|
|
2407
|
+
return o.request(s, function(l) {
|
|
2408
|
+
return n.request(l) || E.of();
|
|
2373
2409
|
}) || E.of();
|
|
2374
|
-
}) :
|
|
2375
|
-
return o.request(
|
|
2376
|
-
return n.request(i,
|
|
2410
|
+
}) : d = new t(function(s, l) {
|
|
2411
|
+
return o.request(s, function(i) {
|
|
2412
|
+
return n.request(i, l) || E.of();
|
|
2377
2413
|
}) || E.of();
|
|
2378
|
-
}), Object.assign(
|
|
2414
|
+
}), Object.assign(d, { left: o, right: n });
|
|
2379
2415
|
}, t.prototype.split = function(e, r, o) {
|
|
2380
|
-
return this.concat(t.split(e, r, o || new t(
|
|
2416
|
+
return this.concat(t.split(e, r, o || new t(Ae)));
|
|
2381
2417
|
}, t.prototype.concat = function(e) {
|
|
2382
2418
|
return t.concat(this, e);
|
|
2383
2419
|
}, t.prototype.request = function(e, r) {
|
|
2384
|
-
throw
|
|
2420
|
+
throw We(48);
|
|
2385
2421
|
}, t.prototype.onError = function(e, r) {
|
|
2386
|
-
if (globalThis.__DEV__ !== !1 &&
|
|
2422
|
+
if (globalThis.__DEV__ !== !1 && ro("onError", function() {
|
|
2387
2423
|
globalThis.__DEV__ !== !1 && Zt.warn(49);
|
|
2388
2424
|
}), r && r.error)
|
|
2389
2425
|
return r.error(e), !1;
|
|
@@ -2393,26 +2429,26 @@ var Qe = (
|
|
|
2393
2429
|
}, t;
|
|
2394
2430
|
})()
|
|
2395
2431
|
);
|
|
2396
|
-
function
|
|
2397
|
-
return new
|
|
2398
|
-
var o =
|
|
2432
|
+
function oo(t) {
|
|
2433
|
+
return new tr(function(e, r) {
|
|
2434
|
+
var o = Pr(e, []);
|
|
2399
2435
|
return new E(function(n) {
|
|
2400
|
-
var
|
|
2401
|
-
return Promise.resolve(o).then(function(
|
|
2402
|
-
return t(
|
|
2436
|
+
var d, s = !1;
|
|
2437
|
+
return Promise.resolve(o).then(function(l) {
|
|
2438
|
+
return t(l, e.getContext());
|
|
2403
2439
|
}).then(e.setContext).then(function() {
|
|
2404
|
-
|
|
2440
|
+
s || (d = r(e).subscribe({
|
|
2405
2441
|
next: n.next.bind(n),
|
|
2406
2442
|
error: n.error.bind(n),
|
|
2407
2443
|
complete: n.complete.bind(n)
|
|
2408
2444
|
}));
|
|
2409
2445
|
}).catch(n.error.bind(n)), function() {
|
|
2410
|
-
|
|
2446
|
+
s = !0, d && d.unsubscribe();
|
|
2411
2447
|
};
|
|
2412
2448
|
});
|
|
2413
2449
|
});
|
|
2414
2450
|
}
|
|
2415
|
-
const
|
|
2451
|
+
const no = async () => {
|
|
2416
2452
|
const t = "https://auth.australia-southeast1.gcp.commercetools.com/oauth/token", o = "Basic " + btoa(encodeURIComponent("tfegsSBVOYnR7e_yE-AjxVVN") + ":" + encodeURIComponent("pyKWgHuTxuMwDygh9JH1ehLEaLvAhBo4"));
|
|
2417
2453
|
try {
|
|
2418
2454
|
const n = await T.post(
|
|
@@ -2430,30 +2466,30 @@ const ro = async () => {
|
|
|
2430
2466
|
} catch (n) {
|
|
2431
2467
|
return T.isAxiosError(n) ? console.error("Error fetching token:", n.response || n.message) : console.error("Unexpected error:", n), null;
|
|
2432
2468
|
}
|
|
2433
|
-
},
|
|
2434
|
-
uri: `${
|
|
2435
|
-
}),
|
|
2436
|
-
const r = await
|
|
2469
|
+
}, ao = "https://api.australia-southeast1.gcp.commercetools.com/kt-demo/graphql", io = sr({
|
|
2470
|
+
uri: `${ao}`
|
|
2471
|
+
}), so = oo(async (t, { headers: e }) => {
|
|
2472
|
+
const r = await no();
|
|
2437
2473
|
return {
|
|
2438
2474
|
headers: {
|
|
2439
2475
|
...e,
|
|
2440
2476
|
authorization: `Bearer ${r}`
|
|
2441
2477
|
}
|
|
2442
2478
|
};
|
|
2443
|
-
}),
|
|
2444
|
-
link:
|
|
2445
|
-
cache: new
|
|
2479
|
+
}), lo = new lr({
|
|
2480
|
+
link: so.concat(io),
|
|
2481
|
+
cache: new cr(),
|
|
2446
2482
|
defaultOptions: {
|
|
2447
2483
|
watchQuery: {
|
|
2448
2484
|
fetchPolicy: "cache-and-network"
|
|
2449
2485
|
}
|
|
2450
2486
|
}
|
|
2451
|
-
}),
|
|
2487
|
+
}), Fo = (t) => {
|
|
2452
2488
|
const { tanyaConfig: e } = t;
|
|
2453
|
-
return /* @__PURE__ */ a(
|
|
2489
|
+
return /* @__PURE__ */ a(dr, { client: lo, children: /* @__PURE__ */ a(xr, { children: /* @__PURE__ */ a(Tr, { tanyaConfig: e }) }) });
|
|
2454
2490
|
};
|
|
2455
2491
|
export {
|
|
2456
|
-
|
|
2457
|
-
|
|
2492
|
+
Fo as TanyaChatbot,
|
|
2493
|
+
vo as TanyaChatbotProvider
|
|
2458
2494
|
};
|
|
2459
2495
|
//# sourceMappingURL=tanya-chatbot.es.js.map
|