From 303a17591ad5a3b2c1ad452022816015822e831b Mon Sep 17 00:00:00 2001 From: blair2004 Date: Wed, 11 Jan 2023 10:59:13 +0100 Subject: [PATCH] Changelog: - Fixed: Initialization of Axios HTTP Client (#1206) --- config/nexopos.php | 2 +- public/css-manifest.json | 6 ++--- public/css/app.8e6b5ebc12879ff51a1b.css | 1 - public/css/app.fd019f689f87eb441ab3.css | 1 + ...827a.css => dark.27ee9f62809c1ef1073e.css} | 0 ...156.css => light.4d84b75697bee3a4f7ec.css} | 0 public/js/app.min.js | 2 +- public/js/auth.min.js | 2 +- public/js/bootstrap.min/114.js | 1 + public/js/bootstrap.min/117.js | 1 + public/js/bootstrap.min/155.js | 1 + public/js/bootstrap.min/202.js | 1 + public/js/bootstrap.min/204.js | 1 + public/js/bootstrap.min/270.js | 1 + public/js/bootstrap.min/33.js | 1 + public/js/bootstrap.min/333.js | 1 + public/js/bootstrap.min/352.js | 1 + public/js/bootstrap.min/380.js | 1 + public/js/bootstrap.min/399.js | 1 + public/js/bootstrap.min/409.js | 1 + public/js/bootstrap.min/458.js | 1 + public/js/bootstrap.min/496.js | 1 + public/js/bootstrap.min/509.js | 1 + public/js/bootstrap.min/517.js | 1 + public/js/bootstrap.min/521.js | 1 + public/js/bootstrap.min/522.js | 1 + public/js/bootstrap.min/533.js | 1 + public/js/bootstrap.min/537.js | 1 + public/js/bootstrap.min/588.js | 1 + public/js/bootstrap.min/59.js | 1 + public/js/bootstrap.min/634.js | 2 +- public/js/bootstrap.min/665.js | 1 + public/js/bootstrap.min/69.js | 1 + public/js/bootstrap.min/716.js | 1 + public/js/bootstrap.min/730.js | 2 +- public/js/bootstrap.min/804.js | 1 + public/js/bootstrap.min/82.js | 2 +- public/js/bootstrap.min/877.js | 1 + public/js/bootstrap.min/914.js | 1 + public/js/bootstrap.min/919.js | 1 + public/js/bootstrap.min/939.js | 1 + public/js/bootstrap.min/945.js | 1 + public/js/bootstrap.min/967.js | 1 + public/js/bootstrap.min/987.js | 1 + public/js/bootstrap.min/bootstrap.js | 2 +- public/js/cashier.min.js | 2 +- public/js/dashboard.min.js | 2 +- public/js/lang-loader.min.js | 2 +- public/js/manifest.js | 2 +- public/js/popups.min.js | 2 +- public/js/pos-init.min.js | 2 +- public/js/pos.min.js | 2 +- public/js/setup.min.js | 2 +- public/js/update.min.js | 2 +- public/js/vendor.js | 2 +- public/mix-manifest.json | 26 +++++++++---------- resources/ts/bootstrap.ts | 7 ++--- 57 files changed, 71 insertions(+), 37 deletions(-) delete mode 100644 public/css/app.8e6b5ebc12879ff51a1b.css create mode 100644 public/css/app.fd019f689f87eb441ab3.css rename public/css/{dark.0174d418deda1ce7827a.css => dark.27ee9f62809c1ef1073e.css} (100%) rename public/css/{light.9e990100ce36c59d8156.css => light.4d84b75697bee3a4f7ec.css} (100%) create mode 100644 public/js/bootstrap.min/114.js create mode 100644 public/js/bootstrap.min/117.js create mode 100644 public/js/bootstrap.min/155.js create mode 100644 public/js/bootstrap.min/202.js create mode 100644 public/js/bootstrap.min/204.js create mode 100644 public/js/bootstrap.min/270.js create mode 100644 public/js/bootstrap.min/33.js create mode 100644 public/js/bootstrap.min/333.js create mode 100644 public/js/bootstrap.min/352.js create mode 100644 public/js/bootstrap.min/380.js create mode 100644 public/js/bootstrap.min/399.js create mode 100644 public/js/bootstrap.min/409.js create mode 100644 public/js/bootstrap.min/458.js create mode 100644 public/js/bootstrap.min/496.js create mode 100644 public/js/bootstrap.min/509.js create mode 100644 public/js/bootstrap.min/517.js create mode 100644 public/js/bootstrap.min/521.js create mode 100644 public/js/bootstrap.min/522.js create mode 100644 public/js/bootstrap.min/533.js create mode 100644 public/js/bootstrap.min/537.js create mode 100644 public/js/bootstrap.min/588.js create mode 100644 public/js/bootstrap.min/59.js create mode 100644 public/js/bootstrap.min/665.js create mode 100644 public/js/bootstrap.min/69.js create mode 100644 public/js/bootstrap.min/716.js create mode 100644 public/js/bootstrap.min/804.js create mode 100644 public/js/bootstrap.min/877.js create mode 100644 public/js/bootstrap.min/914.js create mode 100644 public/js/bootstrap.min/919.js create mode 100644 public/js/bootstrap.min/939.js create mode 100644 public/js/bootstrap.min/945.js create mode 100644 public/js/bootstrap.min/967.js create mode 100644 public/js/bootstrap.min/987.js diff --git a/config/nexopos.php b/config/nexopos.php index 2d3e1fc14..6a67799d5 100644 --- a/config/nexopos.php +++ b/config/nexopos.php @@ -1,7 +1,7 @@ '4.8.12', + 'version' => '4.8.13', 'languages' => [ 'en' => 'English', 'fr' => 'Français', diff --git a/public/css-manifest.json b/public/css-manifest.json index 1e1c21d15..304d78078 100644 --- a/public/css-manifest.json +++ b/public/css-manifest.json @@ -1,10 +1,10 @@ { "animations.css": "animations.cb4544d9bb06aeaa8e48.css", - "app.css": "app.8e6b5ebc12879ff51a1b.css", + "app.css": "app.fd019f689f87eb441ab3.css", "typography.css": "typography.5d798833a07dd150efa8.css", "fonts.css": "fonts.64053e5a2ec1dd65399b.css", - "light.css": "light.9e990100ce36c59d8156.css", - "dark.css": "dark.0174d418deda1ce7827a.css", + "light.css": "light.4d84b75697bee3a4f7ec.css", + "dark.css": "dark.27ee9f62809c1ef1073e.css", "vue2-daterange-picker.css": "vue2-daterange-picker.fe9e4f57ad74c98c9324.css", "grid.css": "grid.02de9031306c45f5b9f2.css" } \ No newline at end of file diff --git a/public/css/app.8e6b5ebc12879ff51a1b.css b/public/css/app.8e6b5ebc12879ff51a1b.css deleted file mode 100644 index d7e0d9192..000000000 --- a/public/css/app.8e6b5ebc12879ff51a1b.css +++ /dev/null @@ -1 +0,0 @@ -/*! tailwindcss v3.1.8 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}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,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;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{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-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,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}*,:after,:before{--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-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:rgba(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: }::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-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:rgba(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: }.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!important}.\!visible,.visible{visibility:visible!important}.static{position:static!important}.absolute{position:absolute!important}.relative{position:relative!important}.inset-y-0{bottom:0!important;top:0!important}.left-0{left:0!important}.top-0{top:0!important}.bottom-0{bottom:0!important}.-top-10{top:-5em!important}.z-10{z-index:10!important}.z-50{z-index:50!important}.z-40{z-index:40!important}.z-30{z-index:30!important}.col-span-3{grid-column:span 3/span 3!important}.col-span-2{grid-column:span 2/span 2!important}.m-4{margin:1rem!important}.m-1{margin:.25rem!important}.m-2{margin:.5rem!important}.-m-3{margin:-.75rem!important}.-m-4{margin:-1rem!important}.-m-2{margin:-.5rem!important}.mx-2{margin-left:.5rem!important;margin-right:.5rem!important}.my-2{margin-bottom:.5rem!important;margin-top:.5rem!important}.my-5{margin-bottom:1.25rem!important;margin-top:1.25rem!important}.-mx-4{margin-left:-1rem!important;margin-right:-1rem!important}.-mx-2{margin-left:-.5rem!important;margin-right:-.5rem!important}.-mx-1{margin-left:-.25rem!important;margin-right:-.25rem!important}.mx-4{margin-left:1rem!important;margin-right:1rem!important}.mx-1{margin-left:.25rem!important;margin-right:.25rem!important}.-my-1{margin-bottom:-.25rem!important;margin-top:-.25rem!important}.my-1{margin-bottom:.25rem!important;margin-top:.25rem!important}.my-4{margin-bottom:1rem!important;margin-top:1rem!important}.-my-2{margin-bottom:-.5rem!important;margin-top:-.5rem!important}.my-3{margin-bottom:.75rem!important;margin-top:.75rem!important}.mx-auto{margin-left:auto!important;margin-right:auto!important}.-mx-3{margin-left:-.75rem!important;margin-right:-.75rem!important}.mr-2{margin-right:.5rem!important}.mb-2{margin-bottom:.5rem!important}.mt-1{margin-top:.25rem!important}.mb-8{margin-bottom:2rem!important}.ml-1{margin-left:.25rem!important}.-mt-4{margin-top:-1rem!important}.mt-2{margin-top:.5rem!important}.-mb-2{margin-bottom:-.5rem!important}.mb-1{margin-bottom:.25rem!important}.-ml-28{margin-left:-7rem!important}.mr-1{margin-right:.25rem!important}.mb-4{margin-bottom:1rem!important}.mt-4{margin-top:1rem!important}.ml-2{margin-left:.5rem!important}.mb-3{margin-bottom:.75rem!important}.-ml-6{margin-left:-1.5rem!important}.-mt-8{margin-top:-2rem!important}.mb-6{margin-bottom:1.5rem!important}.block{display:block!important}.inline-block{display:inline-block!important}.flex{display:flex!important}.table{display:table!important}.grid{display:grid!important}.hidden{display:none!important}.aspect-square{aspect-ratio:1/1!important}.h-full{height:100%!important}.h-8{height:2rem!important}.h-6{height:1.5rem!important}.h-10{height:2.5rem!important}.h-0{height:0!important}.h-32{height:8rem!important}.h-40{height:10rem!important}.h-24{height:6rem!important}.h-half{height:50vh!important}.h-6\/7-screen{height:85.71vh!important}.h-95vh{height:95vh!important}.h-120{height:30rem!important}.h-16{height:4rem!important}.h-64{height:16rem!important}.h-3\/5-screen{height:60vh!important}.h-56{height:14rem!important}.h-screen{height:100vh!important}.h-12{height:3rem!important}.h-20{height:5rem!important}.h-5\/7-screen{height:71.42vh!important}.h-2\/5-screen{height:40vh!important}.h-96{height:24rem!important}.h-28{height:7rem!important}.max-h-5\/6-screen{max-height:83.33vh!important}.min-h-2\/5-screen{min-height:40vh!important}.w-full{width:100%!important}.w-32{width:8rem!important}.w-1\/3{width:33.333333%!important}.w-8{width:2rem!important}.w-6{width:1.5rem!important}.w-36{width:9rem!important}.w-16{width:4rem!important}.w-0{width:0!important}.w-72{width:18rem!important}.w-2\/3{width:66.666667%!important}.w-24{width:6rem!important}.w-12{width:3rem!important}.w-10{width:2.5rem!important}.w-52{width:13rem!important}.w-56{width:14rem!important}.w-1\/2{width:50%!important}.w-6\/7-screen{width:85.71vw!important}.w-95vw{width:95vw!important}.w-5\/7-screen{width:71.42vw!important}.w-4\/5-screen{width:80vw!important}.w-screen{width:100vw!important}.w-3\/4-screen{width:75vw!important}.w-2\/3-screen{width:66.66vw!important}.w-64{width:16rem!important}.w-11\/12{width:91.666667%!important}.w-48{width:12rem!important}.w-1\/6{width:16.666667%!important}.w-1\/4{width:25%!important}.w-3{width:.75rem!important}.w-3\/5{width:60%!important}.w-3\/4{width:75%!important}.flex-auto{flex:1 1 auto!important}.flex-shrink-0{flex-shrink:0!important}.origin-bottom-right{transform-origin:bottom right!important}@keyframes spin{to{transform:rotate(1turn)}}.animate-spin{animation:spin 1s linear infinite!important}.cursor-pointer{cursor:pointer!important}.cursor-not-allowed{cursor:not-allowed!important}.select-none{-webkit-user-select:none!important;-moz-user-select:none!important;user-select:none!important}.resize{resize:both!important}.appearance-none{-webkit-appearance:none!important;-moz-appearance:none!important;appearance:none!important}.grid-flow-row{grid-auto-flow:row!important}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}.grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))!important}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))!important}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))!important}.grid-rows-1{grid-template-rows:repeat(1,minmax(0,1fr))!important}.grid-rows-3{grid-template-rows:repeat(3,minmax(0,1fr))!important}.grid-rows-2{grid-template-rows:repeat(2,minmax(0,1fr))!important}.flex-row{flex-direction:row!important}.flex-row-reverse{flex-direction:row-reverse!important}.flex-col{flex-direction:column!important}.flex-wrap{flex-wrap:wrap!important}.items-start{align-items:flex-start!important}.items-end{align-items:flex-end!important}.items-center{align-items:center!important}.justify-start{justify-content:flex-start!important}.justify-end{justify-content:flex-end!important}.justify-center{justify-content:center!important}.justify-between{justify-content:space-between!important}.gap-0{gap:0!important}.gap-2{gap:.5rem!important}.divide-y-4>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0!important;border-bottom-width:calc(4px*var(--tw-divide-y-reverse))!important;border-top-width:calc(4px*(1 - var(--tw-divide-y-reverse)))!important}.overflow-auto{overflow:auto!important}.overflow-hidden{overflow:hidden!important}.overflow-scroll{overflow:scroll!important}.overflow-x-auto{overflow-x:auto!important}.overflow-y-auto{overflow-y:auto!important}.overflow-y-hidden{overflow-y:hidden!important}.overflow-y-scroll{overflow-y:scroll!important}.truncate{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}.whitespace-pre-wrap{white-space:pre-wrap!important}.rounded-full{border-radius:9999px!important}.rounded{border-radius:.25rem!important}.rounded-md{border-radius:.375rem!important}.rounded-lg{border-radius:.5rem!important}.rounded-none{border-radius:0!important}.rounded-t-lg{border-top-left-radius:.5rem!important;border-top-right-radius:.5rem!important}.rounded-tl{border-top-left-radius:.25rem!important}.rounded-tr{border-top-right-radius:.25rem!important}.rounded-br-lg{border-bottom-right-radius:.5rem!important}.rounded-bl-lg{border-bottom-left-radius:.5rem!important}.rounded-tl-lg{border-top-left-radius:.5rem!important}.rounded-tr-lg{border-top-right-radius:.5rem!important}.border{border-width:1px!important}.border-2{border-width:2px!important}.border-4{border-width:4px!important}.border-0{border-width:0!important}.border-t{border-top-width:1px!important}.border-l{border-left-width:1px!important}.border-b{border-bottom-width:1px!important}.border-l-2{border-left-width:2px!important}.border-l-8{border-left-width:8px!important}.border-l-4{border-left-width:4px!important}.border-r-2{border-right-width:2px!important}.border-t-4{border-top-width:4px!important}.border-b-0{border-bottom-width:0!important}.border-r{border-right-width:1px!important}.border-b-2{border-bottom-width:2px!important}.border-l-0{border-left-width:0!important}.border-t-0{border-top-width:0!important}.border-r-0{border-right-width:0!important}.border-dashed{border-style:dashed!important}.border-red-200{--tw-border-opacity:1!important;border-color:rgb(254 202 202/var(--tw-border-opacity))!important}.border-green-200{--tw-border-opacity:1!important;border-color:rgb(187 247 208/var(--tw-border-opacity))!important}.border-blue-200{--tw-border-opacity:1!important;border-color:rgb(191 219 254/var(--tw-border-opacity))!important}.border-yellow-200{--tw-border-opacity:1!important;border-color:rgb(254 240 138/var(--tw-border-opacity))!important}.border-input-edge{--tw-border-opacity:1!important;border-color:rgb(var(--input-edge)/var(--tw-border-opacity))!important}.border-gray-400{--tw-border-opacity:1!important;border-color:rgb(156 163 175/var(--tw-border-opacity))!important}.border-popup-surface{--tw-border-opacity:1!important;border-color:rgb(var(--popup-surface)/var(--tw-border-opacity))!important}.border-transparent{border-color:transparent!important}.border-numpad-edge{--tw-border-opacity:1!important;border-color:rgb(var(--numpad-edge)/var(--tw-border-opacity))!important}.border-info-secondary{--tw-border-opacity:1!important;border-color:rgb(var(--info-secondary)/var(--tw-border-opacity))!important}.border-error-primary{--tw-border-opacity:1!important;border-color:rgb(var(--error-primary)/var(--tw-border-opacity))!important}.border-gray-200{--tw-border-opacity:1!important;border-color:rgb(229 231 235/var(--tw-border-opacity))!important}.border-blue-500{--tw-border-opacity:1!important;border-color:rgb(59 130 246/var(--tw-border-opacity))!important}.border-blue-800{--tw-border-opacity:1!important;border-color:rgb(30 64 175/var(--tw-border-opacity))!important}.border-input-option-hover{--tw-border-opacity:1!important;border-color:rgb(var(--input-option-hover)/var(--tw-border-opacity))!important}.border-box-edge{--tw-border-opacity:1!important;border-color:rgb(var(--box-edge)/var(--tw-border-opacity))!important}.border-info-primary{--tw-border-opacity:1!important;border-color:rgb(var(--info-primary)/var(--tw-border-opacity))!important}.border-green-400{--tw-border-opacity:1!important;border-color:rgb(74 222 128/var(--tw-border-opacity))!important}.border-red-400{--tw-border-opacity:1!important;border-color:rgb(248 113 113/var(--tw-border-opacity))!important}.border-gray-700{--tw-border-opacity:1!important;border-color:rgb(55 65 81/var(--tw-border-opacity))!important}.border-table-th-edge{--tw-border-opacity:1!important;border-color:rgb(var(--table-th-edge)/var(--tw-border-opacity))!important}.border-tertiary{--tw-border-opacity:1!important;border-color:rgb(var(--tertiary)/var(--tw-border-opacity))!important}.border-gray-300{--tw-border-opacity:1!important;border-color:rgb(209 213 219/var(--tw-border-opacity))!important}.border-white{--tw-border-opacity:1!important;border-color:rgb(255 255 255/var(--tw-border-opacity))!important}.border-gray-100{--tw-border-opacity:1!important;border-color:rgb(243 244 246/var(--tw-border-opacity))!important}.border-blue-400{--tw-border-opacity:1!important;border-color:rgb(96 165 250/var(--tw-border-opacity))!important}.border-error-secondary{--tw-border-opacity:1!important;border-color:rgb(var(--error-secondary)/var(--tw-border-opacity))!important}.border-success-secondary{--tw-border-opacity:1!important;border-color:rgb(var(--success-secondary)/var(--tw-border-opacity))!important}.border-green-600{--tw-border-opacity:1!important;border-color:rgb(22 163 74/var(--tw-border-opacity))!important}.border-blue-600{--tw-border-opacity:1!important;border-color:rgb(37 99 235/var(--tw-border-opacity))!important}.border-error-tertiary{--tw-border-opacity:1!important;border-color:rgb(var(--error-tertiary)/var(--tw-border-opacity))!important}.border-box-elevation-edge{--tw-border-opacity:1!important;border-color:rgb(var(--box-elevation-edge)/var(--tw-border-opacity))!important}.border-floating-menu-edge{--tw-border-opacity:1!important;border-color:rgb(var(--floating-menu-edge)/var(--tw-border-opacity))!important}.border-black{--tw-border-opacity:1!important;border-color:rgb(0 0 0/var(--tw-border-opacity))!important}.border-box-background{--tw-border-opacity:1!important;border-color:rgb(var(--box-background)/var(--tw-border-opacity))!important}.border-success-primary{--tw-border-opacity:1!important;border-color:rgb(var(--success-primary)/var(--tw-border-opacity))!important}.border-success-tertiary{--tw-border-opacity:1!important;border-color:rgb(var(--success-tertiary)/var(--tw-border-opacity))!important}.border-gray-800{--tw-border-opacity:1!important;border-color:rgb(31 41 55/var(--tw-border-opacity))!important}.border-b-transparent{border-bottom-color:transparent!important}.bg-green-400{background-color:rgb(74 222 128/var(--tw-bg-opacity))!important}.bg-green-400,.bg-red-400{--tw-bg-opacity:1!important}.bg-red-400{background-color:rgb(248 113 113/var(--tw-bg-opacity))!important}.bg-red-100{background-color:rgb(254 226 226/var(--tw-bg-opacity))!important}.bg-green-100,.bg-red-100{--tw-bg-opacity:1!important}.bg-green-100{background-color:rgb(220 252 231/var(--tw-bg-opacity))!important}.bg-blue-100{--tw-bg-opacity:1!important;background-color:rgb(219 234 254/var(--tw-bg-opacity))!important}.bg-yellow-100{--tw-bg-opacity:1!important;background-color:rgb(254 249 195/var(--tw-bg-opacity))!important}.bg-gray-600{--tw-bg-opacity:1!important;background-color:rgb(75 85 99/var(--tw-bg-opacity))!important}.bg-input-background{--tw-bg-opacity:1!important;background-color:rgb(var(--input-background)/var(--tw-bg-opacity))!important}.bg-gray-200{--tw-bg-opacity:1!important;background-color:rgb(229 231 235/var(--tw-bg-opacity))!important}.bg-transparent{background-color:transparent!important}.bg-error-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--error-secondary)/var(--tw-bg-opacity))!important}.bg-input-disabled{--tw-bg-opacity:1!important;background-color:rgb(var(--input-disabled)/var(--tw-bg-opacity))!important}.bg-info-tertiary{--tw-bg-opacity:1!important;background-color:rgb(var(--info-tertiary)/var(--tw-bg-opacity))!important}.bg-info-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--info-secondary)/var(--tw-bg-opacity))!important}.bg-input-edge{background-color:rgb(var(--input-edge)/var(--tw-bg-opacity))!important}.bg-input-edge,.bg-white{--tw-bg-opacity:1!important}.bg-white{background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.bg-gray-400{background-color:rgb(156 163 175/var(--tw-bg-opacity))!important}.bg-blue-400,.bg-gray-400{--tw-bg-opacity:1!important}.bg-blue-400{background-color:rgb(96 165 250/var(--tw-bg-opacity))!important}.bg-orange-400{--tw-bg-opacity:1!important;background-color:rgb(251 146 60/var(--tw-bg-opacity))!important}.bg-gray-800{background-color:rgb(31 41 55/var(--tw-bg-opacity))!important}.bg-gray-800,.bg-gray-900{--tw-bg-opacity:1!important}.bg-gray-900{background-color:rgb(17 24 39/var(--tw-bg-opacity))!important}.bg-red-600{--tw-bg-opacity:1!important;background-color:rgb(220 38 38/var(--tw-bg-opacity))!important}.bg-success-primary{--tw-bg-opacity:1!important;background-color:rgb(var(--success-primary)/var(--tw-bg-opacity))!important}.bg-error-primary{--tw-bg-opacity:1!important;background-color:rgb(var(--error-primary)/var(--tw-bg-opacity))!important}.bg-success-tertiary{--tw-bg-opacity:1!important;background-color:rgb(var(--success-tertiary)/var(--tw-bg-opacity))!important}.bg-error-tertiary{--tw-bg-opacity:1!important;background-color:rgb(var(--error-tertiary)/var(--tw-bg-opacity))!important}.bg-tab-active{--tw-bg-opacity:1!important;background-color:rgb(var(--tab-active)/var(--tw-bg-opacity))!important}.bg-tab-inactive{--tw-bg-opacity:1!important;background-color:rgb(var(--tab-inactive)/var(--tw-bg-opacity))!important}.bg-green-500{--tw-bg-opacity:1!important;background-color:rgb(34 197 94/var(--tw-bg-opacity))!important}.bg-green-200{--tw-bg-opacity:1!important;background-color:rgb(187 247 208/var(--tw-bg-opacity))!important}.bg-info-primary{--tw-bg-opacity:1!important;background-color:rgb(var(--info-primary)/var(--tw-bg-opacity))!important}.bg-surface{background-color:rgb(var(--surface)/var(--tw-bg-opacity))!important}.bg-gray-500,.bg-surface{--tw-bg-opacity:1!important}.bg-gray-500{background-color:rgb(107 114 128/var(--tw-bg-opacity))!important}.bg-gray-300{background-color:rgb(209 213 219/var(--tw-bg-opacity))!important}.bg-gray-300,.bg-gray-700{--tw-bg-opacity:1!important}.bg-gray-700{background-color:rgb(55 65 81/var(--tw-bg-opacity))!important}.bg-blue-500{background-color:rgb(59 130 246/var(--tw-bg-opacity))!important}.bg-blue-500,.bg-red-500{--tw-bg-opacity:1!important}.bg-red-500{background-color:rgb(239 68 68/var(--tw-bg-opacity))!important}.bg-box-elevation-background{--tw-bg-opacity:1!important;background-color:rgb(var(--box-elevation-background)/var(--tw-bg-opacity))!important}.bg-floating-menu{--tw-bg-opacity:1!important;background-color:rgb(var(--floating-menu)/var(--tw-bg-opacity))!important}.bg-box-background{--tw-bg-opacity:1!important;background-color:rgb(var(--box-background)/var(--tw-bg-opacity))!important}.bg-success-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--success-secondary)/var(--tw-bg-opacity))!important}.bg-warning-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--warning-secondary)/var(--tw-bg-opacity))!important}.bg-input-button{--tw-bg-opacity:1!important;background-color:rgb(var(--input-button)/var(--tw-bg-opacity))!important}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))!important}.bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))!important}.bg-gradient-to-bl{background-image:linear-gradient(to bottom left,var(--tw-gradient-stops))!important}.from-success-secondary{--tw-gradient-from:rgb(var(--success-secondary))!important;--tw-gradient-to:rgb(var(--success-secondary)/0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-error-secondary{--tw-gradient-from:rgb(var(--error-secondary))!important;--tw-gradient-to:rgb(var(--error-secondary)/0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-blue-500{--tw-gradient-from:#3b82f6!important;--tw-gradient-to:rgba(59,130,246,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-teal-500{--tw-gradient-from:#14b8a6!important;--tw-gradient-to:rgba(20,184,166,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-blue-200{--tw-gradient-from:#bfdbfe!important;--tw-gradient-to:rgba(191,219,254,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-red-500{--tw-gradient-from:#ef4444!important;--tw-gradient-to:rgba(239,68,68,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-pink-400{--tw-gradient-from:#f472b6!important;--tw-gradient-to:rgba(244,114,182,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-purple-500{--tw-gradient-from:#a855f7!important;--tw-gradient-to:rgba(168,85,247,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-purple-400{--tw-gradient-from:#c084fc!important;--tw-gradient-to:rgba(192,132,252,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-red-400{--tw-gradient-from:#f87171!important;--tw-gradient-to:hsla(0,91%,71%,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-blue-400{--tw-gradient-from:#60a5fa!important;--tw-gradient-to:rgba(96,165,250,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-green-400{--tw-gradient-from:#4ade80!important;--tw-gradient-to:rgba(74,222,128,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-info-secondary{--tw-gradient-from:rgb(var(--info-secondary))!important;--tw-gradient-to:rgb(var(--info-secondary)/0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-red-300{--tw-gradient-from:#fca5a5!important;--tw-gradient-to:hsla(0,94%,82%,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-indigo-400{--tw-gradient-from:#818cf8!important;--tw-gradient-to:rgba(129,140,248,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.via-red-400{--tw-gradient-to:hsla(0,91%,71%,0)!important;--tw-gradient-stops:var(--tw-gradient-from),#f87171,var(--tw-gradient-to)!important}.to-green-700{--tw-gradient-to:#15803d!important}.to-red-700{--tw-gradient-to:#b91c1c!important}.to-blue-700{--tw-gradient-to:#1d4ed8!important}.to-teal-700{--tw-gradient-to:#0f766e!important}.to-indigo-400{--tw-gradient-to:#818cf8!important}.to-pink-500{--tw-gradient-to:#ec4899!important}.to-blue-500{--tw-gradient-to:#3b82f6!important}.to-blue-400{--tw-gradient-to:#60a5fa!important}.to-teal-500{--tw-gradient-to:#14b8a6!important}.to-purple-600{--tw-gradient-to:#9333ea!important}.to-red-600{--tw-gradient-to:#dc2626!important}.to-blue-600{--tw-gradient-to:#2563eb!important}.to-green-600{--tw-gradient-to:#16a34a!important}.to-info-tertiary{--tw-gradient-to:rgb(var(--info-tertiary))!important}.to-red-500{--tw-gradient-to:#ef4444!important}.to-indigo-600{--tw-gradient-to:#4f46e5!important}.bg-clip-text{-webkit-background-clip:text!important;background-clip:text!important}.object-cover{-o-object-fit:cover!important;object-fit:cover!important}.p-4{padding:1rem!important}.p-8{padding:2rem!important}.p-2{padding:.5rem!important}.p-1{padding:.25rem!important}.p-3{padding:.75rem!important}.p-0{padding:0!important}.p-10{padding:2.5rem!important}.px-2{padding-left:.5rem!important;padding-right:.5rem!important}.py-1{padding-bottom:.25rem!important;padding-top:.25rem!important}.py-6{padding-bottom:1.5rem!important;padding-top:1.5rem!important}.py-2{padding-bottom:.5rem!important;padding-top:.5rem!important}.px-3{padding-left:.75rem!important;padding-right:.75rem!important}.px-4{padding-left:1rem!important;padding-right:1rem!important}.px-1{padding-left:.25rem!important;padding-right:.25rem!important}.py-3{padding-bottom:.75rem!important;padding-top:.75rem!important}.py-4{padding-bottom:1rem!important;padding-top:1rem!important}.py-10{padding-bottom:2.5rem!important;padding-top:2.5rem!important}.py-5{padding-bottom:1.25rem!important;padding-top:1.25rem!important}.pl-3{padding-left:.75rem!important}.pl-8{padding-left:2rem!important}.pr-8{padding-right:2rem!important}.pl-7{padding-left:1.75rem!important}.pr-12{padding-right:3rem!important}.pr-2{padding-right:.5rem!important}.pt-2{padding-top:.5rem!important}.pb-4{padding-bottom:1rem!important}.pb-10{padding-bottom:2.5rem!important}.pb-2{padding-bottom:.5rem!important}.pl-2{padding-left:.5rem!important}.pb-1{padding-bottom:.25rem!important}.pr-1{padding-right:.25rem!important}.pl-1{padding-left:.25rem!important}.pt-6{padding-top:1.5rem!important}.text-left{text-align:left!important}.text-center{text-align:center!important}.text-right{text-align:right!important}.font-body{font-family:Graphik,sans-serif!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-lg{font-size:1.125rem!important;line-height:1.75rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-6xl{font-size:3.75rem!important;line-height:1!important}.text-xl{font-size:1.25rem!important;line-height:1.75rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-7xl{line-height:1!important}.text-7xl{font-size:4.5rem!important}.font-semibold{font-weight:600!important}.font-medium{font-weight:500!important}.font-bold{font-weight:700!important}.font-black{font-weight:900!important}.uppercase{text-transform:uppercase!important}.leading-5{line-height:1.25rem!important}.text-white{--tw-text-opacity:1!important;color:rgb(255 255 255/var(--tw-text-opacity))!important}.text-success-tertiary{--tw-text-opacity:1!important;color:rgb(var(--success-tertiary)/var(--tw-text-opacity))!important}.text-info-tertiary{--tw-text-opacity:1!important;color:rgb(var(--info-tertiary)/var(--tw-text-opacity))!important}.text-error-primary{--tw-text-opacity:1!important;color:rgb(var(--error-primary)/var(--tw-text-opacity))!important}.text-primary{--tw-text-opacity:1!important;color:rgb(var(--primary)/var(--tw-text-opacity))!important}.text-secondary{--tw-text-opacity:1!important;color:rgb(var(--secondary)/var(--tw-text-opacity))!important}.text-error-tertiary{--tw-text-opacity:1!important;color:rgb(var(--error-tertiary)/var(--tw-text-opacity))!important}.text-gray-600{--tw-text-opacity:1!important;color:rgb(75 85 99/var(--tw-text-opacity))!important}.text-gray-500{--tw-text-opacity:1!important;color:rgb(107 114 128/var(--tw-text-opacity))!important}.text-red-400{--tw-text-opacity:1!important;color:rgb(248 113 113/var(--tw-text-opacity))!important}.text-gray-700{--tw-text-opacity:1!important;color:rgb(55 65 81/var(--tw-text-opacity))!important}.text-gray-800{--tw-text-opacity:1!important;color:rgb(31 41 55/var(--tw-text-opacity))!important}.text-gray-200{--tw-text-opacity:1!important;color:rgb(229 231 235/var(--tw-text-opacity))!important}.text-error-secondary{--tw-text-opacity:1!important;color:rgb(var(--error-secondary)/var(--tw-text-opacity))!important}.text-gray-100{--tw-text-opacity:1!important;color:rgb(243 244 246/var(--tw-text-opacity))!important}.text-tertiary{--tw-text-opacity:1!important;color:rgb(var(--tertiary)/var(--tw-text-opacity))!important}.text-green-700{--tw-text-opacity:1!important;color:rgb(21 128 61/var(--tw-text-opacity))!important}.text-red-700{--tw-text-opacity:1!important;color:rgb(185 28 28/var(--tw-text-opacity))!important}.text-transparent{color:transparent!important}.text-blue-600{--tw-text-opacity:1!important;color:rgb(37 99 235/var(--tw-text-opacity))!important}.text-blue-500{--tw-text-opacity:1!important;color:rgb(59 130 246/var(--tw-text-opacity))!important}.text-red-500{--tw-text-opacity:1!important;color:rgb(239 68 68/var(--tw-text-opacity))!important}.text-success-secondary{--tw-text-opacity:1!important;color:rgb(var(--success-secondary)/var(--tw-text-opacity))!important}.text-black{--tw-text-opacity:1!important;color:rgb(0 0 0/var(--tw-text-opacity))!important}.text-success-light-secondary{--tw-text-opacity:1!important;color:rgb(var(--success-light-secondary)/var(--tw-text-opacity))!important}.underline{text-decoration-line:underline!important}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)!important}.shadow,.shadow-xl{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.shadow-xl{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)!important}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05)!important;--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)!important}.shadow-lg,.shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)!important}.shadow-inner{--tw-shadow:inset 0 2px 4px 0 rgba(0,0,0,.05)!important;--tw-shadow-colored:inset 0 2px 4px 0 var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.outline-none{outline:2px solid transparent!important;outline-offset:2px!important}.ring-4{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)!important;--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color)!important;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)!important}.blur{--tw-blur:blur(8px)!important}.blur,.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)!important}.transition-all{transition-duration:.15s!important;transition-property:all!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important}.duration-100{transition-duration:.1s!important}.ease-linear{transition-timing-function:linear!important}.\[key\:string\]{key:string}body,html{font-family:Jost;height:100%;width:100%}.bg-overlay{background:rgba(51,51,51,.26)}[v-cloak]>*{display:none}.loader{border-top-color:#3498db!important}.loader.slow{animation:spinner 1.5s linear infinite}.loader.fast{animation:spinner .7s linear infinite}@keyframes spinner{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}button{border-radius:0}#editor h1{font-size:3rem;font-weight:700;line-height:1}#editor h2{font-size:2.25rem;font-weight:700;line-height:2.5rem}#editor h3{font-size:1.875rem;font-weight:700;line-height:2.25rem}#editor h4{font-size:1.5rem;font-weight:700;line-height:2rem}#editor h5{font-size:1.25rem;font-weight:700;line-height:1.75rem}#grid-items .vue-recycle-scroller__item-wrapper{display:grid;gap:0;grid-template-columns:repeat(2,minmax(0,1fr));overflow-y:auto}@media (min-width:768px){#grid-items .vue-recycle-scroller__item-wrapper{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (min-width:1024px){#grid-items .vue-recycle-scroller__item-wrapper{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (min-width:1280px){#grid-items .vue-recycle-scroller__item-wrapper{grid-template-columns:repeat(5,minmax(0,1fr))}}#grid-items .vue-recycle-scroller__item-view{--tw-border-opacity:1;align-items:center;border-color:rgb(229 231 235/var(--tw-border-opacity));border-width:1px;cursor:pointer;display:flex;flex-direction:column;height:8rem;justify-content:center;overflow:hidden}@media (min-width:1024px){#grid-items .vue-recycle-scroller__item-view{height:10rem}}#grid-items .vue-recycle-scroller__item-view:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.popup-heading{align-items:center;display:flex;justify-content:space-between;padding:.5rem}.popup-heading h3{font-weight:600}.hover\:border-info-primary:hover{--tw-border-opacity:1!important;border-color:rgb(var(--info-primary)/var(--tw-border-opacity))!important}.hover\:border-transparent:hover{border-color:transparent!important}.hover\:border-opacity-0:hover{--tw-border-opacity:0!important}.hover\:bg-error-tertiary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--error-tertiary)/var(--tw-bg-opacity))!important}.hover\:bg-numpad-hover:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--numpad-hover)/var(--tw-bg-opacity))!important}.hover\:bg-gray-100:hover{--tw-bg-opacity:1!important;background-color:rgb(243 244 246/var(--tw-bg-opacity))!important}.hover\:bg-gray-700:hover{--tw-bg-opacity:1!important;background-color:rgb(55 65 81/var(--tw-bg-opacity))!important}.hover\:bg-info-tertiary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--info-tertiary)/var(--tw-bg-opacity))!important}.hover\:bg-info-secondary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--info-secondary)/var(--tw-bg-opacity))!important}.hover\:bg-info-primary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--info-primary)/var(--tw-bg-opacity))!important}.hover\:bg-white:hover{--tw-bg-opacity:1!important;background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.hover\:bg-green-600:hover{--tw-bg-opacity:1!important;background-color:rgb(22 163 74/var(--tw-bg-opacity))!important}.hover\:bg-blue-600:hover{--tw-bg-opacity:1!important;background-color:rgb(37 99 235/var(--tw-bg-opacity))!important}.hover\:bg-indigo-100:hover{--tw-bg-opacity:1!important;background-color:rgb(224 231 255/var(--tw-bg-opacity))!important}.hover\:bg-red-600:hover{--tw-bg-opacity:1!important;background-color:rgb(220 38 38/var(--tw-bg-opacity))!important}.hover\:bg-error-primary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--error-primary)/var(--tw-bg-opacity))!important}.hover\:bg-floating-menu-hover:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--floating-menu-hover)/var(--tw-bg-opacity))!important}.hover\:bg-box-elevation-hover:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--box-elevation-hover)/var(--tw-bg-opacity))!important}.hover\:bg-success-tertiary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--success-tertiary)/var(--tw-bg-opacity))!important}.hover\:bg-green-500:hover{--tw-bg-opacity:1!important;background-color:rgb(34 197 94/var(--tw-bg-opacity))!important}.hover\:text-white:hover{--tw-text-opacity:1!important;color:rgb(255 255 255/var(--tw-text-opacity))!important}.hover\:text-blue-400:hover{--tw-text-opacity:1!important;color:rgb(96 165 250/var(--tw-text-opacity))!important}.hover\:text-info-primary:hover{--tw-text-opacity:1!important;color:rgb(var(--info-primary)/var(--tw-text-opacity))!important}.hover\:text-gray-700:hover{--tw-text-opacity:1!important;color:rgb(55 65 81/var(--tw-text-opacity))!important}.hover\:text-error-secondary:hover{--tw-text-opacity:1!important;color:rgb(var(--error-secondary)/var(--tw-text-opacity))!important}.hover\:text-success-secondary:hover{--tw-text-opacity:1!important;color:rgb(var(--success-secondary)/var(--tw-text-opacity))!important}.hover\:underline:hover{text-decoration-line:underline!important}.hover\:shadow-lg:hover{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.focus\:border-blue-400:focus{--tw-border-opacity:1!important;border-color:rgb(96 165 250/var(--tw-border-opacity))!important}.focus\:shadow-sm:focus{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05)!important;--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.active\:border-numpad-edge:active{--tw-border-opacity:1!important;border-color:rgb(var(--numpad-edge)/var(--tw-border-opacity))!important}.dark .dark\:border-red-700{--tw-border-opacity:1!important;border-color:rgb(185 28 28/var(--tw-border-opacity))!important}.dark .dark\:border-green-800{--tw-border-opacity:1!important;border-color:rgb(22 101 52/var(--tw-border-opacity))!important}.dark .dark\:border-blue-700{--tw-border-opacity:1!important;border-color:rgb(29 78 216/var(--tw-border-opacity))!important}.dark .dark\:border-yellow-700{--tw-border-opacity:1!important;border-color:rgb(161 98 7/var(--tw-border-opacity))!important}.dark .dark\:border-slate-700{--tw-border-opacity:1!important;border-color:rgb(51 65 85/var(--tw-border-opacity))!important}.dark .dark\:border-slate-600{--tw-border-opacity:1!important;border-color:rgb(71 85 105/var(--tw-border-opacity))!important}.dark .dark\:bg-red-600{--tw-bg-opacity:1!important;background-color:rgb(220 38 38/var(--tw-bg-opacity))!important}.dark .dark\:bg-green-700{--tw-bg-opacity:1!important;background-color:rgb(21 128 61/var(--tw-bg-opacity))!important}.dark .dark\:bg-blue-600{--tw-bg-opacity:1!important;background-color:rgb(37 99 235/var(--tw-bg-opacity))!important}.dark .dark\:bg-yellow-600{--tw-bg-opacity:1!important;background-color:rgb(202 138 4/var(--tw-bg-opacity))!important}.dark .dark\:bg-slate-700{--tw-bg-opacity:1!important;background-color:rgb(51 65 85/var(--tw-bg-opacity))!important}.dark .dark\:bg-slate-900{--tw-bg-opacity:1!important;background-color:rgb(15 23 42/var(--tw-bg-opacity))!important}.dark .dark\:bg-slate-800{--tw-bg-opacity:1!important;background-color:rgb(30 41 59/var(--tw-bg-opacity))!important}.dark .dark\:text-slate-300{--tw-text-opacity:1!important;color:rgb(203 213 225/var(--tw-text-opacity))!important}.dark .dark\:text-slate-200{--tw-text-opacity:1!important;color:rgb(226 232 240/var(--tw-text-opacity))!important}.dark .dark\:hover\:bg-slate-700:hover{--tw-bg-opacity:1!important;background-color:rgb(51 65 85/var(--tw-bg-opacity))!important}@media (min-width:640px){.sm\:relative{position:relative!important}.sm\:mx-auto{margin-left:auto!important;margin-right:auto!important}.sm\:hidden{display:none!important}.sm\:h-108{height:27rem!important}.sm\:w-64{width:16rem!important}.sm\:flex-row{flex-direction:row!important}.sm\:rounded-lg{border-radius:.5rem!important}.sm\:text-sm{font-size:.875rem!important}.sm\:leading-5,.sm\:text-sm{line-height:1.25rem!important}}@media (min-width:768px){.md\:visible{visibility:visible!important}.md\:static{position:static!important}.md\:my-2{margin-bottom:.5rem!important;margin-top:.5rem!important}.md\:-mx-2{margin-left:-.5rem!important;margin-right:-.5rem!important}.md\:-mx-1{margin-left:-.25rem!important;margin-right:-.25rem!important}.md\:mx-auto{margin-left:auto!important;margin-right:auto!important}.md\:-mx-4{margin-left:-1rem!important;margin-right:-1rem!important}.md\:mb-0{margin-bottom:0!important}.md\:mt-2{margin-top:.5rem!important}.md\:mt-0{margin-top:0!important}.md\:block{display:block!important}.md\:inline-block{display:inline-block!important}.md\:inline{display:inline!important}.md\:flex{display:flex!important}.md\:hidden{display:none!important}.md\:h-5\/7-screen{height:71.42vh!important}.md\:h-5\/6-screen{height:83.33vh!important}.md\:h-6\/7-screen{height:85.71vh!important}.md\:h-3\/5-screen{height:60vh!important}.md\:h-4\/5-screen{height:80vh!important}.md\:h-full{height:100%!important}.md\:w-1\/2{width:50%!important}.md\:w-auto{width:auto!important}.md\:w-2\/5{width:40%!important}.md\:w-4\/7-screen{width:57.14vw!important}.md\:w-5\/7-screen{width:71.42vw!important}.md\:w-2\/5-screen{width:40vw!important}.md\:w-6\/7-screen{width:85.71vw!important}.md\:w-4\/6-screen{width:66.66vw!important}.md\:w-3\/5-screen{width:60vw!important}.md\:w-16{width:4rem!important}.md\:w-3\/6-screen{width:50vw!important}.md\:w-1\/4{width:25%!important}.md\:w-1\/3{width:33.333333%!important}.md\:w-3\/7-screen{width:42.85vw!important}.md\:w-2\/3{width:66.666667%!important}.md\:w-24{width:6rem!important}.md\:w-2\/4-screen{width:50vw!important}.md\:w-4\/5-screen{width:80vw!important}.md\:w-56{width:14rem!important}.md\:w-3\/5{width:60%!important}.md\:w-3\/4{width:75%!important}.md\:w-full{width:100%!important}.md\:w-2\/3-screen{width:66.66vw!important}.md\:w-72{width:18rem!important}.md\:flex-auto{flex:1 1 auto!important}.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}.md\:flex-row{flex-direction:row!important}.md\:flex-col{flex-direction:column!important}.md\:items-start{align-items:flex-start!important}.md\:rounded{border-radius:.25rem!important}.md\:border-l{border-left-width:1px!important}.md\:p-0{padding:0!important}.md\:px-2{padding-left:.5rem!important;padding-right:.5rem!important}.md\:px-1{padding-left:.25rem!important;padding-right:.25rem!important}.md\:px-4{padding-left:1rem!important;padding-right:1rem!important}.md\:text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.md\:text-base{font-size:1rem!important;line-height:1.5rem!important}.md\:text-xl{font-size:1.25rem!important;line-height:1.75rem!important}}@media (min-width:1024px){.lg\:my-8{margin-bottom:2rem!important;margin-top:2rem!important}.lg\:my-1{margin-bottom:.25rem!important;margin-top:.25rem!important}.lg\:block{display:block!important}.lg\:flex{display:flex!important}.lg\:hidden{display:none!important}.lg\:h-5\/7-screen{height:71.42vh!important}.lg\:h-3\/7-screen{height:42.85vh!important}.lg\:h-5\/6-screen{height:83.33vh!important}.lg\:h-full{height:100%!important}.lg\:h-4\/5-screen{height:80vh!important}.lg\:w-1\/3{width:33.333333%!important}.lg\:w-3\/7-screen{width:42.85vw!important}.lg\:w-4\/7-screen{width:57.14vw!important}.lg\:w-2\/4-screen,.lg\:w-half{width:50vw!important}.lg\:w-3\/5-screen{width:60vw!important}.lg\:w-2\/7-screen{width:28.57vw!important}.lg\:w-2\/6-screen{width:33.33vw!important}.lg\:w-2\/5-screen{width:40vw!important}.lg\:w-3\/6-screen{width:50vw!important}.lg\:w-56{width:14rem!important}.lg\:w-1\/3-screen{width:33.33vw!important}.lg\:w-2\/5{width:40%!important}.lg\:w-1\/2{width:50%!important}.lg\:w-3\/5{width:60%!important}.lg\:w-auto{width:auto!important}.lg\:w-2\/3{width:66.666667%!important}.lg\:w-1\/4{width:25%!important}.lg\:w-full{width:100%!important}.lg\:w-2\/4{width:50%!important}.lg\:w-4\/6{width:66.666667%!important}.lg\:w-1\/6{width:16.666667%!important}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}.lg\:flex-row{flex-direction:row!important}.lg\:items-start{align-items:flex-start!important}.lg\:border-b{border-bottom-width:1px!important}.lg\:border-t{border-top-width:1px!important}.lg\:px-0{padding-left:0!important;padding-right:0!important}.lg\:py-1{padding-bottom:.25rem!important;padding-top:.25rem!important}.lg\:text-5xl{font-size:3rem!important;line-height:1!important}.lg\:text-lg{font-size:1.125rem!important}.lg\:text-lg,.lg\:text-xl{line-height:1.75rem!important}.lg\:text-xl{font-size:1.25rem!important}.lg\:text-2xl{font-size:1.5rem!important;line-height:2rem!important}}@media (min-width:1280px){.xl\:h-2\/5-screen{height:40vh!important}.xl\:w-2\/5-screen{width:40vw!important}.xl\:w-108{width:27rem!important}.xl\:w-2\/6-screen{width:33.33vw!important}.xl\:w-84{width:21rem!important}.xl\:w-1\/4{width:25%!important}.xl\:w-1\/2,.xl\:w-2\/4{width:50%!important}.xl\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))!important}.xl\:border-none{border-style:none!important}.xl\:text-xl{font-size:1.25rem!important;line-height:1.75rem!important}}@media print{.print\:w-1\/3{width:33.333333%!important}.print\:w-1\/2{width:50%!important}.print\:text-black{--tw-text-opacity:1!important;color:rgb(0 0 0/var(--tw-text-opacity))!important}} \ No newline at end of file diff --git a/public/css/app.fd019f689f87eb441ab3.css b/public/css/app.fd019f689f87eb441ab3.css new file mode 100644 index 000000000..5ed0e6bda --- /dev/null +++ b/public/css/app.fd019f689f87eb441ab3.css @@ -0,0 +1 @@ +/*! tailwindcss v3.2.4 | MIT License | https://tailwindcss.com*/*,:after,:before{border:0 solid #e5e7eb;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}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,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;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{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{color:inherit;font-family:inherit;font-size:100%;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-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,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--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-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:rgba(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: }::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-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:rgba(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: }.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!important}.\!visible,.visible{visibility:visible!important}.static{position:static!important}.absolute{position:absolute!important}.relative{position:relative!important}.inset-y-0{bottom:0!important;top:0!important}.left-0{left:0!important}.top-0{top:0!important}.bottom-0{bottom:0!important}.-top-10{top:-5em!important}.z-10{z-index:10!important}.z-50{z-index:50!important}.z-40{z-index:40!important}.z-30{z-index:30!important}.col-span-3{grid-column:span 3/span 3!important}.col-span-2{grid-column:span 2/span 2!important}.m-4{margin:1rem!important}.m-1{margin:.25rem!important}.m-2{margin:.5rem!important}.-m-3{margin:-.75rem!important}.-m-4{margin:-1rem!important}.-m-2{margin:-.5rem!important}.mx-2{margin-left:.5rem!important;margin-right:.5rem!important}.my-2{margin-bottom:.5rem!important;margin-top:.5rem!important}.my-5{margin-bottom:1.25rem!important;margin-top:1.25rem!important}.-mx-4{margin-left:-1rem!important;margin-right:-1rem!important}.-mx-2{margin-left:-.5rem!important;margin-right:-.5rem!important}.-mx-1{margin-left:-.25rem!important;margin-right:-.25rem!important}.mx-4{margin-left:1rem!important;margin-right:1rem!important}.mx-1{margin-left:.25rem!important;margin-right:.25rem!important}.-my-1{margin-bottom:-.25rem!important;margin-top:-.25rem!important}.my-1{margin-bottom:.25rem!important;margin-top:.25rem!important}.my-4{margin-bottom:1rem!important;margin-top:1rem!important}.-my-2{margin-bottom:-.5rem!important;margin-top:-.5rem!important}.my-3{margin-bottom:.75rem!important;margin-top:.75rem!important}.mx-auto{margin-left:auto!important;margin-right:auto!important}.-mx-3{margin-left:-.75rem!important;margin-right:-.75rem!important}.mr-2{margin-right:.5rem!important}.mb-2{margin-bottom:.5rem!important}.mt-1{margin-top:.25rem!important}.mb-8{margin-bottom:2rem!important}.ml-1{margin-left:.25rem!important}.-mt-4{margin-top:-1rem!important}.mt-2{margin-top:.5rem!important}.-mb-2{margin-bottom:-.5rem!important}.mb-1{margin-bottom:.25rem!important}.-ml-28{margin-left:-7rem!important}.mr-1{margin-right:.25rem!important}.mb-4{margin-bottom:1rem!important}.mt-4{margin-top:1rem!important}.ml-2{margin-left:.5rem!important}.mb-3{margin-bottom:.75rem!important}.-ml-6{margin-left:-1.5rem!important}.-mt-8{margin-top:-2rem!important}.mb-6{margin-bottom:1.5rem!important}.block{display:block!important}.inline-block{display:inline-block!important}.flex{display:flex!important}.table{display:table!important}.grid{display:grid!important}.hidden{display:none!important}.aspect-square{aspect-ratio:1/1!important}.h-full{height:100%!important}.h-8{height:2rem!important}.h-6{height:1.5rem!important}.h-10{height:2.5rem!important}.h-0{height:0!important}.h-32{height:8rem!important}.h-40{height:10rem!important}.h-24{height:6rem!important}.h-half{height:50vh!important}.h-6\/7-screen{height:85.71vh!important}.h-95vh{height:95vh!important}.h-120{height:30rem!important}.h-16{height:4rem!important}.h-64{height:16rem!important}.h-3\/5-screen{height:60vh!important}.h-56{height:14rem!important}.h-screen{height:100vh!important}.h-12{height:3rem!important}.h-20{height:5rem!important}.h-5\/7-screen{height:71.42vh!important}.h-2\/5-screen{height:40vh!important}.h-96{height:24rem!important}.h-28{height:7rem!important}.max-h-5\/6-screen{max-height:83.33vh!important}.min-h-2\/5-screen{min-height:40vh!important}.w-full{width:100%!important}.w-32{width:8rem!important}.w-1\/3{width:33.333333%!important}.w-8{width:2rem!important}.w-6{width:1.5rem!important}.w-36{width:9rem!important}.w-16{width:4rem!important}.w-0{width:0!important}.w-72{width:18rem!important}.w-2\/3{width:66.666667%!important}.w-24{width:6rem!important}.w-12{width:3rem!important}.w-10{width:2.5rem!important}.w-52{width:13rem!important}.w-56{width:14rem!important}.w-1\/2{width:50%!important}.w-6\/7-screen{width:85.71vw!important}.w-95vw{width:95vw!important}.w-5\/7-screen{width:71.42vw!important}.w-4\/5-screen{width:80vw!important}.w-screen{width:100vw!important}.w-3\/4-screen{width:75vw!important}.w-2\/3-screen{width:66.66vw!important}.w-64{width:16rem!important}.w-11\/12{width:91.666667%!important}.w-48{width:12rem!important}.w-1\/6{width:16.666667%!important}.w-1\/4{width:25%!important}.w-3{width:.75rem!important}.w-3\/5{width:60%!important}.w-3\/4{width:75%!important}.flex-auto{flex:1 1 auto!important}.flex-shrink-0{flex-shrink:0!important}.origin-bottom-right{transform-origin:bottom right!important}@keyframes spin{to{transform:rotate(1turn)}}.animate-spin{animation:spin 1s linear infinite!important}.cursor-pointer{cursor:pointer!important}.cursor-not-allowed{cursor:not-allowed!important}.select-none{-webkit-user-select:none!important;-moz-user-select:none!important;user-select:none!important}.resize{resize:both!important}.appearance-none{-webkit-appearance:none!important;-moz-appearance:none!important;appearance:none!important}.grid-flow-row{grid-auto-flow:row!important}.grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}.grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))!important}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))!important}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))!important}.grid-rows-1{grid-template-rows:repeat(1,minmax(0,1fr))!important}.grid-rows-3{grid-template-rows:repeat(3,minmax(0,1fr))!important}.grid-rows-2{grid-template-rows:repeat(2,minmax(0,1fr))!important}.flex-row{flex-direction:row!important}.flex-row-reverse{flex-direction:row-reverse!important}.flex-col{flex-direction:column!important}.flex-wrap{flex-wrap:wrap!important}.items-start{align-items:flex-start!important}.items-end{align-items:flex-end!important}.items-center{align-items:center!important}.justify-start{justify-content:flex-start!important}.justify-end{justify-content:flex-end!important}.justify-center{justify-content:center!important}.justify-between{justify-content:space-between!important}.gap-0{gap:0!important}.gap-2{gap:.5rem!important}.divide-y-4>:not([hidden])~:not([hidden]){--tw-divide-y-reverse:0!important;border-bottom-width:calc(4px*var(--tw-divide-y-reverse))!important;border-top-width:calc(4px*(1 - var(--tw-divide-y-reverse)))!important}.overflow-auto{overflow:auto!important}.overflow-hidden{overflow:hidden!important}.overflow-scroll{overflow:scroll!important}.overflow-x-auto{overflow-x:auto!important}.overflow-y-auto{overflow-y:auto!important}.overflow-y-hidden{overflow-y:hidden!important}.overflow-y-scroll{overflow-y:scroll!important}.truncate{overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}.whitespace-pre-wrap{white-space:pre-wrap!important}.rounded-full{border-radius:9999px!important}.rounded{border-radius:.25rem!important}.rounded-md{border-radius:.375rem!important}.rounded-lg{border-radius:.5rem!important}.rounded-none{border-radius:0!important}.rounded-t-lg{border-top-left-radius:.5rem!important;border-top-right-radius:.5rem!important}.rounded-tl{border-top-left-radius:.25rem!important}.rounded-tr{border-top-right-radius:.25rem!important}.rounded-br-lg{border-bottom-right-radius:.5rem!important}.rounded-bl-lg{border-bottom-left-radius:.5rem!important}.rounded-tl-lg{border-top-left-radius:.5rem!important}.rounded-tr-lg{border-top-right-radius:.5rem!important}.border{border-width:1px!important}.border-2{border-width:2px!important}.border-4{border-width:4px!important}.border-0{border-width:0!important}.border-t{border-top-width:1px!important}.border-l{border-left-width:1px!important}.border-b{border-bottom-width:1px!important}.border-l-2{border-left-width:2px!important}.border-l-8{border-left-width:8px!important}.border-l-4{border-left-width:4px!important}.border-r-2{border-right-width:2px!important}.border-t-4{border-top-width:4px!important}.border-b-0{border-bottom-width:0!important}.border-r{border-right-width:1px!important}.border-b-2{border-bottom-width:2px!important}.border-l-0{border-left-width:0!important}.border-t-0{border-top-width:0!important}.border-r-0{border-right-width:0!important}.border-dashed{border-style:dashed!important}.border-red-200{--tw-border-opacity:1!important;border-color:rgb(254 202 202/var(--tw-border-opacity))!important}.border-green-200{--tw-border-opacity:1!important;border-color:rgb(187 247 208/var(--tw-border-opacity))!important}.border-blue-200{--tw-border-opacity:1!important;border-color:rgb(191 219 254/var(--tw-border-opacity))!important}.border-yellow-200{--tw-border-opacity:1!important;border-color:rgb(254 240 138/var(--tw-border-opacity))!important}.border-input-edge{--tw-border-opacity:1!important;border-color:rgb(var(--input-edge)/var(--tw-border-opacity))!important}.border-gray-400{--tw-border-opacity:1!important;border-color:rgb(156 163 175/var(--tw-border-opacity))!important}.border-popup-surface{--tw-border-opacity:1!important;border-color:rgb(var(--popup-surface)/var(--tw-border-opacity))!important}.border-transparent{border-color:transparent!important}.border-numpad-edge{--tw-border-opacity:1!important;border-color:rgb(var(--numpad-edge)/var(--tw-border-opacity))!important}.border-info-secondary{--tw-border-opacity:1!important;border-color:rgb(var(--info-secondary)/var(--tw-border-opacity))!important}.border-error-primary{--tw-border-opacity:1!important;border-color:rgb(var(--error-primary)/var(--tw-border-opacity))!important}.border-gray-200{--tw-border-opacity:1!important;border-color:rgb(229 231 235/var(--tw-border-opacity))!important}.border-blue-500{--tw-border-opacity:1!important;border-color:rgb(59 130 246/var(--tw-border-opacity))!important}.border-blue-800{--tw-border-opacity:1!important;border-color:rgb(30 64 175/var(--tw-border-opacity))!important}.border-input-option-hover{--tw-border-opacity:1!important;border-color:rgb(var(--input-option-hover)/var(--tw-border-opacity))!important}.border-box-edge{--tw-border-opacity:1!important;border-color:rgb(var(--box-edge)/var(--tw-border-opacity))!important}.border-info-primary{--tw-border-opacity:1!important;border-color:rgb(var(--info-primary)/var(--tw-border-opacity))!important}.border-green-400{--tw-border-opacity:1!important;border-color:rgb(74 222 128/var(--tw-border-opacity))!important}.border-red-400{--tw-border-opacity:1!important;border-color:rgb(248 113 113/var(--tw-border-opacity))!important}.border-gray-700{--tw-border-opacity:1!important;border-color:rgb(55 65 81/var(--tw-border-opacity))!important}.border-table-th-edge{--tw-border-opacity:1!important;border-color:rgb(var(--table-th-edge)/var(--tw-border-opacity))!important}.border-tertiary{--tw-border-opacity:1!important;border-color:rgb(var(--tertiary)/var(--tw-border-opacity))!important}.border-gray-300{--tw-border-opacity:1!important;border-color:rgb(209 213 219/var(--tw-border-opacity))!important}.border-white{--tw-border-opacity:1!important;border-color:rgb(255 255 255/var(--tw-border-opacity))!important}.border-gray-100{--tw-border-opacity:1!important;border-color:rgb(243 244 246/var(--tw-border-opacity))!important}.border-blue-400{--tw-border-opacity:1!important;border-color:rgb(96 165 250/var(--tw-border-opacity))!important}.border-error-secondary{--tw-border-opacity:1!important;border-color:rgb(var(--error-secondary)/var(--tw-border-opacity))!important}.border-success-secondary{--tw-border-opacity:1!important;border-color:rgb(var(--success-secondary)/var(--tw-border-opacity))!important}.border-green-600{--tw-border-opacity:1!important;border-color:rgb(22 163 74/var(--tw-border-opacity))!important}.border-blue-600{--tw-border-opacity:1!important;border-color:rgb(37 99 235/var(--tw-border-opacity))!important}.border-error-tertiary{--tw-border-opacity:1!important;border-color:rgb(var(--error-tertiary)/var(--tw-border-opacity))!important}.border-box-elevation-edge{--tw-border-opacity:1!important;border-color:rgb(var(--box-elevation-edge)/var(--tw-border-opacity))!important}.border-floating-menu-edge{--tw-border-opacity:1!important;border-color:rgb(var(--floating-menu-edge)/var(--tw-border-opacity))!important}.border-black{--tw-border-opacity:1!important;border-color:rgb(0 0 0/var(--tw-border-opacity))!important}.border-box-background{--tw-border-opacity:1!important;border-color:rgb(var(--box-background)/var(--tw-border-opacity))!important}.border-success-primary{--tw-border-opacity:1!important;border-color:rgb(var(--success-primary)/var(--tw-border-opacity))!important}.border-success-tertiary{--tw-border-opacity:1!important;border-color:rgb(var(--success-tertiary)/var(--tw-border-opacity))!important}.border-gray-800{--tw-border-opacity:1!important;border-color:rgb(31 41 55/var(--tw-border-opacity))!important}.border-b-transparent{border-bottom-color:transparent!important}.bg-green-400{background-color:rgb(74 222 128/var(--tw-bg-opacity))!important}.bg-green-400,.bg-red-400{--tw-bg-opacity:1!important}.bg-red-400{background-color:rgb(248 113 113/var(--tw-bg-opacity))!important}.bg-red-100{background-color:rgb(254 226 226/var(--tw-bg-opacity))!important}.bg-green-100,.bg-red-100{--tw-bg-opacity:1!important}.bg-green-100{background-color:rgb(220 252 231/var(--tw-bg-opacity))!important}.bg-blue-100{--tw-bg-opacity:1!important;background-color:rgb(219 234 254/var(--tw-bg-opacity))!important}.bg-yellow-100{--tw-bg-opacity:1!important;background-color:rgb(254 249 195/var(--tw-bg-opacity))!important}.bg-gray-600{--tw-bg-opacity:1!important;background-color:rgb(75 85 99/var(--tw-bg-opacity))!important}.bg-input-background{--tw-bg-opacity:1!important;background-color:rgb(var(--input-background)/var(--tw-bg-opacity))!important}.bg-gray-200{--tw-bg-opacity:1!important;background-color:rgb(229 231 235/var(--tw-bg-opacity))!important}.bg-transparent{background-color:transparent!important}.bg-error-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--error-secondary)/var(--tw-bg-opacity))!important}.bg-input-disabled{--tw-bg-opacity:1!important;background-color:rgb(var(--input-disabled)/var(--tw-bg-opacity))!important}.bg-info-tertiary{--tw-bg-opacity:1!important;background-color:rgb(var(--info-tertiary)/var(--tw-bg-opacity))!important}.bg-info-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--info-secondary)/var(--tw-bg-opacity))!important}.bg-input-edge{background-color:rgb(var(--input-edge)/var(--tw-bg-opacity))!important}.bg-input-edge,.bg-white{--tw-bg-opacity:1!important}.bg-white{background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.bg-gray-400{background-color:rgb(156 163 175/var(--tw-bg-opacity))!important}.bg-blue-400,.bg-gray-400{--tw-bg-opacity:1!important}.bg-blue-400{background-color:rgb(96 165 250/var(--tw-bg-opacity))!important}.bg-orange-400{--tw-bg-opacity:1!important;background-color:rgb(251 146 60/var(--tw-bg-opacity))!important}.bg-gray-800{background-color:rgb(31 41 55/var(--tw-bg-opacity))!important}.bg-gray-800,.bg-gray-900{--tw-bg-opacity:1!important}.bg-gray-900{background-color:rgb(17 24 39/var(--tw-bg-opacity))!important}.bg-red-600{--tw-bg-opacity:1!important;background-color:rgb(220 38 38/var(--tw-bg-opacity))!important}.bg-success-primary{--tw-bg-opacity:1!important;background-color:rgb(var(--success-primary)/var(--tw-bg-opacity))!important}.bg-error-primary{--tw-bg-opacity:1!important;background-color:rgb(var(--error-primary)/var(--tw-bg-opacity))!important}.bg-success-tertiary{--tw-bg-opacity:1!important;background-color:rgb(var(--success-tertiary)/var(--tw-bg-opacity))!important}.bg-error-tertiary{--tw-bg-opacity:1!important;background-color:rgb(var(--error-tertiary)/var(--tw-bg-opacity))!important}.bg-tab-active{--tw-bg-opacity:1!important;background-color:rgb(var(--tab-active)/var(--tw-bg-opacity))!important}.bg-tab-inactive{--tw-bg-opacity:1!important;background-color:rgb(var(--tab-inactive)/var(--tw-bg-opacity))!important}.bg-green-500{--tw-bg-opacity:1!important;background-color:rgb(34 197 94/var(--tw-bg-opacity))!important}.bg-green-200{--tw-bg-opacity:1!important;background-color:rgb(187 247 208/var(--tw-bg-opacity))!important}.bg-info-primary{--tw-bg-opacity:1!important;background-color:rgb(var(--info-primary)/var(--tw-bg-opacity))!important}.bg-surface{background-color:rgb(var(--surface)/var(--tw-bg-opacity))!important}.bg-gray-500,.bg-surface{--tw-bg-opacity:1!important}.bg-gray-500{background-color:rgb(107 114 128/var(--tw-bg-opacity))!important}.bg-gray-300{background-color:rgb(209 213 219/var(--tw-bg-opacity))!important}.bg-gray-300,.bg-gray-700{--tw-bg-opacity:1!important}.bg-gray-700{background-color:rgb(55 65 81/var(--tw-bg-opacity))!important}.bg-blue-500{background-color:rgb(59 130 246/var(--tw-bg-opacity))!important}.bg-blue-500,.bg-red-500{--tw-bg-opacity:1!important}.bg-red-500{background-color:rgb(239 68 68/var(--tw-bg-opacity))!important}.bg-box-elevation-background{--tw-bg-opacity:1!important;background-color:rgb(var(--box-elevation-background)/var(--tw-bg-opacity))!important}.bg-floating-menu{--tw-bg-opacity:1!important;background-color:rgb(var(--floating-menu)/var(--tw-bg-opacity))!important}.bg-box-background{--tw-bg-opacity:1!important;background-color:rgb(var(--box-background)/var(--tw-bg-opacity))!important}.bg-success-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--success-secondary)/var(--tw-bg-opacity))!important}.bg-warning-secondary{--tw-bg-opacity:1!important;background-color:rgb(var(--warning-secondary)/var(--tw-bg-opacity))!important}.bg-input-button{--tw-bg-opacity:1!important;background-color:rgb(var(--input-button)/var(--tw-bg-opacity))!important}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))!important}.bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))!important}.bg-gradient-to-bl{background-image:linear-gradient(to bottom left,var(--tw-gradient-stops))!important}.from-success-secondary{--tw-gradient-from:rgb(var(--success-secondary))!important;--tw-gradient-to:rgb(var(--success-secondary)/0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-error-secondary{--tw-gradient-from:rgb(var(--error-secondary))!important;--tw-gradient-to:rgb(var(--error-secondary)/0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-blue-500{--tw-gradient-from:#3b82f6!important;--tw-gradient-to:rgba(59,130,246,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-teal-500{--tw-gradient-from:#14b8a6!important;--tw-gradient-to:rgba(20,184,166,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-blue-200{--tw-gradient-from:#bfdbfe!important;--tw-gradient-to:rgba(191,219,254,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-red-500{--tw-gradient-from:#ef4444!important;--tw-gradient-to:rgba(239,68,68,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-pink-400{--tw-gradient-from:#f472b6!important;--tw-gradient-to:rgba(244,114,182,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-purple-500{--tw-gradient-from:#a855f7!important;--tw-gradient-to:rgba(168,85,247,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-purple-400{--tw-gradient-from:#c084fc!important;--tw-gradient-to:rgba(192,132,252,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-red-400{--tw-gradient-from:#f87171!important;--tw-gradient-to:hsla(0,91%,71%,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-blue-400{--tw-gradient-from:#60a5fa!important;--tw-gradient-to:rgba(96,165,250,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-green-400{--tw-gradient-from:#4ade80!important;--tw-gradient-to:rgba(74,222,128,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-info-secondary{--tw-gradient-from:rgb(var(--info-secondary))!important;--tw-gradient-to:rgb(var(--info-secondary)/0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-red-300{--tw-gradient-from:#fca5a5!important;--tw-gradient-to:hsla(0,94%,82%,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.from-indigo-400{--tw-gradient-from:#818cf8!important;--tw-gradient-to:rgba(129,140,248,0)!important;--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)!important}.via-red-400{--tw-gradient-to:hsla(0,91%,71%,0)!important;--tw-gradient-stops:var(--tw-gradient-from),#f87171,var(--tw-gradient-to)!important}.to-green-700{--tw-gradient-to:#15803d!important}.to-red-700{--tw-gradient-to:#b91c1c!important}.to-blue-700{--tw-gradient-to:#1d4ed8!important}.to-teal-700{--tw-gradient-to:#0f766e!important}.to-indigo-400{--tw-gradient-to:#818cf8!important}.to-pink-500{--tw-gradient-to:#ec4899!important}.to-blue-500{--tw-gradient-to:#3b82f6!important}.to-blue-400{--tw-gradient-to:#60a5fa!important}.to-teal-500{--tw-gradient-to:#14b8a6!important}.to-purple-600{--tw-gradient-to:#9333ea!important}.to-red-600{--tw-gradient-to:#dc2626!important}.to-blue-600{--tw-gradient-to:#2563eb!important}.to-green-600{--tw-gradient-to:#16a34a!important}.to-info-tertiary{--tw-gradient-to:rgb(var(--info-tertiary))!important}.to-red-500{--tw-gradient-to:#ef4444!important}.to-indigo-600{--tw-gradient-to:#4f46e5!important}.bg-clip-text{-webkit-background-clip:text!important;background-clip:text!important}.object-cover{-o-object-fit:cover!important;object-fit:cover!important}.p-4{padding:1rem!important}.p-8{padding:2rem!important}.p-2{padding:.5rem!important}.p-1{padding:.25rem!important}.p-3{padding:.75rem!important}.p-0{padding:0!important}.p-10{padding:2.5rem!important}.px-2{padding-left:.5rem!important;padding-right:.5rem!important}.py-1{padding-bottom:.25rem!important;padding-top:.25rem!important}.py-6{padding-bottom:1.5rem!important;padding-top:1.5rem!important}.py-2{padding-bottom:.5rem!important;padding-top:.5rem!important}.px-3{padding-left:.75rem!important;padding-right:.75rem!important}.px-4{padding-left:1rem!important;padding-right:1rem!important}.px-1{padding-left:.25rem!important;padding-right:.25rem!important}.py-3{padding-bottom:.75rem!important;padding-top:.75rem!important}.py-4{padding-bottom:1rem!important;padding-top:1rem!important}.py-10{padding-bottom:2.5rem!important;padding-top:2.5rem!important}.py-5{padding-bottom:1.25rem!important;padding-top:1.25rem!important}.pl-3{padding-left:.75rem!important}.pl-8{padding-left:2rem!important}.pr-8{padding-right:2rem!important}.pl-7{padding-left:1.75rem!important}.pr-12{padding-right:3rem!important}.pr-2{padding-right:.5rem!important}.pt-2{padding-top:.5rem!important}.pb-4{padding-bottom:1rem!important}.pb-10{padding-bottom:2.5rem!important}.pb-2{padding-bottom:.5rem!important}.pl-2{padding-left:.5rem!important}.pb-1{padding-bottom:.25rem!important}.pr-1{padding-right:.25rem!important}.pl-1{padding-left:.25rem!important}.pt-6{padding-top:1.5rem!important}.text-left{text-align:left!important}.text-center{text-align:center!important}.text-right{text-align:right!important}.font-body{font-family:Graphik,sans-serif!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-lg{font-size:1.125rem!important;line-height:1.75rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-6xl{font-size:3.75rem!important;line-height:1!important}.text-xl{font-size:1.25rem!important;line-height:1.75rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-7xl{line-height:1!important}.text-7xl{font-size:4.5rem!important}.font-semibold{font-weight:600!important}.font-medium{font-weight:500!important}.font-bold{font-weight:700!important}.font-black{font-weight:900!important}.uppercase{text-transform:uppercase!important}.leading-5{line-height:1.25rem!important}.text-white{--tw-text-opacity:1!important;color:rgb(255 255 255/var(--tw-text-opacity))!important}.text-success-tertiary{--tw-text-opacity:1!important;color:rgb(var(--success-tertiary)/var(--tw-text-opacity))!important}.text-info-tertiary{--tw-text-opacity:1!important;color:rgb(var(--info-tertiary)/var(--tw-text-opacity))!important}.text-error-primary{--tw-text-opacity:1!important;color:rgb(var(--error-primary)/var(--tw-text-opacity))!important}.text-primary{--tw-text-opacity:1!important;color:rgb(var(--primary)/var(--tw-text-opacity))!important}.text-secondary{--tw-text-opacity:1!important;color:rgb(var(--secondary)/var(--tw-text-opacity))!important}.text-error-tertiary{--tw-text-opacity:1!important;color:rgb(var(--error-tertiary)/var(--tw-text-opacity))!important}.text-gray-600{--tw-text-opacity:1!important;color:rgb(75 85 99/var(--tw-text-opacity))!important}.text-gray-500{--tw-text-opacity:1!important;color:rgb(107 114 128/var(--tw-text-opacity))!important}.text-red-400{--tw-text-opacity:1!important;color:rgb(248 113 113/var(--tw-text-opacity))!important}.text-gray-700{--tw-text-opacity:1!important;color:rgb(55 65 81/var(--tw-text-opacity))!important}.text-gray-800{--tw-text-opacity:1!important;color:rgb(31 41 55/var(--tw-text-opacity))!important}.text-gray-200{--tw-text-opacity:1!important;color:rgb(229 231 235/var(--tw-text-opacity))!important}.text-error-secondary{--tw-text-opacity:1!important;color:rgb(var(--error-secondary)/var(--tw-text-opacity))!important}.text-gray-100{--tw-text-opacity:1!important;color:rgb(243 244 246/var(--tw-text-opacity))!important}.text-tertiary{--tw-text-opacity:1!important;color:rgb(var(--tertiary)/var(--tw-text-opacity))!important}.text-green-700{--tw-text-opacity:1!important;color:rgb(21 128 61/var(--tw-text-opacity))!important}.text-red-700{--tw-text-opacity:1!important;color:rgb(185 28 28/var(--tw-text-opacity))!important}.text-transparent{color:transparent!important}.text-blue-600{--tw-text-opacity:1!important;color:rgb(37 99 235/var(--tw-text-opacity))!important}.text-blue-500{--tw-text-opacity:1!important;color:rgb(59 130 246/var(--tw-text-opacity))!important}.text-red-500{--tw-text-opacity:1!important;color:rgb(239 68 68/var(--tw-text-opacity))!important}.text-success-secondary{--tw-text-opacity:1!important;color:rgb(var(--success-secondary)/var(--tw-text-opacity))!important}.text-black{--tw-text-opacity:1!important;color:rgb(0 0 0/var(--tw-text-opacity))!important}.text-success-light-secondary{--tw-text-opacity:1!important;color:rgb(var(--success-light-secondary)/var(--tw-text-opacity))!important}.underline{text-decoration-line:underline!important}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)!important}.shadow,.shadow-xl{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.shadow-xl{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)!important}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05)!important;--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)!important}.shadow-lg,.shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)!important}.shadow-inner{--tw-shadow:inset 0 2px 4px 0 rgba(0,0,0,.05)!important;--tw-shadow-colored:inset 0 2px 4px 0 var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.outline-none{outline:2px solid transparent!important;outline-offset:2px!important}.ring-4{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)!important;--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color)!important;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)!important}.blur{--tw-blur:blur(8px)!important}.blur,.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)!important}.transition-all{transition-duration:.15s!important;transition-property:all!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important}.duration-100{transition-duration:.1s!important}.ease-linear{transition-timing-function:linear!important}.\[key\:string\]{key:string}body,html{font-family:Jost;height:100%;width:100%}.bg-overlay{background:rgba(51,51,51,.26)}[v-cloak]>*{display:none}.loader{border-top-color:#3498db!important}.loader.slow{animation:spinner 1.5s linear infinite}.loader.fast{animation:spinner .7s linear infinite}@keyframes spinner{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}button{border-radius:0}#editor h1{font-size:3rem;font-weight:700;line-height:1}#editor h2{font-size:2.25rem;font-weight:700;line-height:2.5rem}#editor h3{font-size:1.875rem;font-weight:700;line-height:2.25rem}#editor h4{font-size:1.5rem;font-weight:700;line-height:2rem}#editor h5{font-size:1.25rem;font-weight:700;line-height:1.75rem}#grid-items .vue-recycle-scroller__item-wrapper{display:grid;gap:0;grid-template-columns:repeat(2,minmax(0,1fr));overflow-y:auto}@media (min-width:768px){#grid-items .vue-recycle-scroller__item-wrapper{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (min-width:1024px){#grid-items .vue-recycle-scroller__item-wrapper{grid-template-columns:repeat(4,minmax(0,1fr))}}@media (min-width:1280px){#grid-items .vue-recycle-scroller__item-wrapper{grid-template-columns:repeat(5,minmax(0,1fr))}}#grid-items .vue-recycle-scroller__item-view{--tw-border-opacity:1;align-items:center;border-color:rgb(229 231 235/var(--tw-border-opacity));border-width:1px;cursor:pointer;display:flex;flex-direction:column;height:8rem;justify-content:center;overflow:hidden}@media (min-width:1024px){#grid-items .vue-recycle-scroller__item-view{height:10rem}}#grid-items .vue-recycle-scroller__item-view:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity))}.popup-heading{align-items:center;display:flex;justify-content:space-between;padding:.5rem}.popup-heading h3{font-weight:600}.hover\:border-info-primary:hover{--tw-border-opacity:1!important;border-color:rgb(var(--info-primary)/var(--tw-border-opacity))!important}.hover\:border-transparent:hover{border-color:transparent!important}.hover\:border-opacity-0:hover{--tw-border-opacity:0!important}.hover\:bg-error-tertiary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--error-tertiary)/var(--tw-bg-opacity))!important}.hover\:bg-numpad-hover:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--numpad-hover)/var(--tw-bg-opacity))!important}.hover\:bg-gray-100:hover{--tw-bg-opacity:1!important;background-color:rgb(243 244 246/var(--tw-bg-opacity))!important}.hover\:bg-gray-700:hover{--tw-bg-opacity:1!important;background-color:rgb(55 65 81/var(--tw-bg-opacity))!important}.hover\:bg-info-tertiary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--info-tertiary)/var(--tw-bg-opacity))!important}.hover\:bg-info-secondary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--info-secondary)/var(--tw-bg-opacity))!important}.hover\:bg-info-primary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--info-primary)/var(--tw-bg-opacity))!important}.hover\:bg-white:hover{--tw-bg-opacity:1!important;background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.hover\:bg-green-600:hover{--tw-bg-opacity:1!important;background-color:rgb(22 163 74/var(--tw-bg-opacity))!important}.hover\:bg-blue-600:hover{--tw-bg-opacity:1!important;background-color:rgb(37 99 235/var(--tw-bg-opacity))!important}.hover\:bg-indigo-100:hover{--tw-bg-opacity:1!important;background-color:rgb(224 231 255/var(--tw-bg-opacity))!important}.hover\:bg-red-600:hover{--tw-bg-opacity:1!important;background-color:rgb(220 38 38/var(--tw-bg-opacity))!important}.hover\:bg-error-primary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--error-primary)/var(--tw-bg-opacity))!important}.hover\:bg-floating-menu-hover:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--floating-menu-hover)/var(--tw-bg-opacity))!important}.hover\:bg-box-elevation-hover:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--box-elevation-hover)/var(--tw-bg-opacity))!important}.hover\:bg-success-tertiary:hover{--tw-bg-opacity:1!important;background-color:rgb(var(--success-tertiary)/var(--tw-bg-opacity))!important}.hover\:bg-green-500:hover{--tw-bg-opacity:1!important;background-color:rgb(34 197 94/var(--tw-bg-opacity))!important}.hover\:text-white:hover{--tw-text-opacity:1!important;color:rgb(255 255 255/var(--tw-text-opacity))!important}.hover\:text-blue-400:hover{--tw-text-opacity:1!important;color:rgb(96 165 250/var(--tw-text-opacity))!important}.hover\:text-info-primary:hover{--tw-text-opacity:1!important;color:rgb(var(--info-primary)/var(--tw-text-opacity))!important}.hover\:text-gray-700:hover{--tw-text-opacity:1!important;color:rgb(55 65 81/var(--tw-text-opacity))!important}.hover\:text-error-secondary:hover{--tw-text-opacity:1!important;color:rgb(var(--error-secondary)/var(--tw-text-opacity))!important}.hover\:text-success-secondary:hover{--tw-text-opacity:1!important;color:rgb(var(--success-secondary)/var(--tw-text-opacity))!important}.hover\:underline:hover{text-decoration-line:underline!important}.hover\:shadow-lg:hover{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1)!important;--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.focus\:border-blue-400:focus{--tw-border-opacity:1!important;border-color:rgb(96 165 250/var(--tw-border-opacity))!important}.focus\:shadow-sm:focus{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05)!important;--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}.active\:border-numpad-edge:active{--tw-border-opacity:1!important;border-color:rgb(var(--numpad-edge)/var(--tw-border-opacity))!important}.dark .dark\:border-red-700{--tw-border-opacity:1!important;border-color:rgb(185 28 28/var(--tw-border-opacity))!important}.dark .dark\:border-green-800{--tw-border-opacity:1!important;border-color:rgb(22 101 52/var(--tw-border-opacity))!important}.dark .dark\:border-blue-700{--tw-border-opacity:1!important;border-color:rgb(29 78 216/var(--tw-border-opacity))!important}.dark .dark\:border-yellow-700{--tw-border-opacity:1!important;border-color:rgb(161 98 7/var(--tw-border-opacity))!important}.dark .dark\:border-slate-700{--tw-border-opacity:1!important;border-color:rgb(51 65 85/var(--tw-border-opacity))!important}.dark .dark\:border-slate-600{--tw-border-opacity:1!important;border-color:rgb(71 85 105/var(--tw-border-opacity))!important}.dark .dark\:bg-red-600{--tw-bg-opacity:1!important;background-color:rgb(220 38 38/var(--tw-bg-opacity))!important}.dark .dark\:bg-green-700{--tw-bg-opacity:1!important;background-color:rgb(21 128 61/var(--tw-bg-opacity))!important}.dark .dark\:bg-blue-600{--tw-bg-opacity:1!important;background-color:rgb(37 99 235/var(--tw-bg-opacity))!important}.dark .dark\:bg-yellow-600{--tw-bg-opacity:1!important;background-color:rgb(202 138 4/var(--tw-bg-opacity))!important}.dark .dark\:bg-slate-700{--tw-bg-opacity:1!important;background-color:rgb(51 65 85/var(--tw-bg-opacity))!important}.dark .dark\:bg-slate-900{--tw-bg-opacity:1!important;background-color:rgb(15 23 42/var(--tw-bg-opacity))!important}.dark .dark\:bg-slate-800{--tw-bg-opacity:1!important;background-color:rgb(30 41 59/var(--tw-bg-opacity))!important}.dark .dark\:text-slate-300{--tw-text-opacity:1!important;color:rgb(203 213 225/var(--tw-text-opacity))!important}.dark .dark\:text-slate-200{--tw-text-opacity:1!important;color:rgb(226 232 240/var(--tw-text-opacity))!important}.dark .dark\:hover\:bg-slate-700:hover{--tw-bg-opacity:1!important;background-color:rgb(51 65 85/var(--tw-bg-opacity))!important}@media (min-width:640px){.sm\:relative{position:relative!important}.sm\:mx-auto{margin-left:auto!important;margin-right:auto!important}.sm\:hidden{display:none!important}.sm\:h-108{height:27rem!important}.sm\:w-64{width:16rem!important}.sm\:flex-row{flex-direction:row!important}.sm\:rounded-lg{border-radius:.5rem!important}.sm\:text-sm{font-size:.875rem!important}.sm\:leading-5,.sm\:text-sm{line-height:1.25rem!important}}@media (min-width:768px){.md\:visible{visibility:visible!important}.md\:static{position:static!important}.md\:my-2{margin-bottom:.5rem!important;margin-top:.5rem!important}.md\:-mx-2{margin-left:-.5rem!important;margin-right:-.5rem!important}.md\:-mx-1{margin-left:-.25rem!important;margin-right:-.25rem!important}.md\:mx-auto{margin-left:auto!important;margin-right:auto!important}.md\:-mx-4{margin-left:-1rem!important;margin-right:-1rem!important}.md\:mb-0{margin-bottom:0!important}.md\:mt-2{margin-top:.5rem!important}.md\:mt-0{margin-top:0!important}.md\:block{display:block!important}.md\:inline-block{display:inline-block!important}.md\:inline{display:inline!important}.md\:flex{display:flex!important}.md\:hidden{display:none!important}.md\:h-5\/7-screen{height:71.42vh!important}.md\:h-5\/6-screen{height:83.33vh!important}.md\:h-6\/7-screen{height:85.71vh!important}.md\:h-3\/5-screen{height:60vh!important}.md\:h-4\/5-screen{height:80vh!important}.md\:h-full{height:100%!important}.md\:w-1\/2{width:50%!important}.md\:w-auto{width:auto!important}.md\:w-2\/5{width:40%!important}.md\:w-4\/7-screen{width:57.14vw!important}.md\:w-5\/7-screen{width:71.42vw!important}.md\:w-2\/5-screen{width:40vw!important}.md\:w-6\/7-screen{width:85.71vw!important}.md\:w-4\/6-screen{width:66.66vw!important}.md\:w-3\/5-screen{width:60vw!important}.md\:w-16{width:4rem!important}.md\:w-3\/6-screen{width:50vw!important}.md\:w-1\/4{width:25%!important}.md\:w-1\/3{width:33.333333%!important}.md\:w-3\/7-screen{width:42.85vw!important}.md\:w-2\/3{width:66.666667%!important}.md\:w-24{width:6rem!important}.md\:w-2\/4-screen{width:50vw!important}.md\:w-4\/5-screen{width:80vw!important}.md\:w-56{width:14rem!important}.md\:w-3\/5{width:60%!important}.md\:w-3\/4{width:75%!important}.md\:w-full{width:100%!important}.md\:w-2\/3-screen{width:66.66vw!important}.md\:w-72{width:18rem!important}.md\:flex-auto{flex:1 1 auto!important}.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}.md\:flex-row{flex-direction:row!important}.md\:flex-col{flex-direction:column!important}.md\:items-start{align-items:flex-start!important}.md\:rounded{border-radius:.25rem!important}.md\:border-l{border-left-width:1px!important}.md\:p-0{padding:0!important}.md\:px-2{padding-left:.5rem!important;padding-right:.5rem!important}.md\:px-1{padding-left:.25rem!important;padding-right:.25rem!important}.md\:px-4{padding-left:1rem!important;padding-right:1rem!important}.md\:text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.md\:text-base{font-size:1rem!important;line-height:1.5rem!important}.md\:text-xl{font-size:1.25rem!important;line-height:1.75rem!important}}@media (min-width:1024px){.lg\:my-8{margin-bottom:2rem!important;margin-top:2rem!important}.lg\:my-1{margin-bottom:.25rem!important;margin-top:.25rem!important}.lg\:block{display:block!important}.lg\:flex{display:flex!important}.lg\:hidden{display:none!important}.lg\:h-5\/7-screen{height:71.42vh!important}.lg\:h-3\/7-screen{height:42.85vh!important}.lg\:h-5\/6-screen{height:83.33vh!important}.lg\:h-full{height:100%!important}.lg\:h-4\/5-screen{height:80vh!important}.lg\:w-1\/3{width:33.333333%!important}.lg\:w-3\/7-screen{width:42.85vw!important}.lg\:w-4\/7-screen{width:57.14vw!important}.lg\:w-2\/4-screen,.lg\:w-half{width:50vw!important}.lg\:w-3\/5-screen{width:60vw!important}.lg\:w-2\/7-screen{width:28.57vw!important}.lg\:w-2\/6-screen{width:33.33vw!important}.lg\:w-2\/5-screen{width:40vw!important}.lg\:w-3\/6-screen{width:50vw!important}.lg\:w-56{width:14rem!important}.lg\:w-1\/3-screen{width:33.33vw!important}.lg\:w-2\/5{width:40%!important}.lg\:w-1\/2{width:50%!important}.lg\:w-3\/5{width:60%!important}.lg\:w-auto{width:auto!important}.lg\:w-2\/3{width:66.666667%!important}.lg\:w-1\/4{width:25%!important}.lg\:w-full{width:100%!important}.lg\:w-2\/4{width:50%!important}.lg\:w-4\/6{width:66.666667%!important}.lg\:w-1\/6{width:16.666667%!important}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))!important}.lg\:flex-row{flex-direction:row!important}.lg\:items-start{align-items:flex-start!important}.lg\:border-b{border-bottom-width:1px!important}.lg\:border-t{border-top-width:1px!important}.lg\:px-0{padding-left:0!important;padding-right:0!important}.lg\:py-1{padding-bottom:.25rem!important;padding-top:.25rem!important}.lg\:text-5xl{font-size:3rem!important;line-height:1!important}.lg\:text-lg{font-size:1.125rem!important}.lg\:text-lg,.lg\:text-xl{line-height:1.75rem!important}.lg\:text-xl{font-size:1.25rem!important}.lg\:text-2xl{font-size:1.5rem!important;line-height:2rem!important}}@media (min-width:1280px){.xl\:h-2\/5-screen{height:40vh!important}.xl\:w-2\/5-screen{width:40vw!important}.xl\:w-108{width:27rem!important}.xl\:w-2\/6-screen{width:33.33vw!important}.xl\:w-84{width:21rem!important}.xl\:w-1\/4{width:25%!important}.xl\:w-1\/2,.xl\:w-2\/4{width:50%!important}.xl\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))!important}.xl\:border-none{border-style:none!important}.xl\:text-xl{font-size:1.25rem!important;line-height:1.75rem!important}}@media print{.print\:w-1\/3{width:33.333333%!important}.print\:w-1\/2{width:50%!important}.print\:text-black{--tw-text-opacity:1!important;color:rgb(0 0 0/var(--tw-text-opacity))!important}} \ No newline at end of file diff --git a/public/css/dark.0174d418deda1ce7827a.css b/public/css/dark.27ee9f62809c1ef1073e.css similarity index 100% rename from public/css/dark.0174d418deda1ce7827a.css rename to public/css/dark.27ee9f62809c1ef1073e.css diff --git a/public/css/light.9e990100ce36c59d8156.css b/public/css/light.4d84b75697bee3a4f7ec.css similarity index 100% rename from public/css/light.9e990100ce36c59d8156.css rename to public/css/light.4d84b75697bee3a4f7ec.css diff --git a/public/js/app.min.js b/public/js/app.min.js index cf663e145..acf9dbf36 100644 --- a/public/js/app.min.js +++ b/public/js/app.min.js @@ -1 +1 @@ -(self.webpackChunknexopos_4x=self.webpackChunknexopos_4x||[]).push([[219,198],{4297:(e,t,n)=>{"use strict";var s=n(538),i=n(7975),r=(n(824),n(7166)),a=n.n(r),o=n(5675),l=n(6781),c=window.nsState,d=window.nsScreen,u=window.ns.cssFiles,f=window.nsExtraComponents,p={name:"_blank",specs:["fullscreen=yes","titlebar=yes","scrollbars=yes"],styles:["/css/".concat(u["app.css"]),"/css/".concat(u["light.css"]),"/css/".concat(u["grid.css"]),"/css/".concat(u["typography.css"])]};window.nsHotPress=new l.e,s.default.use(o.Z,p);var h=s.default.component("vue-apex-charts",a()),m=Object.assign(Object.assign({nsModules:function(){return n.e(82).then(n.bind(n,1082))},nsRewardsSystem:function(){return n.e(896).then(n.bind(n,2896))},nsCreateCoupons:function(){return n.e(225).then(n.bind(n,3225))},nsManageProducts:function(){return n.e(852).then(n.bind(n,9852))},nsSettings:function(){return n.e(677).then(n.bind(n,5724))},nsReset:function(){return n.e(800).then(n.bind(n,800))},nsPermissions:function(){return n.e(418).then(n.bind(n,2418))},nsProcurement:function(){return n.e(95).then(n.bind(n,5095))},nsProcurementInvoice:function(){return n.e(531).then(n.bind(n,2531))},nsMedia:function(){return Promise.resolve().then(n.bind(n,4255))},nsDashboardCards:function(){return n.e(251).then(n.bind(n,251))},nsCashierDashboard:function(){return n.e(805).then(n.bind(n,805))},nsBestCustomers:function(){return n.e(336).then(n.bind(n,336))},nsBestCashiers:function(){return n.e(226).then(n.bind(n,2226))},nsOrdersSummary:function(){return n.e(880).then(n.bind(n,2880))},nsOrdersChart:function(){return n.e(417).then(n.bind(n,417))},nsNotifications:function(){return n.e(724).then(n.bind(n,3724))},nsSaleReport:function(){return n.e(978).then(n.bind(n,978))},nsSoldStockReport:function(){return n.e(15).then(n.bind(n,9015))},nsProfitReport:function(){return n.e(523).then(n.bind(n,523))},nsCashFlowReport:function(){return n.e(317).then(n.bind(n,6317))},nsYearlyReport:function(){return n.e(232).then(n.bind(n,5232))},nsPaymentTypesReport:function(){return n.e(759).then(n.bind(n,8759))},nsBestProductsReport:function(){return n.e(441).then(n.bind(n,6441))},nsLowStockReport:function(){return n.e(348).then(n.bind(n,6348))},nsStockAdjustment:function(){return n.e(163).then(n.bind(n,163))},nsPromptPopup:function(){return n.e(89).then(n.bind(n,9089))},nsAlertPopup:function(){return n.e(110).then(n.bind(n,9110))},nsConfirmPopup:function(){return Promise.resolve().then(n.bind(n,3601))},nsPOSLoadingPopup:function(){return n.e(4).then(n.bind(n,2004))},nsOrderInvoice:function(){return n.e(185).then(n.bind(n,2407))},VueApexCharts:h},i),f);for(var v in m)void 0!==m[v].name&&"VueComponent"!==m[v].name&&s.default.component(m[v].name,m[v]);var b=new s.default({el:"#dashboard-aside",data:{sidebar:"visible"},components:m,mounted:function(){var e=this;c.behaviorState.subscribe((function(t){var n=t.object;e.sidebar=n.sidebar}))}});window.nsDashboardAside=b,window.nsDashboardOverlay=new s.default({el:"#dashboard-overlay",data:{sidebar:null},components:m,mounted:function(){var e=this;c.behaviorState.subscribe((function(t){var n=t.object;e.sidebar=n.sidebar}))},methods:{closeMenu:function(){c.setState({sidebar:"hidden"===this.sidebar?"visible":"hidden"})}}}),window.nsDashboardHeader=new s.default({el:"#dashboard-header",data:{menuToggled:!1,sidebar:"visible"},components:m,methods:{toggleMenu:function(){this.menuToggled=!this.menuToggled},toggleSideMenu:function(){["lg","xl"].includes(d.breakpoint),c.setState({sidebar:"hidden"===this.sidebar?"visible":"hidden"})}},mounted:function(){var e=this;c.behaviorState.subscribe((function(t){var n=t.object;e.sidebar=n.sidebar}))}}),window.nsComponents=Object.assign(m,i),window.nsDashboardContent=new s.default({el:"#dashboard-content",components:m})},9671:(e,t,n)=>{"use strict";n.d(t,{l:()=>Y,kq:()=>Z,ih:()=>z,kX:()=>H});var s=n(6486),i=n(9669),r=n(6300),a=n(8345),o=n(9624),l=n(9248),c=n(230);function d(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};return this._request("post",e,t,n)}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("get",e,void 0,t)}},{key:"delete",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("delete",e,void 0,t)}},{key:"put",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._request("put",e,t,n)}},{key:"response",get:function(){return this._lastRequestData}},{key:"_request",value:function(e,t){var n=this,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return t=Z.applyFilters("http-client-url",t.replace(/\/$/,"")),this._subject.next({identifier:"async.start",url:t,data:s}),new c.y((function(r){n._client[e](t,s,Object.assign(Object.assign({},n._client.defaults[e]),i)).then((function(e){n._lastRequestData=e,r.next(e.data),r.complete(),n._subject.next({identifier:"async.stop"})})).catch((function(e){var t;r.error((null===(t=e.response)||void 0===t?void 0:t.data)||e.response||e),n._subject.next({identifier:"async.stop"})}))}))}},{key:"subject",value:function(){return this._subject}},{key:"emit",value:function(e){var t=e.identifier,n=e.value;this._subject.next({identifier:t,value:n})}}],n&&d(t.prototype,n),s&&d(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}(),f=n(3);function p(e,t){for(var n=0;n=1e3){for(var n,s=Math.floor((""+e).length/3),i=2;i>=1;i--){if(((n=parseFloat((0!=s?e/Math.pow(1e3,s):e).toPrecision(i)))+"").replace(/[^a-zA-Z 0-9]+/g,"").length<=2)break}n%1!=0&&(n=n.toFixed(1)),t=n+["","k","m","b","t"][s]}return t})),S=n(1356),E=n(9698);function P(e,t){for(var n=0;n0&&window.outerWidth<=480:this.breakpoint="xs";break;case window.outerWidth>480&&window.outerWidth<=640:this.breakpoint="sm";break;case window.outerWidth>640&&window.outerWidth<=1024:this.breakpoint="md";break;case window.outerWidth>1024&&window.outerWidth<=1280:this.breakpoint="lg";break;case window.outerWidth>1280:this.breakpoint="xl"}}}])&&q(t.prototype,n),s&&q(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()),N=new b({sidebar:["xs","sm","md"].includes(I.breakpoint)?"hidden":"visible"});z.defineClient(i),window.nsEvent=Y,window.nsHttpClient=z,window.nsSnackBar=H,window.nsCurrency=S.W,window.nsTruncate=E.b,window.nsRawCurrency=S.f,window.nsAbbreviate=$,window.nsState=N,window.nsUrl=L,window.nsScreen=I,window.ChartJS=r,window.EventEmitter=h,window.Popup=x.G,window.RxJS=y,window.FormValidation=k.Z,window.nsCrudHandler=R},7975:(e,t,n)=>{"use strict";n.r(t),n.d(t,{nsAvatar:()=>Q,nsButton:()=>o,nsCheckbox:()=>p,nsCkeditor:()=>O,nsCloseButton:()=>j,nsCrud:()=>U,nsCrudForm:()=>g,nsDate:()=>w,nsDateRangePicker:()=>K.Z,nsDateTimePicker:()=>A.Z,nsDatepicker:()=>ee.Z,nsField:()=>_.P,nsIconButton:()=>$,nsInput:()=>c,nsLink:()=>l,nsMediaInput:()=>C,nsMenu:()=>r,nsMultiselect:()=>x,nsNotice:()=>J.Z,nsNumpad:()=>W.Z,nsPaginate:()=>te.Z,nsSearch:()=>se,nsSelect:()=>u,nsSelectAudio:()=>f,nsSpinner:()=>v,nsSubmenu:()=>a,nsSwitch:()=>M.Z,nsTableRow:()=>m,nsTabs:()=>T,nsTabsItem:()=>F,nsTextarea:()=>y});var s=n(538),i=n(9671),r=s.default.component("ns-menu",{data:function(){return{defaultToggledState:!1,_save:0}},props:["href","label","icon","notification","toggled","identifier"],template:'\n
\n \n \n \n {{ label }}\n \n {{ notification }}\n \n \n
\n ',mounted:function(){var e=this;this.defaultToggledState=void 0!==this.toggled?this.toggled:this.defaultToggledState,i.l.subject().subscribe((function(t){t.value!==e.identifier&&(e.defaultToggledState=!1)}))},methods:{toggleEmit:function(){var e=this;this.toggle().then((function(t){t&&i.l.emit({identifier:"side-menu.open",value:e.identifier})}))},toggle:function(){var e=this;return new Promise((function(t,n){0===e.href.length&&(e.defaultToggledState=!e.defaultToggledState,t(e.defaultToggledState))}))}}}),a=s.default.component("ns-submenu",{data:function(){return{}},props:["href","label","active"],mounted:function(){},template:'\n
\n
  • \n \n \n \n
  • \n
    \n '}),o=s.default.component("ns-button",{data:function(){return{clicked:!1,_save:0}},props:["type","disabled","link","href","routerLink","to"],template:'\n
    \n \n \n \n
    \n ',mounted:function(){},computed:{isDisabled:function(){return this.disabled&&(0===this.disabled.length||"disabled"===this.disabled||this.disabled)}}}),l=s.default.component("ns-link",{data:function(){return{clicked:!1,_save:0}},props:["type","to","href","target"],template:'\n
    \n \n \n
    \n ',computed:{buttonclass:function(){switch(this.type){case"info":return"shadow bg-blue-400 text-white";case"success":return"shadow bg-green-400 text-white";case"error":return"shadow bg-red-400 text-white";case"warning":return"shadow bg-orange-400 text-white";default:return"shadow bg-white text-gray-800"}}}}),c=s.default.component("ns-input",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),d=n(7389),u=s.default.component("ns-select",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},mounted:function(){},methods:{__:d.__},template:'\n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),f=s.default.component("ns-select-audio",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__:d.__,playSelectedSound:function(){this.field.value.length>0&&new Audio(this.field.value).play()}},template:'\n
    \n \n
    \n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),p=s.default.component("ns-checkbox",{data:function(){return{}},props:["checked","field","label"],template:'\n
    \n
    \n \n
    \n {{ label }}\n {{ field.label }}\n
    \n ',computed:{isChecked:function(){return this.field?this.field.value:this.checked}},methods:{toggleIt:function(){void 0!==this.field&&(this.field.value=!this.field.value),this.$emit("change",!this.checked)}}}),h=n(2242),m=s.default.component("ns-table-row",{props:["options","row","columns","prependOptions","showOptions"],data:function(){return{optionsToggled:!1}},mounted:function(){},methods:{__:d.__,sanitizeHTML:function(e){var t=document.createElement("div");t.innerHTML=e;for(var n=t.getElementsByTagName("script"),s=n.length;s--;)n[s].parentNode.removeChild(n[s]);return t.innerHTML},getElementOffset:function(e){var t=e.getBoundingClientRect();return{top:t.top+window.pageYOffset,left:t.left+window.pageXOffset}},toggleMenu:function(e){var t=this;if(this.row.$toggled=!this.row.$toggled,this.$emit("toggled",this.row),this.row.$toggled)setTimeout((function(){var e=t.$el.querySelectorAll(".relative > .absolute")[0],n=t.$el.querySelectorAll(".relative")[0],s=t.getElementOffset(n);e.style.top=s.top+"px",e.style.left=s.left+"px",n.classList.remove("relative"),n.classList.add("dropdown-holder")}),100);else{var n=this.$el.querySelectorAll(".dropdown-holder")[0];n.classList.remove("dropdown-holder"),n.classList.add("relative")}},handleChanged:function(e){this.row.$checked=e,this.$emit("updated",this.row)},triggerAsync:function(e){var t=this;e.confirm?confirm(e.confirm.message)&&i.ih[e.type.toLowerCase()](e.url).subscribe((function(e){i.kX.success(e.message).subscribe(),t.$emit("reload",t.row)}),(function(e){t.toggleMenu(),i.kX.error(e.message).subscribe()})):(i.l.emit({identifier:"ns-table-row-action",value:{action:e,row:this.row,component:this}}),this.toggleMenu())},triggerPopup:function(e,t){var n=window.nsExtraComponents[e.component];if(e.component)return n?new Promise((function(s,i){h.G.show(n,{resolve:s,reject:i,row:t,action:e})})):i.kX.error((0,d.__)('Unable to load the component "'.concat(e.component,'". Make sure the component is registered to "nsExtraComponents".'))).subscribe();this.triggerAsync(e)}},template:'\n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n '}),v=s.default.component("ns-spinner",{data:function(){return{}},mounted:function(){},computed:{validatedSize:function(){return this.size||24},validatedBorder:function(){return this.border||8},validatedAnimation:function(){return this.animation||"fast"}},props:["color","size","border"],template:"\n
    \n
    \n
    \n "}),b=n(7266),g=s.default.component("ns-crud-form",{data:function(){return{form:{},globallyChecked:!1,formValidation:new b.Z,rows:[]}},mounted:function(){this.loadForm()},props:["src","create-url","field-class","return-url","submit-url","submit-method","disable-tabs"],computed:{activeTabFields:function(){for(var e in this.form.tabs)if(this.form.tabs[e].active)return this.form.tabs[e].fields;return[]}},methods:{__:d.__,toggle:function(e){for(var t in this.form.tabs)this.form.tabs[t].active=!1;this.form.tabs[e].active=!0},handleShowOptions:function(e){this.rows.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},submit:function(){var e=this;return this.formValidation.validateForm(this.form).length>0?i.kX.error(this.$slots["error-invalid"]?this.$slots["error-invalid"][0].text:"No error message provided for having an invalid form.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():(this.formValidation.disableForm(this.form),void 0===this.submitUrl?i.kX.error(this.$slots["error-no-submit-url"]?this.$slots["error-no-submit-url"][0].text:"No error message provided for not having a valid submit url.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():void i.ih[this.submitMethod?this.submitMethod.toLowerCase():"post"](this.submitUrl,this.formValidation.extractForm(this.form)).subscribe((function(t){if("success"===t.status){if(e.submitMethod&&"post"===e.submitMethod.toLowerCase()&&!1!==e.returnUrl)return document.location=t.data.editUrl||e.returnUrl;i.kX.info(t.message,(0,d.__)("Okay"),{duration:3e3}).subscribe(),e.$emit("save",t)}e.formValidation.enableForm(e.form)}),(function(t){i.kX.error(t.message,void 0,{duration:5e3}).subscribe(),void 0!==t.data&&e.formValidation.triggerError(e.form,t.data),e.formValidation.enableForm(e.form)})))},handleGlobalChange:function(e){this.globallyChecked=e,this.rows.forEach((function(t){return t.$checked=e}))},loadForm:function(){var e=this;i.ih.get("".concat(this.src)).subscribe({next:function(t){e.form=e.parseForm(t.form),i.kq.doAction("ns-crud-form-loaded",e),e.$emit("updated",e.form)},error:function(e){i.kX.error(e.message,"OKAY",{duration:0}).subscribe()}})},parseForm:function(e){e.main.value=void 0===e.main.value?"":e.main.value,e.main=this.formValidation.createFields([e.main])[0];var t=0;for(var n in e.tabs)0===t&&(e.tabs[n].active=!0),e.tabs[n].active=void 0!==e.tabs[n].active&&e.tabs[n].active,e.tabs[n].fields=this.formValidation.createFields(e.tabs[n].fields),t++;return e}},template:'\n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n
    \n
    \n
    \n
    {{ tab.label }}
    \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n
    \n
    \n '}),y=s.default.component("ns-textarea",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),_=n(8737),x=s.default.component("ns-multiselect",{data:function(){return{showPanel:!1,search:""}},props:["field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=void 0!==t.selected&&t.selected,e.field.value&&e.field.value.includes(t.value)&&(t.selected=!0),t}))}},methods:{__:d.__,addOption:function(e){this.field.disabled||(this.$emit("addOption",e),this.$forceUpdate(),setTimeout((function(){}),100))},removeOption:function(e,t){var n=this;if(!this.field.disabled)return t.preventDefault(),t.stopPropagation(),this.$emit("removeOption",e),this.$forceUpdate(),setTimeout((function(){n.search=""}),100),!1}},mounted:function(){var e=this;this.field.value&&this.field.value.reverse().forEach((function(t){var n=e.field.options.filter((function(e){return e.value===t}));n.length>=0&&e.addOption(n[0])}))},template:'\n
    \n \n
    \n
    \n
    \n
    \n
    \n {{ option.label }}\n \n
    \n
    \n
    \n
    \n \n \n
    \n
    \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n
    \n '}),w=s.default.component("ns-date",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-input-edge cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),k=n(4255),C=s.default.component("ns-media-input",{template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n
    \n
    \n \n
    \n \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n ',computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":"ns-enabled"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},data:function(){return{}},props:["placeholder","leading","type","field"],mounted:function(){},methods:{toggleMedia:function(){var e=this;new Promise((function(t,n){h.G.show(k.default,Object.assign({resolve:t,reject:n},e.field.data||{}))})).then((function(t){"use-selected"===t.event&&(e.field.data&&"url"!==e.field.data.type?e.field.data&&"model"!==e.field.data.type||(e.field.value=t.value[0]):e.field.value=t.value[0].sizes.original,e.$forceUpdate())}))}}}),j=s.default.component("ns-close-button",{template:'\n \n ',methods:{clicked:function(e){this.$emit("click",e)}}}),$=s.default.component("ns-icon-button",{template:'\n \n ',props:["className","buttonClass","type"],methods:{clicked:function(e){this.$emit("click",e)}}}),S=n(1272),E=n.n(S),P=n(5234),D=n.n(P),O=s.default.component("ns-ckeditor",{data:function(){return{editor:D()}},components:{ckeditor:E().component},mounted:function(){},methods:{__:d.__},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),T=s.default.component("ns-tabs",{data:function(){return{childrens:[]}},props:["active"],computed:{activeComponent:function(){var e=this.$children.filter((function(e){return e.active}));return e.length>0&&e[0]}},methods:{toggle:function(e){this.$emit("active",e.identifier),this.$emit("changeTab",e.identifier)}},mounted:function(){this.childrens=this.$children},template:'\n
    \n
    \n
    {{ tab.label }}
    \n
    \n \n
    \n '}),F=s.default.component("ns-tabs-item",{data:function(){return{}},mounted:function(){},props:["label","identifier","padding"],template:'\n
    \n \n
    \n '}),M=n(9408),A=n(2744),q=n(7757),V=n.n(q),Y=n(3601),z=n(8603),H=n(6386);const L={data:function(){return{fields:[],validation:new b.Z}},methods:{__:d.__,popupCloser:z.Z,popupResolver:H.Z,closePopup:function(){this.popupResolver(!1)},useFilters:function(){this.popupResolver(this.validation.extractFields(this.fields))},clearFilters:function(){this.fields.forEach((function(e){return e.value=""})),this.popupResolver(null)}},mounted:function(){this.fields=this.validation.createFields(this.$popupParams.queryFilters),this.popupCloser()}};var R=n(1900);const Z=(0,R.Z)(L,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-box shadow-lg w-95vw h-95vh md:w-2/5-screen overflow-hidden md:h-5/6-screen flex flex-col"},[n("div",{staticClass:"p-2 border-b ns-box-header flex justify-between items-center"},[n("h3",[e._v(e._s(e.__("Search Filters")))]),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.closePopup()}}})],1)]),e._v(" "),n("div",{staticClass:"p-2 ns-box-body flex-auto overflow-y-auto"},e._l(e.fields,(function(e,t){return n("ns-field",{key:t,attrs:{field:e}})})),1),e._v(" "),n("div",{staticClass:"p-2 flex justify-between ns-box-footer border-t"},[n("div",[n("ns-button",{attrs:{type:"error"},on:{click:function(t){return e.clearFilters()}}},[e._v(e._s(e.__("Clear Filters")))])],1),e._v(" "),n("div",[n("ns-button",{attrs:{type:"info"},on:{click:function(t){return e.useFilters()}}},[e._v(e._s(e.__("Use Filters")))])],1)])])}),[],!1,null,null,null).exports;var I=function(e,t,n,s){return new(n||(n=Promise))((function(i,r){function a(e){try{l(s.next(e))}catch(e){r(e)}}function o(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,o)}l((s=s.apply(e,t||[])).next())}))};const N={data:function(){return{prependOptions:!1,showOptions:!0,isRefreshing:!1,sortColumn:"",searchInput:"",queryFiltersString:"",searchQuery:"",page:1,bulkAction:"",bulkActions:[],queryFilters:[],withFilters:!1,columns:[],selectedEntries:[],globallyChecked:!1,result:{current_page:null,data:[],first_page_url:null,from:null,last_page:null,last_page_url:null,next_page_url:null,path:null,per_page:null,prev_page_url:null,to:null,total:null}}},name:"ns-crud",mounted:function(){void 0!==this.identifier&&nsCrudHandler.defineInstance(this.identifier,this),this.loadConfig()},props:["src","create-url","mode","identifier","queryParams"],computed:{getParsedSrc:function(){return"".concat(this.src,"?").concat(this.sortColumn).concat(this.searchQuery).concat(this.queryFiltersString).concat(this.queryPage).concat(this.getQueryParams()?"&"+this.getQueryParams():"")},showQueryFilters:function(){return this.queryFilters.length>0},getSelectedAction:function(){var e=this,t=this.bulkActions.filter((function(t){return t.identifier===e.bulkAction}));return t.length>0&&t[0]},pagination:function(){return this.result?this.pageNumbers(this.result.last_page,this.result.current_page):[]},queryPage:function(){return this.result?"&page=".concat(this.page):""},resultInfo:function(){return(0,d.__)("displaying {perPage} on {items} items").replace("{perPage}",this.result.total).replace("{items}",this.result.total)}},methods:{__:d.__,getQueryParams:function(){var e=this;return this.queryParams?Object.keys(this.queryParams).map((function(t){return"".concat(t,"=").concat(e.queryParams[t])})).join("&"):""},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))},downloadContent:function(){nsHttpClient.post("".concat(this.src,"/export?").concat(this.getParsedSrc),{entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe((function(e){setTimeout((function(){return document.location=e.url}),300),i.kX.success((0,d.__)("The document has been generated.")).subscribe()}),(function(e){i.kX.error(e.message||(0,d.__)("Unexpected error occured.")).subscribe()}))},clearSelectedEntries:function(){var e=this;h.G.show(Y.default,{title:(0,d.__)("Clear Selected Entries ?"),message:(0,d.__)("Would you like to clear all selected entries ?"),onAction:function(t){t&&(e.selectedEntries=[])}})},refreshRow:function(e){if(!0===e.$checked){0===this.selectedEntries.filter((function(t){return t.$id===e.$id})).length&&this.selectedEntries.push(e)}else{var t=this.selectedEntries.filter((function(t){return t.$id===e.$id}));if(t.length>0){var n=this.selectedEntries.indexOf(t[0]);this.selectedEntries.splice(n,1)}}},handleShowOptions:function(e){this.result.data.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},handleGlobalChange:function(e){var t=this;this.globallyChecked=e,this.result.data.forEach((function(n){n.$checked=e,t.refreshRow(n)}))},loadConfig:function(){var e=this;nsHttpClient.get("".concat(this.src,"/config?").concat(this.getQueryParams())).subscribe((function(t){e.columns=t.columns,e.bulkActions=t.bulkActions,e.queryFilters=t.queryFilters,e.prependOptions=t.prependOptions,e.showOptions=t.showOptions,e.refresh()}),(function(e){i.kX.error(e.message,"OK",{duration:!1}).subscribe()}))},cancelSearch:function(){this.searchInput="",this.search()},search:function(){this.searchInput?this.searchQuery="&search=".concat(this.searchInput):this.searchQuery="",this.refresh()},sort:function(e){for(var t in this.columns)t!==e&&(this.columns[t].$sorted=!1,this.columns[t].$direction="");switch(this.columns[e].$sorted=!0,this.columns[e].$direction){case"asc":this.columns[e].$direction="desc";break;case"desc":this.columns[e].$direction="";break;case"":this.columns[e].$direction="asc"}["asc","desc"].includes(this.columns[e].$direction)?this.sortColumn="active=".concat(e,"&direction=").concat(this.columns[e].$direction):this.sortColumn="",this.$emit("sort",this.columns[e]),this.refresh()},bulkDo:function(){var e=this;return this.bulkAction?this.selectedEntries.length>0?confirm(this.getSelectedAction.confirm||this.$slots["error-bulk-confirmation"]||(0,d.__)("Would you like to perform the selected bulk action on the selected entries ?"))?nsHttpClient.post("".concat(this.src,"/bulk-actions"),{action:this.bulkAction,entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe({next:function(t){i.kX.info(t.message).subscribe(),e.selectedEntries=[],e.refresh()},error:function(e){i.kX.error(e.message).subscribe()}}):void 0:i.kX.error(this.$slots["error-no-selection"]?this.$slots["error-no-selection"][0].text:(0,d.__)("No selection has been made.")).subscribe():i.kX.error(this.$slots["error-no-action"]?this.$slots["error-no-action"][0].text:(0,d.__)("No action has been selected.")).subscribe()},openQueryFilter:function(){return I(this,void 0,void 0,V().mark((function e(){var t,n=this;return V().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,console.log(Z),e.next=4,new Promise((function(e,t){h.G.show(Z,{resolve:e,reject:t,queryFilters:n.queryFilters})}));case 4:t=e.sent,this.withFilters=!1,this.queryFiltersString="",null!==t&&(this.withFilters=!0,this.queryFiltersString="&queryFilters="+encodeURIComponent(JSON.stringify(t))),this.refresh(),e.next=13;break;case 11:e.prev=11,e.t0=e.catch(0);case 13:case"end":return e.stop()}}),e,this,[[0,11]])})))},refresh:function(){var e=this;this.globallyChecked=!1,this.isRefreshing=!0,nsHttpClient.get("".concat(this.getParsedSrc)).subscribe((function(t){t.data=t.data.map((function(t){return e.selectedEntries.filter((function(e){return e.$id===t.$id})).length>0&&(t.$checked=!0),t})),e.isRefreshing=!1,e.result=t,e.page=t.current_page}),(function(t){e.isRefreshing=!1,i.kX.error(t.message).subscribe()}))}}};const U=(0,R.Z)(N,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"w-full rounded-lg",class:"light"!==e.mode?"shadow mb-8":"",attrs:{id:"crud-table"}},["light"!==e.mode?n("div",{staticClass:"p-2 border-b border-popup-surface flex flex-col md:flex-row justify-between flex-wrap",attrs:{id:"crud-table-header"}},[n("div",{staticClass:"w-full md:w-auto -mx-2 mb-2 md:mb-0 flex",attrs:{id:"crud-search-box"}},[e.createUrl?n("div",{staticClass:"px-2 flex items-center justify-center"},[n("a",{staticClass:"rounded-full ns-crud-button text-sm h-10 flex items-center justify-center cursor-pointer px-3 outline-none border",attrs:{href:e.createUrl||"#"}},[n("i",{staticClass:"las la-plus"})])]):e._e(),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded-full p-1 ns-crud-input flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchInput,expression:"searchInput"}],staticClass:"w-36 md:w-auto bg-transparent outline-none px-2",attrs:{type:"text"},domProps:{value:e.searchInput},on:{input:function(t){t.target.composing||(e.searchInput=t.target.value)}}}),e._v(" "),n("button",{staticClass:"rounded-full w-8 h-8 outline-none ns-crud-input-button",on:{click:function(t){return e.search()}}},[n("i",{staticClass:"las la-search"})]),e._v(" "),e.searchQuery?n("button",{staticClass:"ml-1 rounded-full w-8 h-8 bg-error-secondary text-white outline-none hover:bg-error-tertiary",on:{click:function(t){return e.cancelSearch()}}},[n("i",{staticClass:"las la-times"})]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2 flex items-center justify-center"},[n("button",{staticClass:"rounded-full\n text-sm\n h-10\n px-3\n outline-none\n border\n ns-crud-button\n ",on:{click:function(t){return e.refresh()}}},[n("i",{staticClass:"las la-sync",class:e.isRefreshing?"animate-spin":""})])]),e._v(" "),e.showQueryFilters?n("div",{staticClass:"px-2 flex items-center"},[n("button",{staticClass:"ns-crud-button border rounded-full text-sm h-10 px-3 outline-none ",class:e.withFilters?"table-filters-enabled":"table-filters-disabled",on:{click:function(t){return e.openQueryFilter()}}},[e.withFilters?e._e():n("i",{staticClass:"las la-filter"}),e._v(" "),e.withFilters?n("i",{staticClass:"las la-check"}):e._e(),e._v(" "),e.withFilters?e._e():n("span",[e._v(e._s(e.__("Filters")))]),e._v(" "),e.withFilters?n("span",[e._v(e._s(e.__("Has Filters")))]):e._e()])]):e._e()]),e._v(" "),n("div",{staticClass:"-mx-1 flex flex-wrap w-full md:w-auto",attrs:{id:"crud-buttons"}},[e.selectedEntries.length>0?n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 outline-none ns-crud-button border",on:{click:function(t){return e.clearSelectedEntries()}}},[n("i",{staticClass:"lar la-check-square"}),e._v(" "+e._s(e.__("{entries} entries selected").replace("{entries}",e.selectedEntries.length))+"\n ")])]):e._e(),e._v(" "),n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 ns-crud-button border outline-none",on:{click:function(t){return e.downloadContent()}}},[n("i",{staticClass:"las la-download"}),e._v(" "+e._s(e.__("Download")))])])])]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"overflow-x-auto flex-auto"},[Object.values(e.columns).length>0?n("table",{staticClass:"table ns-table w-full"},[n("thead",[n("tr",[n("th",{staticClass:"text-center px-2 border w-16 py-2"},[n("ns-checkbox",{attrs:{checked:e.globallyChecked},on:{change:function(t){return e.handleGlobalChange(t)}}})],1),e._v(" "),e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e(),e._v(" "),e._l(e.columns,(function(t,s){return n("th",{key:s,staticClass:"cursor-pointer justify-betweenw-40 border text-left px-2 py-2",style:{"min-width":t.width||"auto"},on:{click:function(t){return e.sort(s)}}},[n("div",{staticClass:"w-full flex justify-between items-center"},[n("span",{staticClass:"flex"},[e._v(e._s(t.label))]),e._v(" "),n("span",{staticClass:"h-6 w-6 flex justify-center items-center"},["desc"===t.$direction?n("i",{staticClass:"las la-sort-amount-up"}):e._e(),e._v(" "),"asc"===t.$direction?n("i",{staticClass:"las la-sort-amount-down"}):e._e()])])])})),e._v(" "),!e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e()],2)]),e._v(" "),n("tbody",[void 0!==e.result.data&&e.result.data.length>0?e._l(e.result.data,(function(t,s){return n("ns-table-row",{key:s,attrs:{columns:e.columns,prependOptions:e.prependOptions,showOptions:e.showOptions,row:t},on:{updated:function(t){return e.refreshRow(t)},reload:function(t){return e.refresh()},toggled:function(t){return e.handleShowOptions(t)}}})})):e._e(),e._v(" "),e.result&&0!==e.result.data.length?e._e():n("tr",[n("td",{staticClass:"text-center text-gray-600 dark:text-slate-300 py-3",attrs:{colspan:Object.values(e.columns).length+2}},[e._v(e._s(e.__("There is nothing to display...")))])])],2)]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex border-t flex-col md:flex-row justify-between footer"},[e.bulkActions.length>0?n("div",{staticClass:"mb-2 md:mb-0 flex justify-between rounded-full ns-crud-input p-1",attrs:{id:"grouped-actions"}},[n("select",{directives:[{name:"model",rawName:"v-model",value:e.bulkAction,expression:"bulkAction"}],staticClass:"outline-none bg-transparent",attrs:{id:"grouped-actions"},on:{change:function(t){var n=Array.prototype.filter.call(t.target.options,(function(e){return e.selected})).map((function(e){return"_value"in e?e._value:e.value}));e.bulkAction=t.target.multiple?n:n[0]}}},[n("option",{staticClass:"bg-input-disabled",attrs:{selected:"",value:""}},[e._t("bulk-label",(function(){return[e._v(e._s(e.__("Bulk Actions")))]}))],2),e._v(" "),e._l(e.bulkActions,(function(t,s){return n("option",{key:s,staticClass:"bg-input-disabled",domProps:{value:t.identifier}},[e._v(e._s(t.label))])}))],2),e._v(" "),n("button",{staticClass:"ns-crud-input-button h-8 px-3 outline-none rounded-full flex items-center justify-center",on:{click:function(t){return e.bulkDo()}}},[e._t("bulk-go",(function(){return[e._v(e._s(e.__("Apply")))]}))],2)]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"items-center flex text-primary mx-4"},[e._v(e._s(e.resultInfo))]),e._v(" "),n("div",{staticClass:"flex items-center -mx-1",attrs:{id:"pagination"}},[e.result.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.first_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.pagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",class:e.page==t?"bg-info-tertiary border-transparent text-white":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){e.page=t,e.refresh()}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.last_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)])])])}),[],!1,null,null,null).exports;var W=n(4864),B=n(1726),X=n(7259);const G=s.default.extend({methods:{__:d.__},name:"ns-avatar",data:function(){return{svg:""}},mounted:function(){this.svg=(0,B.createAvatar)(X,{seed:this.displayName})},computed:{avatarUrl:function(){return 0===this.url.length?"":this.url}},props:["url","display-name"]});const Q=(0,R.Z)(G,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex justify-between items-center flex-shrink-0"},[n("span",{staticClass:"hidden md:inline-block px-2"},[e._v(e._s(e.__("Howdy, {name}").replace("{name}",this.displayName)))]),e._v(" "),n("span",{staticClass:"md:hidden px-2"},[e._v(e._s(e.displayName))]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"w-8 h-8 overflow-hidden rounded-full bg-gray-600"},[""!==e.avatarUrl?n("img",{staticClass:"w-8 h-8 overflow-hidden rounded-full",attrs:{src:e.avatarUrl,alt:e.displayName,srcset:""}}):e._e(),e._v(" "),""===e.avatarUrl?n("div",{domProps:{innerHTML:e._s(e.svg)}}):e._e()])])])}),[],!1,null,null,null).exports;var K=n(4806),J=n(1828),ee=n(1544),te=n(3506);const ne={name:"ns-search",props:["url","placeholder","value","label","method","searchArgument"],data:function(){return{searchText:"",searchTimeout:null,results:[]}},methods:{__:d.__,selectOption:function(e){this.$emit("select",e),this.searchText="",this.results=[]}},watch:{searchText:function(){var e=this;clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout((function(){var t,n,s;e.searchText.length>0&&i.ih[e.method||"post"](e.url,(t={},n=e.searchArgument||"search",s=e.searchText,n in t?Object.defineProperty(t,n,{value:s,enumerable:!0,configurable:!0,writable:!0}):t[n]=s,t)).subscribe({next:function(t){e.results=t},error:function(e){i.kX.error(e.message||(0,d.__)("An unexpected error occured.")).subscribe()}})}),1e3)}},mounted:function(){}};const se=(0,R.Z)(ne,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-search"},[n("div",{staticClass:"input-group info border-2"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchText,expression:"searchText"}],staticClass:"p-2 w-full",attrs:{type:"text",placeholder:e.placeholder||e.__("Search..."),id:""},domProps:{value:e.searchText},on:{input:function(t){t.target.composing||(e.searchText=t.target.value)}}})]),e._v(" "),n("div",{staticClass:"relative"},[n("div",{staticClass:"w-full absolute"},[e.results.length>0&&e.searchText.length>0?n("ul",{staticClass:"ns-vertical-menu"},e._l(e.results,(function(t,s){return n("li",{key:s,staticClass:"border-b p-2 cursor-pointer",on:{click:function(n){return e.selectOption(t)}}},[e._v(e._s(t[e.label]))])})),0):e._e()])])])}),[],!1,null,null,null).exports},8737:(e,t,n)=>{"use strict";n.d(t,{P:()=>o});var s=n(538),i=n(4806),r=n(2744),a=n(9408),o=s.default.component("ns-field",{data:function(){return{}},mounted:function(){},components:{nsDateRangePicker:i.Z,nsDateTimePicker:r.Z,nsSwitch:a.Z},computed:{isInputField:function(){return["text","password","email","number","tel"].includes(this.field.type)},isDateField:function(){return["date"].includes(this.field.type)},isSelectField:function(){return["select"].includes(this.field.type)},isTextarea:function(){return["textarea"].includes(this.field.type)},isCheckbox:function(){return["checkbox"].includes(this.field.type)},isMultiselect:function(){return["multiselect"].includes(this.field.type)},isSelectAudio:function(){return["select-audio"].includes(this.field.type)},isSwitch:function(){return["switch"].includes(this.field.type)},isMedia:function(){return["media"].includes(this.field.type)},isCkEditor:function(){return["ckeditor"].includes(this.field.type)},isDateTimePicker:function(){return["datetimepicker"].includes(this.field.type)},isDateRangePicker:function(){return["daterangepicker"].includes(this.field.type)},isCustom:function(){return["custom"].includes(this.field.type)}},props:["field"],methods:{addOption:function(e){"select"===this.field.type&&this.field.options.forEach((function(e){return e.selected=!1})),e.selected=!0;var t=this.field.options.indexOf(e);this.field.options.splice(t,1),this.field.options.unshift(e),this.refreshMultiselect(),this.$emit("change",{action:"addOption",option:e})},refreshMultiselect:function(){this.field.value=this.field.options.filter((function(e){return e.selected})).map((function(e){return e.value}))},removeOption:function(e){e.selected=!1,this.refreshMultiselect(),this.$emit("change",{action:"removeOption",option:e})}},template:'\n
    \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    \n '})},1356:(e,t,n)=>{"use strict";n.d(t,{W:()=>c,f:()=>d});var s=n(2077),i=n.n(s),r=n(538),a=n(6740),o=n.n(a),l=new Array(parseInt(ns.currency.ns_currency_precision)).fill("").map((function(e){return 0})).join(""),c=r.default.filter("currency",(function(e){var t,n,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"full";switch(ns.currency.ns_currency_prefered){case"iso":t=ns.currency.ns_currency_iso;break;case"symbol":t=ns.currency.ns_currency_symbol}if("full"===s){var r={decimal:ns.currency.ns_currency_decimal_separator,separator:ns.currency.ns_currency_thousand_separator,precision:parseInt(ns.currency.ns_currency_precision),symbol:""};n=o()(e,r).format()}else n=i()(e).format("0.0a");return"".concat("before"===ns.currency.ns_currency_position?t:"").concat(n).concat("after"===ns.currency.ns_currency_position?t:"")})),d=function(e){var t="0.".concat(l);return parseFloat(i()(e).format(t))}},9698:(e,t,n)=>{"use strict";n.d(t,{b:()=>s});var s=n(538).default.filter("truncate",(function(e,t){return e?(e=e.toString()).length>t?e.substring(0,t)+"...":e:""}))},7266:(e,t,n)=>{"use strict";function s(e,t){for(var n=0;ni});var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,i;return t=e,n=[{key:"validateFields",value:function(e){var t=this;return 0===e.map((function(e){return t.checkField(e),e.errors?0===e.errors.length:0})).filter((function(e){return!1===e})).length}},{key:"validateFieldsErrors",value:function(e){var t=this;return e.map((function(e){return t.checkField(e),e.errors})).flat()}},{key:"validateForm",value:function(e){e.main&&this.validateField(e.main);var t=[];for(var n in e.tabs)if(e.tabs[n].fields){var s=[],i=this.validateFieldsErrors(e.tabs[n].fields);i.length>0&&s.push(i),e.tabs[n].errors=s.flat(),t.push(s.flat())}return t.flat().filter((function(e){return void 0!==e}))}},{key:"initializeTabs",value:function(e){var t=0;for(var n in e)0===t&&(e[n].active=!0),e[n].active=void 0!==e[n].active&&e[n].active,e[n].fields=this.createFields(e[n].fields),t++;return e}},{key:"validateField",value:function(e){return this.checkField(e)}},{key:"fieldsValid",value:function(e){return!(e.map((function(e){return e.errors&&e.errors.length>0})).filter((function(e){return e})).length>0)}},{key:"createFields",value:function(e){return e.map((function(t){if(t.type=t.type||"text",t.errors=t.errors||[],t.disabled=t.disabled||!1,"custom"===t.type&&"string"==typeof t.component){var n=t.component;if(t.component=nsExtraComponents[t.component],!t.component)throw'Failed to load a custom component. "'.concat(n,'" is not provided as an extra component. More details here: https://my.nexopos.com/en/documentation/developpers-guides/how-to-register-a-custom-vue-component');t.component.$field=t,t.component.$fields=e}return t}))}},{key:"createForm",value:function(e){if(e.main&&(e.main=this.createFields([e.main])[0]),e.tabs)for(var t in e.tabs)e.tabs[t].errors=[],void 0!==e.tabs[t].fields?e.tabs[t].fields=this.createFields(e.tabs[t].fields):console.info('Warning: The tab "'.concat(e.tabs[t].label,'" is missing fields. Fallback on checking dynamic component instead.'));return e}},{key:"enableFields",value:function(e){return e.map((function(e){return e.disabled=!1}))}},{key:"disableFields",value:function(e){return e.map((function(e){return e.disabled=!0}))}},{key:"disableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!0),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!0}))}},{key:"enableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!1),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!1}))}},{key:"getValue",value:function(e){var t={};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"checkField",value:function(e){var t=this;return void 0!==e.validation&&(e.errors=[],this.detectValidationRules(e.validation).forEach((function(n){t.fieldPassCheck(e,n)}))),e}},{key:"extractForm",value:function(e){var t={};if(e.main&&(t[e.main.name]=e.main.value),e.tabs)for(var n in e.tabs)void 0===t[n]&&(t[n]={}),t[n]=this.extractFields(e.tabs[n].fields);return t}},{key:"extractFields",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"detectValidationRules",value:function(e){var t=function(e){var t;return["email","required"].includes(e)?{identifier:e}:(t=/(min)\:([0-9])+/g.exec(e))||(t=/(max)\:([0-9])+/g.exec(e))?{identifier:t[1],value:t[2]}:e};return Array.isArray(e)?e.filter((function(e){return"string"==typeof e})).map(t):e.split("|").map(t)}},{key:"triggerError",value:function(e,t){if(console.log(t),t.errors){var n=function(n){var s=n.split(".").filter((function(e){return!/^\d+$/.test(e)}));2===s.length&&e.tabs[s[0]].fields.forEach((function(e){e.name===s[1]&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))})),n===e.main.name&&t.errors[n].forEach((function(t){e.main.errors.push({identifier:"invalid",invalid:!0,message:t,name:e.main.name})}))};for(var s in t.errors)n(s)}}},{key:"triggerFieldsErrors",value:function(e,t){if(t&&t.errors){var n=function(n){e.forEach((function(e){e.name===n&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))}))};for(var s in t.errors)n(s)}}},{key:"fieldPassCheck",value:function(e,t){if("required"===t.identifier){if(void 0===e.value||null===e.value||0===e.value.length)return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){n.identifier===t.identifier&&!0===n.invalid&&e.errors.splice(s,1)}))}if("email"===t.identifier&&e.value.length>0){if(!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(e.value))return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){!0===n[t.identifier]&&e.errors.splice(s,1)}))}return e}}],n&&s(t.prototype,n),i&&s(t,i),Object.defineProperty(t,"prototype",{writable:!1}),e}()},7389:(e,t,n)=>{"use strict";n.d(t,{__:()=>s,c:()=>i});var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"NexoPOS";return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e},i=function(e,t){return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e}},6781:(e,t,n)=>{"use strict";function s(e){return function(e){if(Array.isArray(e))return i(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,s=new Array(t);nc});var c=function(){function e(){var t=this;a(this,e),this.listeners=new Object,document.addEventListener("keydown",(function(e){return t.processEvent(e)}))}return l(e,[{key:"processEvent",value:function(e){var t=this;for(var n in this.listeners){var s=this.listeners[n].getConfig();if(s.hidden.length>0)if(s.hidden.filter((function(e){return e instanceof HTMLElement==!1&&null===document.querySelector(e)})).length!==s.hidden.length)continue;if(s.visible.length>0)if(!(s.visible.filter((function(e){return e instanceof HTMLElement==!0||null!==document.querySelector(e)})).length===s.visible.length))continue;s.callbacks.forEach((function(e){"string"==typeof e.action?t.processSingleAction({action:e.action.trim(),callback:e.callback}):"object"===r(e.action)&&null!==e.action&&e.action.length>0&&e.action.forEach((function(n){t.processSingleAction({action:n.toString().trim(),callback:e.callback})}))}))}}},{key:"processSingleAction",value:function(e){var t=e.action,n=e.callback,s=t.split("+"),i={ctrlKey:!1,altKey:!1,shiftKey:!1};s.forEach((function(e){switch(e){case"ctrl":i.ctrlKey=!0;break;case"alt":i.altKey=!0;break;case"shift":i.shiftKey=!0}}));var r=s.filter((function(e){return!["ctrl","alt","shift"].includes(e)}));this.executeCallback({event,combinableKeys:i,callback:n,key:r[0]})}},{key:"executeCallback",value:function(e){var t=e.event,n=e.callback,s=e.combinableKeys,i=e.key;if(void 0!==t.key&&t.key.toLowerCase()===i.toLowerCase()){var r=!0;for(var a in s)t[a]!==s[a]&&(r=!1);r&&n(t,i)}}},{key:"create",value:function(e){return this.listeners[e]=new d}},{key:"destroy",value:function(e){delete this.listeners[e]}}]),e}(),d=function(){function e(){a(this,e),this.visible=[],this.hidden=[],this.callbacks=[]}return l(e,[{key:"whenVisible",value:function(e){var t;"object"===r(e)?(t=this.visible).push.apply(t,s(e)):this.visible.push(e);return this}},{key:"clearVisible",value:function(){return this.visible=[],this}},{key:"whenNotVisible",value:function(e){var t;e.length>0?(t=this.hidden).push.apply(t,s(e)):this.hidden.push(e);return this}},{key:"clearHidden",value:function(){return this.hidden=[],this}},{key:"whenPressed",value:function(e,t){this.callbacks.push({action:e,callback:t})}},{key:"clearCallbacks",value:function(){return this.callbacks=[],this}},{key:"getConfig",value:function(){return{callbacks:this.callbacks,hidden:this.hidden,visible:this.visible}}}]),e}()},8603:(e,t,n)=>{"use strict";function s(){var e=this;Object.keys(this).includes("$popup")&&(this.$popup.event.subscribe((function(t){"click-overlay"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close()),"press-esc"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close())})),nsHotPress.create("popup-esc").whenPressed("escape",(function(t){t.preventDefault();var n=parseInt(e.$el.parentElement.getAttribute("data-index"));null===document.querySelector('.is-popup [data-index="'.concat(n+1,"]"))&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close(),nsHotPress.destroy("popup-esc"))})))}n.d(t,{Z:()=>s})},6386:(e,t,n)=>{"use strict";function s(e){void 0!==this.$popupParams.resolve&&this.$popupParams.reject&&(!1!==e?this.$popupParams.resolve(e):this.$popupParams.reject(e)),this.$popup.close()}n.d(t,{Z:()=>s})},2242:(e,t,n)=>{"use strict";n.d(t,{G:()=>c});var s=n(7757),i=n.n(s),r=n(9248);function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};if(a(this,e),this.config={primarySelector:void 0,popupClass:"shadow-lg h-half w-1/2 bg-white"},this.container=document.createElement("div"),this.popupBody=document.createElement("div"),this.popupSelector="",this.config=Object.assign(this.config,t),void 0===this.config.primarySelector&&document.querySelectorAll(".is-popup").length>0){var n=document.querySelectorAll(".is-popup").length;this.parentWrapper=document.querySelectorAll(".is-popup")[n-1]}else this.parentWrapper=document.querySelector("body").querySelectorAll("div")[0];this.event=new r.x}var t,n,s;return t=e,n=[{key:"hash",value:function(){for(var e="",t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=0;n<10;n++)e+=t.charAt(Math.floor(Math.random()*t.length));return e}},{key:"open",value:function(e){var t,n,s,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return l(this,void 0,void 0,i().mark((function a(){var o,l,c,d=this;return i().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if("function"!=typeof e){i.next=9;break}return i.prev=1,i.next=4,e();case 4:e=i.sent.default,i.next=9;break;case 7:i.prev=7,i.t0=i.catch(1);case 9:o=document.querySelector("body").querySelectorAll("div")[0],this.parentWrapper.style.filter="blur(4px)",o.style.filter="blur(6px)",this.container.setAttribute("class","absolute top-0 left-0 w-full h-full flex items-center justify-center is-popup"),this.container.addEventListener("click",(function(e){d.event.next({event:"click-overlay",value:!0}),e.stopPropagation()})),this.popupBody.addEventListener("click",(function(e){e.stopImmediatePropagation()})),l=document.querySelectorAll(".is-popup").length,this.container.id="popup-container-"+this.hash(),this.popupSelector="#".concat(this.container.id),this.popupBody.setAttribute("class","zoom-out-entrance popup-body"),this.popupBody.setAttribute("data-index",l),this.popupBody.innerHTML='
    ',this.container.appendChild(this.popupBody),document.body.appendChild(this.container),c=Vue.extend(e),this.instance=new c({propsData:{popup:this}}),this.instance.template=(null===(t=null==e?void 0:e.options)||void 0===t?void 0:t.template)||void 0,this.instance.render=e.render||void 0,this.instance.methods=(null===(n=null==e?void 0:e.options)||void 0===n?void 0:n.methods)||(null==e?void 0:e.methods),this.instance.data=(null===(s=null==e?void 0:e.options)||void 0===s?void 0:s.data)||(null==e?void 0:e.data),this.instance.$popup=this,this.instance.$popupParams=r,this.instance.$mount("#".concat(this.container.id," .vue-component"));case 32:case"end":return i.stop()}}),a,this,[[1,7]])})))}},{key:"close",value:function(){var e=this;this.instance.$destroy(),this.event.unsubscribe(),this.parentWrapper.style.filter="blur(0px)";var t=document.querySelector("body").querySelectorAll("div")[0];document.querySelectorAll(".is-popup").length<=1&&(t.style.filter="blur(0px)");var n="".concat(this.popupSelector," .popup-body");this.popupBody=document.querySelector(n),this.popupBody.classList.remove("zoom-out-entrance"),this.popupBody.classList.add("zoom-in-exit"),this.container=document.querySelector("".concat(this.popupSelector)),this.container.classList.remove("is-popup"),setTimeout((function(){e.container.remove()}),300)}}],s=[{key:"show",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=new e(s);return i.open(t,n),i}}],n&&o(t.prototype,n),s&&o(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()},9624:(e,t,n)=>{"use strict";n.d(t,{S:()=>r});var s=n(3260);function i(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return s.Observable.create((function(s){var r=n.__createSnack({message:e,label:t,type:i.type}),a=r.buttonNode,o=(r.textNode,r.snackWrapper,r.sampleSnack);a.addEventListener("click",(function(e){s.onNext(a),s.onCompleted(),o.remove()})),n.__startTimer(i.duration,o)}))}},{key:"error",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"error"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"error"}))}},{key:"success",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"success"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"success"}))}},{key:"info",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"info"}))}},{key:"__startTimer",value:function(e,t){var n,s=function(){e>0&&!1!==e&&(n=setTimeout((function(){t.remove()}),e))};t.addEventListener("mouseenter",(function(){clearTimeout(n)})),t.addEventListener("mouseleave",(function(){s()})),s()}},{key:"__createSnack",value:function(e){var t=e.message,n=e.label,s=e.type,i=void 0===s?"info":s,r=document.getElementById("snack-wrapper")||document.createElement("div"),a=document.createElement("div"),o=document.createElement("p"),l=document.createElement("div"),c=document.createElement("button"),d="",u="";switch(i){case"info":d="",u="info";break;case"error":d="",u="error";break;case"success":d="",u="success"}return o.textContent=t,o.setAttribute("class","pr-2"),n&&(l.setAttribute("class","ns-button default"),c.textContent=n,c.setAttribute("class","px-3 py-2 shadow rounded uppercase ".concat(d)),l.appendChild(c)),a.appendChild(o),a.appendChild(l),a.setAttribute("class","md:rounded py-2 px-3 md:w-2/5 w-full z-10 md:my-2 shadow-lg flex justify-between items-center zoom-in-entrance anim-duration-300 ns-notice ".concat(u)),r.appendChild(a),null===document.getElementById("snack-wrapper")&&(r.setAttribute("id","snack-wrapper"),r.setAttribute("class","absolute bottom-0 w-full flex justify-between items-center flex-col"),document.body.appendChild(r)),{snackWrapper:r,sampleSnack:a,buttonsWrapper:l,buttonNode:c,textNode:o}}}],n&&i(t.prototype,n),r&&i(t,r),Object.defineProperty(t,"prototype",{writable:!1}),e}()},824:(e,t,n)=>{"use strict";var s=n(381),i=n.n(s);ns.date.moment=i()(ns.date.current),ns.date.interval=setInterval((function(){ns.date.moment.add(1,"seconds"),ns.date.current=i()(ns.date.current).add(1,"seconds").format("YYYY-MM-DD HH:mm:ss")}),1e3),ns.date.getNowString=function(){var e=Date.parse((new Date).toLocaleString("en-US",{timeZone:ns.date.timeZone}));return i()(e).format("YYYY-MM-DD HH:mm:ss")},ns.date.getMoment=function(){var e=Date.parse((new Date).toLocaleString("en-US",{timeZone:ns.date.timeZone}));return i()(e)}},6700:(e,t,n)=>{var s={"./af":2786,"./af.js":2786,"./ar":867,"./ar-dz":4130,"./ar-dz.js":4130,"./ar-kw":6135,"./ar-kw.js":6135,"./ar-ly":6440,"./ar-ly.js":6440,"./ar-ma":7702,"./ar-ma.js":7702,"./ar-sa":6040,"./ar-sa.js":6040,"./ar-tn":7100,"./ar-tn.js":7100,"./ar.js":867,"./az":1083,"./az.js":1083,"./be":9808,"./be.js":9808,"./bg":8338,"./bg.js":8338,"./bm":7438,"./bm.js":7438,"./bn":8905,"./bn-bd":6225,"./bn-bd.js":6225,"./bn.js":8905,"./bo":1560,"./bo.js":1560,"./br":1278,"./br.js":1278,"./bs":622,"./bs.js":622,"./ca":2468,"./ca.js":2468,"./cs":5822,"./cs.js":5822,"./cv":877,"./cv.js":877,"./cy":7373,"./cy.js":7373,"./da":4780,"./da.js":4780,"./de":9740,"./de-at":217,"./de-at.js":217,"./de-ch":894,"./de-ch.js":894,"./de.js":9740,"./dv":5300,"./dv.js":5300,"./el":837,"./el.js":837,"./en-au":8348,"./en-au.js":8348,"./en-ca":7925,"./en-ca.js":7925,"./en-gb":2243,"./en-gb.js":2243,"./en-ie":6436,"./en-ie.js":6436,"./en-il":7207,"./en-il.js":7207,"./en-in":4175,"./en-in.js":4175,"./en-nz":6319,"./en-nz.js":6319,"./en-sg":1662,"./en-sg.js":1662,"./eo":2915,"./eo.js":2915,"./es":5655,"./es-do":5251,"./es-do.js":5251,"./es-mx":6112,"./es-mx.js":6112,"./es-us":1146,"./es-us.js":1146,"./es.js":5655,"./et":5603,"./et.js":5603,"./eu":7763,"./eu.js":7763,"./fa":6959,"./fa.js":6959,"./fi":1897,"./fi.js":1897,"./fil":2549,"./fil.js":2549,"./fo":4694,"./fo.js":4694,"./fr":4470,"./fr-ca":3049,"./fr-ca.js":3049,"./fr-ch":2330,"./fr-ch.js":2330,"./fr.js":4470,"./fy":4415,"./fy.js":4415,"./ga":9295,"./ga.js":9295,"./gd":2101,"./gd.js":2101,"./gl":8794,"./gl.js":8794,"./gom-deva":7884,"./gom-deva.js":7884,"./gom-latn":3168,"./gom-latn.js":3168,"./gu":5349,"./gu.js":5349,"./he":4206,"./he.js":4206,"./hi":94,"./hi.js":94,"./hr":316,"./hr.js":316,"./hu":2138,"./hu.js":2138,"./hy-am":1423,"./hy-am.js":1423,"./id":9218,"./id.js":9218,"./is":135,"./is.js":135,"./it":626,"./it-ch":150,"./it-ch.js":150,"./it.js":626,"./ja":9183,"./ja.js":9183,"./jv":4286,"./jv.js":4286,"./ka":2105,"./ka.js":2105,"./kk":7772,"./kk.js":7772,"./km":8758,"./km.js":8758,"./kn":9282,"./kn.js":9282,"./ko":3730,"./ko.js":3730,"./ku":1408,"./ku.js":1408,"./ky":3291,"./ky.js":3291,"./lb":6841,"./lb.js":6841,"./lo":5466,"./lo.js":5466,"./lt":7010,"./lt.js":7010,"./lv":7595,"./lv.js":7595,"./me":9861,"./me.js":9861,"./mi":5493,"./mi.js":5493,"./mk":5966,"./mk.js":5966,"./ml":7341,"./ml.js":7341,"./mn":5115,"./mn.js":5115,"./mr":370,"./mr.js":370,"./ms":9847,"./ms-my":1237,"./ms-my.js":1237,"./ms.js":9847,"./mt":2126,"./mt.js":2126,"./my":6165,"./my.js":6165,"./nb":4924,"./nb.js":4924,"./ne":6744,"./ne.js":6744,"./nl":3901,"./nl-be":9814,"./nl-be.js":9814,"./nl.js":3901,"./nn":3877,"./nn.js":3877,"./oc-lnc":2135,"./oc-lnc.js":2135,"./pa-in":5858,"./pa-in.js":5858,"./pl":4495,"./pl.js":4495,"./pt":9520,"./pt-br":7971,"./pt-br.js":7971,"./pt.js":9520,"./ro":6459,"./ro.js":6459,"./ru":238,"./ru.js":238,"./sd":950,"./sd.js":950,"./se":490,"./se.js":490,"./si":124,"./si.js":124,"./sk":4249,"./sk.js":4249,"./sl":4985,"./sl.js":4985,"./sq":1104,"./sq.js":1104,"./sr":9131,"./sr-cyrl":9915,"./sr-cyrl.js":9915,"./sr.js":9131,"./ss":5893,"./ss.js":5893,"./sv":8760,"./sv.js":8760,"./sw":1172,"./sw.js":1172,"./ta":7333,"./ta.js":7333,"./te":3110,"./te.js":3110,"./tet":2095,"./tet.js":2095,"./tg":7321,"./tg.js":7321,"./th":9041,"./th.js":9041,"./tk":9005,"./tk.js":9005,"./tl-ph":5768,"./tl-ph.js":5768,"./tlh":9444,"./tlh.js":9444,"./tr":2397,"./tr.js":2397,"./tzl":8254,"./tzl.js":8254,"./tzm":1106,"./tzm-latn":699,"./tzm-latn.js":699,"./tzm.js":1106,"./ug-cn":9288,"./ug-cn.js":9288,"./uk":7691,"./uk.js":7691,"./ur":3795,"./ur.js":3795,"./uz":6791,"./uz-latn":588,"./uz-latn.js":588,"./uz.js":6791,"./vi":5666,"./vi.js":5666,"./x-pseudo":4378,"./x-pseudo.js":4378,"./yo":5805,"./yo.js":5805,"./zh-cn":3839,"./zh-cn.js":3839,"./zh-hk":5726,"./zh-hk.js":5726,"./zh-mo":9807,"./zh-mo.js":9807,"./zh-tw":4152,"./zh-tw.js":4152};function i(e){var t=r(e);return n(t)}function r(e){if(!n.o(s,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return s[e]}i.keys=function(){return Object.keys(s)},i.resolve=r,e.exports=i,i.id=6700},4806:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var s=n(538),i=n(381),r=n.n(i),a=n(7144),o=n.n(a),l=(n(9095),n(7389));const c=s.default.extend({name:"ns-date-range-picker",data:function(){return{dateRange:{startDate:null,endDate:null}}},components:{DateRangePicker:o()},mounted:function(){void 0!==this.field.value&&(this.dateRange=this.field.value)},watch:{dateRange:function(){var e={startDate:r()(this.dateRange.startDate).format("YYYY-MM-DD HH:mm"),endDate:r()(this.dateRange.endDate).format("YYYY-MM-DD HH:mm")};this.field.value=e,this.$emit("change",this)}},methods:{__:l.__,getFormattedDate:function(e){return null!==e?r()(e).format("YYYY-MM-DD HH:mm"):(0,l.__)("N/D")},clearDate:function(){this.dateRange={startDate:null,endDate:null},this.field.value=void 0}},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"]});const d=(0,n(1900).Z)(c,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-auto flex-col mb-2 ns-date-range-picker"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"text-error-primary":"text-primary",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"mt-1 relative flex input-group border-2 rounded-md overflow-hidden focus:shadow-sm",class:e.hasError?"error":""},[e.leading?n("div",{staticClass:"absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none"},[n("span",{staticClass:"text-primary sm:text-sm sm:leading-5"},[e._v("\n "+e._s(e.leading)+"\n ")])]):e._e(),e._v(" "),n("button",{staticClass:"px-3 outline-none bg-error-secondary font-semibold text-white",on:{click:function(t){return e.clearDate()}}},[n("i",{staticClass:"las la-times"})]),e._v(" "),n("date-range-picker",{ref:"picker",staticClass:"w-full flex items-center bg-input-background",attrs:{"locale-data":{firstDay:1,format:"yyyy-mm-dd HH:mm:ss"},timePicker:!0,timePicker24Hour:!0,showWeekNumbers:!0,showDropdowns:!0,autoApply:!1,appendToBody:!0,disabled:e.field.disabled,linkedCalendars:!0},scopedSlots:e._u([{key:"input",fn:function(t){return[n("div",{staticClass:"flex justify-between items-center w-full py-2"},[n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Starts"))+" : "+e._s(e.getFormattedDate(t.startDate)))]),e._v(" "),n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Ends"))+" : "+e._s(e.getFormattedDate(t.endDate)))])])]}}]),model:{value:e.dateRange,callback:function(t){e.dateRange=t},expression:"dateRange"}})],1),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs text-gray-500"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs text-red-400"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e(),e._v(" "),"email"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field must contain a valid email address.")))]})):e._e(),e._v(" "),"invalid"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(t.message))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},2744:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-date-time-picker",props:["field","date"],data:function(){return{visible:!1,hours:0,minutes:0,currentView:"days",currentDay:void 0,moment:i(),months:new Array(11).fill("").map((function(e,t){return t})),daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},computed:{momentCopy:function(){return i()()}},watch:{visible:function(){var e=this;this.visible&&setTimeout((function(){e.$refs.hours.addEventListener("focus",(function(){this.select()})),e.$refs.minutes.addEventListener("focus",(function(){this.select()}))}),100)}},mounted:function(){var e=this;document.addEventListener("mousedown",(function(t){return e.checkClickedItem(t)})),this.field?this.currentDay=[void 0,"",null].includes(this.field.value)?i()():i()(this.field.value):this.currentDay=[void 0,"",null].includes(this.date)?i()():i()(this.date),this.hours=this.currentDay.format("HH"),this.minutes=this.currentDay.format("mm"),this.build()},methods:{__:n(7389).__,erase:function(){this.selectDate()},setYear:function(e){parseInt(e.srcElement.value)>0&&parseInt(e.srcElement.value)<9999&&(this.currentDay.year(e.srcElement.value),this.updateDateTime())},subYear:function(){parseFloat(this.currentDay.format("YYYY"))>0&&(this.currentDay.subtract(1,"year"),this.updateDateTime())},addYear:function(){this.currentDay.add(1,"year"),this.updateDateTime()},toggleView:function(e){var t=this;this.currentView=e,"years"===this.currentView&&setTimeout((function(){t.$refs.year.select()}),100)},setMonth:function(e){this.currentDay.month(e),this.updateDateTime()},detectHoursChange:function(){parseFloat(this.hours)<0&&(this.hours=0),parseFloat(this.hours)>23&&(this.hours=23),this.updateDateTime()},detectMinuteChange:function(){parseFloat(this.minutes)<0&&(this.minutes=0),parseFloat(this.minutes)>59&&(this.minutes=59),this.updateDateTime()},updateDateTime:function(){this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.build(),this.selectDate(this.currentDay)},checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){[void 0].includes(e)?(this.field&&(this.field.value=null),this.$emit("change",null)):(this.currentDay=e,this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.field&&(this.field.value=this.currentDay.format("YYYY/MM/DD HH:mm")),console.log(this.hours,this.minutes),this.$emit("change",this.field?this.field:this.currentDay))},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker mb-2"},[e.field?n("label",{staticClass:"block leading-5 font-medium text-primary"},[e._v(e._s(e.field.label))]):e._e(),e._v(" "),n("div",{staticClass:"ns-button"},[n("button",{staticClass:"rounded cursor-pointer w-full px-1 py-1 flex items-center text-primary",class:e.field?"mt-1 border":"shadow",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),e.currentDay&&e.field?n("span",{staticClass:"mx-1 text-sm"},[null!==e.field.value?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.field.value?n("span",[e._v("N/A")]):e._e()]):e._e(),e._v(" "),e.currentDay&&e.date?n("span",{staticClass:"mx-1 text-sm"},[null!==e.date?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.date?n("span",[e._v("N/A")]):e._e()]):e._e()])]),e._v(" "),e.field?n("p",{staticClass:"text-sm text-secondary py-1"},[e._v(e._s(e.field.description))]):e._e(),e._v(" "),e.visible?n("div",{staticClass:"relative z-10 h-0 w-0"},[n("div",{staticClass:"absolute w-72 shadow-xl rounded ns-box anim-duration-300 zoom-in-entrance flex flex-col",class:e.field?"-mt-4":"mt-2"},["years"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"h-32 flex items-center justify-center text-primary"},[n("div",{staticClass:"rounded input-group info border-2 flex w-2/3 overflow-hidden"},[n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.subYear()}}},[n("i",{staticClass:"las la-minus"})]),e._v(" "),n("input",{ref:"year",staticClass:"p-2 w-24 text-center outline-none",attrs:{type:"text"},domProps:{value:e.currentDay.format("YYYY")},on:{change:function(t){return e.setYear(t)}}}),e._v(" "),n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.addYear()}}},[n("i",{staticClass:"las la-plus"})])])])]):e._e(),e._v(" "),"months"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 border-b border-info-secondary border-dashed"},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-1 gap-0 text-primary"},e._l(e.months,(function(t,s){return n("div",{key:s,staticClass:"h-8 flex justify-center items-center text-sm"},[[n("div",{staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:e.momentCopy.month(t).format("MM")===e.currentDay.format("MM")?"bg-info-secondary text-white border border-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.setMonth(t)}}},[e._v("\n "+e._s(e.momentCopy.format("MMM"))+"\n ")])]],2)})),0)]):e._e(),e._v(" "),"days"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},[n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"text-white border border-info-secondary bg-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2):e._e(),e._v(" "),n("div",{staticClass:"border-t border-numpad-edge w-full p-2"},[n("div",{staticClass:"-mx-1 flex justify-between"},[n("div",{staticClass:"px-1"},[n("div",{staticClass:"-mx-1 flex"},[e.field?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.erase()}}},[n("i",{staticClass:"las la-trash"})])]):e._e(),e._v(" "),"days"!==e.currentView?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.toggleView("days")}}},[n("i",{staticClass:"las la-sign-out-alt"})])]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.hours,expression:"hours"}],ref:"hours",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"HH",type:"number"},domProps:{value:e.hours},on:{change:function(t){return e.detectHoursChange(t)},input:function(t){t.target.composing||(e.hours=t.target.value)}}}),e._v(" "),n("span",{staticClass:"mx-1"},[e._v(":")]),e._v(" "),n("input",{directives:[{name:"model",rawName:"v-model",value:e.minutes,expression:"minutes"}],ref:"minutes",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"mm",type:"number"},domProps:{value:e.minutes},on:{change:function(t){return e.detectMinuteChange(t)},input:function(t){t.target.composing||(e.minutes=t.target.value)}}})])])])])])]):e._e()])}),[],!1,null,null,null).exports},1544:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-datepicker",props:["label","date"],data:function(){return{visible:!1,currentDay:null,daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},mounted:function(){document.addEventListener("click",this.checkClickedItem),this.currentDay=[void 0,null].includes(this.date)?i()():i()(this.date),this.build()},methods:{__:n(7389).__,checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){this.currentDay=e,this.visible=!1,this.$emit("change",e)},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker"},[n("div",{staticClass:"rounded cursor-pointer bg-white shadow px-1 py-1 flex items-center text-gray-700",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),n("span",{staticClass:"mx-1 text-sm"},[n("span",[e._v(e._s(e.label||e.__("Date"))+" : ")]),e._v(" "),e.currentDay?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD")))]):e._e(),e._v(" "),null===e.currentDay?n("span",[e._v(e._s(e.__("N/A")))]):e._e()])]),e._v(" "),e.visible?n("div",{staticClass:"relative h-0 w-0 -mb-2"},[n("div",{staticClass:"w-72 mt-2 shadow rounded bg-white anim-duration-300 zoom-in-entrance flex flex-col"},[n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-gray-700 justify-center"},[e._v(e._s(e.currentDay.format("MMM"))+" "+e._s(e.currentDay.format("YYYY")))]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},[n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"bg-blue-400 text-white border border-blue-500":"hover:bg-gray-100 border border-gray-200",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2),e._v(" "),n("div")])]):e._e()])}),[],!1,null,null,null).exports},1828:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-notice",props:["color"],computed:{actualColor:function(){return this.color||"blue"}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"p-4 border-l-4 text-primary ns-notice",class:e.actualColor,attrs:{role:"alert"}},[n("h2",{staticClass:"font-bold"},[e._t("title")],2),e._v(" "),n("p",[e._t("description"),e._t("default")],2)])}),[],!1,null,null,null).exports},4864:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var s=n(7389);function i(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,s=new Array(t);n0?this.screenValue=parseFloat(this.value/this.number):this.screenValue=this.value||0;var t=new Array(10).fill("").map((function(e,t){return t}));nsHotPress.create("numpad-keys").whenVisible([".is-popup"]).whenPressed(t,(function(t,n){e.inputValue({value:n})})),nsHotPress.create("numpad-backspace").whenVisible([".is-popup"]).whenPressed("backspace",(function(){return e.inputValue({identifier:"backspace"})})),nsHotPress.create("numpad-increase").whenVisible([".is-popup"]).whenPressed("+",(function(){return e.increaseBy({value:1})})),nsHotPress.create("numpad-reduce").whenVisible([".is-popup"]).whenPressed("-",(function(){return e.increaseBy({value:-1})})),nsHotPress.create("numpad-save").whenVisible([".is-popup"]).whenPressed("enter",(function(){return e.inputValue({identifier:"next"})}))},watch:{value:function(){this.value.toString().length>0?this.floating?this.screenValue=Math.round(this.value*this.number).toString():this.screenValue=this.value:this.screenValue=""}},beforeDestroy:function(){nsHotPress.destroy("numpad-backspace"),nsHotPress.destroy("numpad-increase"),nsHotPress.destroy("numpad-reduce"),nsHotPress.destroy("numpad-save")},methods:{increaseBy:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));this.screenValue=(parseFloat(e.value)*t+(parseFloat(this.screenValue)||0)).toString(),this.allSelected=!1},inputValue:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));if("next"!==e.identifier){if("backspace"===e.identifier)this.allSelected?(this.screenValue="0",this.allSelected=!1):this.screenValue=this.screenValue.toString().substr(0,this.screenValue.length-1);else if(e.value.toString().match(/^\d+$/)){if(this.limit>0&&this.screenValue.length>=this.limit)return;this.allSelected?(this.screenValue=e.value.toString(),this.allSelected=!1):(this.screenValue+=""+e.value.toString(),"percentage"===this.mode&&(this.screenValue=this.screenValue>100?100:this.screenValue))}var n=this.floating&&this.screenValue.length>0&&"0"!==this.screenValue?parseFloat(this.screenValue/this.number):this.screenValue;this.$emit("changed",n)}else this.$emit("next",this.floating&&this.screenValue.length>0?parseFloat(this.screenValue/t):this.screenValue)}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-3",attrs:{id:"numpad"}},[e._l(e.keys,(function(t,s){return n("div",{key:s,staticClass:"select-none ns-numpad-key border-l border-b h-24 font-bold flex items-center justify-center cursor-pointer",on:{click:function(n){return e.inputValue(t)}}},[void 0!==t.value?n("span",[e._v(e._s(t.value))]):e._e(),e._v(" "),t.icon?n("i",{staticClass:"las",class:t.icon}):e._e()])})),e._v(" "),e._t("numpad-footer")],2)}),[],!1,null,null,null).exports},3506:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-paginate",props:["pagination"],data:function(){return{page:1,path:""}},mounted:function(){this.path=this.pagination.path},computed:{getPagination:function(){return this.pagination?this.pageNumbers(this.pagination.last_page,this.pagination.current_page):[]}},methods:{gotoPage:function(e){this.page=e,this.$emit("load","".concat(this.path,"?page=").concat(this.page))},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex -mx-1",attrs:{id:"pagination"}},[e.pagination.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.first_page)}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.getPagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info",class:e.page==t?"active":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){return e.gotoPage(t)}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.last_page)}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)}),[],!1,null,null,null).exports},9408:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={data:function(){return{}},name:"ns-switch",mounted:function(){},computed:{_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=t.value===e.field.value,t}))},hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},sizeClass:function(){return" w-1/".concat(this._options.length<=4?this._options.length:4)},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__,setSelected:function(e){this.field.value=e.value,this._options.forEach((function(e){return e.selected=!1})),e.selected=!0,this.$forceUpdate(),this.$emit("change",e.value)}},props:["placeholder","leading","type","field"]};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"mb-2 ns-switch"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"has-error":"is-pristine",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"rounded-lg flex w-52 overflow-hidden shadow my-1",class:e.hasError?"has-error":""},e._l(e._options,(function(t,s){return n("button",{key:s,staticClass:"p-2 text-sm flex-no-wrap outline-none rounded-none",class:t.selected?"selected "+e.sizeClass:"unselected "+e.inputClass+" "+e.sizeClass,attrs:{disabled:t.disabled},on:{click:function(n){return e.setSelected(t)}}},[e._v(e._s(t.label))])})),0),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs ns-description"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs ns-error"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},4255:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var s=n(7757),i=n.n(s),r=n(9671),a=n(8603),o=n(7389),l=n(3601);function c(e,t,n,s,i,r,a){try{var o=e[r](a),l=o.value}catch(e){return void n(e)}o.done?t(l):Promise.resolve(l).then(s,i)}const d={name:"ns-media",props:["popup"],components:{VueUpload:n(2948)},data:function(){return{pages:[{label:(0,o.__)("Upload"),name:"upload",selected:!1},{label:(0,o.__)("Gallery"),name:"gallery",selected:!0}],resources:[],isDragging:!1,response:{data:[],current_page:0,from:0,to:0,next_page_url:"",prev_page_url:"",path:"",per_page:0,total:0,last_page:0,first_page:0},queryPage:1,bulkSelect:!1,files:[]}},mounted:function(){this.popupCloser();var e=this.pages.filter((function(e){return"gallery"===e.name}))[0];this.select(e)},watch:{files:function(){this.uploadFiles()}},computed:{postMedia:function(){return r.kq.applyFilters("http-client-url","/api/nexopos/v4/medias")},currentPage:function(){return this.pages.filter((function(e){return e.selected}))[0]},hasOneSelected:function(){return this.response.data.filter((function(e){return e.selected})).length>0},selectedResource:function(){return this.response.data.filter((function(e){return e.selected}))[0]},csrf:function(){return ns.authentication.csrf},isPopup:function(){return void 0!==this.$popup},user_id:function(){return this.isPopup&&this.$popupParams.user_id||0},panelOpened:function(){return!this.bulkSelect&&this.hasOneSelected}},methods:{popupCloser:a.Z,__:o.__,cancelBulkSelect:function(){this.bulkSelect=!1,this.response.data.forEach((function(e){return e.selected=!1}))},deleteSelected:function(){var e=this;Popup.show(l.default,{title:(0,o.__)("Confirm Your Action"),message:(0,o.__)("You're about to delete selected resources. Would you like to proceed?"),onAction:function(t){t&&r.ih.post("/api/nexopos/v4/medias/bulk-delete",{ids:e.response.data.filter((function(e){return e.selected})).map((function(e){return e.id}))}).subscribe({next:function(t){r.kX.success(t.message).subscribe(),e.loadGallery()},error:function(e){r.kX.error(e.message).subscribe()}})}})},loadUploadScreen:function(){var e=this;setTimeout((function(){e.setDropZone()}),1e3)},setDropZone:function(){var e=this,t=document.getElementById("dropping-zone");t.addEventListener("dragenter",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragleave",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragover",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("drop",(function(t){return e.preventDefaults(t)}),!1);["dragenter","dragover"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!0}))})),["dragleave","drop"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!1}))})),t.addEventListener("drop",(function(t){return e.handleDrop(t)}),!1),this.$refs.files.addEventListener("change",(function(t){return e.processFiles(t.currentTarget.files)}))},uploadFiles:function(){var e,t=this;return(e=i().mark((function e(){var n,s,a;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=t.files.filter((function(e){return!1===e.uploaded&&0===e.progress&&!1===e.failed})),s=i().mark((function e(t){var s;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return s=n[t],e.prev=1,s.progress=1,e.next=5,new Promise((function(e,t){var n=new FormData;n.append("file",s.file),r.ih.post("/api/nexopos/v4/medias",n,{headers:{"Content-Type":"multipart/form-data"}}).subscribe({next:function(t){s.uploaded=!0,s.progress=100,e(t)},error:function(e){t(e)}})}));case 5:e.sent,e.next=11;break;case 8:e.prev=8,e.t0=e.catch(1),s.failed=!0;case 11:case"end":return e.stop()}}),e,null,[[1,8]])})),a=0;case 3:if(!(a0&&void 0!==arguments[0]?arguments[0]:null;t=null===t?this.queryPage:t,this.queryPage=t,r.ih.get("/api/nexopos/v4/medias?page=".concat(t,"&user_id=").concat(this.user_id)).subscribe((function(t){t.data.forEach((function(e){return e.selected=!1})),e.response=t}))},useSelectedEntries:function(){this.$popupParams.resolve({event:"use-selected",value:this.response.data.filter((function(e){return e.selected}))}),this.$popup.close()},selectResource:function(e){var t=this;this.bulkSelect||this.response.data.forEach((function(n,s){s!==t.response.data.indexOf(e)&&(n.selected=!1)})),e.selected=!e.selected}}};const u=(0,n(1900).Z)(d,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex md:flex-row flex-col ns-box shadow-xl overflow-hidden",class:e.isPopup?"w-6/7-screen h-6/7-screen":"w-full h-full",attrs:{id:"ns-media"}},[n("div",{staticClass:"sidebar w-48 md:h-full flex-shrink-0"},[n("h3",{staticClass:"text-xl font-bold my-4 text-center"},[e._v(e._s(e.__("Medias Manager")))]),e._v(" "),n("ul",{staticClass:"sidebar-menus flex md:block"},e._l(e.pages,(function(t,s){return n("li",{key:s,staticClass:"py-2 px-3 cursor-pointer border-l-8",class:t.selected?"active":"",on:{click:function(n){return e.select(t)}}},[e._v(e._s(t.label))])})),0)]),e._v(" "),"upload"===e.currentPage.name?n("div",{staticClass:"content w-full overflow-hidden flex"},[n("div",{staticClass:"flex flex-auto m-2 p-2 flex-col border-info-primary items-center justify-center",class:e.isDragging?"border-dashed border-2":"",attrs:{id:"dropping-zone"},on:{click:function(t){return e.triggerManualUpload()}}},[n("h3",{staticClass:"text-lg md:text-xl font-bold text-center text-primary mb-4"},[e._v(e._s(e.__("Click Here Or Drop Your File To Upload")))]),e._v(" "),n("input",{ref:"files",staticStyle:{display:"none"},attrs:{type:"file",name:"",multiple:"",id:""}}),e._v(" "),n("div",{staticClass:"rounded w-full md:w-2/3 text-primary h-56 overflow-y-auto ns-scrollbar p-2"},[n("ul",e._l(e.files,(function(t,s){return n("li",{key:s,staticClass:"p-2 mb-2 shadow ns-media-upload-item flex items-center justify-between rounded"},[n("span",[e._v(e._s(t.file.name))]),e._v(" "),n("span",{staticClass:"rounded bg-info-primary flex items-center justify-center text-xs p-2"},[e._v(e._s(t.progress)+"%")])])})),0)])])]):e._e(),e._v(" "),"gallery"===e.currentPage.name?n("div",{staticClass:"content flex-col w-full overflow-hidden flex"},[e.popup?n("div",{staticClass:"p-2 flex flex-shrink-0 justify-between"},[n("div"),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.popup.close()}}})],1)]):e._e(),e._v(" "),n("div",{staticClass:"flex flex-auto overflow-hidden"},[n("div",{staticClass:"shadow ns-grid flex flex-auto flex-col overflow-y-auto ns-scrollbar"},[n("div",{staticClass:"flex flex-auto"},[n("div",{staticClass:"p-2 overflow-x-auto"},[n("div",{staticClass:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-3 xl:grid-cols-4"},e._l(e.response.data,(function(t,s){return n("div",{key:s},[n("div",{staticClass:"p-2"},[n("div",{staticClass:"rounded-lg aspect-square bg-gray-500 m-2 overflow-hidden flex items-center justify-center",class:t.selected?"ns-media-image-selected ring-4":"",on:{click:function(n){return e.selectResource(t)}}},[n("img",{staticClass:"object-cover h-full",attrs:{src:t.sizes.thumb,alt:t.name}})])])])})),0)]),e._v(" "),0===e.response.data.length?n("div",{staticClass:"flex flex-auto items-center justify-center"},[n("h3",{staticClass:"text-2xl font-bold"},[e._v(e._s(e.__("Nothing has already been uploaded")))])]):e._e()])]),e._v(" "),n("div",{staticClass:"ns-media-preview-panel hidden lg:block w-64 flex-shrink-0 ",attrs:{id:"preview"}},[n("div",{staticClass:"h-64 bg-gray-800 flex items-center justify-center"},[e.panelOpened?n("img",{attrs:{src:e.selectedResource.sizes.thumb,alt:e.selectedResource.name}}):e._e()]),e._v(" "),e.panelOpened?n("div",{staticClass:"p-4 text-gray-700 text-sm",attrs:{id:"details"}},[n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("File Name"))+": ")]),n("span",[e._v(e._s(e.selectedResource.name))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("Uploaded At"))+":")]),n("span",[e._v(e._s(e.selectedResource.created_at))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("By"))+" :")]),n("span",[e._v(e._s(e.selectedResource.user.username))])])]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex ns-media-footer flex-shrink-0 justify-between"},[n("div",{staticClass:"flex -mx-2 flex-shrink-0"},[n("div",{staticClass:"px-2 flex-shrink-0 flex"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.cancelBulkSelect()}}},[n("i",{staticClass:"las la-times"})])]):e._e(),e._v(" "),e.hasOneSelected&&!e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){e.bulkSelect=!0}}},[n("i",{staticClass:"las la-check-circle"})])]):e._e(),e._v(" "),e.hasOneSelected?n("div",{staticClass:"ns-button error"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.deleteSelected()}}},[n("i",{staticClass:"las la-trash"})])]):e._e()])])]),e._v(" "),n("div",{staticClass:"flex-shrink-0 -mx-2 flex"},[n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[n("div",{staticClass:"ns-button",class:1===e.response.current_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:1===e.response.current_page},on:{click:function(t){return e.loadGallery(e.response.current_page-1)}}},[e._v(e._s(e.__("Previous")))])]),e._v(" "),n("hr",{staticClass:"border-r border-gray-700"}),e._v(" "),n("div",{staticClass:"ns-button",class:e.response.current_page===e.response.last_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:e.response.current_page===e.response.last_page},on:{click:function(t){return e.loadGallery(e.response.current_page+1)}}},[e._v(e._s(e.__("Next")))])])])]),e._v(" "),e.popup&&e.hasOneSelected?n("div",{staticClass:"px-2"},[n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"rounded shadow p-2 text-sm",on:{click:function(t){return e.useSelectedEntries()}}},[e._v(e._s(e.__("Use Selected")))])])]):e._e()])])]):e._e()])}),[],!1,null,null,null).exports},3601:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>o});var s=n(7389),i=n(6386),r=n(8603);const a={data:function(){return{title:"",message:""}},computed:{size:function(){return this.$popupParams.size||"h-full w-full"}},mounted:function(){this.title=this.$popupParams.title,this.message=this.$popupParams.message,this.popupCloser()},methods:{__:s.__,popupResolver:i.Z,popupCloser:r.Z,emitAction:function(e){this.$popupParams.onAction(e),this.$popup.close()}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-col shadow-lg w-5/7-screen md:w-4/7-screen lg:w-2/7-screen",class:e.size,attrs:{id:"confirm-popup"}},[n("div",{staticClass:"flex items-center justify-center flex-col flex-auto p-4"},[n("h2",{staticClass:"text-xl md:text-3xl font-body text-center"},[e._v(e._s(e.title))]),e._v(" "),n("p",{staticClass:"py-4 text-sm md:text-base text-center"},[e._v(e._s(e.message))])]),e._v(" "),n("div",{staticClass:"action-buttons flex border-t"},[n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!0)}}},[e._v(e._s(e.__("Yes")))]),e._v(" "),n("hr",{staticClass:"border-r h-16"}),e._v(" "),n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!1)}}},[e._v(e._s(e.__("No")))])])])}),[],!1,null,null,null).exports}},e=>{e.O(0,[898],(()=>{return t=4297,e(e.s=t);var t}));e.O()}]); \ No newline at end of file +(self.webpackChunknexopos_4x=self.webpackChunknexopos_4x||[]).push([[219,198],{6178:(e,t,n)=>{"use strict";var s=n(538),i=n(8829),r=(n(131),n(7166)),a=n.n(r),o=n(5675),l=n(1625),c=window.nsState,d=window.nsScreen,u=window.ns.cssFiles,f=window.nsExtraComponents,p={name:"_blank",specs:["fullscreen=yes","titlebar=yes","scrollbars=yes"],styles:["/css/".concat(u["app.css"]),"/css/".concat(u["light.css"]),"/css/".concat(u["grid.css"]),"/css/".concat(u["typography.css"])]};window.nsHotPress=new l.e,s.default.use(o.Z,p);var h=s.default.component("vue-apex-charts",a()),m=Object.assign(Object.assign({nsModules:function(){return n.e(333).then(n.bind(n,2333))},nsRewardsSystem:function(){return n.e(533).then(n.bind(n,1533))},nsCreateCoupons:function(){return n.e(588).then(n.bind(n,7588))},nsManageProducts:function(){return n.e(155).then(n.bind(n,3840))},nsSettings:function(){return n.e(914).then(n.bind(n,7353))},nsReset:function(){return n.e(517).then(n.bind(n,5517))},nsPermissions:function(){return n.e(496).then(n.bind(n,2496))},nsProcurement:function(){return n.e(204).then(n.bind(n,3204))},nsProcurementInvoice:function(){return n.e(716).then(n.bind(n,7716))},nsMedia:function(){return Promise.resolve().then(n.bind(n,1274))},nsDashboardCards:function(){return n.e(270).then(n.bind(n,4270))},nsCashierDashboard:function(){return n.e(987).then(n.bind(n,7987))},nsBestCustomers:function(){return n.e(352).then(n.bind(n,5352))},nsBestCashiers:function(){return n.e(458).then(n.bind(n,8458))},nsOrdersSummary:function(){return n.e(509).then(n.bind(n,509))},nsOrdersChart:function(){return n.e(522).then(n.bind(n,5522))},nsNotifications:function(){return n.e(665).then(n.bind(n,1665))},nsSaleReport:function(){return n.e(939).then(n.bind(n,9939))},nsSoldStockReport:function(){return n.e(967).then(n.bind(n,1967))},nsProfitReport:function(){return n.e(730).then(n.bind(n,9730))},nsCashFlowReport:function(){return n.e(537).then(n.bind(n,7537))},nsYearlyReport:function(){return n.e(59).then(n.bind(n,5059))},nsPaymentTypesReport:function(){return n.e(945).then(n.bind(n,4948))},nsBestProductsReport:function(){return n.e(521).then(n.bind(n,5521))},nsLowStockReport:function(){return n.e(399).then(n.bind(n,399))},nsStockAdjustment:function(){return n.e(114).then(n.bind(n,2114))},nsPromptPopup:function(){return n.e(33).then(n.bind(n,3033))},nsAlertPopup:function(){return n.e(634).then(n.bind(n,7634))},nsConfirmPopup:function(){return Promise.resolve().then(n.bind(n,914))},nsPOSLoadingPopup:function(){return n.e(409).then(n.bind(n,409))},nsOrderInvoice:function(){return n.e(69).then(n.bind(n,2069))},VueApexCharts:h},i),f);for(var v in m)void 0!==m[v].name&&"VueComponent"!==m[v].name&&s.default.component(m[v].name,m[v]);var b=new s.default({el:"#dashboard-aside",data:{sidebar:"visible"},components:m,mounted:function(){var e=this;c.behaviorState.subscribe((function(t){var n=t.object;e.sidebar=n.sidebar}))}});window.nsDashboardAside=b,window.nsDashboardOverlay=new s.default({el:"#dashboard-overlay",data:{sidebar:null},components:m,mounted:function(){var e=this;c.behaviorState.subscribe((function(t){var n=t.object;e.sidebar=n.sidebar}))},methods:{closeMenu:function(){c.setState({sidebar:"hidden"===this.sidebar?"visible":"hidden"})}}}),window.nsDashboardHeader=new s.default({el:"#dashboard-header",data:{menuToggled:!1,sidebar:"visible"},components:m,methods:{toggleMenu:function(){this.menuToggled=!this.menuToggled},toggleSideMenu:function(){["lg","xl"].includes(d.breakpoint),c.setState({sidebar:"hidden"===this.sidebar?"visible":"hidden"})}},mounted:function(){var e=this;c.behaviorState.subscribe((function(t){var n=t.object;e.sidebar=n.sidebar}))}}),window.nsComponents=Object.assign(m,i),window.nsDashboardContent=new s.default({el:"#dashboard-content",components:m})},7700:(e,t,n)=>{"use strict";n.d(t,{l:()=>Y,kq:()=>Z,ih:()=>z,kX:()=>H});var s=n(6486),i=n(8945),r=n(6300),a=n(8345),o=n(9093),l=n(9248),c=n(230);function d(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};return this._request("post",e,t,n)}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("get",e,void 0,t)}},{key:"delete",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("delete",e,void 0,t)}},{key:"put",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._request("put",e,t,n)}},{key:"response",get:function(){return this._lastRequestData}},{key:"_request",value:function(e,t){var n=this,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return t=Z.applyFilters("http-client-url",t.replace(/\/$/,"")),this._subject.next({identifier:"async.start",url:t,data:s}),new c.y((function(r){n._client[e](t,s,Object.assign(Object.assign({},n._client.defaults[e]),i)).then((function(e){n._lastRequestData=e,r.next(e.data),r.complete(),n._subject.next({identifier:"async.stop"})})).catch((function(e){var t;r.error((null===(t=e.response)||void 0===t?void 0:t.data)||e.response||e),n._subject.next({identifier:"async.stop"})}))}))}},{key:"subject",value:function(){return this._subject}},{key:"emit",value:function(e){var t=e.identifier,n=e.value;this._subject.next({identifier:t,value:n})}}],n&&d(t.prototype,n),s&&d(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}(),f=n(3);function p(e,t){for(var n=0;n=1e3){for(var n,s=Math.floor((""+e).length/3),i=2;i>=1;i--){if(((n=parseFloat((0!=s?e/Math.pow(1e3,s):e).toPrecision(i)))+"").replace(/[^a-zA-Z 0-9]+/g,"").length<=2)break}n%1!=0&&(n=n.toFixed(1)),t=n+["","k","m","b","t"][s]}return t})),S=n(9020),E=n(7794);function P(e,t){for(var n=0;n0&&window.outerWidth<=480:this.breakpoint="xs";break;case window.outerWidth>480&&window.outerWidth<=640:this.breakpoint="sm";break;case window.outerWidth>640&&window.outerWidth<=1024:this.breakpoint="md";break;case window.outerWidth>1024&&window.outerWidth<=1280:this.breakpoint="lg";break;case window.outerWidth>1280:this.breakpoint="xl"}}}])&&q(t.prototype,n),s&&q(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()),N=new b({sidebar:["xs","sm","md"].includes(I.breakpoint)?"hidden":"visible"});z.defineClient(i.Z),window.nsEvent=Y,window.nsHttpClient=z,window.nsSnackBar=H,window.nsCurrency=S.W,window.nsTruncate=E.b,window.nsRawCurrency=S.f,window.nsAbbreviate=$,window.nsState=N,window.nsUrl=L,window.nsScreen=I,window.ChartJS=r,window.EventEmitter=h,window.Popup=x.G,window.RxJS=y,window.FormValidation=k.Z,window.nsCrudHandler=R},8829:(e,t,n)=>{"use strict";n.r(t),n.d(t,{nsAvatar:()=>Q,nsButton:()=>o,nsCheckbox:()=>p,nsCkeditor:()=>O,nsCloseButton:()=>j,nsCrud:()=>U,nsCrudForm:()=>g,nsDate:()=>w,nsDateRangePicker:()=>K.Z,nsDateTimePicker:()=>A.Z,nsDatepicker:()=>ee.Z,nsField:()=>_.P,nsIconButton:()=>$,nsInput:()=>c,nsLink:()=>l,nsMediaInput:()=>C,nsMenu:()=>r,nsMultiselect:()=>x,nsNotice:()=>J.Z,nsNumpad:()=>W.Z,nsPaginate:()=>te.Z,nsSearch:()=>se,nsSelect:()=>u,nsSelectAudio:()=>f,nsSpinner:()=>v,nsSubmenu:()=>a,nsSwitch:()=>M.Z,nsTableRow:()=>m,nsTabs:()=>T,nsTabsItem:()=>F,nsTextarea:()=>y});var s=n(538),i=n(7700),r=s.default.component("ns-menu",{data:function(){return{defaultToggledState:!1,_save:0}},props:["href","label","icon","notification","toggled","identifier"],template:'\n \n ',mounted:function(){var e=this;this.defaultToggledState=void 0!==this.toggled?this.toggled:this.defaultToggledState,i.l.subject().subscribe((function(t){t.value!==e.identifier&&(e.defaultToggledState=!1)}))},methods:{toggleEmit:function(){var e=this;this.toggle().then((function(t){t&&i.l.emit({identifier:"side-menu.open",value:e.identifier})}))},toggle:function(){var e=this;return new Promise((function(t,n){0===e.href.length&&(e.defaultToggledState=!e.defaultToggledState,t(e.defaultToggledState))}))}}}),a=s.default.component("ns-submenu",{data:function(){return{}},props:["href","label","active"],mounted:function(){},template:'\n
    \n
  • \n \n \n \n
  • \n
    \n '}),o=s.default.component("ns-button",{data:function(){return{clicked:!1,_save:0}},props:["type","disabled","link","href","routerLink","to"],template:'\n
    \n \n \n \n
    \n ',mounted:function(){},computed:{isDisabled:function(){return this.disabled&&(0===this.disabled.length||"disabled"===this.disabled||this.disabled)}}}),l=s.default.component("ns-link",{data:function(){return{clicked:!1,_save:0}},props:["type","to","href","target"],template:'\n
    \n \n \n
    \n ',computed:{buttonclass:function(){switch(this.type){case"info":return"shadow bg-blue-400 text-white";case"success":return"shadow bg-green-400 text-white";case"error":return"shadow bg-red-400 text-white";case"warning":return"shadow bg-orange-400 text-white";default:return"shadow bg-white text-gray-800"}}}}),c=s.default.component("ns-input",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),d=n(3632),u=s.default.component("ns-select",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},mounted:function(){},methods:{__:d.__},template:'\n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),f=s.default.component("ns-select-audio",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__:d.__,playSelectedSound:function(){this.field.value.length>0&&new Audio(this.field.value).play()}},template:'\n
    \n \n
    \n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),p=s.default.component("ns-checkbox",{data:function(){return{}},props:["checked","field","label"],template:'\n
    \n
    \n \n
    \n {{ label }}\n {{ field.label }}\n
    \n ',computed:{isChecked:function(){return this.field?this.field.value:this.checked}},methods:{toggleIt:function(){void 0!==this.field&&(this.field.value=!this.field.value),this.$emit("change",!this.checked)}}}),h=n(6979),m=s.default.component("ns-table-row",{props:["options","row","columns","prependOptions","showOptions"],data:function(){return{optionsToggled:!1}},mounted:function(){},methods:{__:d.__,sanitizeHTML:function(e){var t=document.createElement("div");t.innerHTML=e;for(var n=t.getElementsByTagName("script"),s=n.length;s--;)n[s].parentNode.removeChild(n[s]);return t.innerHTML},getElementOffset:function(e){var t=e.getBoundingClientRect();return{top:t.top+window.pageYOffset,left:t.left+window.pageXOffset}},toggleMenu:function(e){var t=this;if(this.row.$toggled=!this.row.$toggled,this.$emit("toggled",this.row),this.row.$toggled)setTimeout((function(){var e=t.$el.querySelectorAll(".relative > .absolute")[0],n=t.$el.querySelectorAll(".relative")[0],s=t.getElementOffset(n);e.style.top=s.top+"px",e.style.left=s.left+"px",n.classList.remove("relative"),n.classList.add("dropdown-holder")}),100);else{var n=this.$el.querySelectorAll(".dropdown-holder")[0];n.classList.remove("dropdown-holder"),n.classList.add("relative")}},handleChanged:function(e){this.row.$checked=e,this.$emit("updated",this.row)},triggerAsync:function(e){var t=this;e.confirm?confirm(e.confirm.message)&&i.ih[e.type.toLowerCase()](e.url).subscribe((function(e){i.kX.success(e.message).subscribe(),t.$emit("reload",t.row)}),(function(e){t.toggleMenu(),i.kX.error(e.message).subscribe()})):(i.l.emit({identifier:"ns-table-row-action",value:{action:e,row:this.row,component:this}}),this.toggleMenu())},triggerPopup:function(e,t){var n=window.nsExtraComponents[e.component];if(e.component)return n?new Promise((function(s,i){h.G.show(n,{resolve:s,reject:i,row:t,action:e})})):i.kX.error((0,d.__)('Unable to load the component "'.concat(e.component,'". Make sure the component is registered to "nsExtraComponents".'))).subscribe();this.triggerAsync(e)}},template:'\n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n '}),v=s.default.component("ns-spinner",{data:function(){return{}},mounted:function(){},computed:{validatedSize:function(){return this.size||24},validatedBorder:function(){return this.border||8},validatedAnimation:function(){return this.animation||"fast"}},props:["color","size","border"],template:"\n
    \n
    \n
    \n "}),b=n(4679),g=s.default.component("ns-crud-form",{data:function(){return{form:{},globallyChecked:!1,formValidation:new b.Z,rows:[]}},mounted:function(){this.loadForm()},props:["src","create-url","field-class","return-url","submit-url","submit-method","disable-tabs"],computed:{activeTabFields:function(){for(var e in this.form.tabs)if(this.form.tabs[e].active)return this.form.tabs[e].fields;return[]}},methods:{__:d.__,toggle:function(e){for(var t in this.form.tabs)this.form.tabs[t].active=!1;this.form.tabs[e].active=!0},handleShowOptions:function(e){this.rows.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},submit:function(){var e=this;return this.formValidation.validateForm(this.form).length>0?i.kX.error(this.$slots["error-invalid"]?this.$slots["error-invalid"][0].text:"No error message provided for having an invalid form.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():(this.formValidation.disableForm(this.form),void 0===this.submitUrl?i.kX.error(this.$slots["error-no-submit-url"]?this.$slots["error-no-submit-url"][0].text:"No error message provided for not having a valid submit url.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():void i.ih[this.submitMethod?this.submitMethod.toLowerCase():"post"](this.submitUrl,this.formValidation.extractForm(this.form)).subscribe((function(t){if("success"===t.status){if(e.submitMethod&&"post"===e.submitMethod.toLowerCase()&&!1!==e.returnUrl)return document.location=t.data.editUrl||e.returnUrl;i.kX.info(t.message,(0,d.__)("Okay"),{duration:3e3}).subscribe(),e.$emit("save",t)}e.formValidation.enableForm(e.form)}),(function(t){i.kX.error(t.message,void 0,{duration:5e3}).subscribe(),void 0!==t.data&&e.formValidation.triggerError(e.form,t.data),e.formValidation.enableForm(e.form)})))},handleGlobalChange:function(e){this.globallyChecked=e,this.rows.forEach((function(t){return t.$checked=e}))},loadForm:function(){var e=this;i.ih.get("".concat(this.src)).subscribe({next:function(t){e.form=e.parseForm(t.form),i.kq.doAction("ns-crud-form-loaded",e),e.$emit("updated",e.form)},error:function(e){i.kX.error(e.message,"OKAY",{duration:0}).subscribe()}})},parseForm:function(e){e.main.value=void 0===e.main.value?"":e.main.value,e.main=this.formValidation.createFields([e.main])[0];var t=0;for(var n in e.tabs)0===t&&(e.tabs[n].active=!0),e.tabs[n].active=void 0!==e.tabs[n].active&&e.tabs[n].active,e.tabs[n].fields=this.formValidation.createFields(e.tabs[n].fields),t++;return e}},template:'\n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n
    \n
    \n
    \n
    {{ tab.label }}
    \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n
    \n
    \n '}),y=s.default.component("ns-textarea",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),_=n(4110),x=s.default.component("ns-multiselect",{data:function(){return{showPanel:!1,search:""}},props:["field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=void 0!==t.selected&&t.selected,e.field.value&&e.field.value.includes(t.value)&&(t.selected=!0),t}))}},methods:{__:d.__,addOption:function(e){this.field.disabled||(this.$emit("addOption",e),this.$forceUpdate(),setTimeout((function(){}),100))},removeOption:function(e,t){var n=this;if(!this.field.disabled)return t.preventDefault(),t.stopPropagation(),this.$emit("removeOption",e),this.$forceUpdate(),setTimeout((function(){n.search=""}),100),!1}},mounted:function(){var e=this;this.field.value&&this.field.value.reverse().forEach((function(t){var n=e.field.options.filter((function(e){return e.value===t}));n.length>=0&&e.addOption(n[0])}))},template:'\n
    \n \n
    \n
    \n
    \n
    \n
    \n {{ option.label }}\n \n
    \n
    \n
    \n
    \n \n \n
    \n
    \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n
    \n '}),w=s.default.component("ns-date",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-input-edge cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),k=n(1274),C=s.default.component("ns-media-input",{template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n
    \n
    \n \n
    \n \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n ',computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":"ns-enabled"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},data:function(){return{}},props:["placeholder","leading","type","field"],mounted:function(){},methods:{toggleMedia:function(){var e=this;new Promise((function(t,n){h.G.show(k.default,Object.assign({resolve:t,reject:n},e.field.data||{}))})).then((function(t){"use-selected"===t.event&&(e.field.data&&"url"!==e.field.data.type?e.field.data&&"model"!==e.field.data.type||(e.field.value=t.value[0]):e.field.value=t.value[0].sizes.original,e.$forceUpdate())}))}}}),j=s.default.component("ns-close-button",{template:'\n \n ',methods:{clicked:function(e){this.$emit("click",e)}}}),$=s.default.component("ns-icon-button",{template:'\n \n ',props:["className","buttonClass","type"],methods:{clicked:function(e){this.$emit("click",e)}}}),S=n(1272),E=n.n(S),P=n(5234),D=n.n(P),O=s.default.component("ns-ckeditor",{data:function(){return{editor:D()}},components:{ckeditor:E().component},mounted:function(){},methods:{__:d.__},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),T=s.default.component("ns-tabs",{data:function(){return{childrens:[]}},props:["active"],computed:{activeComponent:function(){var e=this.$children.filter((function(e){return e.active}));return e.length>0&&e[0]}},methods:{toggle:function(e){this.$emit("active",e.identifier),this.$emit("changeTab",e.identifier)}},mounted:function(){this.childrens=this.$children},template:'\n
    \n
    \n
    {{ tab.label }}
    \n
    \n \n
    \n '}),F=s.default.component("ns-tabs-item",{data:function(){return{}},mounted:function(){},props:["label","identifier","padding"],template:'\n
    \n \n
    \n '}),M=n(3164),A=n(9765),q=n(7757),V=n.n(q),Y=n(914),z=n(665),H=n(2830);const L={data:function(){return{fields:[],validation:new b.Z}},methods:{__:d.__,popupCloser:z.Z,popupResolver:H.Z,closePopup:function(){this.popupResolver(!1)},useFilters:function(){this.popupResolver(this.validation.extractFields(this.fields))},clearFilters:function(){this.fields.forEach((function(e){return e.value=""})),this.popupResolver(null)}},mounted:function(){this.fields=this.validation.createFields(this.$popupParams.queryFilters),this.popupCloser()}};var R=n(1900);const Z=(0,R.Z)(L,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-box shadow-lg w-95vw h-95vh md:w-2/5-screen overflow-hidden md:h-5/6-screen flex flex-col"},[n("div",{staticClass:"p-2 border-b ns-box-header flex justify-between items-center"},[n("h3",[e._v(e._s(e.__("Search Filters")))]),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.closePopup()}}})],1)]),e._v(" "),n("div",{staticClass:"p-2 ns-box-body flex-auto overflow-y-auto"},e._l(e.fields,(function(e,t){return n("ns-field",{key:t,attrs:{field:e}})})),1),e._v(" "),n("div",{staticClass:"p-2 flex justify-between ns-box-footer border-t"},[n("div",[n("ns-button",{attrs:{type:"error"},on:{click:function(t){return e.clearFilters()}}},[e._v(e._s(e.__("Clear Filters")))])],1),e._v(" "),n("div",[n("ns-button",{attrs:{type:"info"},on:{click:function(t){return e.useFilters()}}},[e._v(e._s(e.__("Use Filters")))])],1)])])}),[],!1,null,null,null).exports;var I=function(e,t,n,s){return new(n||(n=Promise))((function(i,r){function a(e){try{l(s.next(e))}catch(e){r(e)}}function o(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,o)}l((s=s.apply(e,t||[])).next())}))};const N={data:function(){return{prependOptions:!1,showOptions:!0,isRefreshing:!1,sortColumn:"",searchInput:"",queryFiltersString:"",searchQuery:"",page:1,bulkAction:"",bulkActions:[],queryFilters:[],withFilters:!1,columns:[],selectedEntries:[],globallyChecked:!1,result:{current_page:null,data:[],first_page_url:null,from:null,last_page:null,last_page_url:null,next_page_url:null,path:null,per_page:null,prev_page_url:null,to:null,total:null}}},name:"ns-crud",mounted:function(){void 0!==this.identifier&&nsCrudHandler.defineInstance(this.identifier,this),this.loadConfig()},props:["src","create-url","mode","identifier","queryParams"],computed:{getParsedSrc:function(){return"".concat(this.src,"?").concat(this.sortColumn).concat(this.searchQuery).concat(this.queryFiltersString).concat(this.queryPage).concat(this.getQueryParams()?"&"+this.getQueryParams():"")},showQueryFilters:function(){return this.queryFilters.length>0},getSelectedAction:function(){var e=this,t=this.bulkActions.filter((function(t){return t.identifier===e.bulkAction}));return t.length>0&&t[0]},pagination:function(){return this.result?this.pageNumbers(this.result.last_page,this.result.current_page):[]},queryPage:function(){return this.result?"&page=".concat(this.page):""},resultInfo:function(){return(0,d.__)("displaying {perPage} on {items} items").replace("{perPage}",this.result.total).replace("{items}",this.result.total)}},methods:{__:d.__,getQueryParams:function(){var e=this;return this.queryParams?Object.keys(this.queryParams).map((function(t){return"".concat(t,"=").concat(e.queryParams[t])})).join("&"):""},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))},downloadContent:function(){nsHttpClient.post("".concat(this.src,"/export?").concat(this.getParsedSrc),{entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe((function(e){setTimeout((function(){return document.location=e.url}),300),i.kX.success((0,d.__)("The document has been generated.")).subscribe()}),(function(e){i.kX.error(e.message||(0,d.__)("Unexpected error occured.")).subscribe()}))},clearSelectedEntries:function(){var e=this;h.G.show(Y.default,{title:(0,d.__)("Clear Selected Entries ?"),message:(0,d.__)("Would you like to clear all selected entries ?"),onAction:function(t){t&&(e.selectedEntries=[])}})},refreshRow:function(e){if(!0===e.$checked){0===this.selectedEntries.filter((function(t){return t.$id===e.$id})).length&&this.selectedEntries.push(e)}else{var t=this.selectedEntries.filter((function(t){return t.$id===e.$id}));if(t.length>0){var n=this.selectedEntries.indexOf(t[0]);this.selectedEntries.splice(n,1)}}},handleShowOptions:function(e){this.result.data.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},handleGlobalChange:function(e){var t=this;this.globallyChecked=e,this.result.data.forEach((function(n){n.$checked=e,t.refreshRow(n)}))},loadConfig:function(){var e=this;nsHttpClient.get("".concat(this.src,"/config?").concat(this.getQueryParams())).subscribe((function(t){e.columns=t.columns,e.bulkActions=t.bulkActions,e.queryFilters=t.queryFilters,e.prependOptions=t.prependOptions,e.showOptions=t.showOptions,e.refresh()}),(function(e){i.kX.error(e.message,"OK",{duration:!1}).subscribe()}))},cancelSearch:function(){this.searchInput="",this.search()},search:function(){this.searchInput?this.searchQuery="&search=".concat(this.searchInput):this.searchQuery="",this.refresh()},sort:function(e){for(var t in this.columns)t!==e&&(this.columns[t].$sorted=!1,this.columns[t].$direction="");switch(this.columns[e].$sorted=!0,this.columns[e].$direction){case"asc":this.columns[e].$direction="desc";break;case"desc":this.columns[e].$direction="";break;case"":this.columns[e].$direction="asc"}["asc","desc"].includes(this.columns[e].$direction)?this.sortColumn="active=".concat(e,"&direction=").concat(this.columns[e].$direction):this.sortColumn="",this.$emit("sort",this.columns[e]),this.refresh()},bulkDo:function(){var e=this;return this.bulkAction?this.selectedEntries.length>0?confirm(this.getSelectedAction.confirm||this.$slots["error-bulk-confirmation"]||(0,d.__)("Would you like to perform the selected bulk action on the selected entries ?"))?nsHttpClient.post("".concat(this.src,"/bulk-actions"),{action:this.bulkAction,entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe({next:function(t){i.kX.info(t.message).subscribe(),e.selectedEntries=[],e.refresh()},error:function(e){i.kX.error(e.message).subscribe()}}):void 0:i.kX.error(this.$slots["error-no-selection"]?this.$slots["error-no-selection"][0].text:(0,d.__)("No selection has been made.")).subscribe():i.kX.error(this.$slots["error-no-action"]?this.$slots["error-no-action"][0].text:(0,d.__)("No action has been selected.")).subscribe()},openQueryFilter:function(){return I(this,void 0,void 0,V().mark((function e(){var t,n=this;return V().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,console.log(Z),e.next=4,new Promise((function(e,t){h.G.show(Z,{resolve:e,reject:t,queryFilters:n.queryFilters})}));case 4:t=e.sent,this.withFilters=!1,this.queryFiltersString="",null!==t&&(this.withFilters=!0,this.queryFiltersString="&queryFilters="+encodeURIComponent(JSON.stringify(t))),this.refresh(),e.next=13;break;case 11:e.prev=11,e.t0=e.catch(0);case 13:case"end":return e.stop()}}),e,this,[[0,11]])})))},refresh:function(){var e=this;this.globallyChecked=!1,this.isRefreshing=!0,nsHttpClient.get("".concat(this.getParsedSrc)).subscribe((function(t){t.data=t.data.map((function(t){return e.selectedEntries.filter((function(e){return e.$id===t.$id})).length>0&&(t.$checked=!0),t})),e.isRefreshing=!1,e.result=t,e.page=t.current_page}),(function(t){e.isRefreshing=!1,i.kX.error(t.message).subscribe()}))}}};const U=(0,R.Z)(N,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"w-full rounded-lg",class:"light"!==e.mode?"shadow mb-8":"",attrs:{id:"crud-table"}},["light"!==e.mode?n("div",{staticClass:"p-2 border-b border-popup-surface flex flex-col md:flex-row justify-between flex-wrap",attrs:{id:"crud-table-header"}},[n("div",{staticClass:"w-full md:w-auto -mx-2 mb-2 md:mb-0 flex",attrs:{id:"crud-search-box"}},[e.createUrl?n("div",{staticClass:"px-2 flex items-center justify-center"},[n("a",{staticClass:"rounded-full ns-crud-button text-sm h-10 flex items-center justify-center cursor-pointer px-3 outline-none border",attrs:{href:e.createUrl||"#"}},[n("i",{staticClass:"las la-plus"})])]):e._e(),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded-full p-1 ns-crud-input flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchInput,expression:"searchInput"}],staticClass:"w-36 md:w-auto bg-transparent outline-none px-2",attrs:{type:"text"},domProps:{value:e.searchInput},on:{input:function(t){t.target.composing||(e.searchInput=t.target.value)}}}),e._v(" "),n("button",{staticClass:"rounded-full w-8 h-8 outline-none ns-crud-input-button",on:{click:function(t){return e.search()}}},[n("i",{staticClass:"las la-search"})]),e._v(" "),e.searchQuery?n("button",{staticClass:"ml-1 rounded-full w-8 h-8 bg-error-secondary text-white outline-none hover:bg-error-tertiary",on:{click:function(t){return e.cancelSearch()}}},[n("i",{staticClass:"las la-times"})]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2 flex items-center justify-center"},[n("button",{staticClass:"rounded-full text-sm h-10 px-3 outline-none border ns-crud-button",on:{click:function(t){return e.refresh()}}},[n("i",{staticClass:"las la-sync",class:e.isRefreshing?"animate-spin":""})])]),e._v(" "),e.showQueryFilters?n("div",{staticClass:"px-2 flex items-center"},[n("button",{staticClass:"ns-crud-button border rounded-full text-sm h-10 px-3 outline-none",class:e.withFilters?"table-filters-enabled":"table-filters-disabled",on:{click:function(t){return e.openQueryFilter()}}},[e.withFilters?e._e():n("i",{staticClass:"las la-filter"}),e._v(" "),e.withFilters?n("i",{staticClass:"las la-check"}):e._e(),e._v(" "),e.withFilters?e._e():n("span",[e._v(e._s(e.__("Filters")))]),e._v(" "),e.withFilters?n("span",[e._v(e._s(e.__("Has Filters")))]):e._e()])]):e._e()]),e._v(" "),n("div",{staticClass:"-mx-1 flex flex-wrap w-full md:w-auto",attrs:{id:"crud-buttons"}},[e.selectedEntries.length>0?n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 outline-none ns-crud-button border",on:{click:function(t){return e.clearSelectedEntries()}}},[n("i",{staticClass:"lar la-check-square"}),e._v(" "+e._s(e.__("{entries} entries selected").replace("{entries}",e.selectedEntries.length))+"\n ")])]):e._e(),e._v(" "),n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 ns-crud-button border outline-none",on:{click:function(t){return e.downloadContent()}}},[n("i",{staticClass:"las la-download"}),e._v(" "+e._s(e.__("Download")))])])])]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"overflow-x-auto flex-auto"},[Object.values(e.columns).length>0?n("table",{staticClass:"table ns-table w-full"},[n("thead",[n("tr",[n("th",{staticClass:"text-center px-2 border w-16 py-2"},[n("ns-checkbox",{attrs:{checked:e.globallyChecked},on:{change:function(t){return e.handleGlobalChange(t)}}})],1),e._v(" "),e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e(),e._v(" "),e._l(e.columns,(function(t,s){return n("th",{key:s,staticClass:"cursor-pointer justify-betweenw-40 border text-left px-2 py-2",style:{"min-width":t.width||"auto"},on:{click:function(t){return e.sort(s)}}},[n("div",{staticClass:"w-full flex justify-between items-center"},[n("span",{staticClass:"flex"},[e._v(e._s(t.label))]),e._v(" "),n("span",{staticClass:"h-6 w-6 flex justify-center items-center"},["desc"===t.$direction?n("i",{staticClass:"las la-sort-amount-up"}):e._e(),e._v(" "),"asc"===t.$direction?n("i",{staticClass:"las la-sort-amount-down"}):e._e()])])])})),e._v(" "),!e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e()],2)]),e._v(" "),n("tbody",[void 0!==e.result.data&&e.result.data.length>0?e._l(e.result.data,(function(t,s){return n("ns-table-row",{key:s,attrs:{columns:e.columns,prependOptions:e.prependOptions,showOptions:e.showOptions,row:t},on:{updated:function(t){return e.refreshRow(t)},reload:function(t){return e.refresh()},toggled:function(t){return e.handleShowOptions(t)}}})})):e._e(),e._v(" "),e.result&&0!==e.result.data.length?e._e():n("tr",[n("td",{staticClass:"text-center text-gray-600 dark:text-slate-300 py-3",attrs:{colspan:Object.values(e.columns).length+2}},[e._v(e._s(e.__("There is nothing to display...")))])])],2)]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex border-t flex-col md:flex-row justify-between footer"},[e.bulkActions.length>0?n("div",{staticClass:"mb-2 md:mb-0 flex justify-between rounded-full ns-crud-input p-1",attrs:{id:"grouped-actions"}},[n("select",{directives:[{name:"model",rawName:"v-model",value:e.bulkAction,expression:"bulkAction"}],staticClass:"outline-none bg-transparent",attrs:{id:"grouped-actions"},on:{change:function(t){var n=Array.prototype.filter.call(t.target.options,(function(e){return e.selected})).map((function(e){return"_value"in e?e._value:e.value}));e.bulkAction=t.target.multiple?n:n[0]}}},[n("option",{staticClass:"bg-input-disabled",attrs:{selected:"",value:""}},[e._t("bulk-label",(function(){return[e._v(e._s(e.__("Bulk Actions")))]}))],2),e._v(" "),e._l(e.bulkActions,(function(t,s){return n("option",{key:s,staticClass:"bg-input-disabled",domProps:{value:t.identifier}},[e._v(e._s(t.label))])}))],2),e._v(" "),n("button",{staticClass:"ns-crud-input-button h-8 px-3 outline-none rounded-full flex items-center justify-center",on:{click:function(t){return e.bulkDo()}}},[e._t("bulk-go",(function(){return[e._v(e._s(e.__("Apply")))]}))],2)]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"items-center flex text-primary mx-4"},[e._v(e._s(e.resultInfo))]),e._v(" "),n("div",{staticClass:"flex items-center -mx-1",attrs:{id:"pagination"}},[e.result.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.first_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.pagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",class:e.page==t?"bg-info-tertiary border-transparent text-white":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){e.page=t,e.refresh()}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.last_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)])])])}),[],!1,null,null,null).exports;var W=n(7751),B=n(1726),X=n(7259);const G=s.default.extend({methods:{__:d.__},name:"ns-avatar",data:function(){return{svg:""}},mounted:function(){this.svg=(0,B.createAvatar)(X,{seed:this.displayName})},computed:{avatarUrl:function(){return 0===this.url.length?"":this.url}},props:["url","display-name"]});const Q=(0,R.Z)(G,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex justify-between items-center flex-shrink-0"},[n("span",{staticClass:"hidden md:inline-block px-2"},[e._v(e._s(e.__("Howdy, {name}").replace("{name}",this.displayName)))]),e._v(" "),n("span",{staticClass:"md:hidden px-2"},[e._v(e._s(e.displayName))]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"w-8 h-8 overflow-hidden rounded-full bg-gray-600"},[""!==e.avatarUrl?n("img",{staticClass:"w-8 h-8 overflow-hidden rounded-full",attrs:{src:e.avatarUrl,alt:e.displayName,srcset:""}}):e._e(),e._v(" "),""===e.avatarUrl?n("div",{domProps:{innerHTML:e._s(e.svg)}}):e._e()])])])}),[],!1,null,null,null).exports;var K=n(328),J=n(2404),ee=n(4915),te=n(3502);const ne={name:"ns-search",props:["url","placeholder","value","label","method","searchArgument"],data:function(){return{searchText:"",searchTimeout:null,results:[]}},methods:{__:d.__,selectOption:function(e){this.$emit("select",e),this.searchText="",this.results=[]}},watch:{searchText:function(){var e=this;clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout((function(){var t,n,s;e.searchText.length>0&&i.ih[e.method||"post"](e.url,(t={},n=e.searchArgument||"search",s=e.searchText,n in t?Object.defineProperty(t,n,{value:s,enumerable:!0,configurable:!0,writable:!0}):t[n]=s,t)).subscribe({next:function(t){e.results=t},error:function(e){i.kX.error(e.message||(0,d.__)("An unexpected error occured.")).subscribe()}})}),1e3)}},mounted:function(){}};const se=(0,R.Z)(ne,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-search"},[n("div",{staticClass:"input-group info border-2"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchText,expression:"searchText"}],staticClass:"p-2 w-full",attrs:{type:"text",placeholder:e.placeholder||e.__("Search..."),id:""},domProps:{value:e.searchText},on:{input:function(t){t.target.composing||(e.searchText=t.target.value)}}})]),e._v(" "),n("div",{staticClass:"relative"},[n("div",{staticClass:"w-full absolute"},[e.results.length>0&&e.searchText.length>0?n("ul",{staticClass:"ns-vertical-menu"},e._l(e.results,(function(t,s){return n("li",{key:s,staticClass:"border-b p-2 cursor-pointer",on:{click:function(n){return e.selectOption(t)}}},[e._v(e._s(t[e.label]))])})),0):e._e()])])])}),[],!1,null,null,null).exports},4110:(e,t,n)=>{"use strict";n.d(t,{P:()=>o});var s=n(538),i=n(328),r=n(9765),a=n(3164),o=s.default.component("ns-field",{data:function(){return{}},mounted:function(){},components:{nsDateRangePicker:i.Z,nsDateTimePicker:r.Z,nsSwitch:a.Z},computed:{isInputField:function(){return["text","password","email","number","tel"].includes(this.field.type)},isDateField:function(){return["date"].includes(this.field.type)},isSelectField:function(){return["select"].includes(this.field.type)},isTextarea:function(){return["textarea"].includes(this.field.type)},isCheckbox:function(){return["checkbox"].includes(this.field.type)},isMultiselect:function(){return["multiselect"].includes(this.field.type)},isSelectAudio:function(){return["select-audio"].includes(this.field.type)},isSwitch:function(){return["switch"].includes(this.field.type)},isMedia:function(){return["media"].includes(this.field.type)},isCkEditor:function(){return["ckeditor"].includes(this.field.type)},isDateTimePicker:function(){return["datetimepicker"].includes(this.field.type)},isDateRangePicker:function(){return["daterangepicker"].includes(this.field.type)},isCustom:function(){return["custom"].includes(this.field.type)}},props:["field"],methods:{addOption:function(e){"select"===this.field.type&&this.field.options.forEach((function(e){return e.selected=!1})),e.selected=!0;var t=this.field.options.indexOf(e);this.field.options.splice(t,1),this.field.options.unshift(e),this.refreshMultiselect(),this.$emit("change",{action:"addOption",option:e})},refreshMultiselect:function(){this.field.value=this.field.options.filter((function(e){return e.selected})).map((function(e){return e.value}))},removeOption:function(e){e.selected=!1,this.refreshMultiselect(),this.$emit("change",{action:"removeOption",option:e})}},template:'\n
    \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    \n '})},9020:(e,t,n)=>{"use strict";n.d(t,{W:()=>c,f:()=>d});var s=n(2077),i=n.n(s),r=n(538),a=n(6740),o=n.n(a),l=new Array(parseInt(ns.currency.ns_currency_precision)).fill("").map((function(e){return 0})).join(""),c=r.default.filter("currency",(function(e){var t,n,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"full";switch(ns.currency.ns_currency_prefered){case"iso":t=ns.currency.ns_currency_iso;break;case"symbol":t=ns.currency.ns_currency_symbol}if("full"===s){var r={decimal:ns.currency.ns_currency_decimal_separator,separator:ns.currency.ns_currency_thousand_separator,precision:parseInt(ns.currency.ns_currency_precision),symbol:""};n=o()(e,r).format()}else n=i()(e).format("0.0a");return"".concat("before"===ns.currency.ns_currency_position?t:"").concat(n).concat("after"===ns.currency.ns_currency_position?t:"")})),d=function(e){var t="0.".concat(l);return parseFloat(i()(e).format(t))}},7794:(e,t,n)=>{"use strict";n.d(t,{b:()=>s});var s=n(538).default.filter("truncate",(function(e,t){return e?(e=e.toString()).length>t?e.substring(0,t)+"...":e:""}))},4679:(e,t,n)=>{"use strict";function s(e,t){for(var n=0;ni});var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,i;return t=e,n=[{key:"validateFields",value:function(e){var t=this;return 0===e.map((function(e){return t.checkField(e),e.errors?0===e.errors.length:0})).filter((function(e){return!1===e})).length}},{key:"validateFieldsErrors",value:function(e){var t=this;return e.map((function(e){return t.checkField(e),e.errors})).flat()}},{key:"validateForm",value:function(e){e.main&&this.validateField(e.main);var t=[];for(var n in e.tabs)if(e.tabs[n].fields){var s=[],i=this.validateFieldsErrors(e.tabs[n].fields);i.length>0&&s.push(i),e.tabs[n].errors=s.flat(),t.push(s.flat())}return t.flat().filter((function(e){return void 0!==e}))}},{key:"initializeTabs",value:function(e){var t=0;for(var n in e)0===t&&(e[n].active=!0),e[n].active=void 0!==e[n].active&&e[n].active,e[n].fields=this.createFields(e[n].fields),t++;return e}},{key:"validateField",value:function(e){return this.checkField(e)}},{key:"fieldsValid",value:function(e){return!(e.map((function(e){return e.errors&&e.errors.length>0})).filter((function(e){return e})).length>0)}},{key:"createFields",value:function(e){return e.map((function(t){if(t.type=t.type||"text",t.errors=t.errors||[],t.disabled=t.disabled||!1,"custom"===t.type&&"string"==typeof t.component){var n=t.component;if(t.component=nsExtraComponents[t.component],!t.component)throw'Failed to load a custom component. "'.concat(n,'" is not provided as an extra component. More details here: https://my.nexopos.com/en/documentation/developpers-guides/how-to-register-a-custom-vue-component');t.component.$field=t,t.component.$fields=e}return t}))}},{key:"createForm",value:function(e){if(e.main&&(e.main=this.createFields([e.main])[0]),e.tabs)for(var t in e.tabs)e.tabs[t].errors=[],void 0!==e.tabs[t].fields?e.tabs[t].fields=this.createFields(e.tabs[t].fields):console.info('Warning: The tab "'.concat(e.tabs[t].label,'" is missing fields. Fallback on checking dynamic component instead.'));return e}},{key:"enableFields",value:function(e){return e.map((function(e){return e.disabled=!1}))}},{key:"disableFields",value:function(e){return e.map((function(e){return e.disabled=!0}))}},{key:"disableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!0),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!0}))}},{key:"enableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!1),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!1}))}},{key:"getValue",value:function(e){var t={};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"checkField",value:function(e){var t=this;return void 0!==e.validation&&(e.errors=[],this.detectValidationRules(e.validation).forEach((function(n){t.fieldPassCheck(e,n)}))),e}},{key:"extractForm",value:function(e){var t={};if(e.main&&(t[e.main.name]=e.main.value),e.tabs)for(var n in e.tabs)void 0===t[n]&&(t[n]={}),t[n]=this.extractFields(e.tabs[n].fields);return t}},{key:"extractFields",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"detectValidationRules",value:function(e){var t=function(e){var t;return["email","required"].includes(e)?{identifier:e}:(t=/(min)\:([0-9])+/g.exec(e))||(t=/(max)\:([0-9])+/g.exec(e))?{identifier:t[1],value:t[2]}:e};return Array.isArray(e)?e.filter((function(e){return"string"==typeof e})).map(t):e.split("|").map(t)}},{key:"triggerError",value:function(e,t){if(console.log(t),t.errors){var n=function(n){var s=n.split(".").filter((function(e){return!/^\d+$/.test(e)}));2===s.length&&e.tabs[s[0]].fields.forEach((function(e){e.name===s[1]&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))})),n===e.main.name&&t.errors[n].forEach((function(t){e.main.errors.push({identifier:"invalid",invalid:!0,message:t,name:e.main.name})}))};for(var s in t.errors)n(s)}}},{key:"triggerFieldsErrors",value:function(e,t){if(t&&t.errors){var n=function(n){e.forEach((function(e){e.name===n&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))}))};for(var s in t.errors)n(s)}}},{key:"fieldPassCheck",value:function(e,t){if("required"===t.identifier){if(void 0===e.value||null===e.value||0===e.value.length)return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){n.identifier===t.identifier&&!0===n.invalid&&e.errors.splice(s,1)}))}if("email"===t.identifier&&e.value.length>0){if(!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(e.value))return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){!0===n[t.identifier]&&e.errors.splice(s,1)}))}return e}}],n&&s(t.prototype,n),i&&s(t,i),Object.defineProperty(t,"prototype",{writable:!1}),e}()},3632:(e,t,n)=>{"use strict";n.d(t,{__:()=>s,c:()=>i});var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"NexoPOS";return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e},i=function(e,t){return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e}},1625:(e,t,n)=>{"use strict";function s(e){return function(e){if(Array.isArray(e))return i(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,s=new Array(t);nc});var c=function(){function e(){var t=this;a(this,e),this.listeners=new Object,document.addEventListener("keydown",(function(e){return t.processEvent(e)}))}return l(e,[{key:"processEvent",value:function(e){var t=this;for(var n in this.listeners){var s=this.listeners[n].getConfig();if(s.hidden.length>0)if(s.hidden.filter((function(e){return e instanceof HTMLElement==!1&&null===document.querySelector(e)})).length!==s.hidden.length)continue;if(s.visible.length>0)if(!(s.visible.filter((function(e){return e instanceof HTMLElement==!0||null!==document.querySelector(e)})).length===s.visible.length))continue;s.callbacks.forEach((function(e){"string"==typeof e.action?t.processSingleAction({action:e.action.trim(),callback:e.callback}):"object"===r(e.action)&&null!==e.action&&e.action.length>0&&e.action.forEach((function(n){t.processSingleAction({action:n.toString().trim(),callback:e.callback})}))}))}}},{key:"processSingleAction",value:function(e){var t=e.action,n=e.callback,s=t.split("+"),i={ctrlKey:!1,altKey:!1,shiftKey:!1};s.forEach((function(e){switch(e){case"ctrl":i.ctrlKey=!0;break;case"alt":i.altKey=!0;break;case"shift":i.shiftKey=!0}}));var r=s.filter((function(e){return!["ctrl","alt","shift"].includes(e)}));this.executeCallback({event,combinableKeys:i,callback:n,key:r[0]})}},{key:"executeCallback",value:function(e){var t=e.event,n=e.callback,s=e.combinableKeys,i=e.key;if(void 0!==t.key&&t.key.toLowerCase()===i.toLowerCase()){var r=!0;for(var a in s)t[a]!==s[a]&&(r=!1);r&&n(t,i)}}},{key:"create",value:function(e){return this.listeners[e]=new d}},{key:"destroy",value:function(e){delete this.listeners[e]}}]),e}(),d=function(){function e(){a(this,e),this.visible=[],this.hidden=[],this.callbacks=[]}return l(e,[{key:"whenVisible",value:function(e){var t;"object"===r(e)?(t=this.visible).push.apply(t,s(e)):this.visible.push(e);return this}},{key:"clearVisible",value:function(){return this.visible=[],this}},{key:"whenNotVisible",value:function(e){var t;e.length>0?(t=this.hidden).push.apply(t,s(e)):this.hidden.push(e);return this}},{key:"clearHidden",value:function(){return this.hidden=[],this}},{key:"whenPressed",value:function(e,t){this.callbacks.push({action:e,callback:t})}},{key:"clearCallbacks",value:function(){return this.callbacks=[],this}},{key:"getConfig",value:function(){return{callbacks:this.callbacks,hidden:this.hidden,visible:this.visible}}}]),e}()},665:(e,t,n)=>{"use strict";function s(){var e=this;Object.keys(this).includes("$popup")&&(this.$popup.event.subscribe((function(t){"click-overlay"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close()),"press-esc"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close())})),nsHotPress.create("popup-esc").whenPressed("escape",(function(t){t.preventDefault();var n=parseInt(e.$el.parentElement.getAttribute("data-index"));null===document.querySelector('.is-popup [data-index="'.concat(n+1,"]"))&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close(),nsHotPress.destroy("popup-esc"))})))}n.d(t,{Z:()=>s})},2830:(e,t,n)=>{"use strict";function s(e){void 0!==this.$popupParams.resolve&&this.$popupParams.reject&&(!1!==e?this.$popupParams.resolve(e):this.$popupParams.reject(e)),this.$popup.close()}n.d(t,{Z:()=>s})},6979:(e,t,n)=>{"use strict";n.d(t,{G:()=>c});var s=n(7757),i=n.n(s),r=n(9248);function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};if(a(this,e),this.config={primarySelector:void 0,popupClass:"shadow-lg h-half w-1/2 bg-white"},this.container=document.createElement("div"),this.popupBody=document.createElement("div"),this.popupSelector="",this.config=Object.assign(this.config,t),void 0===this.config.primarySelector&&document.querySelectorAll(".is-popup").length>0){var n=document.querySelectorAll(".is-popup").length;this.parentWrapper=document.querySelectorAll(".is-popup")[n-1]}else this.parentWrapper=document.querySelector("body").querySelectorAll("div")[0];this.event=new r.x}var t,n,s;return t=e,n=[{key:"hash",value:function(){for(var e="",t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=0;n<10;n++)e+=t.charAt(Math.floor(Math.random()*t.length));return e}},{key:"open",value:function(e){var t,n,s,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return l(this,void 0,void 0,i().mark((function a(){var o,l,c,d=this;return i().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if("function"!=typeof e){i.next=9;break}return i.prev=1,i.next=4,e();case 4:e=i.sent.default,i.next=9;break;case 7:i.prev=7,i.t0=i.catch(1);case 9:o=document.querySelector("body").querySelectorAll("div")[0],this.parentWrapper.style.filter="blur(4px)",o.style.filter="blur(6px)",this.container.setAttribute("class","absolute top-0 left-0 w-full h-full flex items-center justify-center is-popup"),this.container.addEventListener("click",(function(e){d.event.next({event:"click-overlay",value:!0}),e.stopPropagation()})),this.popupBody.addEventListener("click",(function(e){e.stopImmediatePropagation()})),l=document.querySelectorAll(".is-popup").length,this.container.id="popup-container-"+this.hash(),this.popupSelector="#".concat(this.container.id),this.popupBody.setAttribute("class","zoom-out-entrance popup-body"),this.popupBody.setAttribute("data-index",l),this.popupBody.innerHTML='
    ',this.container.appendChild(this.popupBody),document.body.appendChild(this.container),c=Vue.extend(e),this.instance=new c({propsData:{popup:this}}),this.instance.template=(null===(t=null==e?void 0:e.options)||void 0===t?void 0:t.template)||void 0,this.instance.render=e.render||void 0,this.instance.methods=(null===(n=null==e?void 0:e.options)||void 0===n?void 0:n.methods)||(null==e?void 0:e.methods),this.instance.data=(null===(s=null==e?void 0:e.options)||void 0===s?void 0:s.data)||(null==e?void 0:e.data),this.instance.$popup=this,this.instance.$popupParams=r,this.instance.$mount("#".concat(this.container.id," .vue-component"));case 32:case"end":return i.stop()}}),a,this,[[1,7]])})))}},{key:"close",value:function(){var e=this;this.instance.$destroy(),this.event.unsubscribe(),this.parentWrapper.style.filter="blur(0px)";var t=document.querySelector("body").querySelectorAll("div")[0];document.querySelectorAll(".is-popup").length<=1&&(t.style.filter="blur(0px)");var n="".concat(this.popupSelector," .popup-body");this.popupBody=document.querySelector(n),this.popupBody.classList.remove("zoom-out-entrance"),this.popupBody.classList.add("zoom-in-exit"),this.container=document.querySelector("".concat(this.popupSelector)),this.container.classList.remove("is-popup"),setTimeout((function(){e.container.remove()}),300)}}],s=[{key:"show",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=new e(s);return i.open(t,n),i}}],n&&o(t.prototype,n),s&&o(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()},9093:(e,t,n)=>{"use strict";n.d(t,{S:()=>r});var s=n(3260);function i(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return s.Observable.create((function(s){var r=n.__createSnack({message:e,label:t,type:i.type}),a=r.buttonNode,o=(r.textNode,r.snackWrapper,r.sampleSnack);a.addEventListener("click",(function(e){s.onNext(a),s.onCompleted(),o.remove()})),n.__startTimer(i.duration,o)}))}},{key:"error",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"error"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"error"}))}},{key:"success",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"success"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"success"}))}},{key:"info",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"info"}))}},{key:"__startTimer",value:function(e,t){var n,s=function(){e>0&&!1!==e&&(n=setTimeout((function(){t.remove()}),e))};t.addEventListener("mouseenter",(function(){clearTimeout(n)})),t.addEventListener("mouseleave",(function(){s()})),s()}},{key:"__createSnack",value:function(e){var t=e.message,n=e.label,s=e.type,i=void 0===s?"info":s,r=document.getElementById("snack-wrapper")||document.createElement("div"),a=document.createElement("div"),o=document.createElement("p"),l=document.createElement("div"),c=document.createElement("button"),d="",u="";switch(i){case"info":d="",u="info";break;case"error":d="",u="error";break;case"success":d="",u="success"}return o.textContent=t,o.setAttribute("class","pr-2"),n&&(l.setAttribute("class","ns-button default"),c.textContent=n,c.setAttribute("class","px-3 py-2 shadow rounded uppercase ".concat(d)),l.appendChild(c)),a.appendChild(o),a.appendChild(l),a.setAttribute("class","md:rounded py-2 px-3 md:w-2/5 w-full z-10 md:my-2 shadow-lg flex justify-between items-center zoom-in-entrance anim-duration-300 ns-notice ".concat(u)),r.appendChild(a),null===document.getElementById("snack-wrapper")&&(r.setAttribute("id","snack-wrapper"),r.setAttribute("class","absolute bottom-0 w-full flex justify-between items-center flex-col"),document.body.appendChild(r)),{snackWrapper:r,sampleSnack:a,buttonsWrapper:l,buttonNode:c,textNode:o}}}],n&&i(t.prototype,n),r&&i(t,r),Object.defineProperty(t,"prototype",{writable:!1}),e}()},131:(e,t,n)=>{"use strict";var s=n(381),i=n.n(s);ns.date.moment=i()(ns.date.current),ns.date.interval=setInterval((function(){ns.date.moment.add(1,"seconds"),ns.date.current=i()(ns.date.current).add(1,"seconds").format("YYYY-MM-DD HH:mm:ss")}),1e3),ns.date.getNowString=function(){var e=Date.parse((new Date).toLocaleString("en-US",{timeZone:ns.date.timeZone}));return i()(e).format("YYYY-MM-DD HH:mm:ss")},ns.date.getMoment=function(){var e=Date.parse((new Date).toLocaleString("en-US",{timeZone:ns.date.timeZone}));return i()(e)}},6700:(e,t,n)=>{var s={"./af":2786,"./af.js":2786,"./ar":867,"./ar-dz":4130,"./ar-dz.js":4130,"./ar-kw":6135,"./ar-kw.js":6135,"./ar-ly":6440,"./ar-ly.js":6440,"./ar-ma":7702,"./ar-ma.js":7702,"./ar-sa":6040,"./ar-sa.js":6040,"./ar-tn":7100,"./ar-tn.js":7100,"./ar.js":867,"./az":1083,"./az.js":1083,"./be":9808,"./be.js":9808,"./bg":8338,"./bg.js":8338,"./bm":7438,"./bm.js":7438,"./bn":8905,"./bn-bd":6225,"./bn-bd.js":6225,"./bn.js":8905,"./bo":1560,"./bo.js":1560,"./br":1278,"./br.js":1278,"./bs":622,"./bs.js":622,"./ca":2468,"./ca.js":2468,"./cs":5822,"./cs.js":5822,"./cv":877,"./cv.js":877,"./cy":7373,"./cy.js":7373,"./da":4780,"./da.js":4780,"./de":9740,"./de-at":217,"./de-at.js":217,"./de-ch":894,"./de-ch.js":894,"./de.js":9740,"./dv":5300,"./dv.js":5300,"./el":837,"./el.js":837,"./en-au":8348,"./en-au.js":8348,"./en-ca":7925,"./en-ca.js":7925,"./en-gb":2243,"./en-gb.js":2243,"./en-ie":6436,"./en-ie.js":6436,"./en-il":7207,"./en-il.js":7207,"./en-in":4175,"./en-in.js":4175,"./en-nz":6319,"./en-nz.js":6319,"./en-sg":1662,"./en-sg.js":1662,"./eo":2915,"./eo.js":2915,"./es":5655,"./es-do":5251,"./es-do.js":5251,"./es-mx":6112,"./es-mx.js":6112,"./es-us":1146,"./es-us.js":1146,"./es.js":5655,"./et":5603,"./et.js":5603,"./eu":7763,"./eu.js":7763,"./fa":6959,"./fa.js":6959,"./fi":1897,"./fi.js":1897,"./fil":2549,"./fil.js":2549,"./fo":4694,"./fo.js":4694,"./fr":4470,"./fr-ca":3049,"./fr-ca.js":3049,"./fr-ch":2330,"./fr-ch.js":2330,"./fr.js":4470,"./fy":4415,"./fy.js":4415,"./ga":9295,"./ga.js":9295,"./gd":2101,"./gd.js":2101,"./gl":8794,"./gl.js":8794,"./gom-deva":7884,"./gom-deva.js":7884,"./gom-latn":3168,"./gom-latn.js":3168,"./gu":5349,"./gu.js":5349,"./he":4206,"./he.js":4206,"./hi":94,"./hi.js":94,"./hr":316,"./hr.js":316,"./hu":2138,"./hu.js":2138,"./hy-am":1423,"./hy-am.js":1423,"./id":9218,"./id.js":9218,"./is":135,"./is.js":135,"./it":626,"./it-ch":150,"./it-ch.js":150,"./it.js":626,"./ja":9183,"./ja.js":9183,"./jv":4286,"./jv.js":4286,"./ka":2105,"./ka.js":2105,"./kk":7772,"./kk.js":7772,"./km":8758,"./km.js":8758,"./kn":9282,"./kn.js":9282,"./ko":3730,"./ko.js":3730,"./ku":1408,"./ku.js":1408,"./ky":3291,"./ky.js":3291,"./lb":6841,"./lb.js":6841,"./lo":5466,"./lo.js":5466,"./lt":7010,"./lt.js":7010,"./lv":7595,"./lv.js":7595,"./me":9861,"./me.js":9861,"./mi":5493,"./mi.js":5493,"./mk":5966,"./mk.js":5966,"./ml":7341,"./ml.js":7341,"./mn":5115,"./mn.js":5115,"./mr":370,"./mr.js":370,"./ms":9847,"./ms-my":1237,"./ms-my.js":1237,"./ms.js":9847,"./mt":2126,"./mt.js":2126,"./my":6165,"./my.js":6165,"./nb":4924,"./nb.js":4924,"./ne":6744,"./ne.js":6744,"./nl":3901,"./nl-be":9814,"./nl-be.js":9814,"./nl.js":3901,"./nn":3877,"./nn.js":3877,"./oc-lnc":2135,"./oc-lnc.js":2135,"./pa-in":5858,"./pa-in.js":5858,"./pl":4495,"./pl.js":4495,"./pt":9520,"./pt-br":7971,"./pt-br.js":7971,"./pt.js":9520,"./ro":6459,"./ro.js":6459,"./ru":1793,"./ru.js":1793,"./sd":950,"./sd.js":950,"./se":490,"./se.js":490,"./si":124,"./si.js":124,"./sk":4249,"./sk.js":4249,"./sl":4985,"./sl.js":4985,"./sq":1104,"./sq.js":1104,"./sr":9131,"./sr-cyrl":9915,"./sr-cyrl.js":9915,"./sr.js":9131,"./ss":5893,"./ss.js":5893,"./sv":8760,"./sv.js":8760,"./sw":1172,"./sw.js":1172,"./ta":7333,"./ta.js":7333,"./te":3110,"./te.js":3110,"./tet":2095,"./tet.js":2095,"./tg":7321,"./tg.js":7321,"./th":9041,"./th.js":9041,"./tk":9005,"./tk.js":9005,"./tl-ph":5768,"./tl-ph.js":5768,"./tlh":9444,"./tlh.js":9444,"./tr":2397,"./tr.js":2397,"./tzl":8254,"./tzl.js":8254,"./tzm":1106,"./tzm-latn":699,"./tzm-latn.js":699,"./tzm.js":1106,"./ug-cn":9288,"./ug-cn.js":9288,"./uk":7691,"./uk.js":7691,"./ur":3795,"./ur.js":3795,"./uz":6791,"./uz-latn":588,"./uz-latn.js":588,"./uz.js":6791,"./vi":5666,"./vi.js":5666,"./x-pseudo":4378,"./x-pseudo.js":4378,"./yo":5805,"./yo.js":5805,"./zh-cn":3839,"./zh-cn.js":3839,"./zh-hk":5726,"./zh-hk.js":5726,"./zh-mo":9807,"./zh-mo.js":9807,"./zh-tw":4152,"./zh-tw.js":4152};function i(e){var t=r(e);return n(t)}function r(e){if(!n.o(s,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return s[e]}i.keys=function(){return Object.keys(s)},i.resolve=r,e.exports=i,i.id=6700},328:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var s=n(538),i=n(381),r=n.n(i),a=n(7144),o=n.n(a),l=(n(9095),n(3632));const c=s.default.extend({name:"ns-date-range-picker",data:function(){return{dateRange:{startDate:null,endDate:null}}},components:{DateRangePicker:o()},mounted:function(){void 0!==this.field.value&&(this.dateRange=this.field.value)},watch:{dateRange:function(){var e={startDate:r()(this.dateRange.startDate).format("YYYY-MM-DD HH:mm"),endDate:r()(this.dateRange.endDate).format("YYYY-MM-DD HH:mm")};this.field.value=e,this.$emit("change",this)}},methods:{__:l.__,getFormattedDate:function(e){return null!==e?r()(e).format("YYYY-MM-DD HH:mm"):(0,l.__)("N/D")},clearDate:function(){this.dateRange={startDate:null,endDate:null},this.field.value=void 0}},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"]});const d=(0,n(1900).Z)(c,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-auto flex-col mb-2 ns-date-range-picker"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"text-error-primary":"text-primary",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"mt-1 relative flex input-group border-2 rounded-md overflow-hidden focus:shadow-sm",class:e.hasError?"error":""},[e.leading?n("div",{staticClass:"absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none"},[n("span",{staticClass:"text-primary sm:text-sm sm:leading-5"},[e._v("\n "+e._s(e.leading)+"\n ")])]):e._e(),e._v(" "),n("button",{staticClass:"px-3 outline-none bg-error-secondary font-semibold text-white",on:{click:function(t){return e.clearDate()}}},[n("i",{staticClass:"las la-times"})]),e._v(" "),n("date-range-picker",{ref:"picker",staticClass:"w-full flex items-center bg-input-background",attrs:{"locale-data":{firstDay:1,format:"yyyy-mm-dd HH:mm:ss"},timePicker:!0,timePicker24Hour:!0,showWeekNumbers:!0,showDropdowns:!0,autoApply:!1,appendToBody:!0,disabled:e.field.disabled,linkedCalendars:!0},scopedSlots:e._u([{key:"input",fn:function(t){return[n("div",{staticClass:"flex justify-between items-center w-full py-2"},[n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Starts"))+" : "+e._s(e.getFormattedDate(t.startDate)))]),e._v(" "),n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Ends"))+" : "+e._s(e.getFormattedDate(t.endDate)))])])]}}]),model:{value:e.dateRange,callback:function(t){e.dateRange=t},expression:"dateRange"}})],1),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs text-gray-500"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs text-red-400"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e(),e._v(" "),"email"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field must contain a valid email address.")))]})):e._e(),e._v(" "),"invalid"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(t.message))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},9765:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-date-time-picker",props:["field","date"],data:function(){return{visible:!1,hours:0,minutes:0,currentView:"days",currentDay:void 0,moment:i(),months:new Array(11).fill("").map((function(e,t){return t})),daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},computed:{momentCopy:function(){return i()()}},watch:{visible:function(){var e=this;this.visible&&setTimeout((function(){e.$refs.hours.addEventListener("focus",(function(){this.select()})),e.$refs.minutes.addEventListener("focus",(function(){this.select()}))}),100)}},mounted:function(){var e=this;document.addEventListener("mousedown",(function(t){return e.checkClickedItem(t)})),this.field?this.currentDay=[void 0,"",null].includes(this.field.value)?i()():i()(this.field.value):this.currentDay=[void 0,"",null].includes(this.date)?i()():i()(this.date),this.hours=this.currentDay.format("HH"),this.minutes=this.currentDay.format("mm"),this.build()},methods:{__:n(3632).__,erase:function(){this.selectDate()},setYear:function(e){parseInt(e.srcElement.value)>0&&parseInt(e.srcElement.value)<9999&&(this.currentDay.year(e.srcElement.value),this.updateDateTime())},subYear:function(){parseFloat(this.currentDay.format("YYYY"))>0&&(this.currentDay.subtract(1,"year"),this.updateDateTime())},addYear:function(){this.currentDay.add(1,"year"),this.updateDateTime()},toggleView:function(e){var t=this;this.currentView=e,"years"===this.currentView&&setTimeout((function(){t.$refs.year.select()}),100)},setMonth:function(e){this.currentDay.month(e),this.updateDateTime()},detectHoursChange:function(){parseFloat(this.hours)<0&&(this.hours=0),parseFloat(this.hours)>23&&(this.hours=23),this.updateDateTime()},detectMinuteChange:function(){parseFloat(this.minutes)<0&&(this.minutes=0),parseFloat(this.minutes)>59&&(this.minutes=59),this.updateDateTime()},updateDateTime:function(){this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.build(),this.selectDate(this.currentDay)},checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){[void 0].includes(e)?(this.field&&(this.field.value=null),this.$emit("change",null)):(this.currentDay=e,this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.field&&(this.field.value=this.currentDay.format("YYYY/MM/DD HH:mm")),console.log(this.hours,this.minutes),this.$emit("change",this.field?this.field:this.currentDay))},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker mb-2"},[e.field?n("label",{staticClass:"block leading-5 font-medium text-primary"},[e._v(e._s(e.field.label))]):e._e(),e._v(" "),n("div",{staticClass:"ns-button"},[n("button",{staticClass:"rounded cursor-pointer w-full px-1 py-1 flex items-center text-primary",class:e.field?"mt-1 border":"shadow",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),e.currentDay&&e.field?n("span",{staticClass:"mx-1 text-sm"},[null!==e.field.value?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.field.value?n("span",[e._v("N/A")]):e._e()]):e._e(),e._v(" "),e.currentDay&&e.date?n("span",{staticClass:"mx-1 text-sm"},[null!==e.date?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.date?n("span",[e._v("N/A")]):e._e()]):e._e()])]),e._v(" "),e.field?n("p",{staticClass:"text-sm text-secondary py-1"},[e._v(e._s(e.field.description))]):e._e(),e._v(" "),e.visible?n("div",{staticClass:"relative z-10 h-0 w-0"},[n("div",{staticClass:"absolute w-72 shadow-xl rounded ns-box anim-duration-300 zoom-in-entrance flex flex-col",class:e.field?"-mt-4":"mt-2"},["years"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"h-32 flex items-center justify-center text-primary"},[n("div",{staticClass:"rounded input-group info border-2 flex w-2/3 overflow-hidden"},[n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.subYear()}}},[n("i",{staticClass:"las la-minus"})]),e._v(" "),n("input",{ref:"year",staticClass:"p-2 w-24 text-center outline-none",attrs:{type:"text"},domProps:{value:e.currentDay.format("YYYY")},on:{change:function(t){return e.setYear(t)}}}),e._v(" "),n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.addYear()}}},[n("i",{staticClass:"las la-plus"})])])])]):e._e(),e._v(" "),"months"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 border-b border-info-secondary border-dashed"},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-1 gap-0 text-primary"},e._l(e.months,(function(t,s){return n("div",{key:s,staticClass:"h-8 flex justify-center items-center text-sm"},[[n("div",{staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:e.momentCopy.month(t).format("MM")===e.currentDay.format("MM")?"bg-info-secondary text-white border border-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.setMonth(t)}}},[e._v("\n "+e._s(e.momentCopy.format("MMM"))+"\n ")])]],2)})),0)]):e._e(),e._v(" "),"days"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},[n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"text-white border border-info-secondary bg-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2):e._e(),e._v(" "),n("div",{staticClass:"border-t border-numpad-edge w-full p-2"},[n("div",{staticClass:"-mx-1 flex justify-between"},[n("div",{staticClass:"px-1"},[n("div",{staticClass:"-mx-1 flex"},[e.field?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.erase()}}},[n("i",{staticClass:"las la-trash"})])]):e._e(),e._v(" "),"days"!==e.currentView?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.toggleView("days")}}},[n("i",{staticClass:"las la-sign-out-alt"})])]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.hours,expression:"hours"}],ref:"hours",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"HH",type:"number"},domProps:{value:e.hours},on:{change:function(t){return e.detectHoursChange(t)},input:function(t){t.target.composing||(e.hours=t.target.value)}}}),e._v(" "),n("span",{staticClass:"mx-1"},[e._v(":")]),e._v(" "),n("input",{directives:[{name:"model",rawName:"v-model",value:e.minutes,expression:"minutes"}],ref:"minutes",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"mm",type:"number"},domProps:{value:e.minutes},on:{change:function(t){return e.detectMinuteChange(t)},input:function(t){t.target.composing||(e.minutes=t.target.value)}}})])])])])])]):e._e()])}),[],!1,null,null,null).exports},4915:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-datepicker",props:["label","date"],data:function(){return{visible:!1,currentDay:null,daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},mounted:function(){document.addEventListener("click",this.checkClickedItem),this.currentDay=[void 0,null].includes(this.date)?i()():i()(this.date),this.build()},methods:{__:n(3632).__,checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){this.currentDay=e,this.visible=!1,this.$emit("change",e)},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker"},[n("div",{staticClass:"rounded cursor-pointer bg-white shadow px-1 py-1 flex items-center text-gray-700",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),n("span",{staticClass:"mx-1 text-sm"},[n("span",[e._v(e._s(e.label||e.__("Date"))+" : ")]),e._v(" "),e.currentDay?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD")))]):e._e(),e._v(" "),null===e.currentDay?n("span",[e._v(e._s(e.__("N/A")))]):e._e()])]),e._v(" "),e.visible?n("div",{staticClass:"relative h-0 w-0 -mb-2"},[n("div",{staticClass:"w-72 mt-2 shadow rounded bg-white anim-duration-300 zoom-in-entrance flex flex-col"},[n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-gray-700 justify-center"},[e._v(e._s(e.currentDay.format("MMM"))+" "+e._s(e.currentDay.format("YYYY")))]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},[n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"bg-blue-400 text-white border border-blue-500":"hover:bg-gray-100 border border-gray-200",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2),e._v(" "),n("div")])]):e._e()])}),[],!1,null,null,null).exports},2404:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-notice",props:["color"],computed:{actualColor:function(){return this.color||"blue"}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"p-4 border-l-4 text-primary ns-notice",class:e.actualColor,attrs:{role:"alert"}},[n("h2",{staticClass:"font-bold"},[e._t("title")],2),e._v(" "),n("p",[e._t("description"),e._t("default")],2)])}),[],!1,null,null,null).exports},7751:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var s=n(3632);function i(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,s=new Array(t);n0?this.screenValue=parseFloat(this.value/this.number):this.screenValue=this.value||0;var t=new Array(10).fill("").map((function(e,t){return t}));nsHotPress.create("numpad-keys").whenVisible([".is-popup"]).whenPressed(t,(function(t,n){e.inputValue({value:n})})),nsHotPress.create("numpad-backspace").whenVisible([".is-popup"]).whenPressed("backspace",(function(){return e.inputValue({identifier:"backspace"})})),nsHotPress.create("numpad-increase").whenVisible([".is-popup"]).whenPressed("+",(function(){return e.increaseBy({value:1})})),nsHotPress.create("numpad-reduce").whenVisible([".is-popup"]).whenPressed("-",(function(){return e.increaseBy({value:-1})})),nsHotPress.create("numpad-save").whenVisible([".is-popup"]).whenPressed("enter",(function(){return e.inputValue({identifier:"next"})}))},watch:{value:function(){this.value.toString().length>0?this.floating?this.screenValue=Math.round(this.value*this.number).toString():this.screenValue=this.value:this.screenValue=""}},beforeDestroy:function(){nsHotPress.destroy("numpad-backspace"),nsHotPress.destroy("numpad-increase"),nsHotPress.destroy("numpad-reduce"),nsHotPress.destroy("numpad-save")},methods:{increaseBy:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));this.screenValue=(parseFloat(e.value)*t+(parseFloat(this.screenValue)||0)).toString(),this.allSelected=!1},inputValue:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));if("next"!==e.identifier){if("backspace"===e.identifier)this.allSelected?(this.screenValue="0",this.allSelected=!1):this.screenValue=this.screenValue.toString().substr(0,this.screenValue.length-1);else if(e.value.toString().match(/^\d+$/)){if(this.limit>0&&this.screenValue.length>=this.limit)return;this.allSelected?(this.screenValue=e.value.toString(),this.allSelected=!1):(this.screenValue+=""+e.value.toString(),"percentage"===this.mode&&(this.screenValue=this.screenValue>100?100:this.screenValue))}var n=this.floating&&this.screenValue.length>0&&"0"!==this.screenValue?parseFloat(this.screenValue/this.number):this.screenValue;this.$emit("changed",n)}else this.$emit("next",this.floating&&this.screenValue.length>0?parseFloat(this.screenValue/t):this.screenValue)}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-3",attrs:{id:"numpad"}},[e._l(e.keys,(function(t,s){return n("div",{key:s,staticClass:"select-none ns-numpad-key border-l border-b h-24 font-bold flex items-center justify-center cursor-pointer",on:{click:function(n){return e.inputValue(t)}}},[void 0!==t.value?n("span",[e._v(e._s(t.value))]):e._e(),e._v(" "),t.icon?n("i",{staticClass:"las",class:t.icon}):e._e()])})),e._v(" "),e._t("numpad-footer")],2)}),[],!1,null,null,null).exports},3502:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-paginate",props:["pagination"],data:function(){return{page:1,path:""}},mounted:function(){this.path=this.pagination.path},computed:{getPagination:function(){return this.pagination?this.pageNumbers(this.pagination.last_page,this.pagination.current_page):[]}},methods:{gotoPage:function(e){this.page=e,this.$emit("load","".concat(this.path,"?page=").concat(this.page))},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex -mx-1",attrs:{id:"pagination"}},[e.pagination.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.first_page)}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.getPagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info",class:e.page==t?"active":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){return e.gotoPage(t)}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.last_page)}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)}),[],!1,null,null,null).exports},3164:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={data:function(){return{}},name:"ns-switch",mounted:function(){},computed:{_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=t.value===e.field.value,t}))},hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},sizeClass:function(){return" w-1/".concat(this._options.length<=4?this._options.length:4)},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__,setSelected:function(e){this.field.value=e.value,this._options.forEach((function(e){return e.selected=!1})),e.selected=!0,this.$forceUpdate(),this.$emit("change",e.value)}},props:["placeholder","leading","type","field"]};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"mb-2 ns-switch"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"has-error":"is-pristine",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"rounded-lg flex w-52 overflow-hidden shadow my-1",class:e.hasError?"has-error":""},e._l(e._options,(function(t,s){return n("button",{key:s,staticClass:"p-2 text-sm flex-no-wrap outline-none rounded-none",class:t.selected?"selected "+e.sizeClass:"unselected "+e.inputClass+" "+e.sizeClass,attrs:{disabled:t.disabled},on:{click:function(n){return e.setSelected(t)}}},[e._v(e._s(t.label))])})),0),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs ns-description"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs ns-error"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},1274:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var s=n(7757),i=n.n(s),r=n(7700),a=n(665),o=n(3632),l=n(914);function c(e,t,n,s,i,r,a){try{var o=e[r](a),l=o.value}catch(e){return void n(e)}o.done?t(l):Promise.resolve(l).then(s,i)}const d={name:"ns-media",props:["popup"],components:{VueUpload:n(2948)},data:function(){return{pages:[{label:(0,o.__)("Upload"),name:"upload",selected:!1},{label:(0,o.__)("Gallery"),name:"gallery",selected:!0}],resources:[],isDragging:!1,response:{data:[],current_page:0,from:0,to:0,next_page_url:"",prev_page_url:"",path:"",per_page:0,total:0,last_page:0,first_page:0},queryPage:1,bulkSelect:!1,files:[]}},mounted:function(){this.popupCloser();var e=this.pages.filter((function(e){return"gallery"===e.name}))[0];this.select(e)},watch:{files:function(){this.uploadFiles()}},computed:{postMedia:function(){return r.kq.applyFilters("http-client-url","/api/nexopos/v4/medias")},currentPage:function(){return this.pages.filter((function(e){return e.selected}))[0]},hasOneSelected:function(){return this.response.data.filter((function(e){return e.selected})).length>0},selectedResource:function(){return this.response.data.filter((function(e){return e.selected}))[0]},csrf:function(){return ns.authentication.csrf},isPopup:function(){return void 0!==this.$popup},user_id:function(){return this.isPopup&&this.$popupParams.user_id||0},panelOpened:function(){return!this.bulkSelect&&this.hasOneSelected}},methods:{popupCloser:a.Z,__:o.__,cancelBulkSelect:function(){this.bulkSelect=!1,this.response.data.forEach((function(e){return e.selected=!1}))},deleteSelected:function(){var e=this;Popup.show(l.default,{title:(0,o.__)("Confirm Your Action"),message:(0,o.__)("You're about to delete selected resources. Would you like to proceed?"),onAction:function(t){t&&r.ih.post("/api/nexopos/v4/medias/bulk-delete",{ids:e.response.data.filter((function(e){return e.selected})).map((function(e){return e.id}))}).subscribe({next:function(t){r.kX.success(t.message).subscribe(),e.loadGallery()},error:function(e){r.kX.error(e.message).subscribe()}})}})},loadUploadScreen:function(){var e=this;setTimeout((function(){e.setDropZone()}),1e3)},setDropZone:function(){var e=this,t=document.getElementById("dropping-zone");t.addEventListener("dragenter",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragleave",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragover",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("drop",(function(t){return e.preventDefaults(t)}),!1);["dragenter","dragover"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!0}))})),["dragleave","drop"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!1}))})),t.addEventListener("drop",(function(t){return e.handleDrop(t)}),!1),this.$refs.files.addEventListener("change",(function(t){return e.processFiles(t.currentTarget.files)}))},uploadFiles:function(){var e,t=this;return(e=i().mark((function e(){var n,s,a;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=t.files.filter((function(e){return!1===e.uploaded&&0===e.progress&&!1===e.failed})),s=i().mark((function e(t){var s;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return s=n[t],e.prev=1,s.progress=1,e.next=5,new Promise((function(e,t){var n=new FormData;n.append("file",s.file),r.ih.post("/api/nexopos/v4/medias",n,{headers:{"Content-Type":"multipart/form-data"}}).subscribe({next:function(t){s.uploaded=!0,s.progress=100,e(t)},error:function(e){t(e)}})}));case 5:e.sent,e.next=11;break;case 8:e.prev=8,e.t0=e.catch(1),s.failed=!0;case 11:case"end":return e.stop()}}),e,null,[[1,8]])})),a=0;case 3:if(!(a0&&void 0!==arguments[0]?arguments[0]:null;t=null===t?this.queryPage:t,this.queryPage=t,r.ih.get("/api/nexopos/v4/medias?page=".concat(t,"&user_id=").concat(this.user_id)).subscribe((function(t){t.data.forEach((function(e){return e.selected=!1})),e.response=t}))},useSelectedEntries:function(){this.$popupParams.resolve({event:"use-selected",value:this.response.data.filter((function(e){return e.selected}))}),this.$popup.close()},selectResource:function(e){var t=this;this.bulkSelect||this.response.data.forEach((function(n,s){s!==t.response.data.indexOf(e)&&(n.selected=!1)})),e.selected=!e.selected}}};const u=(0,n(1900).Z)(d,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex md:flex-row flex-col ns-box shadow-xl overflow-hidden",class:e.isPopup?"w-6/7-screen h-6/7-screen":"w-full h-full",attrs:{id:"ns-media"}},[n("div",{staticClass:"sidebar w-48 md:h-full flex-shrink-0"},[n("h3",{staticClass:"text-xl font-bold my-4 text-center"},[e._v(e._s(e.__("Medias Manager")))]),e._v(" "),n("ul",{staticClass:"sidebar-menus flex md:block"},e._l(e.pages,(function(t,s){return n("li",{key:s,staticClass:"py-2 px-3 cursor-pointer border-l-8",class:t.selected?"active":"",on:{click:function(n){return e.select(t)}}},[e._v(e._s(t.label))])})),0)]),e._v(" "),"upload"===e.currentPage.name?n("div",{staticClass:"content w-full overflow-hidden flex"},[n("div",{staticClass:"flex flex-auto m-2 p-2 flex-col border-info-primary items-center justify-center",class:e.isDragging?"border-dashed border-2":"",attrs:{id:"dropping-zone"},on:{click:function(t){return e.triggerManualUpload()}}},[n("h3",{staticClass:"text-lg md:text-xl font-bold text-center text-primary mb-4"},[e._v(e._s(e.__("Click Here Or Drop Your File To Upload")))]),e._v(" "),n("input",{ref:"files",staticStyle:{display:"none"},attrs:{type:"file",name:"",multiple:"",id:""}}),e._v(" "),n("div",{staticClass:"rounded w-full md:w-2/3 text-primary h-56 overflow-y-auto ns-scrollbar p-2"},[n("ul",e._l(e.files,(function(t,s){return n("li",{key:s,staticClass:"p-2 mb-2 shadow ns-media-upload-item flex items-center justify-between rounded"},[n("span",[e._v(e._s(t.file.name))]),e._v(" "),n("span",{staticClass:"rounded bg-info-primary flex items-center justify-center text-xs p-2"},[e._v(e._s(t.progress)+"%")])])})),0)])])]):e._e(),e._v(" "),"gallery"===e.currentPage.name?n("div",{staticClass:"content flex-col w-full overflow-hidden flex"},[e.popup?n("div",{staticClass:"p-2 flex flex-shrink-0 justify-between"},[n("div"),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.popup.close()}}})],1)]):e._e(),e._v(" "),n("div",{staticClass:"flex flex-auto overflow-hidden"},[n("div",{staticClass:"shadow ns-grid flex flex-auto flex-col overflow-y-auto ns-scrollbar"},[n("div",{staticClass:"flex flex-auto"},[n("div",{staticClass:"p-2 overflow-x-auto"},[n("div",{staticClass:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-3 xl:grid-cols-4"},e._l(e.response.data,(function(t,s){return n("div",{key:s},[n("div",{staticClass:"p-2"},[n("div",{staticClass:"rounded-lg aspect-square bg-gray-500 m-2 overflow-hidden flex items-center justify-center",class:t.selected?"ns-media-image-selected ring-4":"",on:{click:function(n){return e.selectResource(t)}}},[n("img",{staticClass:"object-cover h-full",attrs:{src:t.sizes.thumb,alt:t.name}})])])])})),0)]),e._v(" "),0===e.response.data.length?n("div",{staticClass:"flex flex-auto items-center justify-center"},[n("h3",{staticClass:"text-2xl font-bold"},[e._v(e._s(e.__("Nothing has already been uploaded")))])]):e._e()])]),e._v(" "),n("div",{staticClass:"ns-media-preview-panel hidden lg:block w-64 flex-shrink-0",attrs:{id:"preview"}},[n("div",{staticClass:"h-64 bg-gray-800 flex items-center justify-center"},[e.panelOpened?n("img",{attrs:{src:e.selectedResource.sizes.thumb,alt:e.selectedResource.name}}):e._e()]),e._v(" "),e.panelOpened?n("div",{staticClass:"p-4 text-gray-700 text-sm",attrs:{id:"details"}},[n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("File Name"))+": ")]),n("span",[e._v(e._s(e.selectedResource.name))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("Uploaded At"))+":")]),n("span",[e._v(e._s(e.selectedResource.created_at))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("By"))+" :")]),n("span",[e._v(e._s(e.selectedResource.user.username))])])]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex ns-media-footer flex-shrink-0 justify-between"},[n("div",{staticClass:"flex -mx-2 flex-shrink-0"},[n("div",{staticClass:"px-2 flex-shrink-0 flex"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.cancelBulkSelect()}}},[n("i",{staticClass:"las la-times"})])]):e._e(),e._v(" "),e.hasOneSelected&&!e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){e.bulkSelect=!0}}},[n("i",{staticClass:"las la-check-circle"})])]):e._e(),e._v(" "),e.hasOneSelected?n("div",{staticClass:"ns-button error"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.deleteSelected()}}},[n("i",{staticClass:"las la-trash"})])]):e._e()])])]),e._v(" "),n("div",{staticClass:"flex-shrink-0 -mx-2 flex"},[n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[n("div",{staticClass:"ns-button",class:1===e.response.current_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:1===e.response.current_page},on:{click:function(t){return e.loadGallery(e.response.current_page-1)}}},[e._v(e._s(e.__("Previous")))])]),e._v(" "),n("hr",{staticClass:"border-r border-gray-700"}),e._v(" "),n("div",{staticClass:"ns-button",class:e.response.current_page===e.response.last_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:e.response.current_page===e.response.last_page},on:{click:function(t){return e.loadGallery(e.response.current_page+1)}}},[e._v(e._s(e.__("Next")))])])])]),e._v(" "),e.popup&&e.hasOneSelected?n("div",{staticClass:"px-2"},[n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"rounded shadow p-2 text-sm",on:{click:function(t){return e.useSelectedEntries()}}},[e._v(e._s(e.__("Use Selected")))])])]):e._e()])])]):e._e()])}),[],!1,null,null,null).exports},914:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>o});var s=n(3632),i=n(2830),r=n(665);const a={data:function(){return{title:"",message:""}},computed:{size:function(){return this.$popupParams.size||"h-full w-full"}},mounted:function(){this.title=this.$popupParams.title,this.message=this.$popupParams.message,this.popupCloser()},methods:{__:s.__,popupResolver:i.Z,popupCloser:r.Z,emitAction:function(e){this.$popupParams.onAction(e),this.$popup.close()}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-col shadow-lg w-5/7-screen md:w-4/7-screen lg:w-2/7-screen",class:e.size,attrs:{id:"confirm-popup"}},[n("div",{staticClass:"flex items-center justify-center flex-col flex-auto p-4"},[n("h2",{staticClass:"text-xl md:text-3xl font-body text-center"},[e._v(e._s(e.title))]),e._v(" "),n("p",{staticClass:"py-4 text-sm md:text-base text-center"},[e._v(e._s(e.message))])]),e._v(" "),n("div",{staticClass:"action-buttons flex border-t"},[n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!0)}}},[e._v(e._s(e.__("Yes")))]),e._v(" "),n("hr",{staticClass:"border-r h-16"}),e._v(" "),n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!1)}}},[e._v(e._s(e.__("No")))])])])}),[],!1,null,null,null).exports}},e=>{e.O(0,[898],(()=>{return t=6178,e(e.s=t);var t}));e.O()}]); \ No newline at end of file diff --git a/public/js/auth.min.js b/public/js/auth.min.js index 3e90ba41d..705dca806 100644 --- a/public/js/auth.min.js +++ b/public/js/auth.min.js @@ -1 +1 @@ -(self.webpackChunknexopos_4x=self.webpackChunknexopos_4x||[]).push([[743,198],{8108:(e,t,n)=>{"use strict";var s=n(538),i=n(7975),r=function(){return n.e(781).then(n.bind(n,8781))},a=function(){return n.e(331).then(n.bind(n,3331))},o=function(){return n.e(179).then(n.bind(n,6179))},l=function(){return n.e(669).then(n.bind(n,3669))},c=(window.nsState,window.nsScreen,window.nsExtraComponents);window.nsComponents=Object.assign(i,c,{nsRegister:r,nsLogin:a,nsPasswordLost:o,nsNewPassword:l}),window.authVueComponent=new s.default({el:"#page-container",components:Object.assign(Object.assign({nsLogin:a,nsRegister:r,nsPasswordLost:o,nsNewPassword:l},c),i)})},9671:(e,t,n)=>{"use strict";n.d(t,{l:()=>V,kq:()=>Z,ih:()=>Y,kX:()=>H});var s=n(6486),i=n(9669),r=n(6300),a=n(8345),o=n(9624),l=n(9248),c=n(230);function d(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};return this._request("post",e,t,n)}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("get",e,void 0,t)}},{key:"delete",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("delete",e,void 0,t)}},{key:"put",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._request("put",e,t,n)}},{key:"response",get:function(){return this._lastRequestData}},{key:"_request",value:function(e,t){var n=this,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return t=Z.applyFilters("http-client-url",t.replace(/\/$/,"")),this._subject.next({identifier:"async.start",url:t,data:s}),new c.y((function(r){n._client[e](t,s,Object.assign(Object.assign({},n._client.defaults[e]),i)).then((function(e){n._lastRequestData=e,r.next(e.data),r.complete(),n._subject.next({identifier:"async.stop"})})).catch((function(e){var t;r.error((null===(t=e.response)||void 0===t?void 0:t.data)||e.response||e),n._subject.next({identifier:"async.stop"})}))}))}},{key:"subject",value:function(){return this._subject}},{key:"emit",value:function(e){var t=e.identifier,n=e.value;this._subject.next({identifier:t,value:n})}}],n&&d(t.prototype,n),s&&d(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}(),f=n(3);function p(e,t){for(var n=0;n=1e3){for(var n,s=Math.floor((""+e).length/3),i=2;i>=1;i--){if(((n=parseFloat((0!=s?e/Math.pow(1e3,s):e).toPrecision(i)))+"").replace(/[^a-zA-Z 0-9]+/g,"").length<=2)break}n%1!=0&&(n=n.toFixed(1)),t=n+["","k","m","b","t"][s]}return t})),E=n(1356),S=n(9698);function P(e,t){for(var n=0;n0&&window.outerWidth<=480:this.breakpoint="xs";break;case window.outerWidth>480&&window.outerWidth<=640:this.breakpoint="sm";break;case window.outerWidth>640&&window.outerWidth<=1024:this.breakpoint="md";break;case window.outerWidth>1024&&window.outerWidth<=1280:this.breakpoint="lg";break;case window.outerWidth>1280:this.breakpoint="xl"}}}])&&q(t.prototype,n),s&&q(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()),I=new b({sidebar:["xs","sm","md"].includes(N.breakpoint)?"hidden":"visible"});Y.defineClient(i),window.nsEvent=V,window.nsHttpClient=Y,window.nsSnackBar=H,window.nsCurrency=E.W,window.nsTruncate=S.b,window.nsRawCurrency=E.f,window.nsAbbreviate=$,window.nsState=I,window.nsUrl=L,window.nsScreen=N,window.ChartJS=r,window.EventEmitter=h,window.Popup=x.G,window.RxJS=y,window.FormValidation=k.Z,window.nsCrudHandler=R},7975:(e,t,n)=>{"use strict";n.r(t),n.d(t,{nsAvatar:()=>Q,nsButton:()=>o,nsCheckbox:()=>p,nsCkeditor:()=>O,nsCloseButton:()=>j,nsCrud:()=>U,nsCrudForm:()=>g,nsDate:()=>w,nsDateRangePicker:()=>J.Z,nsDateTimePicker:()=>A.Z,nsDatepicker:()=>ee.Z,nsField:()=>_.P,nsIconButton:()=>$,nsInput:()=>c,nsLink:()=>l,nsMediaInput:()=>C,nsMenu:()=>r,nsMultiselect:()=>x,nsNotice:()=>K.Z,nsNumpad:()=>W.Z,nsPaginate:()=>te.Z,nsSearch:()=>se,nsSelect:()=>u,nsSelectAudio:()=>f,nsSpinner:()=>v,nsSubmenu:()=>a,nsSwitch:()=>M.Z,nsTableRow:()=>m,nsTabs:()=>T,nsTabsItem:()=>F,nsTextarea:()=>y});var s=n(538),i=n(9671),r=s.default.component("ns-menu",{data:function(){return{defaultToggledState:!1,_save:0}},props:["href","label","icon","notification","toggled","identifier"],template:'\n \n ',mounted:function(){var e=this;this.defaultToggledState=void 0!==this.toggled?this.toggled:this.defaultToggledState,i.l.subject().subscribe((function(t){t.value!==e.identifier&&(e.defaultToggledState=!1)}))},methods:{toggleEmit:function(){var e=this;this.toggle().then((function(t){t&&i.l.emit({identifier:"side-menu.open",value:e.identifier})}))},toggle:function(){var e=this;return new Promise((function(t,n){0===e.href.length&&(e.defaultToggledState=!e.defaultToggledState,t(e.defaultToggledState))}))}}}),a=s.default.component("ns-submenu",{data:function(){return{}},props:["href","label","active"],mounted:function(){},template:'\n
    \n
  • \n \n \n \n
  • \n
    \n '}),o=s.default.component("ns-button",{data:function(){return{clicked:!1,_save:0}},props:["type","disabled","link","href","routerLink","to"],template:'\n
    \n \n \n \n
    \n ',mounted:function(){},computed:{isDisabled:function(){return this.disabled&&(0===this.disabled.length||"disabled"===this.disabled||this.disabled)}}}),l=s.default.component("ns-link",{data:function(){return{clicked:!1,_save:0}},props:["type","to","href","target"],template:'\n
    \n \n \n
    \n ',computed:{buttonclass:function(){switch(this.type){case"info":return"shadow bg-blue-400 text-white";case"success":return"shadow bg-green-400 text-white";case"error":return"shadow bg-red-400 text-white";case"warning":return"shadow bg-orange-400 text-white";default:return"shadow bg-white text-gray-800"}}}}),c=s.default.component("ns-input",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),d=n(7389),u=s.default.component("ns-select",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},mounted:function(){},methods:{__:d.__},template:'\n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),f=s.default.component("ns-select-audio",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__:d.__,playSelectedSound:function(){this.field.value.length>0&&new Audio(this.field.value).play()}},template:'\n
    \n \n
    \n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),p=s.default.component("ns-checkbox",{data:function(){return{}},props:["checked","field","label"],template:'\n
    \n
    \n \n
    \n {{ label }}\n {{ field.label }}\n
    \n ',computed:{isChecked:function(){return this.field?this.field.value:this.checked}},methods:{toggleIt:function(){void 0!==this.field&&(this.field.value=!this.field.value),this.$emit("change",!this.checked)}}}),h=n(2242),m=s.default.component("ns-table-row",{props:["options","row","columns","prependOptions","showOptions"],data:function(){return{optionsToggled:!1}},mounted:function(){},methods:{__:d.__,sanitizeHTML:function(e){var t=document.createElement("div");t.innerHTML=e;for(var n=t.getElementsByTagName("script"),s=n.length;s--;)n[s].parentNode.removeChild(n[s]);return t.innerHTML},getElementOffset:function(e){var t=e.getBoundingClientRect();return{top:t.top+window.pageYOffset,left:t.left+window.pageXOffset}},toggleMenu:function(e){var t=this;if(this.row.$toggled=!this.row.$toggled,this.$emit("toggled",this.row),this.row.$toggled)setTimeout((function(){var e=t.$el.querySelectorAll(".relative > .absolute")[0],n=t.$el.querySelectorAll(".relative")[0],s=t.getElementOffset(n);e.style.top=s.top+"px",e.style.left=s.left+"px",n.classList.remove("relative"),n.classList.add("dropdown-holder")}),100);else{var n=this.$el.querySelectorAll(".dropdown-holder")[0];n.classList.remove("dropdown-holder"),n.classList.add("relative")}},handleChanged:function(e){this.row.$checked=e,this.$emit("updated",this.row)},triggerAsync:function(e){var t=this;e.confirm?confirm(e.confirm.message)&&i.ih[e.type.toLowerCase()](e.url).subscribe((function(e){i.kX.success(e.message).subscribe(),t.$emit("reload",t.row)}),(function(e){t.toggleMenu(),i.kX.error(e.message).subscribe()})):(i.l.emit({identifier:"ns-table-row-action",value:{action:e,row:this.row,component:this}}),this.toggleMenu())},triggerPopup:function(e,t){var n=window.nsExtraComponents[e.component];if(e.component)return n?new Promise((function(s,i){h.G.show(n,{resolve:s,reject:i,row:t,action:e})})):i.kX.error((0,d.__)('Unable to load the component "'.concat(e.component,'". Make sure the component is registered to "nsExtraComponents".'))).subscribe();this.triggerAsync(e)}},template:'\n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n '}),v=s.default.component("ns-spinner",{data:function(){return{}},mounted:function(){},computed:{validatedSize:function(){return this.size||24},validatedBorder:function(){return this.border||8},validatedAnimation:function(){return this.animation||"fast"}},props:["color","size","border"],template:"\n
    \n
    \n
    \n "}),b=n(7266),g=s.default.component("ns-crud-form",{data:function(){return{form:{},globallyChecked:!1,formValidation:new b.Z,rows:[]}},mounted:function(){this.loadForm()},props:["src","create-url","field-class","return-url","submit-url","submit-method","disable-tabs"],computed:{activeTabFields:function(){for(var e in this.form.tabs)if(this.form.tabs[e].active)return this.form.tabs[e].fields;return[]}},methods:{__:d.__,toggle:function(e){for(var t in this.form.tabs)this.form.tabs[t].active=!1;this.form.tabs[e].active=!0},handleShowOptions:function(e){this.rows.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},submit:function(){var e=this;return this.formValidation.validateForm(this.form).length>0?i.kX.error(this.$slots["error-invalid"]?this.$slots["error-invalid"][0].text:"No error message provided for having an invalid form.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():(this.formValidation.disableForm(this.form),void 0===this.submitUrl?i.kX.error(this.$slots["error-no-submit-url"]?this.$slots["error-no-submit-url"][0].text:"No error message provided for not having a valid submit url.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():void i.ih[this.submitMethod?this.submitMethod.toLowerCase():"post"](this.submitUrl,this.formValidation.extractForm(this.form)).subscribe((function(t){if("success"===t.status){if(e.submitMethod&&"post"===e.submitMethod.toLowerCase()&&!1!==e.returnUrl)return document.location=t.data.editUrl||e.returnUrl;i.kX.info(t.message,(0,d.__)("Okay"),{duration:3e3}).subscribe(),e.$emit("save",t)}e.formValidation.enableForm(e.form)}),(function(t){i.kX.error(t.message,void 0,{duration:5e3}).subscribe(),void 0!==t.data&&e.formValidation.triggerError(e.form,t.data),e.formValidation.enableForm(e.form)})))},handleGlobalChange:function(e){this.globallyChecked=e,this.rows.forEach((function(t){return t.$checked=e}))},loadForm:function(){var e=this;i.ih.get("".concat(this.src)).subscribe({next:function(t){e.form=e.parseForm(t.form),i.kq.doAction("ns-crud-form-loaded",e),e.$emit("updated",e.form)},error:function(e){i.kX.error(e.message,"OKAY",{duration:0}).subscribe()}})},parseForm:function(e){e.main.value=void 0===e.main.value?"":e.main.value,e.main=this.formValidation.createFields([e.main])[0];var t=0;for(var n in e.tabs)0===t&&(e.tabs[n].active=!0),e.tabs[n].active=void 0!==e.tabs[n].active&&e.tabs[n].active,e.tabs[n].fields=this.formValidation.createFields(e.tabs[n].fields),t++;return e}},template:'\n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n
    \n
    \n
    \n
    {{ tab.label }}
    \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n
    \n
    \n '}),y=s.default.component("ns-textarea",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),_=n(8737),x=s.default.component("ns-multiselect",{data:function(){return{showPanel:!1,search:""}},props:["field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=void 0!==t.selected&&t.selected,e.field.value&&e.field.value.includes(t.value)&&(t.selected=!0),t}))}},methods:{__:d.__,addOption:function(e){this.field.disabled||(this.$emit("addOption",e),this.$forceUpdate(),setTimeout((function(){}),100))},removeOption:function(e,t){var n=this;if(!this.field.disabled)return t.preventDefault(),t.stopPropagation(),this.$emit("removeOption",e),this.$forceUpdate(),setTimeout((function(){n.search=""}),100),!1}},mounted:function(){var e=this;this.field.value&&this.field.value.reverse().forEach((function(t){var n=e.field.options.filter((function(e){return e.value===t}));n.length>=0&&e.addOption(n[0])}))},template:'\n
    \n \n
    \n
    \n
    \n
    \n
    \n {{ option.label }}\n \n
    \n
    \n
    \n
    \n \n \n
    \n
    \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n
    \n '}),w=s.default.component("ns-date",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-input-edge cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),k=n(4255),C=s.default.component("ns-media-input",{template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n
    \n
    \n \n
    \n \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n ',computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":"ns-enabled"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},data:function(){return{}},props:["placeholder","leading","type","field"],mounted:function(){},methods:{toggleMedia:function(){var e=this;new Promise((function(t,n){h.G.show(k.default,Object.assign({resolve:t,reject:n},e.field.data||{}))})).then((function(t){"use-selected"===t.event&&(e.field.data&&"url"!==e.field.data.type?e.field.data&&"model"!==e.field.data.type||(e.field.value=t.value[0]):e.field.value=t.value[0].sizes.original,e.$forceUpdate())}))}}}),j=s.default.component("ns-close-button",{template:'\n \n ',methods:{clicked:function(e){this.$emit("click",e)}}}),$=s.default.component("ns-icon-button",{template:'\n \n ',props:["className","buttonClass","type"],methods:{clicked:function(e){this.$emit("click",e)}}}),E=n(1272),S=n.n(E),P=n(5234),D=n.n(P),O=s.default.component("ns-ckeditor",{data:function(){return{editor:D()}},components:{ckeditor:S().component},mounted:function(){},methods:{__:d.__},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),T=s.default.component("ns-tabs",{data:function(){return{childrens:[]}},props:["active"],computed:{activeComponent:function(){var e=this.$children.filter((function(e){return e.active}));return e.length>0&&e[0]}},methods:{toggle:function(e){this.$emit("active",e.identifier),this.$emit("changeTab",e.identifier)}},mounted:function(){this.childrens=this.$children},template:'\n
    \n
    \n
    {{ tab.label }}
    \n
    \n \n
    \n '}),F=s.default.component("ns-tabs-item",{data:function(){return{}},mounted:function(){},props:["label","identifier","padding"],template:'\n
    \n \n
    \n '}),M=n(9408),A=n(2744),q=n(7757),z=n.n(q),V=n(3601),Y=n(8603),H=n(6386);const L={data:function(){return{fields:[],validation:new b.Z}},methods:{__:d.__,popupCloser:Y.Z,popupResolver:H.Z,closePopup:function(){this.popupResolver(!1)},useFilters:function(){this.popupResolver(this.validation.extractFields(this.fields))},clearFilters:function(){this.fields.forEach((function(e){return e.value=""})),this.popupResolver(null)}},mounted:function(){this.fields=this.validation.createFields(this.$popupParams.queryFilters),this.popupCloser()}};var R=n(1900);const Z=(0,R.Z)(L,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-box shadow-lg w-95vw h-95vh md:w-2/5-screen overflow-hidden md:h-5/6-screen flex flex-col"},[n("div",{staticClass:"p-2 border-b ns-box-header flex justify-between items-center"},[n("h3",[e._v(e._s(e.__("Search Filters")))]),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.closePopup()}}})],1)]),e._v(" "),n("div",{staticClass:"p-2 ns-box-body flex-auto overflow-y-auto"},e._l(e.fields,(function(e,t){return n("ns-field",{key:t,attrs:{field:e}})})),1),e._v(" "),n("div",{staticClass:"p-2 flex justify-between ns-box-footer border-t"},[n("div",[n("ns-button",{attrs:{type:"error"},on:{click:function(t){return e.clearFilters()}}},[e._v(e._s(e.__("Clear Filters")))])],1),e._v(" "),n("div",[n("ns-button",{attrs:{type:"info"},on:{click:function(t){return e.useFilters()}}},[e._v(e._s(e.__("Use Filters")))])],1)])])}),[],!1,null,null,null).exports;var N=function(e,t,n,s){return new(n||(n=Promise))((function(i,r){function a(e){try{l(s.next(e))}catch(e){r(e)}}function o(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,o)}l((s=s.apply(e,t||[])).next())}))};const I={data:function(){return{prependOptions:!1,showOptions:!0,isRefreshing:!1,sortColumn:"",searchInput:"",queryFiltersString:"",searchQuery:"",page:1,bulkAction:"",bulkActions:[],queryFilters:[],withFilters:!1,columns:[],selectedEntries:[],globallyChecked:!1,result:{current_page:null,data:[],first_page_url:null,from:null,last_page:null,last_page_url:null,next_page_url:null,path:null,per_page:null,prev_page_url:null,to:null,total:null}}},name:"ns-crud",mounted:function(){void 0!==this.identifier&&nsCrudHandler.defineInstance(this.identifier,this),this.loadConfig()},props:["src","create-url","mode","identifier","queryParams"],computed:{getParsedSrc:function(){return"".concat(this.src,"?").concat(this.sortColumn).concat(this.searchQuery).concat(this.queryFiltersString).concat(this.queryPage).concat(this.getQueryParams()?"&"+this.getQueryParams():"")},showQueryFilters:function(){return this.queryFilters.length>0},getSelectedAction:function(){var e=this,t=this.bulkActions.filter((function(t){return t.identifier===e.bulkAction}));return t.length>0&&t[0]},pagination:function(){return this.result?this.pageNumbers(this.result.last_page,this.result.current_page):[]},queryPage:function(){return this.result?"&page=".concat(this.page):""},resultInfo:function(){return(0,d.__)("displaying {perPage} on {items} items").replace("{perPage}",this.result.total).replace("{items}",this.result.total)}},methods:{__:d.__,getQueryParams:function(){var e=this;return this.queryParams?Object.keys(this.queryParams).map((function(t){return"".concat(t,"=").concat(e.queryParams[t])})).join("&"):""},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))},downloadContent:function(){nsHttpClient.post("".concat(this.src,"/export?").concat(this.getParsedSrc),{entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe((function(e){setTimeout((function(){return document.location=e.url}),300),i.kX.success((0,d.__)("The document has been generated.")).subscribe()}),(function(e){i.kX.error(e.message||(0,d.__)("Unexpected error occured.")).subscribe()}))},clearSelectedEntries:function(){var e=this;h.G.show(V.default,{title:(0,d.__)("Clear Selected Entries ?"),message:(0,d.__)("Would you like to clear all selected entries ?"),onAction:function(t){t&&(e.selectedEntries=[])}})},refreshRow:function(e){if(!0===e.$checked){0===this.selectedEntries.filter((function(t){return t.$id===e.$id})).length&&this.selectedEntries.push(e)}else{var t=this.selectedEntries.filter((function(t){return t.$id===e.$id}));if(t.length>0){var n=this.selectedEntries.indexOf(t[0]);this.selectedEntries.splice(n,1)}}},handleShowOptions:function(e){this.result.data.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},handleGlobalChange:function(e){var t=this;this.globallyChecked=e,this.result.data.forEach((function(n){n.$checked=e,t.refreshRow(n)}))},loadConfig:function(){var e=this;nsHttpClient.get("".concat(this.src,"/config?").concat(this.getQueryParams())).subscribe((function(t){e.columns=t.columns,e.bulkActions=t.bulkActions,e.queryFilters=t.queryFilters,e.prependOptions=t.prependOptions,e.showOptions=t.showOptions,e.refresh()}),(function(e){i.kX.error(e.message,"OK",{duration:!1}).subscribe()}))},cancelSearch:function(){this.searchInput="",this.search()},search:function(){this.searchInput?this.searchQuery="&search=".concat(this.searchInput):this.searchQuery="",this.refresh()},sort:function(e){for(var t in this.columns)t!==e&&(this.columns[t].$sorted=!1,this.columns[t].$direction="");switch(this.columns[e].$sorted=!0,this.columns[e].$direction){case"asc":this.columns[e].$direction="desc";break;case"desc":this.columns[e].$direction="";break;case"":this.columns[e].$direction="asc"}["asc","desc"].includes(this.columns[e].$direction)?this.sortColumn="active=".concat(e,"&direction=").concat(this.columns[e].$direction):this.sortColumn="",this.$emit("sort",this.columns[e]),this.refresh()},bulkDo:function(){var e=this;return this.bulkAction?this.selectedEntries.length>0?confirm(this.getSelectedAction.confirm||this.$slots["error-bulk-confirmation"]||(0,d.__)("Would you like to perform the selected bulk action on the selected entries ?"))?nsHttpClient.post("".concat(this.src,"/bulk-actions"),{action:this.bulkAction,entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe({next:function(t){i.kX.info(t.message).subscribe(),e.selectedEntries=[],e.refresh()},error:function(e){i.kX.error(e.message).subscribe()}}):void 0:i.kX.error(this.$slots["error-no-selection"]?this.$slots["error-no-selection"][0].text:(0,d.__)("No selection has been made.")).subscribe():i.kX.error(this.$slots["error-no-action"]?this.$slots["error-no-action"][0].text:(0,d.__)("No action has been selected.")).subscribe()},openQueryFilter:function(){return N(this,void 0,void 0,z().mark((function e(){var t,n=this;return z().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,console.log(Z),e.next=4,new Promise((function(e,t){h.G.show(Z,{resolve:e,reject:t,queryFilters:n.queryFilters})}));case 4:t=e.sent,this.withFilters=!1,this.queryFiltersString="",null!==t&&(this.withFilters=!0,this.queryFiltersString="&queryFilters="+encodeURIComponent(JSON.stringify(t))),this.refresh(),e.next=13;break;case 11:e.prev=11,e.t0=e.catch(0);case 13:case"end":return e.stop()}}),e,this,[[0,11]])})))},refresh:function(){var e=this;this.globallyChecked=!1,this.isRefreshing=!0,nsHttpClient.get("".concat(this.getParsedSrc)).subscribe((function(t){t.data=t.data.map((function(t){return e.selectedEntries.filter((function(e){return e.$id===t.$id})).length>0&&(t.$checked=!0),t})),e.isRefreshing=!1,e.result=t,e.page=t.current_page}),(function(t){e.isRefreshing=!1,i.kX.error(t.message).subscribe()}))}}};const U=(0,R.Z)(I,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"w-full rounded-lg",class:"light"!==e.mode?"shadow mb-8":"",attrs:{id:"crud-table"}},["light"!==e.mode?n("div",{staticClass:"p-2 border-b border-popup-surface flex flex-col md:flex-row justify-between flex-wrap",attrs:{id:"crud-table-header"}},[n("div",{staticClass:"w-full md:w-auto -mx-2 mb-2 md:mb-0 flex",attrs:{id:"crud-search-box"}},[e.createUrl?n("div",{staticClass:"px-2 flex items-center justify-center"},[n("a",{staticClass:"rounded-full ns-crud-button text-sm h-10 flex items-center justify-center cursor-pointer px-3 outline-none border",attrs:{href:e.createUrl||"#"}},[n("i",{staticClass:"las la-plus"})])]):e._e(),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded-full p-1 ns-crud-input flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchInput,expression:"searchInput"}],staticClass:"w-36 md:w-auto bg-transparent outline-none px-2",attrs:{type:"text"},domProps:{value:e.searchInput},on:{input:function(t){t.target.composing||(e.searchInput=t.target.value)}}}),e._v(" "),n("button",{staticClass:"rounded-full w-8 h-8 outline-none ns-crud-input-button",on:{click:function(t){return e.search()}}},[n("i",{staticClass:"las la-search"})]),e._v(" "),e.searchQuery?n("button",{staticClass:"ml-1 rounded-full w-8 h-8 bg-error-secondary text-white outline-none hover:bg-error-tertiary",on:{click:function(t){return e.cancelSearch()}}},[n("i",{staticClass:"las la-times"})]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2 flex items-center justify-center"},[n("button",{staticClass:"rounded-full\n text-sm\n h-10\n px-3\n outline-none\n border\n ns-crud-button\n ",on:{click:function(t){return e.refresh()}}},[n("i",{staticClass:"las la-sync",class:e.isRefreshing?"animate-spin":""})])]),e._v(" "),e.showQueryFilters?n("div",{staticClass:"px-2 flex items-center"},[n("button",{staticClass:"ns-crud-button border rounded-full text-sm h-10 px-3 outline-none ",class:e.withFilters?"table-filters-enabled":"table-filters-disabled",on:{click:function(t){return e.openQueryFilter()}}},[e.withFilters?e._e():n("i",{staticClass:"las la-filter"}),e._v(" "),e.withFilters?n("i",{staticClass:"las la-check"}):e._e(),e._v(" "),e.withFilters?e._e():n("span",[e._v(e._s(e.__("Filters")))]),e._v(" "),e.withFilters?n("span",[e._v(e._s(e.__("Has Filters")))]):e._e()])]):e._e()]),e._v(" "),n("div",{staticClass:"-mx-1 flex flex-wrap w-full md:w-auto",attrs:{id:"crud-buttons"}},[e.selectedEntries.length>0?n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 outline-none ns-crud-button border",on:{click:function(t){return e.clearSelectedEntries()}}},[n("i",{staticClass:"lar la-check-square"}),e._v(" "+e._s(e.__("{entries} entries selected").replace("{entries}",e.selectedEntries.length))+"\n ")])]):e._e(),e._v(" "),n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 ns-crud-button border outline-none",on:{click:function(t){return e.downloadContent()}}},[n("i",{staticClass:"las la-download"}),e._v(" "+e._s(e.__("Download")))])])])]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"overflow-x-auto flex-auto"},[Object.values(e.columns).length>0?n("table",{staticClass:"table ns-table w-full"},[n("thead",[n("tr",[n("th",{staticClass:"text-center px-2 border w-16 py-2"},[n("ns-checkbox",{attrs:{checked:e.globallyChecked},on:{change:function(t){return e.handleGlobalChange(t)}}})],1),e._v(" "),e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e(),e._v(" "),e._l(e.columns,(function(t,s){return n("th",{key:s,staticClass:"cursor-pointer justify-betweenw-40 border text-left px-2 py-2",style:{"min-width":t.width||"auto"},on:{click:function(t){return e.sort(s)}}},[n("div",{staticClass:"w-full flex justify-between items-center"},[n("span",{staticClass:"flex"},[e._v(e._s(t.label))]),e._v(" "),n("span",{staticClass:"h-6 w-6 flex justify-center items-center"},["desc"===t.$direction?n("i",{staticClass:"las la-sort-amount-up"}):e._e(),e._v(" "),"asc"===t.$direction?n("i",{staticClass:"las la-sort-amount-down"}):e._e()])])])})),e._v(" "),!e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e()],2)]),e._v(" "),n("tbody",[void 0!==e.result.data&&e.result.data.length>0?e._l(e.result.data,(function(t,s){return n("ns-table-row",{key:s,attrs:{columns:e.columns,prependOptions:e.prependOptions,showOptions:e.showOptions,row:t},on:{updated:function(t){return e.refreshRow(t)},reload:function(t){return e.refresh()},toggled:function(t){return e.handleShowOptions(t)}}})})):e._e(),e._v(" "),e.result&&0!==e.result.data.length?e._e():n("tr",[n("td",{staticClass:"text-center text-gray-600 dark:text-slate-300 py-3",attrs:{colspan:Object.values(e.columns).length+2}},[e._v(e._s(e.__("There is nothing to display...")))])])],2)]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex border-t flex-col md:flex-row justify-between footer"},[e.bulkActions.length>0?n("div",{staticClass:"mb-2 md:mb-0 flex justify-between rounded-full ns-crud-input p-1",attrs:{id:"grouped-actions"}},[n("select",{directives:[{name:"model",rawName:"v-model",value:e.bulkAction,expression:"bulkAction"}],staticClass:"outline-none bg-transparent",attrs:{id:"grouped-actions"},on:{change:function(t){var n=Array.prototype.filter.call(t.target.options,(function(e){return e.selected})).map((function(e){return"_value"in e?e._value:e.value}));e.bulkAction=t.target.multiple?n:n[0]}}},[n("option",{staticClass:"bg-input-disabled",attrs:{selected:"",value:""}},[e._t("bulk-label",(function(){return[e._v(e._s(e.__("Bulk Actions")))]}))],2),e._v(" "),e._l(e.bulkActions,(function(t,s){return n("option",{key:s,staticClass:"bg-input-disabled",domProps:{value:t.identifier}},[e._v(e._s(t.label))])}))],2),e._v(" "),n("button",{staticClass:"ns-crud-input-button h-8 px-3 outline-none rounded-full flex items-center justify-center",on:{click:function(t){return e.bulkDo()}}},[e._t("bulk-go",(function(){return[e._v(e._s(e.__("Apply")))]}))],2)]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"items-center flex text-primary mx-4"},[e._v(e._s(e.resultInfo))]),e._v(" "),n("div",{staticClass:"flex items-center -mx-1",attrs:{id:"pagination"}},[e.result.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.first_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.pagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",class:e.page==t?"bg-info-tertiary border-transparent text-white":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){e.page=t,e.refresh()}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.last_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)])])])}),[],!1,null,null,null).exports;var W=n(4864),B=n(1726),X=n(7259);const G=s.default.extend({methods:{__:d.__},name:"ns-avatar",data:function(){return{svg:""}},mounted:function(){this.svg=(0,B.createAvatar)(X,{seed:this.displayName})},computed:{avatarUrl:function(){return 0===this.url.length?"":this.url}},props:["url","display-name"]});const Q=(0,R.Z)(G,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex justify-between items-center flex-shrink-0"},[n("span",{staticClass:"hidden md:inline-block px-2"},[e._v(e._s(e.__("Howdy, {name}").replace("{name}",this.displayName)))]),e._v(" "),n("span",{staticClass:"md:hidden px-2"},[e._v(e._s(e.displayName))]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"w-8 h-8 overflow-hidden rounded-full bg-gray-600"},[""!==e.avatarUrl?n("img",{staticClass:"w-8 h-8 overflow-hidden rounded-full",attrs:{src:e.avatarUrl,alt:e.displayName,srcset:""}}):e._e(),e._v(" "),""===e.avatarUrl?n("div",{domProps:{innerHTML:e._s(e.svg)}}):e._e()])])])}),[],!1,null,null,null).exports;var J=n(4806),K=n(1828),ee=n(1544),te=n(3506);const ne={name:"ns-search",props:["url","placeholder","value","label","method","searchArgument"],data:function(){return{searchText:"",searchTimeout:null,results:[]}},methods:{__:d.__,selectOption:function(e){this.$emit("select",e),this.searchText="",this.results=[]}},watch:{searchText:function(){var e=this;clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout((function(){var t,n,s;e.searchText.length>0&&i.ih[e.method||"post"](e.url,(t={},n=e.searchArgument||"search",s=e.searchText,n in t?Object.defineProperty(t,n,{value:s,enumerable:!0,configurable:!0,writable:!0}):t[n]=s,t)).subscribe({next:function(t){e.results=t},error:function(e){i.kX.error(e.message||(0,d.__)("An unexpected error occured.")).subscribe()}})}),1e3)}},mounted:function(){}};const se=(0,R.Z)(ne,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-search"},[n("div",{staticClass:"input-group info border-2"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchText,expression:"searchText"}],staticClass:"p-2 w-full",attrs:{type:"text",placeholder:e.placeholder||e.__("Search..."),id:""},domProps:{value:e.searchText},on:{input:function(t){t.target.composing||(e.searchText=t.target.value)}}})]),e._v(" "),n("div",{staticClass:"relative"},[n("div",{staticClass:"w-full absolute"},[e.results.length>0&&e.searchText.length>0?n("ul",{staticClass:"ns-vertical-menu"},e._l(e.results,(function(t,s){return n("li",{key:s,staticClass:"border-b p-2 cursor-pointer",on:{click:function(n){return e.selectOption(t)}}},[e._v(e._s(t[e.label]))])})),0):e._e()])])])}),[],!1,null,null,null).exports},8737:(e,t,n)=>{"use strict";n.d(t,{P:()=>o});var s=n(538),i=n(4806),r=n(2744),a=n(9408),o=s.default.component("ns-field",{data:function(){return{}},mounted:function(){},components:{nsDateRangePicker:i.Z,nsDateTimePicker:r.Z,nsSwitch:a.Z},computed:{isInputField:function(){return["text","password","email","number","tel"].includes(this.field.type)},isDateField:function(){return["date"].includes(this.field.type)},isSelectField:function(){return["select"].includes(this.field.type)},isTextarea:function(){return["textarea"].includes(this.field.type)},isCheckbox:function(){return["checkbox"].includes(this.field.type)},isMultiselect:function(){return["multiselect"].includes(this.field.type)},isSelectAudio:function(){return["select-audio"].includes(this.field.type)},isSwitch:function(){return["switch"].includes(this.field.type)},isMedia:function(){return["media"].includes(this.field.type)},isCkEditor:function(){return["ckeditor"].includes(this.field.type)},isDateTimePicker:function(){return["datetimepicker"].includes(this.field.type)},isDateRangePicker:function(){return["daterangepicker"].includes(this.field.type)},isCustom:function(){return["custom"].includes(this.field.type)}},props:["field"],methods:{addOption:function(e){"select"===this.field.type&&this.field.options.forEach((function(e){return e.selected=!1})),e.selected=!0;var t=this.field.options.indexOf(e);this.field.options.splice(t,1),this.field.options.unshift(e),this.refreshMultiselect(),this.$emit("change",{action:"addOption",option:e})},refreshMultiselect:function(){this.field.value=this.field.options.filter((function(e){return e.selected})).map((function(e){return e.value}))},removeOption:function(e){e.selected=!1,this.refreshMultiselect(),this.$emit("change",{action:"removeOption",option:e})}},template:'\n
    \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    \n '})},1356:(e,t,n)=>{"use strict";n.d(t,{W:()=>c,f:()=>d});var s=n(2077),i=n.n(s),r=n(538),a=n(6740),o=n.n(a),l=new Array(parseInt(ns.currency.ns_currency_precision)).fill("").map((function(e){return 0})).join(""),c=r.default.filter("currency",(function(e){var t,n,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"full";switch(ns.currency.ns_currency_prefered){case"iso":t=ns.currency.ns_currency_iso;break;case"symbol":t=ns.currency.ns_currency_symbol}if("full"===s){var r={decimal:ns.currency.ns_currency_decimal_separator,separator:ns.currency.ns_currency_thousand_separator,precision:parseInt(ns.currency.ns_currency_precision),symbol:""};n=o()(e,r).format()}else n=i()(e).format("0.0a");return"".concat("before"===ns.currency.ns_currency_position?t:"").concat(n).concat("after"===ns.currency.ns_currency_position?t:"")})),d=function(e){var t="0.".concat(l);return parseFloat(i()(e).format(t))}},9698:(e,t,n)=>{"use strict";n.d(t,{b:()=>s});var s=n(538).default.filter("truncate",(function(e,t){return e?(e=e.toString()).length>t?e.substring(0,t)+"...":e:""}))},7266:(e,t,n)=>{"use strict";function s(e,t){for(var n=0;ni});var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,i;return t=e,n=[{key:"validateFields",value:function(e){var t=this;return 0===e.map((function(e){return t.checkField(e),e.errors?0===e.errors.length:0})).filter((function(e){return!1===e})).length}},{key:"validateFieldsErrors",value:function(e){var t=this;return e.map((function(e){return t.checkField(e),e.errors})).flat()}},{key:"validateForm",value:function(e){e.main&&this.validateField(e.main);var t=[];for(var n in e.tabs)if(e.tabs[n].fields){var s=[],i=this.validateFieldsErrors(e.tabs[n].fields);i.length>0&&s.push(i),e.tabs[n].errors=s.flat(),t.push(s.flat())}return t.flat().filter((function(e){return void 0!==e}))}},{key:"initializeTabs",value:function(e){var t=0;for(var n in e)0===t&&(e[n].active=!0),e[n].active=void 0!==e[n].active&&e[n].active,e[n].fields=this.createFields(e[n].fields),t++;return e}},{key:"validateField",value:function(e){return this.checkField(e)}},{key:"fieldsValid",value:function(e){return!(e.map((function(e){return e.errors&&e.errors.length>0})).filter((function(e){return e})).length>0)}},{key:"createFields",value:function(e){return e.map((function(t){if(t.type=t.type||"text",t.errors=t.errors||[],t.disabled=t.disabled||!1,"custom"===t.type&&"string"==typeof t.component){var n=t.component;if(t.component=nsExtraComponents[t.component],!t.component)throw'Failed to load a custom component. "'.concat(n,'" is not provided as an extra component. More details here: https://my.nexopos.com/en/documentation/developpers-guides/how-to-register-a-custom-vue-component');t.component.$field=t,t.component.$fields=e}return t}))}},{key:"createForm",value:function(e){if(e.main&&(e.main=this.createFields([e.main])[0]),e.tabs)for(var t in e.tabs)e.tabs[t].errors=[],void 0!==e.tabs[t].fields?e.tabs[t].fields=this.createFields(e.tabs[t].fields):console.info('Warning: The tab "'.concat(e.tabs[t].label,'" is missing fields. Fallback on checking dynamic component instead.'));return e}},{key:"enableFields",value:function(e){return e.map((function(e){return e.disabled=!1}))}},{key:"disableFields",value:function(e){return e.map((function(e){return e.disabled=!0}))}},{key:"disableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!0),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!0}))}},{key:"enableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!1),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!1}))}},{key:"getValue",value:function(e){var t={};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"checkField",value:function(e){var t=this;return void 0!==e.validation&&(e.errors=[],this.detectValidationRules(e.validation).forEach((function(n){t.fieldPassCheck(e,n)}))),e}},{key:"extractForm",value:function(e){var t={};if(e.main&&(t[e.main.name]=e.main.value),e.tabs)for(var n in e.tabs)void 0===t[n]&&(t[n]={}),t[n]=this.extractFields(e.tabs[n].fields);return t}},{key:"extractFields",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"detectValidationRules",value:function(e){var t=function(e){var t;return["email","required"].includes(e)?{identifier:e}:(t=/(min)\:([0-9])+/g.exec(e))||(t=/(max)\:([0-9])+/g.exec(e))?{identifier:t[1],value:t[2]}:e};return Array.isArray(e)?e.filter((function(e){return"string"==typeof e})).map(t):e.split("|").map(t)}},{key:"triggerError",value:function(e,t){if(console.log(t),t.errors){var n=function(n){var s=n.split(".").filter((function(e){return!/^\d+$/.test(e)}));2===s.length&&e.tabs[s[0]].fields.forEach((function(e){e.name===s[1]&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))})),n===e.main.name&&t.errors[n].forEach((function(t){e.main.errors.push({identifier:"invalid",invalid:!0,message:t,name:e.main.name})}))};for(var s in t.errors)n(s)}}},{key:"triggerFieldsErrors",value:function(e,t){if(t&&t.errors){var n=function(n){e.forEach((function(e){e.name===n&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))}))};for(var s in t.errors)n(s)}}},{key:"fieldPassCheck",value:function(e,t){if("required"===t.identifier){if(void 0===e.value||null===e.value||0===e.value.length)return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){n.identifier===t.identifier&&!0===n.invalid&&e.errors.splice(s,1)}))}if("email"===t.identifier&&e.value.length>0){if(!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(e.value))return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){!0===n[t.identifier]&&e.errors.splice(s,1)}))}return e}}],n&&s(t.prototype,n),i&&s(t,i),Object.defineProperty(t,"prototype",{writable:!1}),e}()},7389:(e,t,n)=>{"use strict";n.d(t,{__:()=>s,c:()=>i});var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"NexoPOS";return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e},i=function(e,t){return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e}},8603:(e,t,n)=>{"use strict";function s(){var e=this;Object.keys(this).includes("$popup")&&(this.$popup.event.subscribe((function(t){"click-overlay"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close()),"press-esc"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close())})),nsHotPress.create("popup-esc").whenPressed("escape",(function(t){t.preventDefault();var n=parseInt(e.$el.parentElement.getAttribute("data-index"));null===document.querySelector('.is-popup [data-index="'.concat(n+1,"]"))&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close(),nsHotPress.destroy("popup-esc"))})))}n.d(t,{Z:()=>s})},6386:(e,t,n)=>{"use strict";function s(e){void 0!==this.$popupParams.resolve&&this.$popupParams.reject&&(!1!==e?this.$popupParams.resolve(e):this.$popupParams.reject(e)),this.$popup.close()}n.d(t,{Z:()=>s})},2242:(e,t,n)=>{"use strict";n.d(t,{G:()=>c});var s=n(7757),i=n.n(s),r=n(9248);function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};if(a(this,e),this.config={primarySelector:void 0,popupClass:"shadow-lg h-half w-1/2 bg-white"},this.container=document.createElement("div"),this.popupBody=document.createElement("div"),this.popupSelector="",this.config=Object.assign(this.config,t),void 0===this.config.primarySelector&&document.querySelectorAll(".is-popup").length>0){var n=document.querySelectorAll(".is-popup").length;this.parentWrapper=document.querySelectorAll(".is-popup")[n-1]}else this.parentWrapper=document.querySelector("body").querySelectorAll("div")[0];this.event=new r.x}var t,n,s;return t=e,n=[{key:"hash",value:function(){for(var e="",t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=0;n<10;n++)e+=t.charAt(Math.floor(Math.random()*t.length));return e}},{key:"open",value:function(e){var t,n,s,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return l(this,void 0,void 0,i().mark((function a(){var o,l,c,d=this;return i().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if("function"!=typeof e){i.next=9;break}return i.prev=1,i.next=4,e();case 4:e=i.sent.default,i.next=9;break;case 7:i.prev=7,i.t0=i.catch(1);case 9:o=document.querySelector("body").querySelectorAll("div")[0],this.parentWrapper.style.filter="blur(4px)",o.style.filter="blur(6px)",this.container.setAttribute("class","absolute top-0 left-0 w-full h-full flex items-center justify-center is-popup"),this.container.addEventListener("click",(function(e){d.event.next({event:"click-overlay",value:!0}),e.stopPropagation()})),this.popupBody.addEventListener("click",(function(e){e.stopImmediatePropagation()})),l=document.querySelectorAll(".is-popup").length,this.container.id="popup-container-"+this.hash(),this.popupSelector="#".concat(this.container.id),this.popupBody.setAttribute("class","zoom-out-entrance popup-body"),this.popupBody.setAttribute("data-index",l),this.popupBody.innerHTML='
    ',this.container.appendChild(this.popupBody),document.body.appendChild(this.container),c=Vue.extend(e),this.instance=new c({propsData:{popup:this}}),this.instance.template=(null===(t=null==e?void 0:e.options)||void 0===t?void 0:t.template)||void 0,this.instance.render=e.render||void 0,this.instance.methods=(null===(n=null==e?void 0:e.options)||void 0===n?void 0:n.methods)||(null==e?void 0:e.methods),this.instance.data=(null===(s=null==e?void 0:e.options)||void 0===s?void 0:s.data)||(null==e?void 0:e.data),this.instance.$popup=this,this.instance.$popupParams=r,this.instance.$mount("#".concat(this.container.id," .vue-component"));case 32:case"end":return i.stop()}}),a,this,[[1,7]])})))}},{key:"close",value:function(){var e=this;this.instance.$destroy(),this.event.unsubscribe(),this.parentWrapper.style.filter="blur(0px)";var t=document.querySelector("body").querySelectorAll("div")[0];document.querySelectorAll(".is-popup").length<=1&&(t.style.filter="blur(0px)");var n="".concat(this.popupSelector," .popup-body");this.popupBody=document.querySelector(n),this.popupBody.classList.remove("zoom-out-entrance"),this.popupBody.classList.add("zoom-in-exit"),this.container=document.querySelector("".concat(this.popupSelector)),this.container.classList.remove("is-popup"),setTimeout((function(){e.container.remove()}),300)}}],s=[{key:"show",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=new e(s);return i.open(t,n),i}}],n&&o(t.prototype,n),s&&o(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()},9624:(e,t,n)=>{"use strict";n.d(t,{S:()=>r});var s=n(3260);function i(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return s.Observable.create((function(s){var r=n.__createSnack({message:e,label:t,type:i.type}),a=r.buttonNode,o=(r.textNode,r.snackWrapper,r.sampleSnack);a.addEventListener("click",(function(e){s.onNext(a),s.onCompleted(),o.remove()})),n.__startTimer(i.duration,o)}))}},{key:"error",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"error"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"error"}))}},{key:"success",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"success"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"success"}))}},{key:"info",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"info"}))}},{key:"__startTimer",value:function(e,t){var n,s=function(){e>0&&!1!==e&&(n=setTimeout((function(){t.remove()}),e))};t.addEventListener("mouseenter",(function(){clearTimeout(n)})),t.addEventListener("mouseleave",(function(){s()})),s()}},{key:"__createSnack",value:function(e){var t=e.message,n=e.label,s=e.type,i=void 0===s?"info":s,r=document.getElementById("snack-wrapper")||document.createElement("div"),a=document.createElement("div"),o=document.createElement("p"),l=document.createElement("div"),c=document.createElement("button"),d="",u="";switch(i){case"info":d="",u="info";break;case"error":d="",u="error";break;case"success":d="",u="success"}return o.textContent=t,o.setAttribute("class","pr-2"),n&&(l.setAttribute("class","ns-button default"),c.textContent=n,c.setAttribute("class","px-3 py-2 shadow rounded uppercase ".concat(d)),l.appendChild(c)),a.appendChild(o),a.appendChild(l),a.setAttribute("class","md:rounded py-2 px-3 md:w-2/5 w-full z-10 md:my-2 shadow-lg flex justify-between items-center zoom-in-entrance anim-duration-300 ns-notice ".concat(u)),r.appendChild(a),null===document.getElementById("snack-wrapper")&&(r.setAttribute("id","snack-wrapper"),r.setAttribute("class","absolute bottom-0 w-full flex justify-between items-center flex-col"),document.body.appendChild(r)),{snackWrapper:r,sampleSnack:a,buttonsWrapper:l,buttonNode:c,textNode:o}}}],n&&i(t.prototype,n),r&&i(t,r),Object.defineProperty(t,"prototype",{writable:!1}),e}()},6700:(e,t,n)=>{var s={"./af":2786,"./af.js":2786,"./ar":867,"./ar-dz":4130,"./ar-dz.js":4130,"./ar-kw":6135,"./ar-kw.js":6135,"./ar-ly":6440,"./ar-ly.js":6440,"./ar-ma":7702,"./ar-ma.js":7702,"./ar-sa":6040,"./ar-sa.js":6040,"./ar-tn":7100,"./ar-tn.js":7100,"./ar.js":867,"./az":1083,"./az.js":1083,"./be":9808,"./be.js":9808,"./bg":8338,"./bg.js":8338,"./bm":7438,"./bm.js":7438,"./bn":8905,"./bn-bd":6225,"./bn-bd.js":6225,"./bn.js":8905,"./bo":1560,"./bo.js":1560,"./br":1278,"./br.js":1278,"./bs":622,"./bs.js":622,"./ca":2468,"./ca.js":2468,"./cs":5822,"./cs.js":5822,"./cv":877,"./cv.js":877,"./cy":7373,"./cy.js":7373,"./da":4780,"./da.js":4780,"./de":9740,"./de-at":217,"./de-at.js":217,"./de-ch":894,"./de-ch.js":894,"./de.js":9740,"./dv":5300,"./dv.js":5300,"./el":837,"./el.js":837,"./en-au":8348,"./en-au.js":8348,"./en-ca":7925,"./en-ca.js":7925,"./en-gb":2243,"./en-gb.js":2243,"./en-ie":6436,"./en-ie.js":6436,"./en-il":7207,"./en-il.js":7207,"./en-in":4175,"./en-in.js":4175,"./en-nz":6319,"./en-nz.js":6319,"./en-sg":1662,"./en-sg.js":1662,"./eo":2915,"./eo.js":2915,"./es":5655,"./es-do":5251,"./es-do.js":5251,"./es-mx":6112,"./es-mx.js":6112,"./es-us":1146,"./es-us.js":1146,"./es.js":5655,"./et":5603,"./et.js":5603,"./eu":7763,"./eu.js":7763,"./fa":6959,"./fa.js":6959,"./fi":1897,"./fi.js":1897,"./fil":2549,"./fil.js":2549,"./fo":4694,"./fo.js":4694,"./fr":4470,"./fr-ca":3049,"./fr-ca.js":3049,"./fr-ch":2330,"./fr-ch.js":2330,"./fr.js":4470,"./fy":4415,"./fy.js":4415,"./ga":9295,"./ga.js":9295,"./gd":2101,"./gd.js":2101,"./gl":8794,"./gl.js":8794,"./gom-deva":7884,"./gom-deva.js":7884,"./gom-latn":3168,"./gom-latn.js":3168,"./gu":5349,"./gu.js":5349,"./he":4206,"./he.js":4206,"./hi":94,"./hi.js":94,"./hr":316,"./hr.js":316,"./hu":2138,"./hu.js":2138,"./hy-am":1423,"./hy-am.js":1423,"./id":9218,"./id.js":9218,"./is":135,"./is.js":135,"./it":626,"./it-ch":150,"./it-ch.js":150,"./it.js":626,"./ja":9183,"./ja.js":9183,"./jv":4286,"./jv.js":4286,"./ka":2105,"./ka.js":2105,"./kk":7772,"./kk.js":7772,"./km":8758,"./km.js":8758,"./kn":9282,"./kn.js":9282,"./ko":3730,"./ko.js":3730,"./ku":1408,"./ku.js":1408,"./ky":3291,"./ky.js":3291,"./lb":6841,"./lb.js":6841,"./lo":5466,"./lo.js":5466,"./lt":7010,"./lt.js":7010,"./lv":7595,"./lv.js":7595,"./me":9861,"./me.js":9861,"./mi":5493,"./mi.js":5493,"./mk":5966,"./mk.js":5966,"./ml":7341,"./ml.js":7341,"./mn":5115,"./mn.js":5115,"./mr":370,"./mr.js":370,"./ms":9847,"./ms-my":1237,"./ms-my.js":1237,"./ms.js":9847,"./mt":2126,"./mt.js":2126,"./my":6165,"./my.js":6165,"./nb":4924,"./nb.js":4924,"./ne":6744,"./ne.js":6744,"./nl":3901,"./nl-be":9814,"./nl-be.js":9814,"./nl.js":3901,"./nn":3877,"./nn.js":3877,"./oc-lnc":2135,"./oc-lnc.js":2135,"./pa-in":5858,"./pa-in.js":5858,"./pl":4495,"./pl.js":4495,"./pt":9520,"./pt-br":7971,"./pt-br.js":7971,"./pt.js":9520,"./ro":6459,"./ro.js":6459,"./ru":238,"./ru.js":238,"./sd":950,"./sd.js":950,"./se":490,"./se.js":490,"./si":124,"./si.js":124,"./sk":4249,"./sk.js":4249,"./sl":4985,"./sl.js":4985,"./sq":1104,"./sq.js":1104,"./sr":9131,"./sr-cyrl":9915,"./sr-cyrl.js":9915,"./sr.js":9131,"./ss":5893,"./ss.js":5893,"./sv":8760,"./sv.js":8760,"./sw":1172,"./sw.js":1172,"./ta":7333,"./ta.js":7333,"./te":3110,"./te.js":3110,"./tet":2095,"./tet.js":2095,"./tg":7321,"./tg.js":7321,"./th":9041,"./th.js":9041,"./tk":9005,"./tk.js":9005,"./tl-ph":5768,"./tl-ph.js":5768,"./tlh":9444,"./tlh.js":9444,"./tr":2397,"./tr.js":2397,"./tzl":8254,"./tzl.js":8254,"./tzm":1106,"./tzm-latn":699,"./tzm-latn.js":699,"./tzm.js":1106,"./ug-cn":9288,"./ug-cn.js":9288,"./uk":7691,"./uk.js":7691,"./ur":3795,"./ur.js":3795,"./uz":6791,"./uz-latn":588,"./uz-latn.js":588,"./uz.js":6791,"./vi":5666,"./vi.js":5666,"./x-pseudo":4378,"./x-pseudo.js":4378,"./yo":5805,"./yo.js":5805,"./zh-cn":3839,"./zh-cn.js":3839,"./zh-hk":5726,"./zh-hk.js":5726,"./zh-mo":9807,"./zh-mo.js":9807,"./zh-tw":4152,"./zh-tw.js":4152};function i(e){var t=r(e);return n(t)}function r(e){if(!n.o(s,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return s[e]}i.keys=function(){return Object.keys(s)},i.resolve=r,e.exports=i,i.id=6700},4806:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var s=n(538),i=n(381),r=n.n(i),a=n(7144),o=n.n(a),l=(n(9095),n(7389));const c=s.default.extend({name:"ns-date-range-picker",data:function(){return{dateRange:{startDate:null,endDate:null}}},components:{DateRangePicker:o()},mounted:function(){void 0!==this.field.value&&(this.dateRange=this.field.value)},watch:{dateRange:function(){var e={startDate:r()(this.dateRange.startDate).format("YYYY-MM-DD HH:mm"),endDate:r()(this.dateRange.endDate).format("YYYY-MM-DD HH:mm")};this.field.value=e,this.$emit("change",this)}},methods:{__:l.__,getFormattedDate:function(e){return null!==e?r()(e).format("YYYY-MM-DD HH:mm"):(0,l.__)("N/D")},clearDate:function(){this.dateRange={startDate:null,endDate:null},this.field.value=void 0}},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"]});const d=(0,n(1900).Z)(c,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-auto flex-col mb-2 ns-date-range-picker"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"text-error-primary":"text-primary",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"mt-1 relative flex input-group border-2 rounded-md overflow-hidden focus:shadow-sm",class:e.hasError?"error":""},[e.leading?n("div",{staticClass:"absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none"},[n("span",{staticClass:"text-primary sm:text-sm sm:leading-5"},[e._v("\n "+e._s(e.leading)+"\n ")])]):e._e(),e._v(" "),n("button",{staticClass:"px-3 outline-none bg-error-secondary font-semibold text-white",on:{click:function(t){return e.clearDate()}}},[n("i",{staticClass:"las la-times"})]),e._v(" "),n("date-range-picker",{ref:"picker",staticClass:"w-full flex items-center bg-input-background",attrs:{"locale-data":{firstDay:1,format:"yyyy-mm-dd HH:mm:ss"},timePicker:!0,timePicker24Hour:!0,showWeekNumbers:!0,showDropdowns:!0,autoApply:!1,appendToBody:!0,disabled:e.field.disabled,linkedCalendars:!0},scopedSlots:e._u([{key:"input",fn:function(t){return[n("div",{staticClass:"flex justify-between items-center w-full py-2"},[n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Starts"))+" : "+e._s(e.getFormattedDate(t.startDate)))]),e._v(" "),n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Ends"))+" : "+e._s(e.getFormattedDate(t.endDate)))])])]}}]),model:{value:e.dateRange,callback:function(t){e.dateRange=t},expression:"dateRange"}})],1),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs text-gray-500"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs text-red-400"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e(),e._v(" "),"email"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field must contain a valid email address.")))]})):e._e(),e._v(" "),"invalid"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(t.message))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},2744:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-date-time-picker",props:["field","date"],data:function(){return{visible:!1,hours:0,minutes:0,currentView:"days",currentDay:void 0,moment:i(),months:new Array(11).fill("").map((function(e,t){return t})),daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},computed:{momentCopy:function(){return i()()}},watch:{visible:function(){var e=this;this.visible&&setTimeout((function(){e.$refs.hours.addEventListener("focus",(function(){this.select()})),e.$refs.minutes.addEventListener("focus",(function(){this.select()}))}),100)}},mounted:function(){var e=this;document.addEventListener("mousedown",(function(t){return e.checkClickedItem(t)})),this.field?this.currentDay=[void 0,"",null].includes(this.field.value)?i()():i()(this.field.value):this.currentDay=[void 0,"",null].includes(this.date)?i()():i()(this.date),this.hours=this.currentDay.format("HH"),this.minutes=this.currentDay.format("mm"),this.build()},methods:{__:n(7389).__,erase:function(){this.selectDate()},setYear:function(e){parseInt(e.srcElement.value)>0&&parseInt(e.srcElement.value)<9999&&(this.currentDay.year(e.srcElement.value),this.updateDateTime())},subYear:function(){parseFloat(this.currentDay.format("YYYY"))>0&&(this.currentDay.subtract(1,"year"),this.updateDateTime())},addYear:function(){this.currentDay.add(1,"year"),this.updateDateTime()},toggleView:function(e){var t=this;this.currentView=e,"years"===this.currentView&&setTimeout((function(){t.$refs.year.select()}),100)},setMonth:function(e){this.currentDay.month(e),this.updateDateTime()},detectHoursChange:function(){parseFloat(this.hours)<0&&(this.hours=0),parseFloat(this.hours)>23&&(this.hours=23),this.updateDateTime()},detectMinuteChange:function(){parseFloat(this.minutes)<0&&(this.minutes=0),parseFloat(this.minutes)>59&&(this.minutes=59),this.updateDateTime()},updateDateTime:function(){this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.build(),this.selectDate(this.currentDay)},checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){[void 0].includes(e)?(this.field&&(this.field.value=null),this.$emit("change",null)):(this.currentDay=e,this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.field&&(this.field.value=this.currentDay.format("YYYY/MM/DD HH:mm")),console.log(this.hours,this.minutes),this.$emit("change",this.field?this.field:this.currentDay))},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker mb-2"},[e.field?n("label",{staticClass:"block leading-5 font-medium text-primary"},[e._v(e._s(e.field.label))]):e._e(),e._v(" "),n("div",{staticClass:"ns-button"},[n("button",{staticClass:"rounded cursor-pointer w-full px-1 py-1 flex items-center text-primary",class:e.field?"mt-1 border":"shadow",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),e.currentDay&&e.field?n("span",{staticClass:"mx-1 text-sm"},[null!==e.field.value?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.field.value?n("span",[e._v("N/A")]):e._e()]):e._e(),e._v(" "),e.currentDay&&e.date?n("span",{staticClass:"mx-1 text-sm"},[null!==e.date?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.date?n("span",[e._v("N/A")]):e._e()]):e._e()])]),e._v(" "),e.field?n("p",{staticClass:"text-sm text-secondary py-1"},[e._v(e._s(e.field.description))]):e._e(),e._v(" "),e.visible?n("div",{staticClass:"relative z-10 h-0 w-0"},[n("div",{staticClass:"absolute w-72 shadow-xl rounded ns-box anim-duration-300 zoom-in-entrance flex flex-col",class:e.field?"-mt-4":"mt-2"},["years"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"h-32 flex items-center justify-center text-primary"},[n("div",{staticClass:"rounded input-group info border-2 flex w-2/3 overflow-hidden"},[n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.subYear()}}},[n("i",{staticClass:"las la-minus"})]),e._v(" "),n("input",{ref:"year",staticClass:"p-2 w-24 text-center outline-none",attrs:{type:"text"},domProps:{value:e.currentDay.format("YYYY")},on:{change:function(t){return e.setYear(t)}}}),e._v(" "),n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.addYear()}}},[n("i",{staticClass:"las la-plus"})])])])]):e._e(),e._v(" "),"months"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 border-b border-info-secondary border-dashed"},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-1 gap-0 text-primary"},e._l(e.months,(function(t,s){return n("div",{key:s,staticClass:"h-8 flex justify-center items-center text-sm"},[[n("div",{staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:e.momentCopy.month(t).format("MM")===e.currentDay.format("MM")?"bg-info-secondary text-white border border-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.setMonth(t)}}},[e._v("\n "+e._s(e.momentCopy.format("MMM"))+"\n ")])]],2)})),0)]):e._e(),e._v(" "),"days"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},[n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"text-white border border-info-secondary bg-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2):e._e(),e._v(" "),n("div",{staticClass:"border-t border-numpad-edge w-full p-2"},[n("div",{staticClass:"-mx-1 flex justify-between"},[n("div",{staticClass:"px-1"},[n("div",{staticClass:"-mx-1 flex"},[e.field?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.erase()}}},[n("i",{staticClass:"las la-trash"})])]):e._e(),e._v(" "),"days"!==e.currentView?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.toggleView("days")}}},[n("i",{staticClass:"las la-sign-out-alt"})])]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.hours,expression:"hours"}],ref:"hours",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"HH",type:"number"},domProps:{value:e.hours},on:{change:function(t){return e.detectHoursChange(t)},input:function(t){t.target.composing||(e.hours=t.target.value)}}}),e._v(" "),n("span",{staticClass:"mx-1"},[e._v(":")]),e._v(" "),n("input",{directives:[{name:"model",rawName:"v-model",value:e.minutes,expression:"minutes"}],ref:"minutes",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"mm",type:"number"},domProps:{value:e.minutes},on:{change:function(t){return e.detectMinuteChange(t)},input:function(t){t.target.composing||(e.minutes=t.target.value)}}})])])])])])]):e._e()])}),[],!1,null,null,null).exports},1544:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-datepicker",props:["label","date"],data:function(){return{visible:!1,currentDay:null,daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},mounted:function(){document.addEventListener("click",this.checkClickedItem),this.currentDay=[void 0,null].includes(this.date)?i()():i()(this.date),this.build()},methods:{__:n(7389).__,checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){this.currentDay=e,this.visible=!1,this.$emit("change",e)},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker"},[n("div",{staticClass:"rounded cursor-pointer bg-white shadow px-1 py-1 flex items-center text-gray-700",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),n("span",{staticClass:"mx-1 text-sm"},[n("span",[e._v(e._s(e.label||e.__("Date"))+" : ")]),e._v(" "),e.currentDay?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD")))]):e._e(),e._v(" "),null===e.currentDay?n("span",[e._v(e._s(e.__("N/A")))]):e._e()])]),e._v(" "),e.visible?n("div",{staticClass:"relative h-0 w-0 -mb-2"},[n("div",{staticClass:"w-72 mt-2 shadow rounded bg-white anim-duration-300 zoom-in-entrance flex flex-col"},[n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-gray-700 justify-center"},[e._v(e._s(e.currentDay.format("MMM"))+" "+e._s(e.currentDay.format("YYYY")))]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},[n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"bg-blue-400 text-white border border-blue-500":"hover:bg-gray-100 border border-gray-200",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2),e._v(" "),n("div")])]):e._e()])}),[],!1,null,null,null).exports},1828:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-notice",props:["color"],computed:{actualColor:function(){return this.color||"blue"}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"p-4 border-l-4 text-primary ns-notice",class:e.actualColor,attrs:{role:"alert"}},[n("h2",{staticClass:"font-bold"},[e._t("title")],2),e._v(" "),n("p",[e._t("description"),e._t("default")],2)])}),[],!1,null,null,null).exports},4864:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var s=n(7389);function i(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,s=new Array(t);n0?this.screenValue=parseFloat(this.value/this.number):this.screenValue=this.value||0;var t=new Array(10).fill("").map((function(e,t){return t}));nsHotPress.create("numpad-keys").whenVisible([".is-popup"]).whenPressed(t,(function(t,n){e.inputValue({value:n})})),nsHotPress.create("numpad-backspace").whenVisible([".is-popup"]).whenPressed("backspace",(function(){return e.inputValue({identifier:"backspace"})})),nsHotPress.create("numpad-increase").whenVisible([".is-popup"]).whenPressed("+",(function(){return e.increaseBy({value:1})})),nsHotPress.create("numpad-reduce").whenVisible([".is-popup"]).whenPressed("-",(function(){return e.increaseBy({value:-1})})),nsHotPress.create("numpad-save").whenVisible([".is-popup"]).whenPressed("enter",(function(){return e.inputValue({identifier:"next"})}))},watch:{value:function(){this.value.toString().length>0?this.floating?this.screenValue=Math.round(this.value*this.number).toString():this.screenValue=this.value:this.screenValue=""}},beforeDestroy:function(){nsHotPress.destroy("numpad-backspace"),nsHotPress.destroy("numpad-increase"),nsHotPress.destroy("numpad-reduce"),nsHotPress.destroy("numpad-save")},methods:{increaseBy:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));this.screenValue=(parseFloat(e.value)*t+(parseFloat(this.screenValue)||0)).toString(),this.allSelected=!1},inputValue:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));if("next"!==e.identifier){if("backspace"===e.identifier)this.allSelected?(this.screenValue="0",this.allSelected=!1):this.screenValue=this.screenValue.toString().substr(0,this.screenValue.length-1);else if(e.value.toString().match(/^\d+$/)){if(this.limit>0&&this.screenValue.length>=this.limit)return;this.allSelected?(this.screenValue=e.value.toString(),this.allSelected=!1):(this.screenValue+=""+e.value.toString(),"percentage"===this.mode&&(this.screenValue=this.screenValue>100?100:this.screenValue))}var n=this.floating&&this.screenValue.length>0&&"0"!==this.screenValue?parseFloat(this.screenValue/this.number):this.screenValue;this.$emit("changed",n)}else this.$emit("next",this.floating&&this.screenValue.length>0?parseFloat(this.screenValue/t):this.screenValue)}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-3",attrs:{id:"numpad"}},[e._l(e.keys,(function(t,s){return n("div",{key:s,staticClass:"select-none ns-numpad-key border-l border-b h-24 font-bold flex items-center justify-center cursor-pointer",on:{click:function(n){return e.inputValue(t)}}},[void 0!==t.value?n("span",[e._v(e._s(t.value))]):e._e(),e._v(" "),t.icon?n("i",{staticClass:"las",class:t.icon}):e._e()])})),e._v(" "),e._t("numpad-footer")],2)}),[],!1,null,null,null).exports},3506:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-paginate",props:["pagination"],data:function(){return{page:1,path:""}},mounted:function(){this.path=this.pagination.path},computed:{getPagination:function(){return this.pagination?this.pageNumbers(this.pagination.last_page,this.pagination.current_page):[]}},methods:{gotoPage:function(e){this.page=e,this.$emit("load","".concat(this.path,"?page=").concat(this.page))},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex -mx-1",attrs:{id:"pagination"}},[e.pagination.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.first_page)}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.getPagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info",class:e.page==t?"active":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){return e.gotoPage(t)}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.last_page)}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)}),[],!1,null,null,null).exports},9408:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={data:function(){return{}},name:"ns-switch",mounted:function(){},computed:{_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=t.value===e.field.value,t}))},hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},sizeClass:function(){return" w-1/".concat(this._options.length<=4?this._options.length:4)},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__,setSelected:function(e){this.field.value=e.value,this._options.forEach((function(e){return e.selected=!1})),e.selected=!0,this.$forceUpdate(),this.$emit("change",e.value)}},props:["placeholder","leading","type","field"]};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"mb-2 ns-switch"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"has-error":"is-pristine",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"rounded-lg flex w-52 overflow-hidden shadow my-1",class:e.hasError?"has-error":""},e._l(e._options,(function(t,s){return n("button",{key:s,staticClass:"p-2 text-sm flex-no-wrap outline-none rounded-none",class:t.selected?"selected "+e.sizeClass:"unselected "+e.inputClass+" "+e.sizeClass,attrs:{disabled:t.disabled},on:{click:function(n){return e.setSelected(t)}}},[e._v(e._s(t.label))])})),0),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs ns-description"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs ns-error"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},4255:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var s=n(7757),i=n.n(s),r=n(9671),a=n(8603),o=n(7389),l=n(3601);function c(e,t,n,s,i,r,a){try{var o=e[r](a),l=o.value}catch(e){return void n(e)}o.done?t(l):Promise.resolve(l).then(s,i)}const d={name:"ns-media",props:["popup"],components:{VueUpload:n(2948)},data:function(){return{pages:[{label:(0,o.__)("Upload"),name:"upload",selected:!1},{label:(0,o.__)("Gallery"),name:"gallery",selected:!0}],resources:[],isDragging:!1,response:{data:[],current_page:0,from:0,to:0,next_page_url:"",prev_page_url:"",path:"",per_page:0,total:0,last_page:0,first_page:0},queryPage:1,bulkSelect:!1,files:[]}},mounted:function(){this.popupCloser();var e=this.pages.filter((function(e){return"gallery"===e.name}))[0];this.select(e)},watch:{files:function(){this.uploadFiles()}},computed:{postMedia:function(){return r.kq.applyFilters("http-client-url","/api/nexopos/v4/medias")},currentPage:function(){return this.pages.filter((function(e){return e.selected}))[0]},hasOneSelected:function(){return this.response.data.filter((function(e){return e.selected})).length>0},selectedResource:function(){return this.response.data.filter((function(e){return e.selected}))[0]},csrf:function(){return ns.authentication.csrf},isPopup:function(){return void 0!==this.$popup},user_id:function(){return this.isPopup&&this.$popupParams.user_id||0},panelOpened:function(){return!this.bulkSelect&&this.hasOneSelected}},methods:{popupCloser:a.Z,__:o.__,cancelBulkSelect:function(){this.bulkSelect=!1,this.response.data.forEach((function(e){return e.selected=!1}))},deleteSelected:function(){var e=this;Popup.show(l.default,{title:(0,o.__)("Confirm Your Action"),message:(0,o.__)("You're about to delete selected resources. Would you like to proceed?"),onAction:function(t){t&&r.ih.post("/api/nexopos/v4/medias/bulk-delete",{ids:e.response.data.filter((function(e){return e.selected})).map((function(e){return e.id}))}).subscribe({next:function(t){r.kX.success(t.message).subscribe(),e.loadGallery()},error:function(e){r.kX.error(e.message).subscribe()}})}})},loadUploadScreen:function(){var e=this;setTimeout((function(){e.setDropZone()}),1e3)},setDropZone:function(){var e=this,t=document.getElementById("dropping-zone");t.addEventListener("dragenter",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragleave",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragover",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("drop",(function(t){return e.preventDefaults(t)}),!1);["dragenter","dragover"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!0}))})),["dragleave","drop"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!1}))})),t.addEventListener("drop",(function(t){return e.handleDrop(t)}),!1),this.$refs.files.addEventListener("change",(function(t){return e.processFiles(t.currentTarget.files)}))},uploadFiles:function(){var e,t=this;return(e=i().mark((function e(){var n,s,a;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=t.files.filter((function(e){return!1===e.uploaded&&0===e.progress&&!1===e.failed})),s=i().mark((function e(t){var s;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return s=n[t],e.prev=1,s.progress=1,e.next=5,new Promise((function(e,t){var n=new FormData;n.append("file",s.file),r.ih.post("/api/nexopos/v4/medias",n,{headers:{"Content-Type":"multipart/form-data"}}).subscribe({next:function(t){s.uploaded=!0,s.progress=100,e(t)},error:function(e){t(e)}})}));case 5:e.sent,e.next=11;break;case 8:e.prev=8,e.t0=e.catch(1),s.failed=!0;case 11:case"end":return e.stop()}}),e,null,[[1,8]])})),a=0;case 3:if(!(a0&&void 0!==arguments[0]?arguments[0]:null;t=null===t?this.queryPage:t,this.queryPage=t,r.ih.get("/api/nexopos/v4/medias?page=".concat(t,"&user_id=").concat(this.user_id)).subscribe((function(t){t.data.forEach((function(e){return e.selected=!1})),e.response=t}))},useSelectedEntries:function(){this.$popupParams.resolve({event:"use-selected",value:this.response.data.filter((function(e){return e.selected}))}),this.$popup.close()},selectResource:function(e){var t=this;this.bulkSelect||this.response.data.forEach((function(n,s){s!==t.response.data.indexOf(e)&&(n.selected=!1)})),e.selected=!e.selected}}};const u=(0,n(1900).Z)(d,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex md:flex-row flex-col ns-box shadow-xl overflow-hidden",class:e.isPopup?"w-6/7-screen h-6/7-screen":"w-full h-full",attrs:{id:"ns-media"}},[n("div",{staticClass:"sidebar w-48 md:h-full flex-shrink-0"},[n("h3",{staticClass:"text-xl font-bold my-4 text-center"},[e._v(e._s(e.__("Medias Manager")))]),e._v(" "),n("ul",{staticClass:"sidebar-menus flex md:block"},e._l(e.pages,(function(t,s){return n("li",{key:s,staticClass:"py-2 px-3 cursor-pointer border-l-8",class:t.selected?"active":"",on:{click:function(n){return e.select(t)}}},[e._v(e._s(t.label))])})),0)]),e._v(" "),"upload"===e.currentPage.name?n("div",{staticClass:"content w-full overflow-hidden flex"},[n("div",{staticClass:"flex flex-auto m-2 p-2 flex-col border-info-primary items-center justify-center",class:e.isDragging?"border-dashed border-2":"",attrs:{id:"dropping-zone"},on:{click:function(t){return e.triggerManualUpload()}}},[n("h3",{staticClass:"text-lg md:text-xl font-bold text-center text-primary mb-4"},[e._v(e._s(e.__("Click Here Or Drop Your File To Upload")))]),e._v(" "),n("input",{ref:"files",staticStyle:{display:"none"},attrs:{type:"file",name:"",multiple:"",id:""}}),e._v(" "),n("div",{staticClass:"rounded w-full md:w-2/3 text-primary h-56 overflow-y-auto ns-scrollbar p-2"},[n("ul",e._l(e.files,(function(t,s){return n("li",{key:s,staticClass:"p-2 mb-2 shadow ns-media-upload-item flex items-center justify-between rounded"},[n("span",[e._v(e._s(t.file.name))]),e._v(" "),n("span",{staticClass:"rounded bg-info-primary flex items-center justify-center text-xs p-2"},[e._v(e._s(t.progress)+"%")])])})),0)])])]):e._e(),e._v(" "),"gallery"===e.currentPage.name?n("div",{staticClass:"content flex-col w-full overflow-hidden flex"},[e.popup?n("div",{staticClass:"p-2 flex flex-shrink-0 justify-between"},[n("div"),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.popup.close()}}})],1)]):e._e(),e._v(" "),n("div",{staticClass:"flex flex-auto overflow-hidden"},[n("div",{staticClass:"shadow ns-grid flex flex-auto flex-col overflow-y-auto ns-scrollbar"},[n("div",{staticClass:"flex flex-auto"},[n("div",{staticClass:"p-2 overflow-x-auto"},[n("div",{staticClass:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-3 xl:grid-cols-4"},e._l(e.response.data,(function(t,s){return n("div",{key:s},[n("div",{staticClass:"p-2"},[n("div",{staticClass:"rounded-lg aspect-square bg-gray-500 m-2 overflow-hidden flex items-center justify-center",class:t.selected?"ns-media-image-selected ring-4":"",on:{click:function(n){return e.selectResource(t)}}},[n("img",{staticClass:"object-cover h-full",attrs:{src:t.sizes.thumb,alt:t.name}})])])])})),0)]),e._v(" "),0===e.response.data.length?n("div",{staticClass:"flex flex-auto items-center justify-center"},[n("h3",{staticClass:"text-2xl font-bold"},[e._v(e._s(e.__("Nothing has already been uploaded")))])]):e._e()])]),e._v(" "),n("div",{staticClass:"ns-media-preview-panel hidden lg:block w-64 flex-shrink-0 ",attrs:{id:"preview"}},[n("div",{staticClass:"h-64 bg-gray-800 flex items-center justify-center"},[e.panelOpened?n("img",{attrs:{src:e.selectedResource.sizes.thumb,alt:e.selectedResource.name}}):e._e()]),e._v(" "),e.panelOpened?n("div",{staticClass:"p-4 text-gray-700 text-sm",attrs:{id:"details"}},[n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("File Name"))+": ")]),n("span",[e._v(e._s(e.selectedResource.name))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("Uploaded At"))+":")]),n("span",[e._v(e._s(e.selectedResource.created_at))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("By"))+" :")]),n("span",[e._v(e._s(e.selectedResource.user.username))])])]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex ns-media-footer flex-shrink-0 justify-between"},[n("div",{staticClass:"flex -mx-2 flex-shrink-0"},[n("div",{staticClass:"px-2 flex-shrink-0 flex"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.cancelBulkSelect()}}},[n("i",{staticClass:"las la-times"})])]):e._e(),e._v(" "),e.hasOneSelected&&!e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){e.bulkSelect=!0}}},[n("i",{staticClass:"las la-check-circle"})])]):e._e(),e._v(" "),e.hasOneSelected?n("div",{staticClass:"ns-button error"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.deleteSelected()}}},[n("i",{staticClass:"las la-trash"})])]):e._e()])])]),e._v(" "),n("div",{staticClass:"flex-shrink-0 -mx-2 flex"},[n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[n("div",{staticClass:"ns-button",class:1===e.response.current_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:1===e.response.current_page},on:{click:function(t){return e.loadGallery(e.response.current_page-1)}}},[e._v(e._s(e.__("Previous")))])]),e._v(" "),n("hr",{staticClass:"border-r border-gray-700"}),e._v(" "),n("div",{staticClass:"ns-button",class:e.response.current_page===e.response.last_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:e.response.current_page===e.response.last_page},on:{click:function(t){return e.loadGallery(e.response.current_page+1)}}},[e._v(e._s(e.__("Next")))])])])]),e._v(" "),e.popup&&e.hasOneSelected?n("div",{staticClass:"px-2"},[n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"rounded shadow p-2 text-sm",on:{click:function(t){return e.useSelectedEntries()}}},[e._v(e._s(e.__("Use Selected")))])])]):e._e()])])]):e._e()])}),[],!1,null,null,null).exports},3601:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>o});var s=n(7389),i=n(6386),r=n(8603);const a={data:function(){return{title:"",message:""}},computed:{size:function(){return this.$popupParams.size||"h-full w-full"}},mounted:function(){this.title=this.$popupParams.title,this.message=this.$popupParams.message,this.popupCloser()},methods:{__:s.__,popupResolver:i.Z,popupCloser:r.Z,emitAction:function(e){this.$popupParams.onAction(e),this.$popup.close()}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-col shadow-lg w-5/7-screen md:w-4/7-screen lg:w-2/7-screen",class:e.size,attrs:{id:"confirm-popup"}},[n("div",{staticClass:"flex items-center justify-center flex-col flex-auto p-4"},[n("h2",{staticClass:"text-xl md:text-3xl font-body text-center"},[e._v(e._s(e.title))]),e._v(" "),n("p",{staticClass:"py-4 text-sm md:text-base text-center"},[e._v(e._s(e.message))])]),e._v(" "),n("div",{staticClass:"action-buttons flex border-t"},[n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!0)}}},[e._v(e._s(e.__("Yes")))]),e._v(" "),n("hr",{staticClass:"border-r h-16"}),e._v(" "),n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!1)}}},[e._v(e._s(e.__("No")))])])])}),[],!1,null,null,null).exports}},e=>{e.O(0,[898],(()=>{return t=8108,e(e.s=t);var t}));e.O()}]); \ No newline at end of file +(self.webpackChunknexopos_4x=self.webpackChunknexopos_4x||[]).push([[743,198],{6623:(e,t,n)=>{"use strict";var s=n(538),i=n(8829),r=function(){return n.e(380).then(n.bind(n,6084))},a=function(){return n.e(202).then(n.bind(n,7202))},o=function(){return n.e(877).then(n.bind(n,4877))},l=function(){return n.e(919).then(n.bind(n,5919))},c=(window.nsState,window.nsScreen,window.nsExtraComponents);window.nsComponents=Object.assign(i,c,{nsRegister:r,nsLogin:a,nsPasswordLost:o,nsNewPassword:l}),window.authVueComponent=new s.default({el:"#page-container",components:Object.assign(Object.assign({nsLogin:a,nsRegister:r,nsPasswordLost:o,nsNewPassword:l},c),i)})},7700:(e,t,n)=>{"use strict";n.d(t,{l:()=>V,kq:()=>Z,ih:()=>Y,kX:()=>H});var s=n(6486),i=n(8945),r=n(6300),a=n(8345),o=n(9093),l=n(9248),c=n(230);function d(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{};return this._request("post",e,t,n)}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("get",e,void 0,t)}},{key:"delete",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return this._request("delete",e,void 0,t)}},{key:"put",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this._request("put",e,t,n)}},{key:"response",get:function(){return this._lastRequestData}},{key:"_request",value:function(e,t){var n=this,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return t=Z.applyFilters("http-client-url",t.replace(/\/$/,"")),this._subject.next({identifier:"async.start",url:t,data:s}),new c.y((function(r){n._client[e](t,s,Object.assign(Object.assign({},n._client.defaults[e]),i)).then((function(e){n._lastRequestData=e,r.next(e.data),r.complete(),n._subject.next({identifier:"async.stop"})})).catch((function(e){var t;r.error((null===(t=e.response)||void 0===t?void 0:t.data)||e.response||e),n._subject.next({identifier:"async.stop"})}))}))}},{key:"subject",value:function(){return this._subject}},{key:"emit",value:function(e){var t=e.identifier,n=e.value;this._subject.next({identifier:t,value:n})}}],n&&d(t.prototype,n),s&&d(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}(),f=n(3);function p(e,t){for(var n=0;n=1e3){for(var n,s=Math.floor((""+e).length/3),i=2;i>=1;i--){if(((n=parseFloat((0!=s?e/Math.pow(1e3,s):e).toPrecision(i)))+"").replace(/[^a-zA-Z 0-9]+/g,"").length<=2)break}n%1!=0&&(n=n.toFixed(1)),t=n+["","k","m","b","t"][s]}return t})),E=n(9020),S=n(7794);function P(e,t){for(var n=0;n0&&window.outerWidth<=480:this.breakpoint="xs";break;case window.outerWidth>480&&window.outerWidth<=640:this.breakpoint="sm";break;case window.outerWidth>640&&window.outerWidth<=1024:this.breakpoint="md";break;case window.outerWidth>1024&&window.outerWidth<=1280:this.breakpoint="lg";break;case window.outerWidth>1280:this.breakpoint="xl"}}}])&&q(t.prototype,n),s&&q(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()),I=new b({sidebar:["xs","sm","md"].includes(N.breakpoint)?"hidden":"visible"});Y.defineClient(i.Z),window.nsEvent=V,window.nsHttpClient=Y,window.nsSnackBar=H,window.nsCurrency=E.W,window.nsTruncate=S.b,window.nsRawCurrency=E.f,window.nsAbbreviate=$,window.nsState=I,window.nsUrl=L,window.nsScreen=N,window.ChartJS=r,window.EventEmitter=h,window.Popup=x.G,window.RxJS=y,window.FormValidation=k.Z,window.nsCrudHandler=R},8829:(e,t,n)=>{"use strict";n.r(t),n.d(t,{nsAvatar:()=>Q,nsButton:()=>o,nsCheckbox:()=>p,nsCkeditor:()=>O,nsCloseButton:()=>j,nsCrud:()=>U,nsCrudForm:()=>g,nsDate:()=>w,nsDateRangePicker:()=>J.Z,nsDateTimePicker:()=>A.Z,nsDatepicker:()=>ee.Z,nsField:()=>_.P,nsIconButton:()=>$,nsInput:()=>c,nsLink:()=>l,nsMediaInput:()=>C,nsMenu:()=>r,nsMultiselect:()=>x,nsNotice:()=>K.Z,nsNumpad:()=>W.Z,nsPaginate:()=>te.Z,nsSearch:()=>se,nsSelect:()=>u,nsSelectAudio:()=>f,nsSpinner:()=>v,nsSubmenu:()=>a,nsSwitch:()=>M.Z,nsTableRow:()=>m,nsTabs:()=>T,nsTabsItem:()=>F,nsTextarea:()=>y});var s=n(538),i=n(7700),r=s.default.component("ns-menu",{data:function(){return{defaultToggledState:!1,_save:0}},props:["href","label","icon","notification","toggled","identifier"],template:'\n \n ',mounted:function(){var e=this;this.defaultToggledState=void 0!==this.toggled?this.toggled:this.defaultToggledState,i.l.subject().subscribe((function(t){t.value!==e.identifier&&(e.defaultToggledState=!1)}))},methods:{toggleEmit:function(){var e=this;this.toggle().then((function(t){t&&i.l.emit({identifier:"side-menu.open",value:e.identifier})}))},toggle:function(){var e=this;return new Promise((function(t,n){0===e.href.length&&(e.defaultToggledState=!e.defaultToggledState,t(e.defaultToggledState))}))}}}),a=s.default.component("ns-submenu",{data:function(){return{}},props:["href","label","active"],mounted:function(){},template:'\n
    \n
  • \n \n \n \n
  • \n
    \n '}),o=s.default.component("ns-button",{data:function(){return{clicked:!1,_save:0}},props:["type","disabled","link","href","routerLink","to"],template:'\n
    \n \n \n \n
    \n ',mounted:function(){},computed:{isDisabled:function(){return this.disabled&&(0===this.disabled.length||"disabled"===this.disabled||this.disabled)}}}),l=s.default.component("ns-link",{data:function(){return{clicked:!1,_save:0}},props:["type","to","href","target"],template:'\n
    \n \n \n
    \n ',computed:{buttonclass:function(){switch(this.type){case"info":return"shadow bg-blue-400 text-white";case"success":return"shadow bg-green-400 text-white";case"error":return"shadow bg-red-400 text-white";case"warning":return"shadow bg-orange-400 text-white";default:return"shadow bg-white text-gray-800"}}}}),c=s.default.component("ns-input",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),d=n(3632),u=s.default.component("ns-select",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},mounted:function(){},methods:{__:d.__},template:'\n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),f=s.default.component("ns-select-audio",{data:function(){return{}},props:["name","placeholder","field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__:d.__,playSelectedSound:function(){this.field.value.length>0&&new Audio(this.field.value).play()}},template:'\n
    \n \n
    \n
    \n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),p=s.default.component("ns-checkbox",{data:function(){return{}},props:["checked","field","label"],template:'\n
    \n
    \n \n
    \n {{ label }}\n {{ field.label }}\n
    \n ',computed:{isChecked:function(){return this.field?this.field.value:this.checked}},methods:{toggleIt:function(){void 0!==this.field&&(this.field.value=!this.field.value),this.$emit("change",!this.checked)}}}),h=n(6979),m=s.default.component("ns-table-row",{props:["options","row","columns","prependOptions","showOptions"],data:function(){return{optionsToggled:!1}},mounted:function(){},methods:{__:d.__,sanitizeHTML:function(e){var t=document.createElement("div");t.innerHTML=e;for(var n=t.getElementsByTagName("script"),s=n.length;s--;)n[s].parentNode.removeChild(n[s]);return t.innerHTML},getElementOffset:function(e){var t=e.getBoundingClientRect();return{top:t.top+window.pageYOffset,left:t.left+window.pageXOffset}},toggleMenu:function(e){var t=this;if(this.row.$toggled=!this.row.$toggled,this.$emit("toggled",this.row),this.row.$toggled)setTimeout((function(){var e=t.$el.querySelectorAll(".relative > .absolute")[0],n=t.$el.querySelectorAll(".relative")[0],s=t.getElementOffset(n);e.style.top=s.top+"px",e.style.left=s.left+"px",n.classList.remove("relative"),n.classList.add("dropdown-holder")}),100);else{var n=this.$el.querySelectorAll(".dropdown-holder")[0];n.classList.remove("dropdown-holder"),n.classList.add("relative")}},handleChanged:function(e){this.row.$checked=e,this.$emit("updated",this.row)},triggerAsync:function(e){var t=this;e.confirm?confirm(e.confirm.message)&&i.ih[e.type.toLowerCase()](e.url).subscribe((function(e){i.kX.success(e.message).subscribe(),t.$emit("reload",t.row)}),(function(e){t.toggleMenu(),i.kX.error(e.message).subscribe()})):(i.l.emit({identifier:"ns-table-row-action",value:{action:e,row:this.row,component:this}}),this.toggleMenu())},triggerPopup:function(e,t){var n=window.nsExtraComponents[e.component];if(e.component)return n?new Promise((function(s,i){h.G.show(n,{resolve:s,reject:i,row:t,action:e})})):i.kX.error((0,d.__)('Unable to load the component "'.concat(e.component,'". Make sure the component is registered to "nsExtraComponents".'))).subscribe();this.triggerAsync(e)}},template:'\n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n \n \n \n \n \n
    \x3c!-- flex items-center justify-center --\x3e\n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n '}),v=s.default.component("ns-spinner",{data:function(){return{}},mounted:function(){},computed:{validatedSize:function(){return this.size||24},validatedBorder:function(){return this.border||8},validatedAnimation:function(){return this.animation||"fast"}},props:["color","size","border"],template:"\n
    \n
    \n
    \n "}),b=n(4679),g=s.default.component("ns-crud-form",{data:function(){return{form:{},globallyChecked:!1,formValidation:new b.Z,rows:[]}},mounted:function(){this.loadForm()},props:["src","create-url","field-class","return-url","submit-url","submit-method","disable-tabs"],computed:{activeTabFields:function(){for(var e in this.form.tabs)if(this.form.tabs[e].active)return this.form.tabs[e].fields;return[]}},methods:{__:d.__,toggle:function(e){for(var t in this.form.tabs)this.form.tabs[t].active=!1;this.form.tabs[e].active=!0},handleShowOptions:function(e){this.rows.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},submit:function(){var e=this;return this.formValidation.validateForm(this.form).length>0?i.kX.error(this.$slots["error-invalid"]?this.$slots["error-invalid"][0].text:"No error message provided for having an invalid form.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():(this.formValidation.disableForm(this.form),void 0===this.submitUrl?i.kX.error(this.$slots["error-no-submit-url"]?this.$slots["error-no-submit-url"][0].text:"No error message provided for not having a valid submit url.",this.$slots.okay?this.$slots.okay[0].text:"OK").subscribe():void i.ih[this.submitMethod?this.submitMethod.toLowerCase():"post"](this.submitUrl,this.formValidation.extractForm(this.form)).subscribe((function(t){if("success"===t.status){if(e.submitMethod&&"post"===e.submitMethod.toLowerCase()&&!1!==e.returnUrl)return document.location=t.data.editUrl||e.returnUrl;i.kX.info(t.message,(0,d.__)("Okay"),{duration:3e3}).subscribe(),e.$emit("save",t)}e.formValidation.enableForm(e.form)}),(function(t){i.kX.error(t.message,void 0,{duration:5e3}).subscribe(),void 0!==t.data&&e.formValidation.triggerError(e.form,t.data),e.formValidation.enableForm(e.form)})))},handleGlobalChange:function(e){this.globallyChecked=e,this.rows.forEach((function(t){return t.$checked=e}))},loadForm:function(){var e=this;i.ih.get("".concat(this.src)).subscribe({next:function(t){e.form=e.parseForm(t.form),i.kq.doAction("ns-crud-form-loaded",e),e.$emit("updated",e.form)},error:function(e){i.kX.error(e.message,"OKAY",{duration:0}).subscribe()}})},parseForm:function(e){e.main.value=void 0===e.main.value?"":e.main.value,e.main=this.formValidation.createFields([e.main])[0];var t=0;for(var n in e.tabs)0===t&&(e.tabs[n].active=!0),e.tabs[n].active=void 0!==e.tabs[n].active&&e.tabs[n].active,e.tabs[n].fields=this.formValidation.createFields(e.tabs[n].fields),t++;return e}},template:'\n
    \n
    \n \n
    \n
    \n
    \n
    \n \n \n
    \n \n
    \n
    \n
    \n
    {{ tab.label }}
    \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n \n
    \n
    \n
    \n
    \n
    \n
    \n '}),y=s.default.component("ns-textarea",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n This field is required.\n This field must contain a valid email address.\n {{ error.message }}\n

    \n
    \n '}),_=n(4110),x=s.default.component("ns-multiselect",{data:function(){return{showPanel:!1,search:""}},props:["field"],computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=void 0!==t.selected&&t.selected,e.field.value&&e.field.value.includes(t.value)&&(t.selected=!0),t}))}},methods:{__:d.__,addOption:function(e){this.field.disabled||(this.$emit("addOption",e),this.$forceUpdate(),setTimeout((function(){}),100))},removeOption:function(e,t){var n=this;if(!this.field.disabled)return t.preventDefault(),t.stopPropagation(),this.$emit("removeOption",e),this.$forceUpdate(),setTimeout((function(){n.search=""}),100),!1}},mounted:function(){var e=this;this.field.value&&this.field.value.reverse().forEach((function(t){var n=e.field.options.filter((function(e){return e.value===t}));n.length>=0&&e.addOption(n[0])}))},template:'\n
    \n \n
    \n
    \n
    \n
    \n
    \n {{ option.label }}\n \n
    \n
    \n
    \n
    \n \n \n
    \n
    \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n
    \n '}),w=s.default.component("ns-date",{data:function(){return{}},mounted:function(){},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-input-edge cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),k=n(1274),C=s.default.component("ns-media-input",{template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n
    \n
    \n \n
    \n \n \n
    \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n ',computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":"ns-enabled"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},data:function(){return{}},props:["placeholder","leading","type","field"],mounted:function(){},methods:{toggleMedia:function(){var e=this;new Promise((function(t,n){h.G.show(k.default,Object.assign({resolve:t,reject:n},e.field.data||{}))})).then((function(t){"use-selected"===t.event&&(e.field.data&&"url"!==e.field.data.type?e.field.data&&"model"!==e.field.data.type||(e.field.value=t.value[0]):e.field.value=t.value[0].sizes.original,e.$forceUpdate())}))}}}),j=s.default.component("ns-close-button",{template:'\n \n ',methods:{clicked:function(e){this.$emit("click",e)}}}),$=s.default.component("ns-icon-button",{template:'\n \n ',props:["className","buttonClass","type"],methods:{clicked:function(e){this.$emit("click",e)}}}),E=n(1272),S=n.n(E),P=n(5234),D=n.n(P),O=s.default.component("ns-ckeditor",{data:function(){return{editor:D()}},components:{ckeditor:S().component},mounted:function(){},methods:{__:d.__},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"p-8":"p-2"}},props:["placeholder","leading","type","field"],template:'\n
    \n \n
    \n
    \n \n {{ leading }}\n \n
    \n \n
    \n

    \n

    \n {{ __( \'This field is required.\' ) }}\n {{ __( \'This field must contain a valid email address.\' ) }}\n {{ error.message }}\n

    \n
    \n '}),T=s.default.component("ns-tabs",{data:function(){return{childrens:[]}},props:["active"],computed:{activeComponent:function(){var e=this.$children.filter((function(e){return e.active}));return e.length>0&&e[0]}},methods:{toggle:function(e){this.$emit("active",e.identifier),this.$emit("changeTab",e.identifier)}},mounted:function(){this.childrens=this.$children},template:'\n
    \n
    \n
    {{ tab.label }}
    \n
    \n \n
    \n '}),F=s.default.component("ns-tabs-item",{data:function(){return{}},mounted:function(){},props:["label","identifier","padding"],template:'\n
    \n \n
    \n '}),M=n(3164),A=n(9765),q=n(7757),z=n.n(q),V=n(914),Y=n(665),H=n(2830);const L={data:function(){return{fields:[],validation:new b.Z}},methods:{__:d.__,popupCloser:Y.Z,popupResolver:H.Z,closePopup:function(){this.popupResolver(!1)},useFilters:function(){this.popupResolver(this.validation.extractFields(this.fields))},clearFilters:function(){this.fields.forEach((function(e){return e.value=""})),this.popupResolver(null)}},mounted:function(){this.fields=this.validation.createFields(this.$popupParams.queryFilters),this.popupCloser()}};var R=n(1900);const Z=(0,R.Z)(L,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-box shadow-lg w-95vw h-95vh md:w-2/5-screen overflow-hidden md:h-5/6-screen flex flex-col"},[n("div",{staticClass:"p-2 border-b ns-box-header flex justify-between items-center"},[n("h3",[e._v(e._s(e.__("Search Filters")))]),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.closePopup()}}})],1)]),e._v(" "),n("div",{staticClass:"p-2 ns-box-body flex-auto overflow-y-auto"},e._l(e.fields,(function(e,t){return n("ns-field",{key:t,attrs:{field:e}})})),1),e._v(" "),n("div",{staticClass:"p-2 flex justify-between ns-box-footer border-t"},[n("div",[n("ns-button",{attrs:{type:"error"},on:{click:function(t){return e.clearFilters()}}},[e._v(e._s(e.__("Clear Filters")))])],1),e._v(" "),n("div",[n("ns-button",{attrs:{type:"info"},on:{click:function(t){return e.useFilters()}}},[e._v(e._s(e.__("Use Filters")))])],1)])])}),[],!1,null,null,null).exports;var N=function(e,t,n,s){return new(n||(n=Promise))((function(i,r){function a(e){try{l(s.next(e))}catch(e){r(e)}}function o(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,o)}l((s=s.apply(e,t||[])).next())}))};const I={data:function(){return{prependOptions:!1,showOptions:!0,isRefreshing:!1,sortColumn:"",searchInput:"",queryFiltersString:"",searchQuery:"",page:1,bulkAction:"",bulkActions:[],queryFilters:[],withFilters:!1,columns:[],selectedEntries:[],globallyChecked:!1,result:{current_page:null,data:[],first_page_url:null,from:null,last_page:null,last_page_url:null,next_page_url:null,path:null,per_page:null,prev_page_url:null,to:null,total:null}}},name:"ns-crud",mounted:function(){void 0!==this.identifier&&nsCrudHandler.defineInstance(this.identifier,this),this.loadConfig()},props:["src","create-url","mode","identifier","queryParams"],computed:{getParsedSrc:function(){return"".concat(this.src,"?").concat(this.sortColumn).concat(this.searchQuery).concat(this.queryFiltersString).concat(this.queryPage).concat(this.getQueryParams()?"&"+this.getQueryParams():"")},showQueryFilters:function(){return this.queryFilters.length>0},getSelectedAction:function(){var e=this,t=this.bulkActions.filter((function(t){return t.identifier===e.bulkAction}));return t.length>0&&t[0]},pagination:function(){return this.result?this.pageNumbers(this.result.last_page,this.result.current_page):[]},queryPage:function(){return this.result?"&page=".concat(this.page):""},resultInfo:function(){return(0,d.__)("displaying {perPage} on {items} items").replace("{perPage}",this.result.total).replace("{items}",this.result.total)}},methods:{__:d.__,getQueryParams:function(){var e=this;return this.queryParams?Object.keys(this.queryParams).map((function(t){return"".concat(t,"=").concat(e.queryParams[t])})).join("&"):""},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))},downloadContent:function(){nsHttpClient.post("".concat(this.src,"/export?").concat(this.getParsedSrc),{entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe((function(e){setTimeout((function(){return document.location=e.url}),300),i.kX.success((0,d.__)("The document has been generated.")).subscribe()}),(function(e){i.kX.error(e.message||(0,d.__)("Unexpected error occured.")).subscribe()}))},clearSelectedEntries:function(){var e=this;h.G.show(V.default,{title:(0,d.__)("Clear Selected Entries ?"),message:(0,d.__)("Would you like to clear all selected entries ?"),onAction:function(t){t&&(e.selectedEntries=[])}})},refreshRow:function(e){if(!0===e.$checked){0===this.selectedEntries.filter((function(t){return t.$id===e.$id})).length&&this.selectedEntries.push(e)}else{var t=this.selectedEntries.filter((function(t){return t.$id===e.$id}));if(t.length>0){var n=this.selectedEntries.indexOf(t[0]);this.selectedEntries.splice(n,1)}}},handleShowOptions:function(e){this.result.data.forEach((function(t){t.$id!==e.$id&&(t.$toggled=!1)}))},handleGlobalChange:function(e){var t=this;this.globallyChecked=e,this.result.data.forEach((function(n){n.$checked=e,t.refreshRow(n)}))},loadConfig:function(){var e=this;nsHttpClient.get("".concat(this.src,"/config?").concat(this.getQueryParams())).subscribe((function(t){e.columns=t.columns,e.bulkActions=t.bulkActions,e.queryFilters=t.queryFilters,e.prependOptions=t.prependOptions,e.showOptions=t.showOptions,e.refresh()}),(function(e){i.kX.error(e.message,"OK",{duration:!1}).subscribe()}))},cancelSearch:function(){this.searchInput="",this.search()},search:function(){this.searchInput?this.searchQuery="&search=".concat(this.searchInput):this.searchQuery="",this.refresh()},sort:function(e){for(var t in this.columns)t!==e&&(this.columns[t].$sorted=!1,this.columns[t].$direction="");switch(this.columns[e].$sorted=!0,this.columns[e].$direction){case"asc":this.columns[e].$direction="desc";break;case"desc":this.columns[e].$direction="";break;case"":this.columns[e].$direction="asc"}["asc","desc"].includes(this.columns[e].$direction)?this.sortColumn="active=".concat(e,"&direction=").concat(this.columns[e].$direction):this.sortColumn="",this.$emit("sort",this.columns[e]),this.refresh()},bulkDo:function(){var e=this;return this.bulkAction?this.selectedEntries.length>0?confirm(this.getSelectedAction.confirm||this.$slots["error-bulk-confirmation"]||(0,d.__)("Would you like to perform the selected bulk action on the selected entries ?"))?nsHttpClient.post("".concat(this.src,"/bulk-actions"),{action:this.bulkAction,entries:this.selectedEntries.map((function(e){return e.$id}))}).subscribe({next:function(t){i.kX.info(t.message).subscribe(),e.selectedEntries=[],e.refresh()},error:function(e){i.kX.error(e.message).subscribe()}}):void 0:i.kX.error(this.$slots["error-no-selection"]?this.$slots["error-no-selection"][0].text:(0,d.__)("No selection has been made.")).subscribe():i.kX.error(this.$slots["error-no-action"]?this.$slots["error-no-action"][0].text:(0,d.__)("No action has been selected.")).subscribe()},openQueryFilter:function(){return N(this,void 0,void 0,z().mark((function e(){var t,n=this;return z().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,console.log(Z),e.next=4,new Promise((function(e,t){h.G.show(Z,{resolve:e,reject:t,queryFilters:n.queryFilters})}));case 4:t=e.sent,this.withFilters=!1,this.queryFiltersString="",null!==t&&(this.withFilters=!0,this.queryFiltersString="&queryFilters="+encodeURIComponent(JSON.stringify(t))),this.refresh(),e.next=13;break;case 11:e.prev=11,e.t0=e.catch(0);case 13:case"end":return e.stop()}}),e,this,[[0,11]])})))},refresh:function(){var e=this;this.globallyChecked=!1,this.isRefreshing=!0,nsHttpClient.get("".concat(this.getParsedSrc)).subscribe((function(t){t.data=t.data.map((function(t){return e.selectedEntries.filter((function(e){return e.$id===t.$id})).length>0&&(t.$checked=!0),t})),e.isRefreshing=!1,e.result=t,e.page=t.current_page}),(function(t){e.isRefreshing=!1,i.kX.error(t.message).subscribe()}))}}};const U=(0,R.Z)(I,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"w-full rounded-lg",class:"light"!==e.mode?"shadow mb-8":"",attrs:{id:"crud-table"}},["light"!==e.mode?n("div",{staticClass:"p-2 border-b border-popup-surface flex flex-col md:flex-row justify-between flex-wrap",attrs:{id:"crud-table-header"}},[n("div",{staticClass:"w-full md:w-auto -mx-2 mb-2 md:mb-0 flex",attrs:{id:"crud-search-box"}},[e.createUrl?n("div",{staticClass:"px-2 flex items-center justify-center"},[n("a",{staticClass:"rounded-full ns-crud-button text-sm h-10 flex items-center justify-center cursor-pointer px-3 outline-none border",attrs:{href:e.createUrl||"#"}},[n("i",{staticClass:"las la-plus"})])]):e._e(),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded-full p-1 ns-crud-input flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchInput,expression:"searchInput"}],staticClass:"w-36 md:w-auto bg-transparent outline-none px-2",attrs:{type:"text"},domProps:{value:e.searchInput},on:{input:function(t){t.target.composing||(e.searchInput=t.target.value)}}}),e._v(" "),n("button",{staticClass:"rounded-full w-8 h-8 outline-none ns-crud-input-button",on:{click:function(t){return e.search()}}},[n("i",{staticClass:"las la-search"})]),e._v(" "),e.searchQuery?n("button",{staticClass:"ml-1 rounded-full w-8 h-8 bg-error-secondary text-white outline-none hover:bg-error-tertiary",on:{click:function(t){return e.cancelSearch()}}},[n("i",{staticClass:"las la-times"})]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2 flex items-center justify-center"},[n("button",{staticClass:"rounded-full text-sm h-10 px-3 outline-none border ns-crud-button",on:{click:function(t){return e.refresh()}}},[n("i",{staticClass:"las la-sync",class:e.isRefreshing?"animate-spin":""})])]),e._v(" "),e.showQueryFilters?n("div",{staticClass:"px-2 flex items-center"},[n("button",{staticClass:"ns-crud-button border rounded-full text-sm h-10 px-3 outline-none",class:e.withFilters?"table-filters-enabled":"table-filters-disabled",on:{click:function(t){return e.openQueryFilter()}}},[e.withFilters?e._e():n("i",{staticClass:"las la-filter"}),e._v(" "),e.withFilters?n("i",{staticClass:"las la-check"}):e._e(),e._v(" "),e.withFilters?e._e():n("span",[e._v(e._s(e.__("Filters")))]),e._v(" "),e.withFilters?n("span",[e._v(e._s(e.__("Has Filters")))]):e._e()])]):e._e()]),e._v(" "),n("div",{staticClass:"-mx-1 flex flex-wrap w-full md:w-auto",attrs:{id:"crud-buttons"}},[e.selectedEntries.length>0?n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 outline-none ns-crud-button border",on:{click:function(t){return e.clearSelectedEntries()}}},[n("i",{staticClass:"lar la-check-square"}),e._v(" "+e._s(e.__("{entries} entries selected").replace("{entries}",e.selectedEntries.length))+"\n ")])]):e._e(),e._v(" "),n("div",{staticClass:"px-1 flex items-center"},[n("button",{staticClass:"flex justify-center items-center rounded-full text-sm h-10 px-3 ns-crud-button border outline-none",on:{click:function(t){return e.downloadContent()}}},[n("i",{staticClass:"las la-download"}),e._v(" "+e._s(e.__("Download")))])])])]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"overflow-x-auto flex-auto"},[Object.values(e.columns).length>0?n("table",{staticClass:"table ns-table w-full"},[n("thead",[n("tr",[n("th",{staticClass:"text-center px-2 border w-16 py-2"},[n("ns-checkbox",{attrs:{checked:e.globallyChecked},on:{change:function(t){return e.handleGlobalChange(t)}}})],1),e._v(" "),e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e(),e._v(" "),e._l(e.columns,(function(t,s){return n("th",{key:s,staticClass:"cursor-pointer justify-betweenw-40 border text-left px-2 py-2",style:{"min-width":t.width||"auto"},on:{click:function(t){return e.sort(s)}}},[n("div",{staticClass:"w-full flex justify-between items-center"},[n("span",{staticClass:"flex"},[e._v(e._s(t.label))]),e._v(" "),n("span",{staticClass:"h-6 w-6 flex justify-center items-center"},["desc"===t.$direction?n("i",{staticClass:"las la-sort-amount-up"}):e._e(),e._v(" "),"asc"===t.$direction?n("i",{staticClass:"las la-sort-amount-down"}):e._e()])])])})),e._v(" "),!e.prependOptions&&e.showOptions?n("th",{staticClass:"text-left px-2 py-2 w-16 border"}):e._e()],2)]),e._v(" "),n("tbody",[void 0!==e.result.data&&e.result.data.length>0?e._l(e.result.data,(function(t,s){return n("ns-table-row",{key:s,attrs:{columns:e.columns,prependOptions:e.prependOptions,showOptions:e.showOptions,row:t},on:{updated:function(t){return e.refreshRow(t)},reload:function(t){return e.refresh()},toggled:function(t){return e.handleShowOptions(t)}}})})):e._e(),e._v(" "),e.result&&0!==e.result.data.length?e._e():n("tr",[n("td",{staticClass:"text-center text-gray-600 dark:text-slate-300 py-3",attrs:{colspan:Object.values(e.columns).length+2}},[e._v(e._s(e.__("There is nothing to display...")))])])],2)]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex border-t flex-col md:flex-row justify-between footer"},[e.bulkActions.length>0?n("div",{staticClass:"mb-2 md:mb-0 flex justify-between rounded-full ns-crud-input p-1",attrs:{id:"grouped-actions"}},[n("select",{directives:[{name:"model",rawName:"v-model",value:e.bulkAction,expression:"bulkAction"}],staticClass:"outline-none bg-transparent",attrs:{id:"grouped-actions"},on:{change:function(t){var n=Array.prototype.filter.call(t.target.options,(function(e){return e.selected})).map((function(e){return"_value"in e?e._value:e.value}));e.bulkAction=t.target.multiple?n:n[0]}}},[n("option",{staticClass:"bg-input-disabled",attrs:{selected:"",value:""}},[e._t("bulk-label",(function(){return[e._v(e._s(e.__("Bulk Actions")))]}))],2),e._v(" "),e._l(e.bulkActions,(function(t,s){return n("option",{key:s,staticClass:"bg-input-disabled",domProps:{value:t.identifier}},[e._v(e._s(t.label))])}))],2),e._v(" "),n("button",{staticClass:"ns-crud-input-button h-8 px-3 outline-none rounded-full flex items-center justify-center",on:{click:function(t){return e.bulkDo()}}},[e._t("bulk-go",(function(){return[e._v(e._s(e.__("Apply")))]}))],2)]):e._e(),e._v(" "),n("div",{staticClass:"flex"},[n("div",{staticClass:"items-center flex text-primary mx-4"},[e._v(e._s(e.resultInfo))]),e._v(" "),n("div",{staticClass:"flex items-center -mx-1",attrs:{id:"pagination"}},[e.result.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.first_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.pagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",class:e.page==t?"bg-info-tertiary border-transparent text-white":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){e.page=t,e.refresh()}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-crud-button border shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){e.page=e.result.last_page,e.refresh()}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)])])])}),[],!1,null,null,null).exports;var W=n(7751),B=n(1726),X=n(7259);const G=s.default.extend({methods:{__:d.__},name:"ns-avatar",data:function(){return{svg:""}},mounted:function(){this.svg=(0,B.createAvatar)(X,{seed:this.displayName})},computed:{avatarUrl:function(){return 0===this.url.length?"":this.url}},props:["url","display-name"]});const Q=(0,R.Z)(G,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex justify-between items-center flex-shrink-0"},[n("span",{staticClass:"hidden md:inline-block px-2"},[e._v(e._s(e.__("Howdy, {name}").replace("{name}",this.displayName)))]),e._v(" "),n("span",{staticClass:"md:hidden px-2"},[e._v(e._s(e.displayName))]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"w-8 h-8 overflow-hidden rounded-full bg-gray-600"},[""!==e.avatarUrl?n("img",{staticClass:"w-8 h-8 overflow-hidden rounded-full",attrs:{src:e.avatarUrl,alt:e.displayName,srcset:""}}):e._e(),e._v(" "),""===e.avatarUrl?n("div",{domProps:{innerHTML:e._s(e.svg)}}):e._e()])])])}),[],!1,null,null,null).exports;var J=n(328),K=n(2404),ee=n(4915),te=n(3502);const ne={name:"ns-search",props:["url","placeholder","value","label","method","searchArgument"],data:function(){return{searchText:"",searchTimeout:null,results:[]}},methods:{__:d.__,selectOption:function(e){this.$emit("select",e),this.searchText="",this.results=[]}},watch:{searchText:function(){var e=this;clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout((function(){var t,n,s;e.searchText.length>0&&i.ih[e.method||"post"](e.url,(t={},n=e.searchArgument||"search",s=e.searchText,n in t?Object.defineProperty(t,n,{value:s,enumerable:!0,configurable:!0,writable:!0}):t[n]=s,t)).subscribe({next:function(t){e.results=t},error:function(e){i.kX.error(e.message||(0,d.__)("An unexpected error occured.")).subscribe()}})}),1e3)}},mounted:function(){}};const se=(0,R.Z)(ne,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"ns-search"},[n("div",{staticClass:"input-group info border-2"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.searchText,expression:"searchText"}],staticClass:"p-2 w-full",attrs:{type:"text",placeholder:e.placeholder||e.__("Search..."),id:""},domProps:{value:e.searchText},on:{input:function(t){t.target.composing||(e.searchText=t.target.value)}}})]),e._v(" "),n("div",{staticClass:"relative"},[n("div",{staticClass:"w-full absolute"},[e.results.length>0&&e.searchText.length>0?n("ul",{staticClass:"ns-vertical-menu"},e._l(e.results,(function(t,s){return n("li",{key:s,staticClass:"border-b p-2 cursor-pointer",on:{click:function(n){return e.selectOption(t)}}},[e._v(e._s(t[e.label]))])})),0):e._e()])])])}),[],!1,null,null,null).exports},4110:(e,t,n)=>{"use strict";n.d(t,{P:()=>o});var s=n(538),i=n(328),r=n(9765),a=n(3164),o=s.default.component("ns-field",{data:function(){return{}},mounted:function(){},components:{nsDateRangePicker:i.Z,nsDateTimePicker:r.Z,nsSwitch:a.Z},computed:{isInputField:function(){return["text","password","email","number","tel"].includes(this.field.type)},isDateField:function(){return["date"].includes(this.field.type)},isSelectField:function(){return["select"].includes(this.field.type)},isTextarea:function(){return["textarea"].includes(this.field.type)},isCheckbox:function(){return["checkbox"].includes(this.field.type)},isMultiselect:function(){return["multiselect"].includes(this.field.type)},isSelectAudio:function(){return["select-audio"].includes(this.field.type)},isSwitch:function(){return["switch"].includes(this.field.type)},isMedia:function(){return["media"].includes(this.field.type)},isCkEditor:function(){return["ckeditor"].includes(this.field.type)},isDateTimePicker:function(){return["datetimepicker"].includes(this.field.type)},isDateRangePicker:function(){return["daterangepicker"].includes(this.field.type)},isCustom:function(){return["custom"].includes(this.field.type)}},props:["field"],methods:{addOption:function(e){"select"===this.field.type&&this.field.options.forEach((function(e){return e.selected=!1})),e.selected=!0;var t=this.field.options.indexOf(e);this.field.options.splice(t,1),this.field.options.unshift(e),this.refreshMultiselect(),this.$emit("change",{action:"addOption",option:e})},refreshMultiselect:function(){this.field.value=this.field.options.filter((function(e){return e.selected})).map((function(e){return e.value}))},removeOption:function(e){e.selected=!1,this.refreshMultiselect(),this.$emit("change",{action:"removeOption",option:e})}},template:'\n
    \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
    \n '})},9020:(e,t,n)=>{"use strict";n.d(t,{W:()=>c,f:()=>d});var s=n(2077),i=n.n(s),r=n(538),a=n(6740),o=n.n(a),l=new Array(parseInt(ns.currency.ns_currency_precision)).fill("").map((function(e){return 0})).join(""),c=r.default.filter("currency",(function(e){var t,n,s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"full";switch(ns.currency.ns_currency_prefered){case"iso":t=ns.currency.ns_currency_iso;break;case"symbol":t=ns.currency.ns_currency_symbol}if("full"===s){var r={decimal:ns.currency.ns_currency_decimal_separator,separator:ns.currency.ns_currency_thousand_separator,precision:parseInt(ns.currency.ns_currency_precision),symbol:""};n=o()(e,r).format()}else n=i()(e).format("0.0a");return"".concat("before"===ns.currency.ns_currency_position?t:"").concat(n).concat("after"===ns.currency.ns_currency_position?t:"")})),d=function(e){var t="0.".concat(l);return parseFloat(i()(e).format(t))}},7794:(e,t,n)=>{"use strict";n.d(t,{b:()=>s});var s=n(538).default.filter("truncate",(function(e,t){return e?(e=e.toString()).length>t?e.substring(0,t)+"...":e:""}))},4679:(e,t,n)=>{"use strict";function s(e,t){for(var n=0;ni});var i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e)}var t,n,i;return t=e,n=[{key:"validateFields",value:function(e){var t=this;return 0===e.map((function(e){return t.checkField(e),e.errors?0===e.errors.length:0})).filter((function(e){return!1===e})).length}},{key:"validateFieldsErrors",value:function(e){var t=this;return e.map((function(e){return t.checkField(e),e.errors})).flat()}},{key:"validateForm",value:function(e){e.main&&this.validateField(e.main);var t=[];for(var n in e.tabs)if(e.tabs[n].fields){var s=[],i=this.validateFieldsErrors(e.tabs[n].fields);i.length>0&&s.push(i),e.tabs[n].errors=s.flat(),t.push(s.flat())}return t.flat().filter((function(e){return void 0!==e}))}},{key:"initializeTabs",value:function(e){var t=0;for(var n in e)0===t&&(e[n].active=!0),e[n].active=void 0!==e[n].active&&e[n].active,e[n].fields=this.createFields(e[n].fields),t++;return e}},{key:"validateField",value:function(e){return this.checkField(e)}},{key:"fieldsValid",value:function(e){return!(e.map((function(e){return e.errors&&e.errors.length>0})).filter((function(e){return e})).length>0)}},{key:"createFields",value:function(e){return e.map((function(t){if(t.type=t.type||"text",t.errors=t.errors||[],t.disabled=t.disabled||!1,"custom"===t.type&&"string"==typeof t.component){var n=t.component;if(t.component=nsExtraComponents[t.component],!t.component)throw'Failed to load a custom component. "'.concat(n,'" is not provided as an extra component. More details here: https://my.nexopos.com/en/documentation/developpers-guides/how-to-register-a-custom-vue-component');t.component.$field=t,t.component.$fields=e}return t}))}},{key:"createForm",value:function(e){if(e.main&&(e.main=this.createFields([e.main])[0]),e.tabs)for(var t in e.tabs)e.tabs[t].errors=[],void 0!==e.tabs[t].fields?e.tabs[t].fields=this.createFields(e.tabs[t].fields):console.info('Warning: The tab "'.concat(e.tabs[t].label,'" is missing fields. Fallback on checking dynamic component instead.'));return e}},{key:"enableFields",value:function(e){return e.map((function(e){return e.disabled=!1}))}},{key:"disableFields",value:function(e){return e.map((function(e){return e.disabled=!0}))}},{key:"disableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!0),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!0}))}},{key:"enableForm",value:function(e){for(var t in e.main&&(e.main.disabled=!1),e.tabs)e.tabs[t].fields.forEach((function(e){return e.disabled=!1}))}},{key:"getValue",value:function(e){var t={};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"checkField",value:function(e){var t=this;return void 0!==e.validation&&(e.errors=[],this.detectValidationRules(e.validation).forEach((function(n){t.fieldPassCheck(e,n)}))),e}},{key:"extractForm",value:function(e){var t={};if(e.main&&(t[e.main.name]=e.main.value),e.tabs)for(var n in e.tabs)void 0===t[n]&&(t[n]={}),t[n]=this.extractFields(e.tabs[n].fields);return t}},{key:"extractFields",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e.forEach((function(e){t[e.name]=e.value})),t}},{key:"detectValidationRules",value:function(e){var t=function(e){var t;return["email","required"].includes(e)?{identifier:e}:(t=/(min)\:([0-9])+/g.exec(e))||(t=/(max)\:([0-9])+/g.exec(e))?{identifier:t[1],value:t[2]}:e};return Array.isArray(e)?e.filter((function(e){return"string"==typeof e})).map(t):e.split("|").map(t)}},{key:"triggerError",value:function(e,t){if(console.log(t),t.errors){var n=function(n){var s=n.split(".").filter((function(e){return!/^\d+$/.test(e)}));2===s.length&&e.tabs[s[0]].fields.forEach((function(e){e.name===s[1]&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))})),n===e.main.name&&t.errors[n].forEach((function(t){e.main.errors.push({identifier:"invalid",invalid:!0,message:t,name:e.main.name})}))};for(var s in t.errors)n(s)}}},{key:"triggerFieldsErrors",value:function(e,t){if(t&&t.errors){var n=function(n){e.forEach((function(e){e.name===n&&t.errors[n].forEach((function(t){var n={identifier:"invalid",invalid:!0,message:t,name:e.name};e.errors.push(n)}))}))};for(var s in t.errors)n(s)}}},{key:"fieldPassCheck",value:function(e,t){if("required"===t.identifier){if(void 0===e.value||null===e.value||0===e.value.length)return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){n.identifier===t.identifier&&!0===n.invalid&&e.errors.splice(s,1)}))}if("email"===t.identifier&&e.value.length>0){if(!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(e.value))return e.errors.push({identifier:t.identifier,invalid:!0,name:e.name});e.errors.forEach((function(n,s){!0===n[t.identifier]&&e.errors.splice(s,1)}))}return e}}],n&&s(t.prototype,n),i&&s(t,i),Object.defineProperty(t,"prototype",{writable:!1}),e}()},3632:(e,t,n)=>{"use strict";n.d(t,{__:()=>s,c:()=>i});var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"NexoPOS";return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e},i=function(e,t){return nsLanguage.getEntries(t)&&nsLanguage.getEntries(t)[e]||e}},665:(e,t,n)=>{"use strict";function s(){var e=this;Object.keys(this).includes("$popup")&&(this.$popup.event.subscribe((function(t){"click-overlay"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close()),"press-esc"===t.event&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close())})),nsHotPress.create("popup-esc").whenPressed("escape",(function(t){t.preventDefault();var n=parseInt(e.$el.parentElement.getAttribute("data-index"));null===document.querySelector('.is-popup [data-index="'.concat(n+1,"]"))&&(e.$popupParams&&void 0!==e.$popupParams.reject&&e.$popupParams.reject(!1),e.$popup.close(),nsHotPress.destroy("popup-esc"))})))}n.d(t,{Z:()=>s})},2830:(e,t,n)=>{"use strict";function s(e){void 0!==this.$popupParams.resolve&&this.$popupParams.reject&&(!1!==e?this.$popupParams.resolve(e):this.$popupParams.reject(e)),this.$popup.close()}n.d(t,{Z:()=>s})},6979:(e,t,n)=>{"use strict";n.d(t,{G:()=>c});var s=n(7757),i=n.n(s),r=n(9248);function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};if(a(this,e),this.config={primarySelector:void 0,popupClass:"shadow-lg h-half w-1/2 bg-white"},this.container=document.createElement("div"),this.popupBody=document.createElement("div"),this.popupSelector="",this.config=Object.assign(this.config,t),void 0===this.config.primarySelector&&document.querySelectorAll(".is-popup").length>0){var n=document.querySelectorAll(".is-popup").length;this.parentWrapper=document.querySelectorAll(".is-popup")[n-1]}else this.parentWrapper=document.querySelector("body").querySelectorAll("div")[0];this.event=new r.x}var t,n,s;return t=e,n=[{key:"hash",value:function(){for(var e="",t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=0;n<10;n++)e+=t.charAt(Math.floor(Math.random()*t.length));return e}},{key:"open",value:function(e){var t,n,s,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return l(this,void 0,void 0,i().mark((function a(){var o,l,c,d=this;return i().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:if("function"!=typeof e){i.next=9;break}return i.prev=1,i.next=4,e();case 4:e=i.sent.default,i.next=9;break;case 7:i.prev=7,i.t0=i.catch(1);case 9:o=document.querySelector("body").querySelectorAll("div")[0],this.parentWrapper.style.filter="blur(4px)",o.style.filter="blur(6px)",this.container.setAttribute("class","absolute top-0 left-0 w-full h-full flex items-center justify-center is-popup"),this.container.addEventListener("click",(function(e){d.event.next({event:"click-overlay",value:!0}),e.stopPropagation()})),this.popupBody.addEventListener("click",(function(e){e.stopImmediatePropagation()})),l=document.querySelectorAll(".is-popup").length,this.container.id="popup-container-"+this.hash(),this.popupSelector="#".concat(this.container.id),this.popupBody.setAttribute("class","zoom-out-entrance popup-body"),this.popupBody.setAttribute("data-index",l),this.popupBody.innerHTML='
    ',this.container.appendChild(this.popupBody),document.body.appendChild(this.container),c=Vue.extend(e),this.instance=new c({propsData:{popup:this}}),this.instance.template=(null===(t=null==e?void 0:e.options)||void 0===t?void 0:t.template)||void 0,this.instance.render=e.render||void 0,this.instance.methods=(null===(n=null==e?void 0:e.options)||void 0===n?void 0:n.methods)||(null==e?void 0:e.methods),this.instance.data=(null===(s=null==e?void 0:e.options)||void 0===s?void 0:s.data)||(null==e?void 0:e.data),this.instance.$popup=this,this.instance.$popupParams=r,this.instance.$mount("#".concat(this.container.id," .vue-component"));case 32:case"end":return i.stop()}}),a,this,[[1,7]])})))}},{key:"close",value:function(){var e=this;this.instance.$destroy(),this.event.unsubscribe(),this.parentWrapper.style.filter="blur(0px)";var t=document.querySelector("body").querySelectorAll("div")[0];document.querySelectorAll(".is-popup").length<=1&&(t.style.filter="blur(0px)");var n="".concat(this.popupSelector," .popup-body");this.popupBody=document.querySelector(n),this.popupBody.classList.remove("zoom-out-entrance"),this.popupBody.classList.add("zoom-in-exit"),this.container=document.querySelector("".concat(this.popupSelector)),this.container.classList.remove("is-popup"),setTimeout((function(){e.container.remove()}),300)}}],s=[{key:"show",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=new e(s);return i.open(t,n),i}}],n&&o(t.prototype,n),s&&o(t,s),Object.defineProperty(t,"prototype",{writable:!1}),e}()},9093:(e,t,n)=>{"use strict";n.d(t,{S:()=>r});var s=n(3260);function i(e,t){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return s.Observable.create((function(s){var r=n.__createSnack({message:e,label:t,type:i.type}),a=r.buttonNode,o=(r.textNode,r.snackWrapper,r.sampleSnack);a.addEventListener("click",(function(e){s.onNext(a),s.onCompleted(),o.remove()})),n.__startTimer(i.duration,o)}))}},{key:"error",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"error"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"error"}))}},{key:"success",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"success"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"success"}))}},{key:"info",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{duration:3e3,type:"info"};return this.show(e,t,Object.assign(Object.assign({},n),{type:"info"}))}},{key:"__startTimer",value:function(e,t){var n,s=function(){e>0&&!1!==e&&(n=setTimeout((function(){t.remove()}),e))};t.addEventListener("mouseenter",(function(){clearTimeout(n)})),t.addEventListener("mouseleave",(function(){s()})),s()}},{key:"__createSnack",value:function(e){var t=e.message,n=e.label,s=e.type,i=void 0===s?"info":s,r=document.getElementById("snack-wrapper")||document.createElement("div"),a=document.createElement("div"),o=document.createElement("p"),l=document.createElement("div"),c=document.createElement("button"),d="",u="";switch(i){case"info":d="",u="info";break;case"error":d="",u="error";break;case"success":d="",u="success"}return o.textContent=t,o.setAttribute("class","pr-2"),n&&(l.setAttribute("class","ns-button default"),c.textContent=n,c.setAttribute("class","px-3 py-2 shadow rounded uppercase ".concat(d)),l.appendChild(c)),a.appendChild(o),a.appendChild(l),a.setAttribute("class","md:rounded py-2 px-3 md:w-2/5 w-full z-10 md:my-2 shadow-lg flex justify-between items-center zoom-in-entrance anim-duration-300 ns-notice ".concat(u)),r.appendChild(a),null===document.getElementById("snack-wrapper")&&(r.setAttribute("id","snack-wrapper"),r.setAttribute("class","absolute bottom-0 w-full flex justify-between items-center flex-col"),document.body.appendChild(r)),{snackWrapper:r,sampleSnack:a,buttonsWrapper:l,buttonNode:c,textNode:o}}}],n&&i(t.prototype,n),r&&i(t,r),Object.defineProperty(t,"prototype",{writable:!1}),e}()},6700:(e,t,n)=>{var s={"./af":2786,"./af.js":2786,"./ar":867,"./ar-dz":4130,"./ar-dz.js":4130,"./ar-kw":6135,"./ar-kw.js":6135,"./ar-ly":6440,"./ar-ly.js":6440,"./ar-ma":7702,"./ar-ma.js":7702,"./ar-sa":6040,"./ar-sa.js":6040,"./ar-tn":7100,"./ar-tn.js":7100,"./ar.js":867,"./az":1083,"./az.js":1083,"./be":9808,"./be.js":9808,"./bg":8338,"./bg.js":8338,"./bm":7438,"./bm.js":7438,"./bn":8905,"./bn-bd":6225,"./bn-bd.js":6225,"./bn.js":8905,"./bo":1560,"./bo.js":1560,"./br":1278,"./br.js":1278,"./bs":622,"./bs.js":622,"./ca":2468,"./ca.js":2468,"./cs":5822,"./cs.js":5822,"./cv":877,"./cv.js":877,"./cy":7373,"./cy.js":7373,"./da":4780,"./da.js":4780,"./de":9740,"./de-at":217,"./de-at.js":217,"./de-ch":894,"./de-ch.js":894,"./de.js":9740,"./dv":5300,"./dv.js":5300,"./el":837,"./el.js":837,"./en-au":8348,"./en-au.js":8348,"./en-ca":7925,"./en-ca.js":7925,"./en-gb":2243,"./en-gb.js":2243,"./en-ie":6436,"./en-ie.js":6436,"./en-il":7207,"./en-il.js":7207,"./en-in":4175,"./en-in.js":4175,"./en-nz":6319,"./en-nz.js":6319,"./en-sg":1662,"./en-sg.js":1662,"./eo":2915,"./eo.js":2915,"./es":5655,"./es-do":5251,"./es-do.js":5251,"./es-mx":6112,"./es-mx.js":6112,"./es-us":1146,"./es-us.js":1146,"./es.js":5655,"./et":5603,"./et.js":5603,"./eu":7763,"./eu.js":7763,"./fa":6959,"./fa.js":6959,"./fi":1897,"./fi.js":1897,"./fil":2549,"./fil.js":2549,"./fo":4694,"./fo.js":4694,"./fr":4470,"./fr-ca":3049,"./fr-ca.js":3049,"./fr-ch":2330,"./fr-ch.js":2330,"./fr.js":4470,"./fy":4415,"./fy.js":4415,"./ga":9295,"./ga.js":9295,"./gd":2101,"./gd.js":2101,"./gl":8794,"./gl.js":8794,"./gom-deva":7884,"./gom-deva.js":7884,"./gom-latn":3168,"./gom-latn.js":3168,"./gu":5349,"./gu.js":5349,"./he":4206,"./he.js":4206,"./hi":94,"./hi.js":94,"./hr":316,"./hr.js":316,"./hu":2138,"./hu.js":2138,"./hy-am":1423,"./hy-am.js":1423,"./id":9218,"./id.js":9218,"./is":135,"./is.js":135,"./it":626,"./it-ch":150,"./it-ch.js":150,"./it.js":626,"./ja":9183,"./ja.js":9183,"./jv":4286,"./jv.js":4286,"./ka":2105,"./ka.js":2105,"./kk":7772,"./kk.js":7772,"./km":8758,"./km.js":8758,"./kn":9282,"./kn.js":9282,"./ko":3730,"./ko.js":3730,"./ku":1408,"./ku.js":1408,"./ky":3291,"./ky.js":3291,"./lb":6841,"./lb.js":6841,"./lo":5466,"./lo.js":5466,"./lt":7010,"./lt.js":7010,"./lv":7595,"./lv.js":7595,"./me":9861,"./me.js":9861,"./mi":5493,"./mi.js":5493,"./mk":5966,"./mk.js":5966,"./ml":7341,"./ml.js":7341,"./mn":5115,"./mn.js":5115,"./mr":370,"./mr.js":370,"./ms":9847,"./ms-my":1237,"./ms-my.js":1237,"./ms.js":9847,"./mt":2126,"./mt.js":2126,"./my":6165,"./my.js":6165,"./nb":4924,"./nb.js":4924,"./ne":6744,"./ne.js":6744,"./nl":3901,"./nl-be":9814,"./nl-be.js":9814,"./nl.js":3901,"./nn":3877,"./nn.js":3877,"./oc-lnc":2135,"./oc-lnc.js":2135,"./pa-in":5858,"./pa-in.js":5858,"./pl":4495,"./pl.js":4495,"./pt":9520,"./pt-br":7971,"./pt-br.js":7971,"./pt.js":9520,"./ro":6459,"./ro.js":6459,"./ru":1793,"./ru.js":1793,"./sd":950,"./sd.js":950,"./se":490,"./se.js":490,"./si":124,"./si.js":124,"./sk":4249,"./sk.js":4249,"./sl":4985,"./sl.js":4985,"./sq":1104,"./sq.js":1104,"./sr":9131,"./sr-cyrl":9915,"./sr-cyrl.js":9915,"./sr.js":9131,"./ss":5893,"./ss.js":5893,"./sv":8760,"./sv.js":8760,"./sw":1172,"./sw.js":1172,"./ta":7333,"./ta.js":7333,"./te":3110,"./te.js":3110,"./tet":2095,"./tet.js":2095,"./tg":7321,"./tg.js":7321,"./th":9041,"./th.js":9041,"./tk":9005,"./tk.js":9005,"./tl-ph":5768,"./tl-ph.js":5768,"./tlh":9444,"./tlh.js":9444,"./tr":2397,"./tr.js":2397,"./tzl":8254,"./tzl.js":8254,"./tzm":1106,"./tzm-latn":699,"./tzm-latn.js":699,"./tzm.js":1106,"./ug-cn":9288,"./ug-cn.js":9288,"./uk":7691,"./uk.js":7691,"./ur":3795,"./ur.js":3795,"./uz":6791,"./uz-latn":588,"./uz-latn.js":588,"./uz.js":6791,"./vi":5666,"./vi.js":5666,"./x-pseudo":4378,"./x-pseudo.js":4378,"./yo":5805,"./yo.js":5805,"./zh-cn":3839,"./zh-cn.js":3839,"./zh-hk":5726,"./zh-hk.js":5726,"./zh-mo":9807,"./zh-mo.js":9807,"./zh-tw":4152,"./zh-tw.js":4152};function i(e){var t=r(e);return n(t)}function r(e){if(!n.o(s,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return s[e]}i.keys=function(){return Object.keys(s)},i.resolve=r,e.exports=i,i.id=6700},328:(e,t,n)=>{"use strict";n.d(t,{Z:()=>d});var s=n(538),i=n(381),r=n.n(i),a=n(7144),o=n.n(a),l=(n(9095),n(3632));const c=s.default.extend({name:"ns-date-range-picker",data:function(){return{dateRange:{startDate:null,endDate:null}}},components:{DateRangePicker:o()},mounted:function(){void 0!==this.field.value&&(this.dateRange=this.field.value)},watch:{dateRange:function(){var e={startDate:r()(this.dateRange.startDate).format("YYYY-MM-DD HH:mm"),endDate:r()(this.dateRange.endDate).format("YYYY-MM-DD HH:mm")};this.field.value=e,this.$emit("change",this)}},methods:{__:l.__,getFormattedDate:function(e){return null!==e?r()(e).format("YYYY-MM-DD HH:mm"):(0,l.__)("N/D")},clearDate:function(){this.dateRange={startDate:null,endDate:null},this.field.value=void 0}},computed:{hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"bg-gray-200 cursor-not-allowed":"bg-transparent"},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},props:["placeholder","leading","type","field"]});const d=(0,n(1900).Z)(c,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-auto flex-col mb-2 ns-date-range-picker"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"text-error-primary":"text-primary",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"mt-1 relative flex input-group border-2 rounded-md overflow-hidden focus:shadow-sm",class:e.hasError?"error":""},[e.leading?n("div",{staticClass:"absolute inset-y-0 left-0 pl-3 flex items-center pointer-events-none"},[n("span",{staticClass:"text-primary sm:text-sm sm:leading-5"},[e._v("\n "+e._s(e.leading)+"\n ")])]):e._e(),e._v(" "),n("button",{staticClass:"px-3 outline-none bg-error-secondary font-semibold text-white",on:{click:function(t){return e.clearDate()}}},[n("i",{staticClass:"las la-times"})]),e._v(" "),n("date-range-picker",{ref:"picker",staticClass:"w-full flex items-center bg-input-background",attrs:{"locale-data":{firstDay:1,format:"yyyy-mm-dd HH:mm:ss"},timePicker:!0,timePicker24Hour:!0,showWeekNumbers:!0,showDropdowns:!0,autoApply:!1,appendToBody:!0,disabled:e.field.disabled,linkedCalendars:!0},scopedSlots:e._u([{key:"input",fn:function(t){return[n("div",{staticClass:"flex justify-between items-center w-full py-2"},[n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Starts"))+" : "+e._s(e.getFormattedDate(t.startDate)))]),e._v(" "),n("span",{staticClass:"text-xs"},[e._v(e._s(e.__("Range Ends"))+" : "+e._s(e.getFormattedDate(t.endDate)))])])]}}]),model:{value:e.dateRange,callback:function(t){e.dateRange=t},expression:"dateRange"}})],1),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs text-gray-500"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs text-red-400"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e(),e._v(" "),"email"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field must contain a valid email address.")))]})):e._e(),e._v(" "),"invalid"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(t.message))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},9765:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-date-time-picker",props:["field","date"],data:function(){return{visible:!1,hours:0,minutes:0,currentView:"days",currentDay:void 0,moment:i(),months:new Array(11).fill("").map((function(e,t){return t})),daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},computed:{momentCopy:function(){return i()()}},watch:{visible:function(){var e=this;this.visible&&setTimeout((function(){e.$refs.hours.addEventListener("focus",(function(){this.select()})),e.$refs.minutes.addEventListener("focus",(function(){this.select()}))}),100)}},mounted:function(){var e=this;document.addEventListener("mousedown",(function(t){return e.checkClickedItem(t)})),this.field?this.currentDay=[void 0,"",null].includes(this.field.value)?i()():i()(this.field.value):this.currentDay=[void 0,"",null].includes(this.date)?i()():i()(this.date),this.hours=this.currentDay.format("HH"),this.minutes=this.currentDay.format("mm"),this.build()},methods:{__:n(3632).__,erase:function(){this.selectDate()},setYear:function(e){parseInt(e.srcElement.value)>0&&parseInt(e.srcElement.value)<9999&&(this.currentDay.year(e.srcElement.value),this.updateDateTime())},subYear:function(){parseFloat(this.currentDay.format("YYYY"))>0&&(this.currentDay.subtract(1,"year"),this.updateDateTime())},addYear:function(){this.currentDay.add(1,"year"),this.updateDateTime()},toggleView:function(e){var t=this;this.currentView=e,"years"===this.currentView&&setTimeout((function(){t.$refs.year.select()}),100)},setMonth:function(e){this.currentDay.month(e),this.updateDateTime()},detectHoursChange:function(){parseFloat(this.hours)<0&&(this.hours=0),parseFloat(this.hours)>23&&(this.hours=23),this.updateDateTime()},detectMinuteChange:function(){parseFloat(this.minutes)<0&&(this.minutes=0),parseFloat(this.minutes)>59&&(this.minutes=59),this.updateDateTime()},updateDateTime:function(){this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.build(),this.selectDate(this.currentDay)},checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){[void 0].includes(e)?(this.field&&(this.field.value=null),this.$emit("change",null)):(this.currentDay=e,this.currentDay.hours(this.hours),this.currentDay.minutes(this.minutes),this.field&&(this.field.value=this.currentDay.format("YYYY/MM/DD HH:mm")),console.log(this.hours,this.minutes),this.$emit("change",this.field?this.field:this.currentDay))},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker mb-2"},[e.field?n("label",{staticClass:"block leading-5 font-medium text-primary"},[e._v(e._s(e.field.label))]):e._e(),e._v(" "),n("div",{staticClass:"ns-button"},[n("button",{staticClass:"rounded cursor-pointer w-full px-1 py-1 flex items-center text-primary",class:e.field?"mt-1 border":"shadow",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),e.currentDay&&e.field?n("span",{staticClass:"mx-1 text-sm"},[null!==e.field.value?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.field.value?n("span",[e._v("N/A")]):e._e()]):e._e(),e._v(" "),e.currentDay&&e.date?n("span",{staticClass:"mx-1 text-sm"},[null!==e.date?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD HH:mm")))]):e._e(),e._v(" "),null===e.date?n("span",[e._v("N/A")]):e._e()]):e._e()])]),e._v(" "),e.field?n("p",{staticClass:"text-sm text-secondary py-1"},[e._v(e._s(e.field.description))]):e._e(),e._v(" "),e.visible?n("div",{staticClass:"relative z-10 h-0 w-0"},[n("div",{staticClass:"absolute w-72 shadow-xl rounded ns-box anim-duration-300 zoom-in-entrance flex flex-col",class:e.field?"-mt-4":"mt-2"},["years"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border border-numpad-edge outline-none text-numpad-text hover:bg-numpad-hover rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"h-32 flex items-center justify-center text-primary"},[n("div",{staticClass:"rounded input-group info border-2 flex w-2/3 overflow-hidden"},[n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.subYear()}}},[n("i",{staticClass:"las la-minus"})]),e._v(" "),n("input",{ref:"year",staticClass:"p-2 w-24 text-center outline-none",attrs:{type:"text"},domProps:{value:e.currentDay.format("YYYY")},on:{change:function(t){return e.setYear(t)}}}),e._v(" "),n("button",{staticClass:"px-4 py-2",on:{click:function(t){return e.addYear()}}},[n("i",{staticClass:"las la-plus"})])])])]):e._e(),e._v(" "),"months"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 border-b border-info-secondary border-dashed"},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border ns-inset-button outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-1 gap-0 text-primary"},e._l(e.months,(function(t,s){return n("div",{key:s,staticClass:"h-8 flex justify-center items-center text-sm"},[[n("div",{staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:e.momentCopy.month(t).format("MM")===e.currentDay.format("MM")?"bg-info-secondary text-white border border-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.setMonth(t)}}},[e._v("\n "+e._s(e.momentCopy.format("MMM"))+"\n ")])]],2)})),0)]):e._e(),e._v(" "),"days"===e.currentView?n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-primary justify-center"},[n("span",{staticClass:"mr-2 cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("months")}}},[e._v(e._s(e.currentDay.format("MMM")))]),e._v(" "),n("span",{staticClass:"cursor-pointer border-b border-info-secondary border-dashed",on:{click:function(t){return e.toggleView("years")}}},[e._v(e._s(e.currentDay.format("YYYY")))])]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 border outline-none ns-inset-button rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},[n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-numpad-edge h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-primary"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"text-white border border-info-secondary bg-info-secondary":"hover:bg-numpad-hover border border-numpad-edge",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2):e._e(),e._v(" "),n("div",{staticClass:"border-t border-numpad-edge w-full p-2"},[n("div",{staticClass:"-mx-1 flex justify-between"},[n("div",{staticClass:"px-1"},[n("div",{staticClass:"-mx-1 flex"},[e.field?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.erase()}}},[n("i",{staticClass:"las la-trash"})])]):e._e(),e._v(" "),"days"!==e.currentView?n("div",{staticClass:"px-1"},[n("button",{staticClass:"border ns-inset-button error hover:text-white rounded w-8 h-8 flex items-center justify-center",on:{click:function(t){return e.toggleView("days")}}},[n("i",{staticClass:"las la-sign-out-alt"})])]):e._e()])]),e._v(" "),n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded flex"},[n("input",{directives:[{name:"model",rawName:"v-model",value:e.hours,expression:"hours"}],ref:"hours",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"HH",type:"number"},domProps:{value:e.hours},on:{change:function(t){return e.detectHoursChange(t)},input:function(t){t.target.composing||(e.hours=t.target.value)}}}),e._v(" "),n("span",{staticClass:"mx-1"},[e._v(":")]),e._v(" "),n("input",{directives:[{name:"model",rawName:"v-model",value:e.minutes,expression:"minutes"}],ref:"minutes",staticClass:"w-12 p-1 text-center border border-numpad-edge bg-input-disabled text-primary active:border-numpad-edge",attrs:{placeholder:"mm",type:"number"},domProps:{value:e.minutes},on:{change:function(t){return e.detectMinuteChange(t)},input:function(t){t.target.composing||(e.minutes=t.target.value)}}})])])])])])]):e._e()])}),[],!1,null,null,null).exports},4915:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var s=n(381),i=n.n(s);const r={name:"ns-datepicker",props:["label","date"],data:function(){return{visible:!1,currentDay:null,daysOfWeek:new Array(7).fill("").map((function(e,t){return t})),calendar:[[]]}},mounted:function(){document.addEventListener("click",this.checkClickedItem),this.currentDay=[void 0,null].includes(this.date)?i()():i()(this.date),this.build()},methods:{__:n(3632).__,checkClickedItem:function(e){!this.$el.contains(e.srcElement)&&this.visible&&(this.visible=!1)},selectDate:function(e){this.currentDay=e,this.visible=!1,this.$emit("change",e)},subMonth:function(){this.currentDay.subtract(1,"month"),this.build()},addMonth:function(){this.currentDay.add(1,"month"),this.build()},resetCalendar:function(){this.calendar=[[]]},build:function(){this.resetCalendar();this.currentDay.clone().startOf("month");for(var e=this.currentDay.clone().startOf("month"),t=this.currentDay.clone().endOf("month");;){0===e.day()&&this.calendar[0].length>0&&this.calendar.push([]);var n=this.calendar.length-1;if(this.calendar[n].push({date:e.clone(),dayOfWeek:e.day(),isToday:e.isSame(i().now(),"day")}),e.isSame(t,"day"))break;e.add(1,"day")}}}};const a=(0,n(1900).Z)(r,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"picker"},[n("div",{staticClass:"rounded cursor-pointer bg-white shadow px-1 py-1 flex items-center text-gray-700",on:{click:function(t){e.visible=!e.visible}}},[n("i",{staticClass:"las la-clock text-2xl"}),e._v(" "),n("span",{staticClass:"mx-1 text-sm"},[n("span",[e._v(e._s(e.label||e.__("Date"))+" : ")]),e._v(" "),e.currentDay?n("span",[e._v(e._s(e.currentDay.format("YYYY/MM/DD")))]):e._e(),e._v(" "),null===e.currentDay?n("span",[e._v(e._s(e.__("N/A")))]):e._e()])]),e._v(" "),e.visible?n("div",{staticClass:"relative h-0 w-0 -mb-2"},[n("div",{staticClass:"w-72 mt-2 shadow rounded bg-white anim-duration-300 zoom-in-entrance flex flex-col"},[n("div",{staticClass:"flex-auto"},[n("div",{staticClass:"p-2 flex items-center"},[n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.subMonth()}}},[n("i",{staticClass:"las la-angle-left"})])]),e._v(" "),n("div",{staticClass:"flex flex-auto font-semibold text-gray-700 justify-center"},[e._v(e._s(e.currentDay.format("MMM"))+" "+e._s(e.currentDay.format("YYYY")))]),e._v(" "),n("div",[n("button",{staticClass:"w-8 h-8 bg-gray-400 rounded",on:{click:function(t){return e.addMonth()}}},[n("i",{staticClass:"las la-angle-right"})])])]),e._v(" "),n("div",{staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},[n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sun")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Mon")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Tue")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Wed")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Thr")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Fri")))]),e._v(" "),n("div",{staticClass:"border border-gray-200 h-8 flex justify-center items-center text-sm"},[e._v(e._s(e.__("Sat")))])]),e._v(" "),e._l(e.calendar,(function(t,s){return n("div",{key:s,staticClass:"grid grid-flow-row grid-cols-7 grid-rows-1 gap-0 text-gray-700"},e._l(e.daysOfWeek,(function(s,i){return n("div",{key:i,staticClass:"h-8 flex justify-center items-center text-sm"},[e._l(t,(function(t,i){return[t.dayOfWeek===s?n("div",{key:i,staticClass:"h-full w-full flex items-center justify-center cursor-pointer",class:t.date.format("DD")===e.currentDay.format("DD")?"bg-blue-400 text-white border border-blue-500":"hover:bg-gray-100 border border-gray-200",on:{click:function(n){return e.selectDate(t.date)}}},[e._v("\n "+e._s(t.date.format("DD"))+"\n ")]):e._e()]}))],2)})),0)}))],2),e._v(" "),n("div")])]):e._e()])}),[],!1,null,null,null).exports},2404:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-notice",props:["color"],computed:{actualColor:function(){return this.color||"blue"}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"p-4 border-l-4 text-primary ns-notice",class:e.actualColor,attrs:{role:"alert"}},[n("h2",{staticClass:"font-bold"},[e._t("title")],2),e._v(" "),n("p",[e._t("description"),e._t("default")],2)])}),[],!1,null,null,null).exports},7751:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var s=n(3632);function i(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,s=new Array(t);n0?this.screenValue=parseFloat(this.value/this.number):this.screenValue=this.value||0;var t=new Array(10).fill("").map((function(e,t){return t}));nsHotPress.create("numpad-keys").whenVisible([".is-popup"]).whenPressed(t,(function(t,n){e.inputValue({value:n})})),nsHotPress.create("numpad-backspace").whenVisible([".is-popup"]).whenPressed("backspace",(function(){return e.inputValue({identifier:"backspace"})})),nsHotPress.create("numpad-increase").whenVisible([".is-popup"]).whenPressed("+",(function(){return e.increaseBy({value:1})})),nsHotPress.create("numpad-reduce").whenVisible([".is-popup"]).whenPressed("-",(function(){return e.increaseBy({value:-1})})),nsHotPress.create("numpad-save").whenVisible([".is-popup"]).whenPressed("enter",(function(){return e.inputValue({identifier:"next"})}))},watch:{value:function(){this.value.toString().length>0?this.floating?this.screenValue=Math.round(this.value*this.number).toString():this.screenValue=this.value:this.screenValue=""}},beforeDestroy:function(){nsHotPress.destroy("numpad-backspace"),nsHotPress.destroy("numpad-increase"),nsHotPress.destroy("numpad-reduce"),nsHotPress.destroy("numpad-save")},methods:{increaseBy:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));this.screenValue=(parseFloat(e.value)*t+(parseFloat(this.screenValue)||0)).toString(),this.allSelected=!1},inputValue:function(e){var t=parseInt(1+new Array(this.cursor).fill("").map((function(e){return 0})).join(""));if("next"!==e.identifier){if("backspace"===e.identifier)this.allSelected?(this.screenValue="0",this.allSelected=!1):this.screenValue=this.screenValue.toString().substr(0,this.screenValue.length-1);else if(e.value.toString().match(/^\d+$/)){if(this.limit>0&&this.screenValue.length>=this.limit)return;this.allSelected?(this.screenValue=e.value.toString(),this.allSelected=!1):(this.screenValue+=""+e.value.toString(),"percentage"===this.mode&&(this.screenValue=this.screenValue>100?100:this.screenValue))}var n=this.floating&&this.screenValue.length>0&&"0"!==this.screenValue?parseFloat(this.screenValue/this.number):this.screenValue;this.$emit("changed",n)}else this.$emit("next",this.floating&&this.screenValue.length>0?parseFloat(this.screenValue/t):this.screenValue)}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-3",attrs:{id:"numpad"}},[e._l(e.keys,(function(t,s){return n("div",{key:s,staticClass:"select-none ns-numpad-key border-l border-b h-24 font-bold flex items-center justify-center cursor-pointer",on:{click:function(n){return e.inputValue(t)}}},[void 0!==t.value?n("span",[e._v(e._s(t.value))]):e._e(),e._v(" "),t.icon?n("i",{staticClass:"las",class:t.icon}):e._e()])})),e._v(" "),e._t("numpad-footer")],2)}),[],!1,null,null,null).exports},3502:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={name:"ns-paginate",props:["pagination"],data:function(){return{page:1,path:""}},mounted:function(){this.path=this.pagination.path},computed:{getPagination:function(){return this.pagination?this.pageNumbers(this.pagination.last_page,this.pagination.current_page):[]}},methods:{gotoPage:function(e){this.page=e,this.$emit("load","".concat(this.path,"?page=").concat(this.page))},pageNumbers:function(e,t){var n=[];t-3>1&&n.push(1,"...");for(var s=1;s<=e;s++)t+3>s&&t-30||"string"==typeof e}))}}};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex -mx-1",attrs:{id:"pagination"}},[e.pagination.current_page?[n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.first_page)}}},[n("i",{staticClass:"las la-angle-double-left"})]),e._v(" "),e._l(e.getPagination,(function(t,s){return["..."!==e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info",class:e.page==t?"active":"",attrs:{href:"javascript:void(0)"},on:{click:function(n){return e.gotoPage(t)}}},[e._v(e._s(t))]):e._e(),e._v(" "),"..."===e.page?n("a",{key:s,staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button",attrs:{href:"javascript:void(0)"}},[e._v("...")]):e._e()]})),e._v(" "),n("a",{staticClass:"mx-1 flex items-center justify-center h-8 w-8 rounded-full ns-inset-button info shadow",attrs:{href:"javascript:void(0)"},on:{click:function(t){return e.gotoPage(e.pagination.last_page)}}},[n("i",{staticClass:"las la-angle-double-right"})])]:e._e()],2)}),[],!1,null,null,null).exports},3164:(e,t,n)=>{"use strict";n.d(t,{Z:()=>i});const s={data:function(){return{}},name:"ns-switch",mounted:function(){},computed:{_options:function(){var e=this;return this.field.options.map((function(t){return t.selected=t.value===e.field.value,t}))},hasError:function(){return void 0!==this.field.errors&&this.field.errors.length>0},disabledClass:function(){return this.field.disabled?"ns-disabled cursor-not-allowed":""},sizeClass:function(){return" w-1/".concat(this._options.length<=4?this._options.length:4)},inputClass:function(){return this.disabledClass+" "+this.leadClass},leadClass:function(){return this.leading?"pl-8":"px-4"}},methods:{__,setSelected:function(e){this.field.value=e.value,this._options.forEach((function(e){return e.selected=!1})),e.selected=!0,this.$forceUpdate(),this.$emit("change",e.value)}},props:["placeholder","leading","type","field"]};const i=(0,n(1900).Z)(s,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"mb-2 ns-switch"},[n("label",{staticClass:"block leading-5 font-medium",class:e.hasError?"has-error":"is-pristine",attrs:{for:e.field.name}},[e._t("default")],2),e._v(" "),n("div",{staticClass:"rounded-lg flex w-52 overflow-hidden shadow my-1",class:e.hasError?"has-error":""},e._l(e._options,(function(t,s){return n("button",{key:s,staticClass:"p-2 text-sm flex-no-wrap outline-none rounded-none",class:t.selected?"selected "+e.sizeClass:"unselected "+e.inputClass+" "+e.sizeClass,attrs:{disabled:t.disabled},on:{click:function(n){return e.setSelected(t)}}},[e._v(e._s(t.label))])})),0),e._v(" "),e.field.errors&&0!==e.field.errors.length?e._e():n("p",{staticClass:"text-xs ns-description"},[e._t("description")],2),e._v(" "),e._l(e.field.errors,(function(t,s){return n("p",{key:s,staticClass:"text-xs ns-error"},["required"===t.identifier?e._t(t.identifier,(function(){return[e._v(e._s(e.__("This field is required.")))]})):e._e()],2)}))],2)}),[],!1,null,null,null).exports},1274:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>u});var s=n(7757),i=n.n(s),r=n(7700),a=n(665),o=n(3632),l=n(914);function c(e,t,n,s,i,r,a){try{var o=e[r](a),l=o.value}catch(e){return void n(e)}o.done?t(l):Promise.resolve(l).then(s,i)}const d={name:"ns-media",props:["popup"],components:{VueUpload:n(2948)},data:function(){return{pages:[{label:(0,o.__)("Upload"),name:"upload",selected:!1},{label:(0,o.__)("Gallery"),name:"gallery",selected:!0}],resources:[],isDragging:!1,response:{data:[],current_page:0,from:0,to:0,next_page_url:"",prev_page_url:"",path:"",per_page:0,total:0,last_page:0,first_page:0},queryPage:1,bulkSelect:!1,files:[]}},mounted:function(){this.popupCloser();var e=this.pages.filter((function(e){return"gallery"===e.name}))[0];this.select(e)},watch:{files:function(){this.uploadFiles()}},computed:{postMedia:function(){return r.kq.applyFilters("http-client-url","/api/nexopos/v4/medias")},currentPage:function(){return this.pages.filter((function(e){return e.selected}))[0]},hasOneSelected:function(){return this.response.data.filter((function(e){return e.selected})).length>0},selectedResource:function(){return this.response.data.filter((function(e){return e.selected}))[0]},csrf:function(){return ns.authentication.csrf},isPopup:function(){return void 0!==this.$popup},user_id:function(){return this.isPopup&&this.$popupParams.user_id||0},panelOpened:function(){return!this.bulkSelect&&this.hasOneSelected}},methods:{popupCloser:a.Z,__:o.__,cancelBulkSelect:function(){this.bulkSelect=!1,this.response.data.forEach((function(e){return e.selected=!1}))},deleteSelected:function(){var e=this;Popup.show(l.default,{title:(0,o.__)("Confirm Your Action"),message:(0,o.__)("You're about to delete selected resources. Would you like to proceed?"),onAction:function(t){t&&r.ih.post("/api/nexopos/v4/medias/bulk-delete",{ids:e.response.data.filter((function(e){return e.selected})).map((function(e){return e.id}))}).subscribe({next:function(t){r.kX.success(t.message).subscribe(),e.loadGallery()},error:function(e){r.kX.error(e.message).subscribe()}})}})},loadUploadScreen:function(){var e=this;setTimeout((function(){e.setDropZone()}),1e3)},setDropZone:function(){var e=this,t=document.getElementById("dropping-zone");t.addEventListener("dragenter",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragleave",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("dragover",(function(t){return e.preventDefaults(t)}),!1),t.addEventListener("drop",(function(t){return e.preventDefaults(t)}),!1);["dragenter","dragover"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!0}))})),["dragleave","drop"].forEach((function(n){t.addEventListener(n,(function(){e.isDragging=!1}))})),t.addEventListener("drop",(function(t){return e.handleDrop(t)}),!1),this.$refs.files.addEventListener("change",(function(t){return e.processFiles(t.currentTarget.files)}))},uploadFiles:function(){var e,t=this;return(e=i().mark((function e(){var n,s,a;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=t.files.filter((function(e){return!1===e.uploaded&&0===e.progress&&!1===e.failed})),s=i().mark((function e(t){var s;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return s=n[t],e.prev=1,s.progress=1,e.next=5,new Promise((function(e,t){var n=new FormData;n.append("file",s.file),r.ih.post("/api/nexopos/v4/medias",n,{headers:{"Content-Type":"multipart/form-data"}}).subscribe({next:function(t){s.uploaded=!0,s.progress=100,e(t)},error:function(e){t(e)}})}));case 5:e.sent,e.next=11;break;case 8:e.prev=8,e.t0=e.catch(1),s.failed=!0;case 11:case"end":return e.stop()}}),e,null,[[1,8]])})),a=0;case 3:if(!(a0&&void 0!==arguments[0]?arguments[0]:null;t=null===t?this.queryPage:t,this.queryPage=t,r.ih.get("/api/nexopos/v4/medias?page=".concat(t,"&user_id=").concat(this.user_id)).subscribe((function(t){t.data.forEach((function(e){return e.selected=!1})),e.response=t}))},useSelectedEntries:function(){this.$popupParams.resolve({event:"use-selected",value:this.response.data.filter((function(e){return e.selected}))}),this.$popup.close()},selectResource:function(e){var t=this;this.bulkSelect||this.response.data.forEach((function(n,s){s!==t.response.data.indexOf(e)&&(n.selected=!1)})),e.selected=!e.selected}}};const u=(0,n(1900).Z)(d,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex md:flex-row flex-col ns-box shadow-xl overflow-hidden",class:e.isPopup?"w-6/7-screen h-6/7-screen":"w-full h-full",attrs:{id:"ns-media"}},[n("div",{staticClass:"sidebar w-48 md:h-full flex-shrink-0"},[n("h3",{staticClass:"text-xl font-bold my-4 text-center"},[e._v(e._s(e.__("Medias Manager")))]),e._v(" "),n("ul",{staticClass:"sidebar-menus flex md:block"},e._l(e.pages,(function(t,s){return n("li",{key:s,staticClass:"py-2 px-3 cursor-pointer border-l-8",class:t.selected?"active":"",on:{click:function(n){return e.select(t)}}},[e._v(e._s(t.label))])})),0)]),e._v(" "),"upload"===e.currentPage.name?n("div",{staticClass:"content w-full overflow-hidden flex"},[n("div",{staticClass:"flex flex-auto m-2 p-2 flex-col border-info-primary items-center justify-center",class:e.isDragging?"border-dashed border-2":"",attrs:{id:"dropping-zone"},on:{click:function(t){return e.triggerManualUpload()}}},[n("h3",{staticClass:"text-lg md:text-xl font-bold text-center text-primary mb-4"},[e._v(e._s(e.__("Click Here Or Drop Your File To Upload")))]),e._v(" "),n("input",{ref:"files",staticStyle:{display:"none"},attrs:{type:"file",name:"",multiple:"",id:""}}),e._v(" "),n("div",{staticClass:"rounded w-full md:w-2/3 text-primary h-56 overflow-y-auto ns-scrollbar p-2"},[n("ul",e._l(e.files,(function(t,s){return n("li",{key:s,staticClass:"p-2 mb-2 shadow ns-media-upload-item flex items-center justify-between rounded"},[n("span",[e._v(e._s(t.file.name))]),e._v(" "),n("span",{staticClass:"rounded bg-info-primary flex items-center justify-center text-xs p-2"},[e._v(e._s(t.progress)+"%")])])})),0)])])]):e._e(),e._v(" "),"gallery"===e.currentPage.name?n("div",{staticClass:"content flex-col w-full overflow-hidden flex"},[e.popup?n("div",{staticClass:"p-2 flex flex-shrink-0 justify-between"},[n("div"),e._v(" "),n("div",[n("ns-close-button",{on:{click:function(t){return e.popup.close()}}})],1)]):e._e(),e._v(" "),n("div",{staticClass:"flex flex-auto overflow-hidden"},[n("div",{staticClass:"shadow ns-grid flex flex-auto flex-col overflow-y-auto ns-scrollbar"},[n("div",{staticClass:"flex flex-auto"},[n("div",{staticClass:"p-2 overflow-x-auto"},[n("div",{staticClass:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-3 xl:grid-cols-4"},e._l(e.response.data,(function(t,s){return n("div",{key:s},[n("div",{staticClass:"p-2"},[n("div",{staticClass:"rounded-lg aspect-square bg-gray-500 m-2 overflow-hidden flex items-center justify-center",class:t.selected?"ns-media-image-selected ring-4":"",on:{click:function(n){return e.selectResource(t)}}},[n("img",{staticClass:"object-cover h-full",attrs:{src:t.sizes.thumb,alt:t.name}})])])])})),0)]),e._v(" "),0===e.response.data.length?n("div",{staticClass:"flex flex-auto items-center justify-center"},[n("h3",{staticClass:"text-2xl font-bold"},[e._v(e._s(e.__("Nothing has already been uploaded")))])]):e._e()])]),e._v(" "),n("div",{staticClass:"ns-media-preview-panel hidden lg:block w-64 flex-shrink-0",attrs:{id:"preview"}},[n("div",{staticClass:"h-64 bg-gray-800 flex items-center justify-center"},[e.panelOpened?n("img",{attrs:{src:e.selectedResource.sizes.thumb,alt:e.selectedResource.name}}):e._e()]),e._v(" "),e.panelOpened?n("div",{staticClass:"p-4 text-gray-700 text-sm",attrs:{id:"details"}},[n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("File Name"))+": ")]),n("span",[e._v(e._s(e.selectedResource.name))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("Uploaded At"))+":")]),n("span",[e._v(e._s(e.selectedResource.created_at))])]),e._v(" "),n("p",{staticClass:"flex flex-col mb-2"},[n("strong",{staticClass:"font-bold block"},[e._v(e._s(e.__("By"))+" :")]),n("span",[e._v(e._s(e.selectedResource.user.username))])])]):e._e()])]),e._v(" "),n("div",{staticClass:"p-2 flex ns-media-footer flex-shrink-0 justify-between"},[n("div",{staticClass:"flex -mx-2 flex-shrink-0"},[n("div",{staticClass:"px-2 flex-shrink-0 flex"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.cancelBulkSelect()}}},[n("i",{staticClass:"las la-times"})])]):e._e(),e._v(" "),e.hasOneSelected&&!e.bulkSelect?n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){e.bulkSelect=!0}}},[n("i",{staticClass:"las la-check-circle"})])]):e._e(),e._v(" "),e.hasOneSelected?n("div",{staticClass:"ns-button error"},[n("button",{staticClass:"py-2 px-3",on:{click:function(t){return e.deleteSelected()}}},[n("i",{staticClass:"las la-trash"})])]):e._e()])])]),e._v(" "),n("div",{staticClass:"flex-shrink-0 -mx-2 flex"},[n("div",{staticClass:"px-2"},[n("div",{staticClass:"rounded shadow overflow-hidden flex text-sm"},[n("div",{staticClass:"ns-button",class:1===e.response.current_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:1===e.response.current_page},on:{click:function(t){return e.loadGallery(e.response.current_page-1)}}},[e._v(e._s(e.__("Previous")))])]),e._v(" "),n("hr",{staticClass:"border-r border-gray-700"}),e._v(" "),n("div",{staticClass:"ns-button",class:e.response.current_page===e.response.last_page?"disabled cursor-not-allowed":"info"},[n("button",{staticClass:"p-2",attrs:{disabled:e.response.current_page===e.response.last_page},on:{click:function(t){return e.loadGallery(e.response.current_page+1)}}},[e._v(e._s(e.__("Next")))])])])]),e._v(" "),e.popup&&e.hasOneSelected?n("div",{staticClass:"px-2"},[n("div",{staticClass:"ns-button info"},[n("button",{staticClass:"rounded shadow p-2 text-sm",on:{click:function(t){return e.useSelectedEntries()}}},[e._v(e._s(e.__("Use Selected")))])])]):e._e()])])]):e._e()])}),[],!1,null,null,null).exports},914:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>o});var s=n(3632),i=n(2830),r=n(665);const a={data:function(){return{title:"",message:""}},computed:{size:function(){return this.$popupParams.size||"h-full w-full"}},mounted:function(){this.title=this.$popupParams.title,this.message=this.$popupParams.message,this.popupCloser()},methods:{__:s.__,popupResolver:i.Z,popupCloser:r.Z,emitAction:function(e){this.$popupParams.onAction(e),this.$popup.close()}}};const o=(0,n(1900).Z)(a,(function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"flex flex-col shadow-lg w-5/7-screen md:w-4/7-screen lg:w-2/7-screen",class:e.size,attrs:{id:"confirm-popup"}},[n("div",{staticClass:"flex items-center justify-center flex-col flex-auto p-4"},[n("h2",{staticClass:"text-xl md:text-3xl font-body text-center"},[e._v(e._s(e.title))]),e._v(" "),n("p",{staticClass:"py-4 text-sm md:text-base text-center"},[e._v(e._s(e.message))])]),e._v(" "),n("div",{staticClass:"action-buttons flex border-t"},[n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!0)}}},[e._v(e._s(e.__("Yes")))]),e._v(" "),n("hr",{staticClass:"border-r h-16"}),e._v(" "),n("button",{staticClass:"flex-auto rounded-none w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(t){return e.emitAction(!1)}}},[e._v(e._s(e.__("No")))])])])}),[],!1,null,null,null).exports}},e=>{e.O(0,[898],(()=>{return t=6623,e(e.s=t);var t}));e.O()}]); \ No newline at end of file diff --git a/public/js/bootstrap.min/114.js b/public/js/bootstrap.min/114.js new file mode 100644 index 000000000..d120b1bab --- /dev/null +++ b/public/js/bootstrap.min/114.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunknexopos_4x=self.webpackChunknexopos_4x||[]).push([[114,33],{2114:(t,e,s)=>{s.r(e),s.d(e,{default:()=>d});var n=s(7700),i=s(6979),a=s(7962),r=s(914),o=s(3033),u=s(3632),c=s(2277);const l={name:"ns-stock-adjustment",props:["actions"],data:function(){return{search:"",timeout:null,suggestions:[],products:[]}},mounted:function(){console.log(this.actions)},methods:{__:u.__,searchProduct:function(t){var e=this;t.length>0&&n.ih.post("/api/nexopos/v4/procurements/products/search-procurement-product",{argument:t}).subscribe((function(t){if("products"===t.from){if(!(t.products.length>0))return e.closeSearch(),n.kX.error((0,u.__)("Looks like no products matched the searched term.")).subscribe();1===t.products.length?e.addSuggestion(t.products[0]):e.suggestions=t.products}else if("procurements"===t.from){if(null===t.product)return e.closeSearch(),n.kX.error((0,u.__)("Looks like no products matched the searched term.")).subscribe();e.addProductToList(t.product)}}))},addProductToList:function(t){if(this.products.filter((function(e){return e.procurement_product_id===t.id})).length>0)return this.closeSearch(),n.kX.error((0,u.__)("The product already exists on the table.")).subscribe();var e=new Object;t.unit_quantity.unit=t.unit,e.quantities=[t.unit_quantity],e.name=t.name,e.adjust_unit=t.unit_quantity,e.adjust_quantity=1,e.adjust_action="",e.adjust_reason="",e.adjust_value=0,e.id=t.product_id,e.accurate_tracking=1,e.available_quantity=t.available_quantity,e.procurement_product_id=t.id,e.procurement_history=[{label:"".concat(t.procurement.name," (").concat(t.available_quantity,")"),value:t.id}],this.products.push(e),this.closeSearch()},addSuggestion:function(t){var e=this;(0,c.D)([n.ih.get("/api/nexopos/v4/products/".concat(t.id,"/units/quantities"))]).subscribe((function(s){if(!(s[0].length>0))return n.kX.error((0,u.__)("This product does't have any stock to adjust.")).subscribe();t.quantities=s[0],t.adjust_quantity=1,t.adjust_action="",t.adjust_reason="",t.adjust_unit="",t.adjust_value=0,t.procurement_product_id=0,e.products.push(t),e.closeSearch(),t.accurate_tracking}))},closeSearch:function(){this.search="",this.suggestions=[]},recalculateProduct:function(t){""!==t.adjust_unit&&(["deleted","defective","lost"].includes(t.adjust_action)?t.adjust_value=-t.adjust_quantity*t.adjust_unit.sale_price:t.adjust_value=t.adjust_quantity*t.adjust_unit.sale_price),this.$forceUpdate()},openQuantityPopup:function(t){var e=this;t.quantity;new Promise((function(e,s){i.G.show(a.Z,{resolve:e,reject:s,quantity:t.adjust_quantity})})).then((function(s){if(!["added"].includes(t.adjust_action)){if(void 0!==t.accurate_tracking&&s.quantity>t.available_quantity)return n.kX.error((0,u.__)("The specified quantity exceed the available quantity.")).subscribe();if(s.quantity>t.adjust_unit.quantity)return n.kX.error((0,u.__)("The specified quantity exceed the available quantity.")).subscribe()}t.adjust_quantity=s.quantity,e.recalculateProduct(t)}))},proceedStockAdjustment:function(){var t=this;if(0===this.products.length)return n.kX.error((0,u.__)("Unable to proceed as the table is empty.")).subscribe();i.G.show(r.default,{title:(0,u.__)("Confirm Your Action"),message:(0,u.__)("The stock adjustment is about to be made. Would you like to confirm ?"),onAction:function(e){e&&n.ih.post("/api/nexopos/v4/products/adjustments",{products:t.products}).subscribe((function(e){n.kX.success(e.message).subscribe(),t.products=[]}),(function(t){n.kX.error(t.message).subscribe()}))}})},provideReason:function(t){new Promise((function(e,s){i.G.show(o.default,{title:(0,u.__)("More Details"),resolve:e,reject:s,message:(0,u.__)("Useful to describe better what are the reasons that leaded to this adjustment."),input:t.adjust_reason,onAction:function(e){!1!==e&&(t.adjust_reason=e)}})})).then((function(t){n.kX.success((0,u.__)("The reason has been updated.")).susbcribe()})).catch((function(t){}))},removeProduct:function(t){var e=this;i.G.show(r.default,{title:(0,u.__)("Confirm Your Action"),message:(0,u.__)("Would you like to remove this product from the table ?"),onAction:function(s){if(s){var n=e.products.indexOf(t);e.products.splice(n,1)}}})}},watch:{search:function(){var t=this;this.search.length>0?(clearTimeout(this.timeout),this.timeout=setTimeout((function(){t.searchProduct(t.search)}),500)):this.closeSearch()}}};const d=(0,s(1900).Z)(l,(function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",[s("div",{staticClass:"input-field flex border-2 input-group rounded"},[s("input",{directives:[{name:"model",rawName:"v-model",value:t.search,expression:"search"}],staticClass:"p-2 flex-auto outline-none",attrs:{type:"text"},domProps:{value:t.search},on:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"esc",27,e.key,["Esc","Escape"])?null:t.closeSearch()},input:function(e){e.target.composing||(t.search=e.target.value)}}}),t._v(" "),s("button",{staticClass:"px-3 py-2 rounded-none"},[t._v(t._s(t.__("Search")))])]),t._v(" "),t.suggestions.length>0?s("div",{staticClass:"h-0"},[s("div",{},[s("ul",{staticClass:"shadow h-96 relative z-10 ns-vertical-menu zoom-in-entrance anim-duration-300 overflow-y-auto"},t._l(t.suggestions,(function(e){return s("li",{key:e.id,staticClass:"cursor-pointer border-b p-2 flex justify-between",on:{click:function(s){return t.addSuggestion(e)}}},[s("span",[t._v(t._s(e.name))])])})),0)])]):t._e(),t._v(" "),s("div",{staticClass:"ns-box rounded shadow my-2 w-full"},[s("table",{staticClass:"table w-full ns-table"},[s("thead",{staticClass:"border-b"},[s("tr",[s("td",{staticClass:"p-2"},[t._v(t._s(t.__("Product")))]),t._v(" "),s("td",{staticClass:"p-2 text-center",attrs:{width:"120"}},[t._v(t._s(t.__("Unit")))]),t._v(" "),s("td",{staticClass:"p-2 text-center",attrs:{width:"120"}},[t._v(t._s(t.__("Operation")))]),t._v(" "),s("td",{staticClass:"p-2 text-center",attrs:{width:"120"}},[t._v(t._s(t.__("Procurement")))]),t._v(" "),s("td",{staticClass:"p-2 text-center",attrs:{width:"120"}},[t._v(t._s(t.__("Quantity")))]),t._v(" "),s("td",{staticClass:"p-2 text-center",attrs:{width:"120"}},[t._v(t._s(t.__("Value")))]),t._v(" "),s("td",{staticClass:"p-2 text-center",attrs:{width:"150"}},[t._v(t._s(t.__("Actions")))])])]),t._v(" "),s("tbody",[0===t.products.length?s("tr",[s("td",{staticClass:"p-2 text-center",attrs:{colspan:"6"}},[t._v(t._s(t.__("Search and add some products")))])]):t._e(),t._v(" "),t._l(t.products,(function(e){return s("tr",{key:e.id},[s("td",{staticClass:"p-2"},[t._v(t._s(e.name)+" ("+t._s((1===e.accurate_tracking?e.available_quantity:e.adjust_unit.quantity)||0)+")")]),t._v(" "),s("td",{staticClass:"p-2"},[s("div",{staticClass:"input-group border-2 info"},[s("select",{directives:[{name:"model",rawName:"v-model",value:e.adjust_unit,expression:"product.adjust_unit"}],staticClass:"outline-none p-2 w-full",on:{change:[function(s){var n=Array.prototype.filter.call(s.target.options,(function(t){return t.selected})).map((function(t){return"_value"in t?t._value:t.value}));t.$set(e,"adjust_unit",s.target.multiple?n:n[0])},function(s){return t.recalculateProduct(e)}]}},t._l(e.quantities,(function(e){return s("option",{key:e.id,domProps:{value:e}},[t._v(t._s(e.unit.name))])})),0)])]),t._v(" "),s("td",{staticClass:"p-2"},[s("div",{staticClass:"input-group border-2 info"},[s("select",{directives:[{name:"model",rawName:"v-model",value:e.adjust_action,expression:"product.adjust_action"}],staticClass:"outline-none p-2 w-full",attrs:{name:"",id:""},on:{change:[function(s){var n=Array.prototype.filter.call(s.target.options,(function(t){return t.selected})).map((function(t){return"_value"in t?t._value:t.value}));t.$set(e,"adjust_action",s.target.multiple?n:n[0])},function(s){return t.recalculateProduct(e)}]}},t._l(t.actions,(function(e){return s("option",{key:e.value,domProps:{value:e.value}},[t._v(t._s(e.label))])})),0)])]),t._v(" "),s("td",{staticClass:"p-2"},[1===e.accurate_tracking?s("div",{staticClass:"input-group border-2 info"},[s("select",{directives:[{name:"model",rawName:"v-model",value:e.procurement_product_id,expression:"product.procurement_product_id"}],staticClass:"outline-none p-2 bg-white w-full",attrs:{name:"",id:""},on:{change:[function(s){var n=Array.prototype.filter.call(s.target.options,(function(t){return t.selected})).map((function(t){return"_value"in t?t._value:t.value}));t.$set(e,"procurement_product_id",s.target.multiple?n:n[0])},function(s){return t.recalculateProduct(e)}]}},t._l(e.procurement_history,(function(e){return s("option",{key:e.value,domProps:{value:e.value}},[t._v(t._s(e.label))])})),0)]):t._e()]),t._v(" "),s("td",{staticClass:"p-2 flex items-center justify-center cursor-pointer",on:{click:function(s){return t.openQuantityPopup(e)}}},[s("span",{staticClass:"border-b border-dashed border-blue-400 py-2 px-4"},[t._v(t._s(e.adjust_quantity))])]),t._v(" "),s("td",{staticClass:"p-2"},[s("span",{staticClass:"border-b border-dashed border-blue-400 py-2 px-4"},[t._v(t._s(t._f("currency")(e.adjust_value)))])]),t._v(" "),s("td",{staticClass:"p-2"},[s("div",{staticClass:"-mx-1 flex justify-end"},[s("div",{staticClass:"px-1"},[s("button",{staticClass:"ns-inset-button active info border outline-none rounded-full shadow h-10 w-10",on:{click:function(s){return t.provideReason(e)}}},[s("i",{staticClass:"las la-comment-dots"})])]),t._v(" "),s("div",{staticClass:"px-1"},[s("button",{staticClass:"ns-inset-button active error border outline-none rounded-full shadow h-10 w-10",on:{click:function(s){return t.removeProduct(e)}}},[s("i",{staticClass:"las la-times"})])])])])])}))],2)]),t._v(" "),s("div",{staticClass:"border-t ns-box-footer p-2 flex justify-end"},[s("ns-button",{attrs:{type:"info"},on:{click:function(e){return t.proceedStockAdjustment()}}},[t._v(t._s(t.__("Proceed")))])],1)])])}),[],!1,null,null,null).exports},7962:(t,e,s)=>{s.d(e,{Z:()=>u});var n=s(7700),i=s(3632);function a(t){return function(t){if(Array.isArray(t))return r(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(!t)return;if("string"==typeof t)return r(t,e);var s=Object.prototype.toString.call(t).slice(8,-1);"Object"===s&&t.constructor&&(s=t.constructor.name);if("Map"===s||"Set"===s)return Array.from(t);if("Arguments"===s||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s))return r(t,e)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var s=0,n=new Array(e);s{s.r(e),s.d(e,{default:()=>i});const n={data:function(){return{title:"",message:"",input:""}},computed:{size:function(){return this.$popupParams.size||"h-full w-full"}},mounted:function(){var t=this;this.input=this.$popupParams.input||"",this.title=this.$popupParams.title,this.message=this.$popupParams.message,this.$popup.event.subscribe((function(e){"click-overlay"===e.event&&(t.$popupParams.reject(!1),t.$popup.close())}))},methods:{__:s(3632).__,emitAction:function(t){this.$popupParams.onAction(t?this.input:t),this.$popup.close()},reject:function(t){void 0!==this.$popupParams.reject&&this.$popupParams.reject(t),this.$popup.close()}}};const i=(0,s(1900).Z)(n,(function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"w-5/7-screen md:w-3/7-screen flex flex-col shadow-lg",class:t.size,attrs:{id:"prompt-popup"}},[s("div",{staticClass:"flex items-center justify-center flex-col flex-auto p-2"},[s("h2",{staticClass:"text-3xl font-body"},[t._v(t._s(t.title))]),t._v(" "),s("p",{staticClass:"w-full md:mx-auto md:w-2/3 py-4 text-center"},[t._v(t._s(t.message))])]),t._v(" "),s("div",{staticClass:"p-2"},[s("div",{staticClass:"ns-input"},[s("textarea",{directives:[{name:"model",rawName:"v-model",value:t.input,expression:"input"}],staticClass:"w-full border-2 p-2",attrs:{name:"",id:"",cols:"30",rows:"10"},domProps:{value:t.input},on:{input:function(e){e.target.composing||(t.input=e.target.value)}}})])]),t._v(" "),s("div",{staticClass:"flex border-t action-buttons"},[s("button",{staticClass:"flex-auto w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(e){return t.emitAction(!0)}}},[t._v(t._s(t.__("Ok")))]),t._v(" "),s("hr",{staticClass:"border-r"}),t._v(" "),s("button",{staticClass:"flex-auto w-1/2 h-16 flex items-center justify-center uppercase",on:{click:function(e){return t.reject(!1)}}},[t._v(t._s(t.__("Cancel")))])])])}),[],!1,null,null,null).exports}}]); \ No newline at end of file diff --git a/public/js/bootstrap.min/117.js b/public/js/bootstrap.min/117.js new file mode 100644 index 000000000..2b031567b --- /dev/null +++ b/public/js/bootstrap.min/117.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunknexopos_4x=self.webpackChunknexopos_4x||[]).push([[117,33,409,82,804],{4678:(e,t,s)=>{function r(e){POS.changeVisibleSection(e)}s.d(t,{Z:()=>r})},282:(e,t,s)=>{function r(e,t){for(var s=0;sn});var n=function(){function e(t){var s=t.settings,r=t.options,n=t.type;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.printingURL={refund:"refund_printing_url",sale:"sale_printing_url",payment:"payment_printing_url"},this.settings=s,this.options=r,this.type=n||"refund"}var t,s,n;return t=e,(s=[{key:"processRegularPrinting",value:function(e){var t=document.querySelector("printing-section");t&&t.remove();var s=this.settings[this.printingURL[this.type]].replace("{reference_id}",e),r=document.createElement("iframe");r.id="printing-section",r.className="hidden",r.src=s,document.body.appendChild(r),setTimeout((function(){document.querySelector("#printing-section").remove()}),5e3)}},{key:"printOrder",value:function(e){"default"===this.options.ns_pos_printing_gateway?this.processRegularPrinting(e):this.processCustomPrinting(e,this.options.ns_pos_printing_gateway)}},{key:"processCustomPrinting",value:function(e,t){nsHooks.applyFilters("ns-order-custom-refund-print",{printed:!1,reference_id:e,gateway:t}).printed||nsSnackBar.error(__("Unsupported print gateway.")).subscribe()}}])&&r(t.prototype,s),n&&r(t,n),Object.defineProperty(t,"prototype",{writable:!1}),e}()},5502:(e,t,s)=>{s.d(t,{$:()=>c});var r=s(7700),n=s(3632),i=s(6979),o=s(4739);function a(e,t){for(var s=0;sparseFloat(e.$quantities().quantity)-u)return r.kX.error((0,n.__)("Unable to add the product, there is not enough stock. Remaining %s").replace("%s",(e.$quantities().quantity-u).toString())).subscribe()}s({quantity:1})}else c.open(o.Z,{resolve:s,reject:a,product:l,data:e})}))}}])&&a(t.prototype,s),c&&a(t,c),Object.defineProperty(t,"prototype",{writable:!1}),e}()},8909:(e,t,s)=>{s.d(t,{Z:()=>i});var r=s(3632);const n={name:"ns-numpad-plus",props:["value","currency","limit"],data:function(){return{screenValue:0,order:null,cursor:parseInt(ns.currency.ns_currency_precision),orderSubscription:null,allSelected:!0,keyRows:[[7,8,9].map((function(e){return{identifier:e,value:e}})),[4,5,6].map((function(e){return{identifier:e,value:e}})),[1,2,3].map((function(e){return{identifier:e,value:e}})),[{identifier:".",value:"."},{identifier:0,value:0},{identifier:"backspace",icon:"la-backspace"}],[{identifier:"next",value:(0,r.__)("Enter")}]]}},mounted:function(){var e=this;this.screenValue=this.value||0;var t=new Array(10).fill("").map((function(e,t){return t}));nsHotPress.create("numpad-keys").whenVisible([".is-popup"]).whenPressed(t,(function(t,s){e.inputValue({value:s})})),nsHotPress.create("numpad-backspace").whenVisible([".is-popup"]).whenPressed("backspace",(function(){return e.inputValue({identifier:"backspace"})})),nsHotPress.create("numpad-increase").whenVisible([".is-popup"]).whenPressed("+",(function(){return e.increaseBy({value:1})})),nsHotPress.create("numpad-dot").whenVisible([".is-popup"]).whenPressed(".",(function(){return e.inputValue({identifier:"."})})),nsHotPress.create("numpad-reduce").whenVisible([".is-popup"]).whenPressed("-",(function(){return e.increaseBy({value:-1})})),nsHotPress.create("numpad-save").whenVisible([".is-popup"]).whenPressed("enter",(function(){return e.inputValue({identifier:"next"})}))},watch:{value:function(){this.value.toString().length>0?this.screenValue=this.value:this.screenValue=""}},beforeDestroy:function(){nsHotPress.destroy("numpad-backspace"),nsHotPress.destroy("numpad-increase"),nsHotPress.destroy("numpad-reduce"),nsHotPress.destroy("numpad-save"),nsHotPress.destroy("numpad-dot")},methods:{increaseBy:function(e){this.screenValue=(parseFloat(e.value)+(parseFloat(this.screenValue)||0)).toString(),this.allSelected=!1},inputValue:function(e){if("next"!==e.identifier){if("backspace"===e.identifier)this.allSelected?(this.screenValue="0",this.allSelected=!1):this.screenValue=this.screenValue.toString().substr(0,this.screenValue.length-1);else if("."===e.identifier)this.allSelected?(this.screenValue="0.",this.allSelected=!1):null===this.screenValue.toString().match(/^[0-9][1-9]*\.[0-9]*$/)&&(this.screenValue=this.screenValue+=".");else if(e.value.toString().match(/^\d+$/)){if(this.limit>0&&this.screenValue.length>=this.limit)return;this.allSelected?(this.screenValue=e.value.toString(),this.allSelected=!1):(this.screenValue+=""+e.value.toString(),"percentage"===this.mode&&(this.screenValue=this.screenValue>100?100:this.screenValue))}this.$emit("changed",this.screenValue)}else this.$emit("next",this.screenValue)}}};const i=(0,s(1900).Z)(n,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{attrs:{id:"numpad-holder"}},e._l(e.keyRows,(function(t,r){return s("div",{key:r},[s("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-1 text-lg",attrs:{id:"numpad"}},[e._l(t,(function(r,n){return s("div",{key:n,staticClass:"select-none ns-numpad-key border-l border-b h-24 font-bold flex items-center justify-center cursor-pointer",class:1===t.length?"col-span-3":"",on:{click:function(t){return e.inputValue(r)}}},[void 0!==r.value?s("span",[e._v(e._s(r.value))]):e._e(),e._v(" "),r.icon?s("i",{staticClass:"las",class:r.icon}):e._e()])})),e._v(" "),e._t("numpad-footer")],2)])})),0)}),[],!1,null,null,null).exports},82:(e,t,s)=>{s.r(t),s.d(t,{default:()=>xe});var r=s(7757),n=s.n(r),i=s(6979),o=s(2830),a=s(3632);function c(e){return function(e){if(Array.isArray(e))return l(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return l(e,t);var s=Object.prototype.toString.call(e).slice(8,-1);"Object"===s&&e.constructor&&(s=e.constructor.name);if("Map"===s||"Set"===s)return Array.from(e);if("Arguments"===s||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s))return l(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var s=0,r=new Array(t);s100?100:this.finalValue))}}};var d=s(1900);const p=(0,d.Z)(u,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"ns-box shadow min-h-2/5-screen w-6/7-screen md:w-3/5-screen lg:w-3/5-screen xl:w-2/5-screen relative",attrs:{id:"discount-popup"}},[s("div",{staticClass:"flex-shrink-0 flex justify-between items-center p-2 border-b ns-box-header"},[s("div",["product"===e.type?s("h1",{staticClass:"text-xl font-bold text-primary text-center"},[e._v(e._s(e.__("Product Discount")))]):e._e(),e._v(" "),"cart"===e.type?s("h1",{staticClass:"text-xl font-bold text-primary text-center"},[e._v(e._s(e.__("Cart Discount")))]):e._e()]),e._v(" "),s("div",[s("ns-close-button",{on:{click:function(t){return e.closePopup()}}})],1)]),e._v(" "),s("div",{staticClass:"h-16 ns-box-body text-white flex items-center justify-center",attrs:{id:"screen"}},[s("h1",{staticClass:"font-bold text-3xl"},["flat"===e.mode?s("span",[e._v(e._s(e._f("currency")(e.finalValue)))]):e._e(),e._v(" "),"percentage"===e.mode?s("span",[e._v(e._s(e.finalValue)+"%")]):e._e()])]),e._v(" "),s("div",{staticClass:"flex",attrs:{id:"switch-mode"}},[s("button",{staticClass:"outline-none w-1/2 py-2 flex items-center justify-center",class:"flat"===e.mode?"bg-tab-active":"bg-tab-inactive text-tertiary",on:{click:function(t){return e.setPercentageType("flat")}}},[e._v(e._s(e.__("Flat")))]),e._v(" "),s("hr",{staticClass:"border-r border-box-edge"}),e._v(" "),s("button",{staticClass:"outline-none w-1/2 py-2 flex items-center justify-center",class:"percentage"===e.mode?"bg-tab-active":"bg-tab-inactive text-tertiary",on:{click:function(t){return e.setPercentageType("percentage")}}},[e._v(e._s(e.__("Percentage")))])]),e._v(" "),s("div",{staticClass:"grid grid-flow-row grid-cols-3 grid-rows-3",attrs:{id:"numpad"}},e._l(e.keys,(function(t,r){return s("div",{key:r,staticClass:"text-primary ns-numpad-key info text-xl font-bold border h-24 flex items-center justify-center cursor-pointer",on:{click:function(s){return e.inputValue(t)}}},[void 0!==t.value?s("span",[e._v(e._s(t.value))]):e._e(),e._v(" "),t.icon?s("i",{staticClass:"las",class:t.icon}):e._e()])})),0)])}),[],!1,null,null,null).exports;var f=s(914),_=s(7700);function v(e){return function(e){if(Array.isArray(e))return m(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return m(e,t);var s=Object.prototype.toString.call(e).slice(8,-1);"Object"===s&&e.constructor&&(s=e.constructor.name);if("Map"===s||"Set"===s)return Array.from(e);if("Arguments"===s||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(s))return m(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var s=0,r=new Array(t);s100?100:this.backValue))),"0"===this.backValue&&(this.backValue="")}}};const h=(0,d.Z)(b,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"h-full w-full py-2"},[e.order?s("div",{staticClass:"px-2 pb-2"},[s("div",{staticClass:"grid grid-cols-2 gap-2"},[s("div",{staticClass:"h-16 flex justify-between items-center border elevation-surface info text-xl md:text-3xl p-2",attrs:{id:"details"}},[s("span",[e._v(e._s(e.__("Total"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.total)))])]),e._v(" "),s("div",{staticClass:"cursor-pointer h-16 flex justify-between items-center border elevation-surface error text-xl md:text-3xl p-2",attrs:{id:"discount"},on:{click:function(t){return e.toggleDiscount()}}},[s("span",[e._v(e._s(e.__("Discount"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.discount)))])]),e._v(" "),s("div",{staticClass:"h-16 flex justify-between items-center border elevation-surface success text-xl md:text-3xl p-2",attrs:{id:"paid"}},[s("span",[e._v(e._s(e.__("Paid"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.tendered)))])]),e._v(" "),s("div",{staticClass:"h-16 flex justify-between items-center border elevation-surface warning text-xl md:text-3xl p-2",attrs:{id:"change"}},[s("span",[e._v(e._s(e.__("Change"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.change)))])]),e._v(" "),s("div",{staticClass:"col-span-2 h-16 flex justify-between items-center elevation-surface border text-xl md:text-3xl p-2",attrs:{id:"change"}},[s("span",[e._v(e._s(e.__("Screen"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.backValue/e.number)))])])])]):e._e(),e._v(" "),s("div",{staticClass:"px-2 pb-2"},[s("div",{staticClass:"-mx-2 flex flex-wrap"},[s("div",{staticClass:"pl-2 pr-1 flex-auto"},[s("div",{staticClass:"grid grid-flow-row grid-cols-3 gap-2 grid-rows-3",staticStyle:{padding:"1px"},attrs:{id:"numpad"}},[e._l(e.keys,(function(t,r){return s("div",{key:r,staticClass:"ns-numpad-key text-2xl border h-16 flex items-center justify-center cursor-pointer",staticStyle:{margin:"-1px"},on:{click:function(s){return e.inputValue(t)}}},[void 0!==t.value?s("span",[e._v(e._s(t.value))]):e._e(),e._v(" "),t.icon?s("i",{staticClass:"las",class:t.icon}):e._e()])})),e._v(" "),s("div",{staticClass:"hover:bg-green-500 col-span-3 bg-success-secondary border-success-tertiary text-2xl text-white border h-16 flex items-center justify-center cursor-pointer",on:{click:function(t){return e.makeFullPayment()}}},[e._v("\n "+e._s(e.__("Full Payment")))])],2)]),e._v(" "),s("div",{staticClass:"w-1/2 md:w-72 pr-2 pl-1"},[s("div",{staticClass:"grid grid-flow-row grid-rows-1 gap-2"},e._l(e.amountShortcuts,(function(t,r){return s("div",{key:r,staticClass:"ns-numpad-key text-2xl border h-16 flex items-center justify-center cursor-pointer",on:{click:function(s){return e.increaseBy({value:t})}}},[s("span",[e._v(e._s(e._f("currency")(t)))])])})),0)])])])])}),[],!1,null,null,null).exports,y={name:"cash-payment",props:["identifier","label"],components:{samplePayment:h}};const x=(0,d.Z)(y,(function(){var e=this,t=e.$createElement;return(e._self._c||t)("sample-payment",{attrs:{identifier:e.identifier,label:e.label},on:{submit:function(t){return e.$emit("submit")}}})}),[],!1,null,null,null).exports;const g={name:"creditcart-payment",props:["identifier"]};const C=(0,d.Z)(g,(function(){var e=this,t=e.$createElement;return(e._self._c||t)("h1",[e._v("Credit Card")])}),[],!1,null,null,null).exports;const w={name:"bank-payment",props:["identifier","label"],components:{samplePayment:h}};const P=(0,d.Z)(w,(function(){var e=this,t=e.$createElement;return(e._self._c||t)("sample-payment",{attrs:{identifier:e.identifier,label:e.label},on:{submit:function(t){return e.$emit("submit")}}})}),[],!1,null,null,null).exports;var k=s(7751);const S={name:"ns-account-payment",components:{nsNumpad:k.Z},props:["identifier","label"],data:function(){return{subscription:null,screenValue:0,order:null}},methods:{__:a.__,handleChange:function(e){this.screenValue=e},proceedAddingPayment:function(e){var t=parseFloat(e),s=this.order.payments;return t<=0?_.kX.error((0,a.__)("Please provide a valid payment amount.")).subscribe():s.filter((function(e){return"account-payment"===e.identifier})).length>0?_.kX.error((0,a.__)("The customer account can only be used once per order. Consider deleting the previously used payment.")).subscribe():t>this.order.customer.account_amount?_.kX.error((0,a.__)("Not enough funds to add {amount} as a payment. Available balance {balance}.").replace("{amount}",this.$options.filters.currency(t)).replace("{balance}",this.$options.filters.currency(this.order.customer.account_amount))).subscribe():(POS.addPayment({value:t,identifier:"account-payment",selected:!1,label:this.label,readonly:!1}),this.order.customer.account_amount-=t,POS.selectCustomer(this.order.customer),void this.$emit("submit"))},proceedFullPayment:function(){this.proceedAddingPayment(this.order.total)},makeFullPayment:function(){var e=this;Popup.show(f.default,{title:(0,a.__)("Confirm Full Payment"),message:(0,a.__)("You're about to use {amount} from the customer account to make a payment. Would you like to proceed ?").replace("{amount}",this.$options.filters.currency(this.order.total)),onAction:function(t){t&&e.proceedFullPayment()}})}},mounted:function(){var e=this;this.subscription=POS.order.subscribe((function(t){return e.order=t}))},destroyed:function(){this.subscription.unsubscribe()}};const O=(0,d.Z)(S,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"h-full w-full py-2"},[e.order?s("div",{staticClass:"px-2 pb-2"},[s("div",{staticClass:"grid grid-cols-2 gap-2"},[s("div",{staticClass:"h-16 flex justify-between items-center elevation-surface border info text-xl md:text-3xl p-2",attrs:{id:"details"}},[s("span",[e._v(e._s(e.__("Total"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.total)))])]),e._v(" "),s("div",{staticClass:"cursor-pointer h-16 flex justify-between items-center elevation-surface error border text-xl md:text-3xl p-2",attrs:{id:"discount"},on:{click:function(t){return e.toggleDiscount()}}},[s("span",[e._v(e._s(e.__("Discount"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.discount)))])]),e._v(" "),s("div",{staticClass:"h-16 flex justify-between items-center elevation-surface success border text-xl md:text-3xl p-2",attrs:{id:"paid"}},[s("span",[e._v(e._s(e.__("Paid"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.tendered)))])]),e._v(" "),s("div",{staticClass:"h-16 flex justify-between items-center elevation-surface warning border text-xl md:text-3xl p-2",attrs:{id:"change"}},[s("span",[e._v(e._s(e.__("Change"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.change)))])]),e._v(" "),s("div",{staticClass:"col-span-2 h-16 flex justify-between items-center elevation-surface border success text-xl md:text-3xl p-2",attrs:{id:"change"}},[s("span",[e._v(e._s(e.__("Current Balance"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.order.customer.account_amount)))])]),e._v(" "),s("div",{staticClass:"col-span-2 h-16 flex justify-between items-center elevation-surface border text-primary text-xl md:text-3xl p-2",attrs:{id:"change"}},[s("span",[e._v(e._s(e.__("Screen"))+" : ")]),e._v(" "),s("span",[e._v(e._s(e._f("currency")(e.screenValue)))])])])]):e._e(),e._v(" "),s("div",{staticClass:"px-2 pb-2"},[s("div",{staticClass:"-mx-2 flex flex-wrap"},[s("div",{staticClass:"pl-2 pr-1 flex-auto"},[s("ns-numpad",{attrs:{floating:!0},on:{changed:function(t){return e.handleChange(t)},next:function(t){return e.proceedAddingPayment(t)}},scopedSlots:e._u([{key:"numpad-footer",fn:function(){return[s("div",{staticClass:"hover:bg-success-tertiary col-span-3 bg-success-secondary text-2xl text-white border border-success-secondary h-16 flex items-center justify-center cursor-pointer",on:{click:function(t){return e.makeFullPayment()}}},[e._v("\n "+e._s(e.__("Full Payment")))])]},proxy:!0}])})],1),e._v(" "),s("div",{staticClass:"w-1/2 md:w-72 pr-2 pl-1"},[s("div",{staticClass:"grid grid-flow-row grid-rows-1 gap-2"},[s("div",{staticClass:"elevation-surface border hoverable text-2xl text-primary h-16 flex items-center justify-center cursor-pointer",on:{click:function(t){return e.increaseBy({value:100})}}},[s("span",[e._v(e._s(e._f("currency")(100)))])]),e._v(" "),s("div",{staticClass:"elevation-surface border hoverable text-2xl text-primary h-16 flex items-center justify-center cursor-pointer",on:{click:function(t){return e.increaseBy({value:500})}}},[s("span",[e._v(e._s(e._f("currency")(500)))])]),e._v(" "),s("div",{staticClass:"elevation-surface border hoverable text-2xl text-primary h-16 flex items-center justify-center cursor-pointer",on:{click:function(t){return e.increaseBy({value:1e3})}}},[s("span",[e._v(e._s(e._f("currency")(1e3)))])])])])])])])}),[],!1,null,null,null).exports;var j=s(409),T=s(2614);function $(e,t){var s=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),s.push.apply(s,r)}return s}function V(e){for(var t=1;t0&&e[0]},expectedPayment:function(){var e=this.order.customer.group.minimal_credit_payment;return this.order.total*e/100}},mounted:function(){var e=this;this.$popup.event.subscribe((function(t){if("click-overlay"===t.event)e.closePopup()})),this.order=this.$popupParams.order,this.paymentTypesSubscription=POS.paymentsType.subscribe((function(t){e.paymentsType=t,t.filter((function(e){e.selected&&POS.selectedPaymentType.next(e)}))})),nsHooks.doAction("ns-pos-payment-mounted",this)},watch:{activePayment:function(e){this.loadPaymentComponent(e)}},destroyed:function(){this.paymentTypesSubscription.unsubscribe(),nsHooks.doAction("ns-pos-payment-destroyed",this)},methods:{__:a.__,resolveIfQueued:o.Z,loadPaymentComponent:function(e){switch(e.identifier){case"cash-payment":this.currentPaymentComponent=x;break;case"creditcard-payment":this.currentPaymentComponent=C;break;case"bank-payment":this.currentPaymentComponent=P;break;case"account-payment":this.currentPaymentComponent=O;break;default:this.currentPaymentComponent=h}},selectPayment:function(){var e,t=this;return(e=n().mark((function e(){var s;return n().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,new Promise((function(e,s){i.G.show(T.Z,{label:(0,a.__)("Select Payment Gateway"),options:t.paymentsType.map((function(e){return{label:e.label,value:e.identifier}})),value:t.activePayment.identifier,resolve:e,reject:s})}));case 3:s=e.sent,t.select(t.paymentsType.filter((function(e){return e.identifier===s[0].value}))[0]),e.next=9;break;case 7:e.prev=7,e.t0=e.catch(0);case 9:case"end":return e.stop()}}),e,null,[[0,7]])})),function(){var t=this,s=arguments;return new Promise((function(r,n){var i=e.apply(t,s);function o(e){Z(i,r,n,o,a,"next",e)}function a(e){Z(i,r,n,o,a,"throw",e)}o(void 0)}))})()},select:function(e){this.showPayment=!1,POS.setPaymentActive(e)},closePopup:function(){this.$popup.close(),POS.selectedPaymentType.next(null)},deletePayment:function(e){POS.removePayment(e)},selectPaymentAsActive:function(e){this.select(this.paymentsType.filter((function(t){return t.identifier===e.target.value}))[0])},submitOrder:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},s=i.G.show(j.default);try{var r=V(V({},POS.order.getValue()),t);POS.submitOrder(r).then((function(t){s.close(),_.kX.success(t.message).subscribe(),POS.printOrderReceipt(t.data.order),e.$popup.close()}),(function(e){s.close(),_.kX.error(e.message).subscribe()}))}catch(e){s.close(),_.kX.error(error.message).subscribe()}}}};const D=(0,d.Z)(F,(function(){var e=this,t=e.$createElement,s=e._self._c||t;return e.order?s("div",{staticClass:"w-screen h-screen p-4 flex overflow-hidden",attrs:{id:"ns-payment-popup"}},[s("div",{staticClass:"flex flex-col flex-auto lg:flex-row shadow-xl"},[s("div",{staticClass:"w-full lg:w-56 lg:h-full flex justify-between px-2 lg:px-0 lg:block items-center lg:items-start"},[s("h3",{staticClass:"lg:hidden text-xl text-center my-4 font-bold lg:my-8"},[e._v(e._s(e.__("Gateway"))+" "),s("span",[e._v(": "+e._s(e.activePayment.label))])]),e._v(" "),s("div",{staticClass:"h-16 hidden lg:block"}),e._v(" "),s("ul",{staticClass:"hidden lg:block"},[e._l(e.paymentsType,(function(t){return s("li",{key:t.identifier,staticClass:"cursor-pointer ns-payment-gateway py-2 px-3",class:t.selected&&!e.showPayment?"ns-visible":"",on:{click:function(s){return e.select(t)}}},[e._v(e._s(t.label))])})),e._v(" "),s("li",{staticClass:"cursor-pointer py-2 px-3 ns-payment-list border-t mt-4 flex items-center justify-between",class:e.showPayment?"ns-visible":"",on:{click:function(t){e.showPayment=!0}}},[s("span",[e._v(e._s(e.__("Payment List")))]),e._v(" "),s("span",{staticClass:"px-2 rounded-full h-8 w-8 flex items-center justify-center ns-label"},[e._v(e._s(e.order.payments.length))])])],2),e._v(" "),s("ns-close-button",{staticClass:"lg:hidden",on:{click:function(t){return e.closePopup()}}})],1),e._v(" "),s("div",{staticClass:"overflow-hidden flex flex-col flex-auto"},[s("div",{staticClass:"flex flex-col flex-auto overflow-hidden"},[s("div",{staticClass:"h-12 hidden items-center justify-between lg:flex"},[s("div",[s("h3",{staticClass:"text-xl hidden lg:block text-center my-4 font-bold lg:my-8"},[e._v(e._s(e.__("Gateway"))+" "),s("span",{staticClass:"hidden-md"},[e._v(": "+e._s(e.activePayment.label))])])]),e._v(" "),s("div",{staticClass:"px-2"},[s("ns-close-button",{on:{click:function(t){return e.closePopup()}}})],1)]),e._v(" "),e.showPayment?e._e():s("div",{staticClass:"flex flex-auto ns-payment-wrapper overflow-y-auto"},[s(e.currentPaymentComponent,{tag:"component",attrs:{label:e.activePayment.label,identifier:e.activePayment.identifier},on:{submit:function(t){return e.submitOrder()}}})],1),e._v(" "),e.showPayment?s("div",{staticClass:"flex flex-auto ns-payment-wrapper overflow-y-auto p-2 flex-col"},[s("h3",{staticClass:"text-center font-bold py-2"},[e._v(e._s(e.__("List Of Payments")))]),e._v(" "),s("ul",{staticClass:"flex-auto"},[0===e.order.payments.length?s("li",{staticClass:"p-2 flex justify-center mb-2 items-center"},[s("h3",{staticClass:"font-semibold"},[e._v(e._s(e.__("No Payment added.")))])]):e._e(),e._v(" "),e._l(e.order.payments,(function(t,r){return s("li",{key:r,staticClass:"p-2 flex justify-between mb-2 items-center"},[s("span",[e._v(e._s(t.label))]),e._v(" "),s("div",{staticClass:"flex items-center"},[s("span",[e._v(e._s(e._f("currency")(t.value)))]),e._v(" "),s("button",{staticClass:"rounded-full h-8 w-8 flex items-center justify-center ml-2",on:{click:function(s){return e.deletePayment(t)}}},[s("i",{staticClass:"las la-trash-alt"})])])])}))],2)]):e._e()]),e._v(" "),s("div",{staticClass:"flex lg:hidden ns-payment-buttons"},[s("button",{staticClass:"flex items-center justify-center w-1/3 text-2xl flex-auto h-12 font-bold ns-payment-type-button",on:{click:function(t){return e.selectPayment()}}},[s("span",{staticClass:"text-sm"},[e._v(e._s(e.__("Payment Type")))])]),e._v(" "),e.order.tendered>=e.order.total?s("button",{staticClass:"flex items-center justify-center w-1/3 text-2xl flex-auto h-12 ns-submit-button font-bold",on:{click:function(t){return e.submitOrder()}}},[s("span",{staticClass:"text-sm"},[e._v(e._s(e.__("Submit Payment")))])]):e._e(),e._v(" "),e.order.tendered