{"version":3,"file":"phoenix.js","sources":["../../../src/js/utils.js","../../../src/js/docs.js","../../../src/js/theme/advance-ajax-table.js","../../../src/js/theme/anchor.js","../../../src/js/theme/bigPicture.js","../../../src/js/theme/node.js","../../../src/js/theme/bulk-select.js","../../../src/js/theme/charts/echarts/echarts-utils.js","../../../src/js/theme/charts/echarts/basic-echarts.js","../../../src/js/theme/charts/echarts/reports-details-chart.js","../../../src/js/theme/chat.js","../../../src/js/theme/choices.js","../../../src/js/theme/copyLink.js","../../../src/js/theme/countUp.js","../../../src/js/theme/create-board.js","../../../src/js/theme/detector.js","../../../src/js/theme/dropdown-on-hover.js","../../../src/js/theme/dropzone.js","../../../src/js/theme/featherIcons.js","../../../node_modules/flatpickr/dist/esm/types/options.js","../../../node_modules/flatpickr/dist/esm/l10n/default.js","../../../node_modules/flatpickr/dist/esm/utils/index.js","../../../node_modules/flatpickr/dist/esm/utils/dom.js","../../../node_modules/flatpickr/dist/esm/utils/formatting.js","../../../node_modules/flatpickr/dist/esm/utils/dates.js","../../../node_modules/flatpickr/dist/esm/utils/polyfills.js","../../../node_modules/flatpickr/dist/esm/index.js","../../../src/js/theme/flatpickr.js","../../../src/js/theme/form-validation.js","../../../src/js/theme/fullcalendar.js","../../../src/js/theme/glightbox.js","../../../src/js/theme/googleMap.js","../../../src/js/theme/icons.js","../../../src/js/theme/isotope.js","../../../src/js/theme/list.js","../../../src/js/theme/lottie.js","../../../src/js/theme/modal.js","../../../src/js/theme/navbar-combo.js","../../../src/js/theme/navbar-shadow-on-scroll.js","../../../src/js/theme/navbar-soft-on-scroll.js","../../../src/js/theme/navbar-vertical.js","../../../src/js/theme/phoenix-offcanvas.js","../../../src/js/theme/picmo.js","../../../src/js/theme/popover.js","../../../src/js/theme/product-details.js","../../../src/js/theme/quantity.js","../../../src/js/theme/randomColor.js","../../../src/js/theme/rater.js","../../../src/js/theme/responsiveNavItems.js","../../../src/js/theme/search.js","../../../src/js/theme/simplabar.js","../../../src/js/theme/sortable.js","../../../src/js/theme/support-chat.js","../../../src/js/theme/swiper.js","../../../src/js/theme/theme-control.js","../../../src/js/theme/tinymce.js","../../../src/js/theme/toast.js","../../../src/js/theme/todoOffCanvas.js","../../../src/js/theme/tooltip.js","../../../src/js/theme/wizard.js","../../../src/js/theme/faq-tab.js","../../../src/js/theme/kanban.js","../../../src/js/theme/2fa-verification.js","../../../src/js/phoenix.js"],"sourcesContent":["/* -------------------------------------------------------------------------- */\n/* Utils */\n/* -------------------------------------------------------------------------- */\nexport const docReady = fn => {\n // see if DOM is already available\n if (document.readyState === 'loading') {\n document.addEventListener('DOMContentLoaded', fn);\n } else {\n setTimeout(fn, 1);\n }\n};\n\nexport const toggleColor = (lightColor, darkColor) => {\n const currentMode = getItemFromStore('phoenixTheme');\n const mode = currentMode === 'auto' ? getSystemTheme() : currentMode;\n return mode === 'light' ? lightColor : darkColor;\n};\n\nexport const resize = fn => window.addEventListener('resize', fn);\n\nexport const isIterableArray = array => Array.isArray(array) && !!array.length;\n\nexport const camelize = str => {\n const text = str.replace(/[-_\\s.]+(.)?/g, (_, c) =>\n c ? c.toUpperCase() : ''\n );\n return `${text.substr(0, 1).toLowerCase()}${text.substr(1)}`;\n};\n\nexport const getData = (el, data) => {\n try {\n return JSON.parse(el.dataset[camelize(data)]);\n } catch (e) {\n return el.dataset[camelize(data)];\n }\n};\n\n/* ----------------------------- Colors function ---------------------------- */\n\nexport const hexToRgb = hexValue => {\n let hex;\n hexValue.indexOf('#') === 0\n ? (hex = hexValue.substring(1))\n : (hex = hexValue);\n // Expand shorthand form (e.g. \"03F\") to full form (e.g. \"0033FF\")\n const shorthandRegex = /^#?([a-f\\d])([a-f\\d])([a-f\\d])$/i;\n const result = /^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(\n hex.replace(shorthandRegex, (m, r, g, b) => r + r + g + g + b + b)\n );\n return result\n ? [\n parseInt(result[1], 16),\n parseInt(result[2], 16),\n parseInt(result[3], 16)\n ]\n : null;\n};\n\nexport const rgbaColor = (color = '#fff', alpha = 0.5) =>\n `rgba(${hexToRgb(color)}, ${alpha})`;\n\n/* --------------------------------- Colors --------------------------------- */\n\nexport const getColor = (name, dom = document.documentElement) => {\n return getComputedStyle(dom).getPropertyValue(`--phoenix-${name}`).trim();\n};\n\nexport const hasClass = (el, className) => {\n !el && false;\n return el.classList.value.includes(className);\n};\n\nexport const addClass = (el, className) => {\n el.classList.add(className);\n};\n\nexport const getOffset = el => {\n const rect = el.getBoundingClientRect();\n const scrollLeft = window.pageXOffset || document.documentElement.scrollLeft;\n const scrollTop = window.pageYOffset || document.documentElement.scrollTop;\n return { top: rect.top + scrollTop, left: rect.left + scrollLeft };\n};\n\nexport const isScrolledIntoView = el => {\n let top = el.offsetTop;\n let left = el.offsetLeft;\n const width = el.offsetWidth;\n const height = el.offsetHeight;\n\n while (el.offsetParent) {\n // eslint-disable-next-line no-param-reassign\n el = el.offsetParent;\n top += el.offsetTop;\n left += el.offsetLeft;\n }\n\n return {\n all:\n top >= window.pageYOffset &&\n left >= window.pageXOffset &&\n top + height <= window.pageYOffset + window.innerHeight &&\n left + width <= window.pageXOffset + window.innerWidth,\n partial:\n top < window.pageYOffset + window.innerHeight &&\n left < window.pageXOffset + window.innerWidth &&\n top + height > window.pageYOffset &&\n left + width > window.pageXOffset\n };\n};\n\nexport const breakpoints = {\n xs: 0,\n sm: 576,\n md: 768,\n lg: 992,\n xl: 1200,\n xxl: 1540\n};\n\nexport const getBreakpoint = el => {\n const classes = el && el.classList.value;\n let breakpoint;\n if (classes) {\n breakpoint =\n breakpoints[\n classes\n .split(' ')\n .filter(cls => cls.includes('navbar-expand-'))\n .pop()\n .split('-')\n .pop()\n ];\n }\n return breakpoint;\n};\n\n/* --------------------------------- Cookie --------------------------------- */\n\nexport const setCookie = (name, value, expire) => {\n const expires = new Date();\n expires.setTime(expires.getTime() + expire);\n document.cookie = `${name}=${value};expires=${expires.toUTCString()}`;\n};\n\nexport const getCookie = name => {\n const keyValue = document.cookie.match(`(^|;) ?${name}=([^;]*)(;|$)`);\n return keyValue ? keyValue[2] : keyValue;\n};\n\nexport const settings = {\n tinymce: {\n theme: 'oxide'\n },\n chart: {\n borderColor: 'rgba(255, 255, 255, 0.8)'\n }\n};\n\n/* -------------------------- Chart Initialization -------------------------- */\n\nexport const newChart = (chart, config) => {\n const ctx = chart.getContext('2d');\n return new window.Chart(ctx, config);\n};\n\n/* ---------------------------------- Store --------------------------------- */\n\nexport const getItemFromStore = (key, defaultValue, store = localStorage) => {\n try {\n return JSON.parse(store.getItem(key)) || defaultValue;\n } catch {\n return store.getItem(key) || defaultValue;\n }\n};\n\nexport const setItemToStore = (key, payload, store = localStorage) =>\n store.setItem(key, payload);\nexport const getStoreSpace = (store = localStorage) =>\n parseFloat(\n (\n escape(encodeURIComponent(JSON.stringify(store))).length /\n (1024 * 1024)\n ).toFixed(2)\n );\n\n/* get Dates between */\n\nexport const getDates = (\n startDate,\n endDate,\n interval = 1000 * 60 * 60 * 24\n) => {\n const duration = endDate - startDate;\n const steps = duration / interval;\n return Array.from(\n { length: steps + 1 },\n (v, i) => new Date(startDate.valueOf() + interval * i)\n );\n};\n\nexport const getPastDates = duration => {\n let days;\n\n switch (duration) {\n case 'week':\n days = 7;\n break;\n case 'month':\n days = 30;\n break;\n case 'year':\n days = 365;\n break;\n\n default:\n days = duration;\n }\n\n const date = new Date();\n const endDate = date;\n const startDate = new Date(new Date().setDate(date.getDate() - (days - 1)));\n return getDates(startDate, endDate);\n};\n\n/* Get Random Number */\nexport const getRandomNumber = (min, max) => {\n return Math.floor(Math.random() * (max - min) + min);\n};\n\nexport const getSystemTheme = () =>\n window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';\n\n// export const handleThemeDropdownIcon = value => {\n// document.querySelectorAll('[data-theme-dropdown-toggle-icon]').forEach(el => {\n// const theme = getData(el, 'theme-dropdown-toggle-icon');\n\n// if (value === theme) {\n// el.classList.remove('d-none');\n// } else {\n// el.classList.add('d-none');\n// }\n// });\n// };\n// handleThemeDropdownIcon(getItemFromStore('phoenixTheme'));\n\nexport default {\n docReady,\n toggleColor,\n resize,\n isIterableArray,\n camelize,\n getData,\n hasClass,\n addClass,\n hexToRgb,\n rgbaColor,\n getColor,\n breakpoints,\n // getGrays,\n getOffset,\n isScrolledIntoView,\n getBreakpoint,\n setCookie,\n getCookie,\n newChart,\n settings,\n getItemFromStore,\n setItemToStore,\n getStoreSpace,\n getDates,\n getPastDates,\n getRandomNumber,\n getSystemTheme\n // handleThemeDropdownIcon\n};\n","import { Collapse, Toast } from 'bootstrap';\n\nconst docComponentInit = () => {\n const componentCards = document.querySelectorAll('[data-component-card]');\n const iconCopiedToast = document.getElementById('icon-copied-toast');\n const iconCopiedToastInstance = new Toast(iconCopiedToast);\n\n componentCards.forEach(card => {\n const copyCodeBtn = card.querySelector('.copy-code-btn');\n const copyCodeEl = card.querySelector('.code-to-copy');\n const previewBtn = card.querySelector('.preview-btn');\n const collapseElement = card.querySelector('.code-collapse');\n const collapseInstance = Collapse.getOrCreateInstance(collapseElement, {\n toggle: false\n });\n\n previewBtn?.addEventListener('click', () => {\n collapseInstance.toggle();\n });\n\n copyCodeBtn?.addEventListener('click', () => {\n const el = document.createElement('textarea');\n el.value = copyCodeEl.innerHTML;\n document.body.appendChild(el);\n\n el.select();\n document.execCommand('copy');\n document.body.removeChild(el);\n\n iconCopiedToast.querySelector(\n '.toast-body'\n ).innerHTML = `Code has been copied to clipboard.
`;\n iconCopiedToastInstance.show();\n });\n });\n};\n\nexport default docComponentInit;\n","/* eslint-disable */\nconst orders = [\n {\n id: 1,\n dropdownId: 'order-dropdown-1',\n orderId: '#2181',\n mailLink: 'mailto:carry@example.com',\n customer: 'Carry Anna',\n date: '10/03/2023',\n address: 'Carry Anna, 2392 Main Avenue, Penasauka, New Jersey 02149',\n deliveryType: 'Cash on Delivery',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$99'\n },\n {\n id: 2,\n dropdownId: 'order-dropdown-2',\n orderId: '#2182',\n mailLink: 'mailto:milind@example.com',\n customer: 'Milind Mikuja',\n date: '10/03/2023',\n address: 'Milind Mikuja, 1 Hollywood Blvd,Beverly Hills, California 90210',\n deliveryType: 'Cash on Delivery',\n status: 'Processing',\n badge: { type: 'primary', icon: 'fas fa-redo' },\n amount: '$120'\n },\n {\n id: 3,\n dropdownId: 'order-dropdown-3',\n orderId: '#2183',\n mailLink: 'mailto:stanly@example.com',\n customer: 'Stanly Drinkwater',\n date: '30/04/2023',\n address: 'Stanly Drinkwater, 1 Infinite Loop, Cupertino, California 90210',\n deliveryType: 'Local Delivery',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$70'\n },\n {\n id: 4,\n dropdownId: 'order-dropdown-4',\n orderId: '#2184',\n mailLink: 'mailto:bucky@example.com',\n customer: 'Bucky Robert',\n date: '30/04/2023',\n address: 'Bucky Robert, 1 Infinite Loop, Cupertino, California 90210',\n deliveryType: 'Free Shipping',\n status: 'Pending',\n badge: { type: 'warning', icon: 'fas fa-stream' },\n amount: '$92'\n },\n {\n id: 5,\n dropdownId: 'order-dropdown-5',\n orderId: '#2185',\n mailLink: 'mailto:josef@example.com',\n customer: 'Josef Stravinsky',\n date: '30/04/2023',\n address: 'Josef Stravinsky, 1 Infinite Loop, Cupertino, California 90210',\n deliveryType: 'Via Free Road',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$120'\n },\n {\n id: 6,\n dropdownId: 'order-dropdown-6',\n orderId: '#2186',\n mailLink: 'mailto:igor@example.com',\n customer: 'Igor Borvibson',\n date: '30/04/2023',\n address: 'Igor Borvibson, 1 Infinite Loop, Cupertino, California 90210',\n deliveryType: 'Free Shipping',\n status: 'Processing',\n badge: { type: 'primary', icon: 'fas fa-redo' },\n amount: '$145'\n },\n {\n id: 7,\n dropdownId: 'order-dropdown-7',\n orderId: '#2187',\n mailLink: 'mailto:katerina@example.com',\n customer: 'Katerina Karenin',\n date: '30/04/2023',\n address: 'Katerina Karenin, 1 Infinite Loop, Cupertino, California 90210',\n deliveryType: 'Flat Rate',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$55'\n },\n {\n id: 8,\n dropdownId: 'order-dropdown-8',\n orderId: '#2188',\n mailLink: 'mailto:roy@example.com',\n customer: 'Roy Anderson',\n date: '29/04/2023',\n address: 'Roy Anderson, 1 Infinite Loop, Cupertino, California 90210',\n deliveryType: 'Local Delivery',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$90'\n },\n {\n id: 9,\n dropdownId: 'order-dropdown-9',\n orderId: '#2189',\n mailLink: 'mailto:Stephenson@example.com',\n customer: 'Thomas Stephenson',\n date: '29/04/2023',\n address: 'Thomas Stephenson, 116 Ballifeary Road, Bamff',\n deliveryType: 'Flat Rate',\n status: 'Processing',\n badge: { type: 'primary', icon: 'fas fa-redo' },\n amount: '$52'\n },\n {\n id: 10,\n dropdownId: 'order-dropdown-10',\n orderId: '#2190',\n mailLink: 'mailto:eviewsing@example.com',\n customer: 'Evie Singh',\n date: '29/04/2023',\n address: 'Evie Singh, 54 Castledore Road, Tunstead',\n deliveryType: 'Flat Rate',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$90'\n },\n {\n id: 11,\n dropdownId: 'order-dropdown-11',\n orderId: '#2191',\n mailLink: 'mailto:peter@example.com',\n customer: 'David Peters',\n date: '29/04/2023',\n address: 'David Peters, Rhyd Y Groes, Rhosgoch, LL66 0AT',\n deliveryType: 'Local Delivery',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$69'\n },\n {\n id: 12,\n dropdownId: 'order-dropdown-12',\n orderId: '#2192',\n mailLink: 'mailto:jennifer@example.com',\n customer: 'Jennifer Johnson',\n date: '28/04/2023',\n address: 'Jennifer Johnson, Rhyd Y Groes, Rhosgoch, LL66 0AT',\n deliveryType: 'Flat Rate',\n status: 'Processing',\n badge: { type: 'primary', icon: 'fas fa-redo' },\n amount: '$112'\n },\n {\n id: 13,\n dropdownId: 'order-dropdown-13',\n orderId: '#2193',\n mailLink: 'mailto:okuneva@example.com',\n customer: 'Demarcus Okuneva',\n date: '28/04/2023',\n address: 'Demarcus Okuneva, 90555 Upton Drive Jeffreyview, UT 08771',\n deliveryType: 'Flat Rate',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$99'\n },\n {\n id: 14,\n dropdownId: 'order-dropdown-14',\n orderId: '#2194',\n mailLink: 'mailto:simeon@example.com',\n customer: 'Simeon Harber',\n date: '27/04/2023',\n address:\n 'Simeon Harber, 702 Kunde Plain Apt. 634 East Bridgetview, HI 13134-1862',\n deliveryType: 'Free Shipping',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$129'\n },\n {\n id: 15,\n dropdownId: 'order-dropdown-15',\n orderId: '#2195',\n mailLink: 'mailto:lavon@example.com',\n customer: 'Lavon Haley',\n date: '27/04/2023',\n address: 'Lavon Haley, 30998 Adonis Locks McGlynnside, ID 27241',\n deliveryType: 'Free Shipping',\n status: 'Pending',\n badge: { type: 'warning', icon: 'fas fa-stream' },\n amount: '$70'\n },\n {\n id: 16,\n dropdownId: 'order-dropdown-16',\n orderId: '#2196',\n mailLink: 'mailto:ashley@example.com',\n customer: 'Ashley Kirlin',\n date: '26/04/2023',\n address:\n 'Ashley Kirlin, 43304 Prosacco Shore South Dejuanfurt, MO 18623-0505',\n deliveryType: 'Local Delivery',\n status: 'Processing',\n badge: { type: 'primary', icon: 'fas fa-redo' },\n amount: '$39'\n },\n {\n id: 17,\n dropdownId: 'order-dropdown-17',\n orderId: '#2197',\n mailLink: 'mailto:johnnie@example.com',\n customer: 'Johnnie Considine',\n date: '26/04/2023',\n address:\n 'Johnnie Considine, 6008 Hermann Points Suite 294 Hansenville, TN 14210',\n deliveryType: 'Flat Rate',\n status: 'Pending',\n badge: { type: 'warning', icon: 'fas fa-stream' },\n amount: '$70'\n },\n {\n id: 18,\n dropdownId: 'order-dropdown-18',\n orderId: '#2198',\n mailLink: 'mailto:trace@example.com',\n customer: 'Trace Farrell',\n date: '26/04/2023',\n address: 'Trace Farrell, 431 Steuber Mews Apt. 252 Germanland, AK 25882',\n deliveryType: 'Free Shipping',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$70'\n },\n {\n id: 19,\n dropdownId: 'order-dropdown-19',\n orderId: '#2199',\n mailLink: 'mailto:nienow@example.com',\n customer: 'Estell Nienow',\n date: '26/04/2023',\n address: 'Estell Nienow, 4167 Laverna Manor Marysemouth, NV 74590',\n deliveryType: 'Free Shipping',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$59'\n },\n {\n id: 20,\n dropdownId: 'order-dropdown-20',\n orderId: '#2200',\n mailLink: 'mailto:howe@example.com',\n customer: 'Daisha Howe',\n date: '25/04/2023',\n address:\n 'Daisha Howe, 829 Lavonne Valley Apt. 074 Stehrfort, RI 77914-0379',\n deliveryType: 'Free Shipping',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$39'\n },\n {\n id: 21,\n dropdownId: 'order-dropdown-21',\n orderId: '#2201',\n mailLink: 'mailto:haley@example.com',\n customer: 'Miles Haley',\n date: '24/04/2023',\n address: 'Miles Haley, 53150 Thad Squares Apt. 263 Archibaldfort, MO 00837',\n deliveryType: 'Flat Rate',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$55'\n },\n {\n id: 22,\n dropdownId: 'order-dropdown-22',\n orderId: '#2202',\n mailLink: 'mailto:watsica@example.com',\n customer: 'Brenda Watsica',\n date: '24/04/2023',\n address: \"Brenda Watsica, 9198 O'Kon Harbors Morarborough, IA 75409-7383\",\n deliveryType: 'Free Shipping',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$89'\n },\n {\n id: 23,\n dropdownId: 'order-dropdown-23',\n orderId: '#2203',\n mailLink: 'mailto:ellie@example.com',\n customer: \"Ellie O'Reilly\",\n date: '24/04/2023',\n address:\n \"Ellie O'Reilly, 1478 Kaitlin Haven Apt. 061 Lake Muhammadmouth, SC 35848\",\n deliveryType: 'Free Shipping',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$47'\n },\n {\n id: 24,\n dropdownId: 'order-dropdown-24',\n orderId: '#2204',\n mailLink: 'mailto:garry@example.com',\n customer: 'Garry Brainstrow',\n date: '23/04/2023',\n address: 'Garry Brainstrow, 13572 Kurt Mews South Merritt, IA 52491',\n deliveryType: 'Free Shipping',\n status: 'Completed',\n badge: { type: 'success', icon: 'fas fa-check' },\n amount: '$139'\n },\n {\n id: 25,\n dropdownId: 'order-dropdown-25',\n orderId: '#2205',\n mailLink: 'mailto:estell@example.com',\n customer: 'Estell Pollich',\n date: '23/04/2023',\n address: 'Estell Pollich, 13572 Kurt Mews South Merritt, IA 52491',\n deliveryType: 'Free Shipping',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$49'\n },\n {\n id: 26,\n dropdownId: 'order-dropdown-26',\n orderId: '#2206',\n mailLink: 'mailto:ara@example.com',\n customer: 'Ara Mueller',\n date: '23/04/2023',\n address: 'Ara Mueller, 91979 Kohler Place Waelchiborough, CT 41291',\n deliveryType: 'Flat Rate',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$19'\n },\n {\n id: 27,\n dropdownId: 'order-dropdown-27',\n orderId: '#2207',\n mailLink: 'mailto:blick@example.com',\n customer: 'Lucienne Blick',\n date: '23/04/2023',\n address:\n 'Lucienne Blick, 6757 Giuseppe Meadows Geraldinemouth, MO 48819-4970',\n deliveryType: 'Flat Rate',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$59'\n },\n {\n id: 28,\n dropdownId: 'order-dropdown-28',\n orderId: '#2208',\n mailLink: 'mailto:haag@example.com',\n customer: 'Laverne Haag',\n date: '22/04/2023',\n address: 'Laverne Haag, 2327 Kaylee Mill East Citlalli, AZ 89582-3143',\n deliveryType: 'Flat Rate',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$49'\n },\n {\n id: 29,\n dropdownId: 'order-dropdown-29',\n orderId: '#2209',\n mailLink: 'mailto:bednar@example.com',\n customer: 'Brandon Bednar',\n date: '22/04/2023',\n address:\n 'Brandon Bednar, 25156 Isaac Crossing Apt. 810 Lonborough, CO 83774-5999',\n deliveryType: 'Flat Rate',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$39'\n },\n {\n id: 30,\n dropdownId: 'order-dropdown-30',\n orderId: '#2210',\n mailLink: 'mailto:dimitri@example.com',\n customer: 'Dimitri Boehm',\n date: '23/04/2023',\n address: 'Dimitri Boehm, 71603 Wolff Plains Apt. 885 Johnstonton, MI 01581',\n deliveryType: 'Flat Rate',\n status: 'On Hold',\n badge: { type: 'secondary', icon: 'fas fa-ban' },\n amount: '$111'\n }\n];\n\nconst advanceAjaxTableInit = () => {\n const togglePaginationButtonDisable = (button, disabled) => {\n button.disabled = disabled;\n button.classList[disabled ? 'add' : 'remove']('disabled');\n };\n // Selectors\n const table = document.getElementById('advanceAjaxTable');\n\n if (table) {\n const options = {\n page: 10,\n pagination: {\n item: \"
${deliveryType}
\n\n ${\n window.dayjs(params[0].axisValue).isValid()\n ? window.dayjs(params[0].axisValue).format(dateFormatter)\n : params[0].axisValue\n }\n
\n ${tooltipItem}\n\n ${\n window.dayjs(params[0].axisValue).isValid()\n ? window.dayjs(params[0].axisValue).format('DD MMM, YYYY')\n : params[0].axisValue\n }\n
\n ${tooltipItem}\n${el.value}
`;\n iconCopiedToastInstance.show();\n }\n });\n }\n};\n\nexport default iconCopiedInit;\n","/*-----------------------------------------------\n| Isotope\n-----------------------------------------------*/\n\nconst isotopeInit = () => {\n const { getData } = window.phoenix.utils;\n const Selector = {\n ISOTOPE_ITEM: '.isotope-item',\n DATA_ISOTOPE: '[data-sl-isotope]',\n DATA_FILTER: '[data-filter]',\n DATA_FILER_NAV: '[data-filter-nav]'\n };\n\n const DATA_KEY = {\n ISOTOPE: 'sl-isotope'\n };\n const ClassName = {\n ACTIVE: 'active'\n };\n\n if (window.Isotope) {\n const masonryItems = document.querySelectorAll(Selector.DATA_ISOTOPE);\n masonryItems.length &&\n masonryItems.forEach(masonryItem => {\n window.imagesLoaded(masonryItem, () => {\n masonryItem.querySelectorAll(Selector.ISOTOPE_ITEM).forEach(item => {\n // eslint-disable-next-line\n item.style.visibility = 'visible';\n });\n\n const userOptions = getData(masonryItem, DATA_KEY.ISOTOPE);\n const defaultOptions = {\n itemSelector: Selector.ISOTOPE_ITEM,\n layoutMode: 'packery'\n };\n\n const options = window._.merge(defaultOptions, userOptions);\n const isotope = new window.Isotope(masonryItem, options);\n\n // --------- filter -----------------\n const filterElement = document.querySelector(Selector.DATA_FILER_NAV);\n filterElement?.addEventListener('click', function (e) {\n const item = e.target.dataset.filter;\n isotope.arrange({ filter: item });\n document.querySelectorAll(Selector.DATA_FILTER).forEach(el => {\n el.classList.remove(ClassName.ACTIVE);\n });\n e.target.classList.add(ClassName.ACTIVE);\n });\n // ---------- filter end ------------\n\n return isotope;\n });\n });\n }\n};\n\nexport default isotopeInit;\n","/* eslint-disable no-unused-expressions */\n/* -------------------------------------------------------------------------- */\n/* Data Table */\n/* -------------------------------------------------------------------------- */\n/* eslint-disable no-param-reassign */\nconst togglePaginationButtonDisable = (button, disabled) => {\n button.disabled = disabled;\n button.classList[disabled ? 'add' : 'remove']('disabled');\n};\n\nconst listInit = () => {\n const { getData } = window.phoenix.utils;\n if (window.List) {\n const lists = document.querySelectorAll('[data-list]');\n\n if (lists.length) {\n lists.forEach(el => {\n const bulkSelect = el.querySelector('[data-bulk-select]');\n\n let options = getData(el, 'list');\n\n if (options.pagination) {\n options = {\n ...options,\n pagination: {\n item: ``,\n ...options.pagination\n }\n };\n }\n\n const paginationButtonNext = el.querySelector(\n '[data-list-pagination=\"next\"]'\n );\n const paginationButtonPrev = el.querySelector(\n '[data-list-pagination=\"prev\"]'\n );\n const viewAll = el.querySelector('[data-list-view=\"*\"]');\n const viewLess = el.querySelector('[data-list-view=\"less\"]');\n const listInfo = el.querySelector('[data-list-info]');\n const listFilter = el.querySelector('[data-list-filter]');\n const list = new List(el, options);\n\n // ---------------------------------------\n\n let totalItem = list.items.length;\n const itemsPerPage = list.page;\n const btnDropdownClose = list.listContainer.querySelector('.btn-close');\n let pageQuantity = Math.ceil(list.size() / list.page);\n let pageCount = 1;\n let numberOfcurrentItems =\n (pageCount - 1) * Number(list.page) + list.visibleItems.length;\n let isSearching = false;\n\n btnDropdownClose &&\n btnDropdownClose.addEventListener('search.close', () => {\n list.fuzzySearch('');\n });\n\n const updateListControls = () => {\n listInfo &&\n (listInfo.innerHTML = `${list.i} to ${numberOfcurrentItems} Items of ${totalItem}`);\n\n paginationButtonPrev &&\n togglePaginationButtonDisable(\n paginationButtonPrev,\n pageCount === 1 || pageCount === 0\n );\n paginationButtonNext &&\n togglePaginationButtonDisable(\n paginationButtonNext,\n pageCount === pageQuantity || pageCount === 0\n );\n\n if (pageCount > 1 && pageCount < pageQuantity) {\n togglePaginationButtonDisable(paginationButtonNext, false);\n togglePaginationButtonDisable(paginationButtonPrev, false);\n }\n };\n\n // List info\n updateListControls();\n\n if (paginationButtonNext) {\n paginationButtonNext.addEventListener('click', e => {\n e.preventDefault();\n pageCount += 1;\n const nextInitialIndex = list.i + itemsPerPage;\n nextInitialIndex <= list.size() &&\n list.show(nextInitialIndex, itemsPerPage);\n });\n }\n\n if (paginationButtonPrev) {\n paginationButtonPrev.addEventListener('click', e => {\n e.preventDefault();\n pageCount -= 1;\n const prevItem = list.i - itemsPerPage;\n prevItem > 0 && list.show(prevItem, itemsPerPage);\n });\n }\n\n const toggleViewBtn = () => {\n viewLess.classList.toggle('d-none');\n viewAll.classList.toggle('d-none');\n };\n\n if (viewAll) {\n viewAll.addEventListener('click', () => {\n list.show(1, totalItem);\n pageCount = 1;\n toggleViewBtn();\n });\n }\n if (viewLess) {\n viewLess.addEventListener('click', () => {\n list.show(1, itemsPerPage);\n pageCount = 1;\n toggleViewBtn();\n });\n }\n // numbering pagination\n if (options.pagination) {\n el.querySelector('.pagination').addEventListener('click', e => {\n if (e.target.classList[0] === 'page') {\n const pageNum = Number(e.target.getAttribute('data-i'));\n if (pageNum) {\n list.show(itemsPerPage * (pageNum - 1) + 1, list.page);\n pageCount = pageNum;\n }\n }\n });\n }\n // filter\n if (options.filter) {\n const { key } = options.filter;\n listFilter.addEventListener('change', e => {\n list.filter(item => {\n if (e.target.value === '') {\n return true;\n }\n pageQuantity = Math.ceil(list.matchingItems.length / list.page);\n pageCount = 1;\n updateListControls();\n return item\n .values()\n [key].toLowerCase()\n .includes(e.target.value.toLowerCase());\n });\n });\n }\n\n // bulk-select\n if (bulkSelect) {\n const bulkSelectInstance =\n window.phoenix.BulkSelect.getInstance(bulkSelect);\n bulkSelectInstance.attachRowNodes(\n list.items.map(item =>\n item.elm.querySelector('[data-bulk-select-row]')\n )\n );\n\n bulkSelect.addEventListener('change', () => {\n if (list) {\n if (bulkSelect.checked) {\n list.items.forEach(item => {\n item.elm.querySelector(\n '[data-bulk-select-row]'\n ).checked = true;\n });\n } else {\n list.items.forEach(item => {\n item.elm.querySelector(\n '[data-bulk-select-row]'\n ).checked = false;\n });\n }\n }\n });\n }\n\n list.on('searchStart', () => {\n isSearching = true;\n });\n list.on('searchComplete', () => {\n isSearching = false;\n });\n\n list.on('updated', item => {\n if (!list.matchingItems.length) {\n pageQuantity = Math.ceil(list.size() / list.page);\n } else {\n pageQuantity = Math.ceil(list.matchingItems.length / list.page);\n }\n numberOfcurrentItems =\n (pageCount - 1) * Number(list.page) + list.visibleItems.length;\n updateListControls();\n\n // -------search-----------\n if (isSearching) {\n if (list.matchingItems.length === 0) {\n pageCount = 0;\n } else {\n pageCount = 1;\n }\n totalItem = list.matchingItems.length;\n numberOfcurrentItems =\n (pageCount === 0 ? 1 : pageCount - 1) * Number(list.page) +\n list.visibleItems.length;\n\n updateListControls();\n listInfo &&\n (listInfo.innerHTML = `${\n list.matchingItems.length === 0 ? 0 : list.i\n } to ${\n list.matchingItems.length === 0 ? 0 : numberOfcurrentItems\n } Items of ${\n list.matchingItems.length\n }`);\n }\n\n // -------fallback-----------\n const fallback =\n el.querySelector('.fallback') ||\n document.getElementById(options.fallback);\n\n if (fallback) {\n if (item.matchingItems.length === 0) {\n fallback.classList.remove('d-none');\n } else {\n fallback.classList.add('d-none');\n }\n }\n });\n });\n }\n }\n};\n\nexport default listInit;\n","const lottieInit = () => {\n const { getData } = window.phoenix.utils;\n const lotties = document.querySelectorAll('.lottie');\n if (lotties.length) {\n lotties.forEach(item => {\n const options = getData(item, 'options');\n window.bodymovin.loadAnimation({\n container: item,\n path: '../img/animated-icons/warning-light.json',\n renderer: 'svg',\n loop: true,\n autoplay: true,\n name: 'Hello World',\n ...options\n });\n });\n }\n};\n\nexport default lottieInit;\n","/* -------------------------------------------------------------------------- */\n/* Modal */\n/* -------------------------------------------------------------------------- */\n\nconst modalInit = () => {\n const $modals = document.querySelectorAll('[data-phoenix-modal]');\n\n if ($modals) {\n $modals.forEach(modal => {\n modal.addEventListener('shown.bs.modal', () => {\n const $autofocusEls = modal.querySelectorAll('[autofocus=autofocus]');\n $autofocusEls.forEach(el => {\n el.focus();\n });\n });\n });\n }\n};\nexport default modalInit;\n","/* -------------------------------------------------------------------------- */\n/* Navbar Combo Layout */\n/* -------------------------------------------------------------------------- */\n\nconst navbarComboInit = () => {\n const { getBreakpoint, getData, addClass, hasClass, resize } =\n window.phoenix.utils;\n\n const Selector = {\n NAVBAR_VERTICAL: '.navbar-vertical',\n NAVBAR_TOP_COMBO: '[data-navbar-top=\"combo\"]',\n COLLAPSE: '.collapse',\n DATA_MOVE_CONTAINER: '[data-move-container]',\n NAVBAR_NAV: '.navbar-nav',\n NAVBAR_VERTICAL_DIVIDER: '.navbar-vertical-divider'\n };\n\n const ClassName = {\n FLEX_COLUMN: 'flex-column'\n };\n\n const navbarVertical = document.querySelector(Selector.NAVBAR_VERTICAL);\n const navbarTopCombo = document.querySelector(Selector.NAVBAR_TOP_COMBO);\n\n const moveNavContent = windowWidth => {\n const navbarVerticalBreakpoint = getBreakpoint(navbarVertical);\n const navbarTopBreakpoint = getBreakpoint(navbarTopCombo);\n\n if (windowWidth < navbarTopBreakpoint) {\n const navbarCollapse = navbarTopCombo.querySelector(Selector.COLLAPSE);\n const navbarTopContent = navbarCollapse.innerHTML;\n\n if (navbarTopContent) {\n const targetID = getData(navbarTopCombo, 'move-target');\n const targetElement = document.querySelector(targetID);\n\n navbarCollapse.innerHTML = '';\n targetElement.insertAdjacentHTML(\n 'afterend',\n `\n