@grazziotin/react-components-next 2.2.1 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js ADDED
@@ -0,0 +1,1244 @@
1
+ 'use strict';
2
+
3
+ var tailwindMerge = require('tailwind-merge');
4
+ var clsx = require('clsx');
5
+ var material = require('@mui/material');
6
+ var core = require('@mantine/core');
7
+ var jsxRuntime = require('react/jsx-runtime');
8
+ var DialogMui = require('@mui/material/Dialog');
9
+ var DialogTitle = require('@mui/material/DialogTitle');
10
+ var DialogActions = require('@mui/material/DialogActions');
11
+ var DialogContent = require('@mui/material/DialogContent');
12
+ var locales = require('@mui/x-data-grid/locales');
13
+ var xDataGrid = require('@mui/x-data-grid');
14
+ var react = require('react');
15
+ var md = require('react-icons/md');
16
+ var Autocomplete = require('@mui/material/Autocomplete');
17
+ var fa = require('react-icons/fa');
18
+ require('react-toastify/dist/ReactToastify.css');
19
+ var reactToastify = require('react-toastify');
20
+ var SayEngine = require('react-say');
21
+
22
+ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
23
+
24
+ var DialogMui__default = /*#__PURE__*/_interopDefault(DialogMui);
25
+ var DialogTitle__default = /*#__PURE__*/_interopDefault(DialogTitle);
26
+ var DialogActions__default = /*#__PURE__*/_interopDefault(DialogActions);
27
+ var DialogContent__default = /*#__PURE__*/_interopDefault(DialogContent);
28
+ var Autocomplete__default = /*#__PURE__*/_interopDefault(Autocomplete);
29
+ var SayEngine__default = /*#__PURE__*/_interopDefault(SayEngine);
30
+
31
+ var __defProp = Object.defineProperty;
32
+ var __defProps = Object.defineProperties;
33
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
34
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
35
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
36
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
37
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
38
+ var __spreadValues = (a, b) => {
39
+ for (var prop in b || (b = {}))
40
+ if (__hasOwnProp.call(b, prop))
41
+ __defNormalProp(a, prop, b[prop]);
42
+ if (__getOwnPropSymbols)
43
+ for (var prop of __getOwnPropSymbols(b)) {
44
+ if (__propIsEnum.call(b, prop))
45
+ __defNormalProp(a, prop, b[prop]);
46
+ }
47
+ return a;
48
+ };
49
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
50
+ var __objRest = (source, exclude) => {
51
+ var target = {};
52
+ for (var prop in source)
53
+ if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
54
+ target[prop] = source[prop];
55
+ if (source != null && __getOwnPropSymbols)
56
+ for (var prop of __getOwnPropSymbols(source)) {
57
+ if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
58
+ target[prop] = source[prop];
59
+ }
60
+ return target;
61
+ };
62
+
63
+ // #style-inject:#style-inject
64
+ function styleInject(css, { insertAt } = {}) {
65
+ if (typeof document === "undefined") return;
66
+ const head = document.head || document.getElementsByTagName("head")[0];
67
+ const style = document.createElement("style");
68
+ style.type = "text/css";
69
+ if (insertAt === "top") {
70
+ if (head.firstChild) {
71
+ head.insertBefore(style, head.firstChild);
72
+ } else {
73
+ head.appendChild(style);
74
+ }
75
+ } else {
76
+ head.appendChild(style);
77
+ }
78
+ if (style.styleSheet) {
79
+ style.styleSheet.cssText = css;
80
+ } else {
81
+ style.appendChild(document.createTextNode(css));
82
+ }
83
+ }
84
+
85
+ // src/styles/tailwind-output.css
86
+ styleInject('/*! tailwindcss v4.3.0 | MIT License | https://tailwindcss.com */\n@layer properties {\n @supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))) {\n *,\n :before,\n :after,\n ::backdrop {\n --tw-space-x-reverse:0;\n --tw-border-style:solid;\n --tw-font-weight:initial;\n --tw-shadow:0 0 #0000;\n --tw-shadow-color:initial;\n --tw-shadow-alpha:100%;\n --tw-inset-shadow:0 0 #0000;\n --tw-inset-shadow-color:initial;\n --tw-inset-shadow-alpha:100%;\n --tw-ring-color:initial;\n --tw-ring-shadow:0 0 #0000;\n --tw-inset-ring-color:initial;\n --tw-inset-ring-shadow:0 0 #0000;\n --tw-ring-inset:initial;\n --tw-ring-offset-width:0px;\n --tw-ring-offset-color:#fff;\n --tw-ring-offset-shadow:0 0 #0000;\n --tw-outline-style:solid;\n --tw-blur:initial;\n --tw-brightness:initial;\n --tw-contrast:initial;\n --tw-grayscale:initial;\n --tw-hue-rotate:initial;\n --tw-invert:initial;\n --tw-opacity:initial;\n --tw-saturate:initial;\n --tw-sepia:initial;\n --tw-drop-shadow:initial;\n --tw-drop-shadow-color:initial;\n --tw-drop-shadow-alpha:100%;\n --tw-drop-shadow-size:initial;\n }\n }\n}\n@layer theme {\n :root,\n :host {\n --font-sans:ui-sans-serif,\n system-ui,\n sans-serif,\n "Apple Color Emoji",\n "Segoe UI Emoji",\n "Segoe UI Symbol",\n "Noto Color Emoji";\n --font-mono:ui-monospace,\n SFMono-Regular,\n Menlo,\n Monaco,\n Consolas,\n "Liberation Mono",\n "Courier New",\n monospace;\n --color-red-600:oklch(57.7% .245 27.325);\n --color-green-50:oklch(98.2% .018 155.826);\n --color-green-100:oklch(96.2% .044 156.743);\n --color-green-400:oklch(79.2% .209 151.711);\n --color-green-500:oklch(72.3% .219 149.579);\n --color-green-800:oklch(44.8% .119 151.328);\n --color-teal-500:oklch(70.4% .14 182.503);\n --color-blue-500:oklch(62.3% .214 259.815);\n --color-gray-50:oklch(98.5% .002 247.839);\n --color-gray-100:oklch(96.7% .003 264.542);\n --color-gray-200:oklch(92.8% .006 264.531);\n --color-gray-500:oklch(55.1% .027 264.364);\n --color-gray-600:oklch(44.6% .03 256.802);\n --color-gray-700:oklch(37.3% .034 259.733);\n --color-gray-900:oklch(21% .034 264.665);\n --color-black:#000;\n --color-white:#fff;\n --spacing:.25rem;\n --container-3xl:48rem;\n --container-5xl:64rem;\n --text-xs:.75rem;\n --text-xs--line-height:calc(1 / .75);\n --text-sm:.875rem;\n --text-sm--line-height:calc(1.25 / .875);\n --text-lg:1.125rem;\n --text-lg--line-height:calc(1.75 / 1.125);\n --text-2xl:1.5rem;\n --text-2xl--line-height:calc(2 / 1.5);\n --font-weight-medium:500;\n --font-weight-semibold:600;\n --font-weight-bold:700;\n --radius-md:.375rem;\n --radius-lg:.5rem;\n --default-transition-duration:.15s;\n --default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);\n --default-font-family:var(--font-sans);\n --default-mono-font-family:var(--font-mono);\n }\n :root {\n --primary-color:#00b2a6;\n --font-poppins:"Poppins", sans-serif;\n --font-family:var(--font-poppins);\n --default-font-family:var(--font-poppins);\n --mui-font-family:var(--font-poppins);\n --mantine-font-family:var(--font-poppins);\n }\n}\n@layer base {\n *,\n :after,\n :before,\n ::backdrop {\n box-sizing: border-box;\n border: 0 solid;\n margin: 0;\n padding: 0;\n }\n ::file-selector-button {\n box-sizing: border-box;\n border: 0 solid;\n margin: 0;\n padding: 0;\n }\n html,\n :host {\n -webkit-text-size-adjust: 100%;\n tab-size: 4;\n line-height: 1.5;\n font-family: var(--default-font-family,ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");\n font-feature-settings: var(--default-font-feature-settings,normal);\n font-variation-settings: var(--default-font-variation-settings,normal);\n -webkit-tap-highlight-color: transparent;\n }\n hr {\n height: 0;\n color: inherit;\n border-top-width: 1px;\n }\n abbr:where([title]) {\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted;\n }\n h1,\n h2,\n h3,\n h4,\n h5,\n h6 {\n font-size: inherit;\n font-weight: inherit;\n }\n a {\n color: inherit;\n -webkit-text-decoration: inherit;\n -webkit-text-decoration: inherit;\n -webkit-text-decoration: inherit;\n text-decoration: inherit;\n }\n b,\n strong {\n font-weight: bolder;\n }\n code,\n kbd,\n samp,\n pre {\n font-family: var(--default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);\n font-feature-settings: var(--default-mono-font-feature-settings,normal);\n font-variation-settings: var(--default-mono-font-variation-settings,normal);\n font-size: 1em;\n }\n small {\n font-size: 80%;\n }\n sub,\n sup {\n vertical-align: baseline;\n font-size: 75%;\n line-height: 0;\n position: relative;\n }\n sub {\n bottom: -.25em;\n }\n sup {\n top: -.5em;\n }\n table {\n text-indent: 0;\n border-color: inherit;\n border-collapse: collapse;\n }\n :-moz-focusring {\n outline: auto;\n }\n progress {\n vertical-align: baseline;\n }\n summary {\n display: list-item;\n }\n ol,\n ul,\n menu {\n list-style: none;\n }\n img,\n svg,\n video,\n canvas,\n audio,\n iframe,\n embed,\n object {\n vertical-align: middle;\n display: block;\n }\n img,\n video {\n max-width: 100%;\n height: auto;\n }\n button,\n input,\n select,\n optgroup,\n textarea {\n font: inherit;\n font-feature-settings: inherit;\n font-variation-settings: inherit;\n letter-spacing: inherit;\n color: inherit;\n opacity: 1;\n background-color: #0000;\n border-radius: 0;\n }\n ::file-selector-button {\n font: inherit;\n font-feature-settings: inherit;\n font-variation-settings: inherit;\n letter-spacing: inherit;\n color: inherit;\n opacity: 1;\n background-color: #0000;\n border-radius: 0;\n }\n :where(select:is([multiple], [size])) optgroup {\n font-weight: bolder;\n }\n :where(select:is([multiple], [size])) optgroup option {\n padding-inline-start: 20px;\n }\n ::file-selector-button {\n margin-inline-end: 4px;\n }\n ::placeholder {\n opacity: 1;\n }\n @supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px) {\n ::placeholder {\n color: currentColor;\n }\n @supports (color:color-mix(in lab, red, red)) {\n ::placeholder {\n color: color-mix(in oklab, currentcolor 50%, transparent);\n }\n }\n }\n textarea {\n resize: vertical;\n }\n ::-webkit-search-decoration {\n -webkit-appearance: none;\n }\n ::-webkit-date-and-time-value {\n min-height: 1lh;\n text-align: inherit;\n }\n ::-webkit-datetime-edit {\n display: inline-flex;\n }\n ::-webkit-datetime-edit-fields-wrapper {\n padding: 0;\n }\n ::-webkit-datetime-edit {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-year-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-month-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-day-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-hour-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-minute-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-second-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-millisecond-field {\n padding-block: 0;\n }\n ::-webkit-datetime-edit-meridiem-field {\n padding-block: 0;\n }\n ::-webkit-calendar-picker-indicator {\n line-height: 1;\n }\n :-moz-ui-invalid {\n box-shadow: none;\n }\n button,\n input:where([type=button], [type=reset], [type=submit]) {\n appearance: button;\n }\n ::file-selector-button {\n appearance: button;\n }\n ::-webkit-inner-spin-button {\n height: auto;\n }\n ::-webkit-outer-spin-button {\n height: auto;\n }\n [hidden]:where(:not([hidden=until-found])) {\n display: none !important;\n }\n}\n@layer components;\n@layer utilities {\n .container {\n width: 100%;\n }\n @media (min-width: 40rem) {\n .container {\n max-width: 40rem;\n }\n }\n @media (min-width: 48rem) {\n .container {\n max-width: 48rem;\n }\n }\n @media (min-width: 64rem) {\n .container {\n max-width: 64rem;\n }\n }\n @media (min-width: 80rem) {\n .container {\n max-width: 80rem;\n }\n }\n @media (min-width: 96rem) {\n .container {\n max-width: 96rem;\n }\n }\n .mt-2 {\n margin-top: calc(var(--spacing) * 2);\n }\n .mt-4 {\n margin-top: calc(var(--spacing) * 4);\n }\n .mb-2 {\n margin-bottom: calc(var(--spacing) * 2);\n }\n .ml-1 {\n margin-left: calc(var(--spacing) * 1);\n }\n .block {\n display: block;\n }\n .block\\! {\n display: block !important;\n }\n .flex {\n display: flex;\n }\n .grid {\n display: grid;\n }\n .hidden {\n display: none;\n }\n .inline-block {\n display: inline-block;\n }\n .table {\n display: table;\n }\n .h-5 {\n height: calc(var(--spacing) * 5);\n }\n .h-15 {\n height: calc(var(--spacing) * 15);\n }\n .h-full {\n height: 100%;\n }\n .min-h-\\[210px\\]\\! {\n min-height: 210px !important;\n }\n .min-h-screen {\n min-height: 100vh;\n }\n .w-2 {\n width: calc(var(--spacing) * 2);\n }\n .w-5 {\n width: calc(var(--spacing) * 5);\n }\n .w-80 {\n width: calc(var(--spacing) * 80);\n }\n .w-full {\n width: 100%;\n }\n .max-w-3xl {\n max-width: var(--container-3xl);\n }\n .max-w-5xl {\n max-width: var(--container-5xl);\n }\n .min-w-0 {\n min-width: calc(var(--spacing) * 0);\n }\n .flex-1 {\n flex: 1;\n }\n .border-collapse {\n border-collapse: collapse;\n }\n .resize {\n resize: both;\n }\n .flex-col {\n flex-direction: column;\n }\n .items-center {\n align-items: center;\n }\n .justify-between {\n justify-content: space-between;\n }\n .justify-center {\n justify-content: center;\n }\n .justify-end {\n justify-content: flex-end;\n }\n .gap-2 {\n gap: calc(var(--spacing) * 2);\n }\n .gap-4 {\n gap: calc(var(--spacing) * 4);\n }\n :where(.space-x-4 > :not(:last-child)) {\n --tw-space-x-reverse:0;\n margin-inline-start: calc(calc(var(--spacing) * 4) * var(--tw-space-x-reverse));\n margin-inline-end: calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-x-reverse)));\n }\n .truncate {\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n }\n .truncate\\! {\n text-overflow: ellipsis !important;\n white-space: nowrap !important;\n overflow: hidden !important;\n }\n .overflow-hidden {\n overflow: hidden;\n }\n .rounded {\n border-radius: .25rem;\n }\n .rounded-lg {\n border-radius: var(--radius-lg);\n }\n .rounded-md {\n border-radius: var(--radius-md);\n }\n .rounded-tl-md {\n border-top-left-radius: var(--radius-md);\n }\n .rounded-bl-md {\n border-bottom-left-radius: var(--radius-md);\n }\n .border {\n border-style: var(--tw-border-style);\n border-width: 1px;\n }\n .border-green-500 {\n border-color: var(--color-green-500);\n }\n .bg-\\(--primary-color\\) {\n background-color: var(--primary-color);\n }\n .bg-blue-500 {\n background-color: var(--color-blue-500);\n }\n .bg-gray-50 {\n background-color: var(--color-gray-50);\n }\n .bg-gray-100 {\n background-color: var(--color-gray-100);\n }\n .bg-gray-200 {\n background-color: var(--color-gray-200);\n }\n .bg-gray-900 {\n background-color: var(--color-gray-900);\n }\n .bg-green-50 {\n background-color: var(--color-green-50);\n }\n .bg-green-100 {\n background-color: var(--color-green-100);\n }\n .bg-red-600 {\n background-color: var(--color-red-600);\n }\n .bg-teal-500 {\n background-color: var(--color-teal-500);\n }\n .bg-white {\n background-color: var(--color-white);\n }\n .p-3 {\n padding: calc(var(--spacing) * 3);\n }\n .p-4 {\n padding: calc(var(--spacing) * 4);\n }\n .px-2 {\n padding-inline: calc(var(--spacing) * 2);\n }\n .px-4 {\n padding-inline: calc(var(--spacing) * 4);\n }\n .px-6 {\n padding-inline: calc(var(--spacing) * 6);\n }\n .py-0 {\n padding-block: calc(var(--spacing) * 0);\n }\n .py-0\\.5 {\n padding-block: calc(var(--spacing) * .5);\n }\n .py-1 {\n padding-block: calc(var(--spacing) * 1);\n }\n .py-2 {\n padding-block: calc(var(--spacing) * 2);\n }\n .py-3 {\n padding-block: calc(var(--spacing) * 3);\n }\n .py-4 {\n padding-block: calc(var(--spacing) * 4);\n }\n .pt-1 {\n padding-top: calc(var(--spacing) * 1);\n }\n .pt-4 {\n padding-top: calc(var(--spacing) * 4);\n }\n .pr-4 {\n padding-right: calc(var(--spacing) * 4);\n }\n .pr-5 {\n padding-right: calc(var(--spacing) * 5);\n }\n .pb-5 {\n padding-bottom: calc(var(--spacing) * 5);\n }\n .pl-5 {\n padding-left: calc(var(--spacing) * 5);\n }\n .text-center {\n text-align: center;\n }\n .font-mono {\n font-family: var(--font-mono);\n }\n .text-2xl {\n font-size: var(--text-2xl);\n line-height: var(--tw-leading,var(--text-2xl--line-height));\n }\n .text-lg {\n font-size: var(--text-lg);\n line-height: var(--tw-leading,var(--text-lg--line-height));\n }\n .text-sm {\n font-size: var(--text-sm);\n line-height: var(--tw-leading,var(--text-sm--line-height));\n }\n .text-sm\\! {\n font-size: var(--text-sm) !important;\n line-height: var(--tw-leading,var(--text-sm--line-height)) !important;\n }\n .text-xs {\n font-size: var(--text-xs);\n line-height: var(--tw-leading,var(--text-xs--line-height));\n }\n .text-xs\\! {\n font-size: var(--text-xs) !important;\n line-height: var(--tw-leading,var(--text-xs--line-height)) !important;\n }\n .font-bold {\n --tw-font-weight:var(--font-weight-bold);\n font-weight: var(--font-weight-bold);\n }\n .font-medium {\n --tw-font-weight:var(--font-weight-medium);\n font-weight: var(--font-weight-medium);\n }\n .font-semibold {\n --tw-font-weight:var(--font-weight-semibold);\n font-weight: var(--font-weight-semibold);\n }\n .font-semibold\\! {\n --tw-font-weight:var(--font-weight-semibold) !important;\n font-weight: var(--font-weight-semibold) !important;\n }\n .text-ellipsis {\n text-overflow: ellipsis;\n }\n .whitespace-nowrap {\n white-space: nowrap;\n }\n .text-black {\n color: var(--color-black);\n }\n .text-black\\/80 {\n color: #000c;\n }\n @supports (color:color-mix(in lab, red, red)) {\n .text-black\\/80 {\n color: color-mix(in oklab, var(--color-black) 80%, transparent);\n }\n }\n .text-gray-500 {\n color: var(--color-gray-500);\n }\n .text-gray-600 {\n color: var(--color-gray-600);\n }\n .text-gray-700 {\n color: var(--color-gray-700);\n }\n .text-gray-900 {\n color: var(--color-gray-900);\n }\n .text-green-400 {\n color: var(--color-green-400);\n }\n .text-green-800 {\n color: var(--color-green-800);\n }\n .text-white {\n color: var(--color-white);\n }\n .uppercase {\n text-transform: uppercase;\n }\n .underline {\n text-decoration-line: underline;\n }\n .shadow-\\[0_2px_6px_-1px_rgba\\(0\\,0\\,0\\,\\.16\\)\\,0_6px_18px_-1px_rgba\\(0\\,0\\,0\\,\\.06\\)\\] {\n --tw-shadow:0 2px 6px -1px var(--tw-shadow-color,#00000029), 0 6px 18px -1px var(--tw-shadow-color,#0000000f);\n box-shadow:\n var(--tw-inset-shadow),\n var(--tw-inset-ring-shadow),\n var(--tw-ring-offset-shadow),\n var(--tw-ring-shadow),\n var(--tw-shadow);\n }\n .outline {\n outline-style: var(--tw-outline-style);\n outline-width: 1px;\n }\n .blur {\n --tw-blur:blur(8px);\n 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,);\n }\n .filter {\n 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,);\n }\n .transition {\n transition-property:\n color,\n background-color,\n border-color,\n outline-color,\n text-decoration-color,\n fill,\n stroke,\n --tw-gradient-from,\n --tw-gradient-via,\n --tw-gradient-to,\n opacity,\n box-shadow,\n transform,\n translate,\n scale,\n rotate,\n filter,\n -webkit-backdrop-filter,\n backdrop-filter,\n display,\n content-visibility,\n overlay,\n pointer-events;\n transition-timing-function: var(--tw-ease,var(--default-transition-timing-function));\n transition-duration: var(--tw-duration,var(--default-transition-duration));\n }\n .select-none {\n -webkit-user-select: none;\n user-select: none;\n }\n .disabled\\:opacity-50:disabled {\n opacity: .5;\n }\n}\n@layer mui, mantine;\n@property --tw-space-x-reverse { syntax:"*";inherits:false;initial-value:0 }\n@property --tw-border-style { syntax:"*";inherits:false;initial-value:solid }\n@property --tw-font-weight { syntax:"*";inherits:false }\n@property --tw-shadow { syntax:"*";inherits:false;initial-value:0 0 #0000 }\n@property --tw-shadow-color { syntax:"*";inherits:false }\n@property --tw-shadow-alpha { syntax:"<percentage>";inherits:false;initial-value:100% }\n@property --tw-inset-shadow { syntax:"*";inherits:false;initial-value:0 0 #0000 }\n@property --tw-inset-shadow-color { syntax:"*";inherits:false }\n@property --tw-inset-shadow-alpha { syntax:"<percentage>";inherits:false;initial-value:100% }\n@property --tw-ring-color { syntax:"*";inherits:false }\n@property --tw-ring-shadow { syntax:"*";inherits:false;initial-value:0 0 #0000 }\n@property --tw-inset-ring-color { syntax:"*";inherits:false }\n@property --tw-inset-ring-shadow { syntax:"*";inherits:false;initial-value:0 0 #0000 }\n@property --tw-ring-inset { syntax:"*";inherits:false }\n@property --tw-ring-offset-width { syntax:"<length>";inherits:false;initial-value:0 }\n@property --tw-ring-offset-color { syntax:"*";inherits:false;initial-value:#fff }\n@property --tw-ring-offset-shadow { syntax:"*";inherits:false;initial-value:0 0 #0000 }\n@property --tw-outline-style { syntax:"*";inherits:false;initial-value:solid }\n@property --tw-blur { syntax:"*";inherits:false }\n@property --tw-brightness { syntax:"*";inherits:false }\n@property --tw-contrast { syntax:"*";inherits:false }\n@property --tw-grayscale { syntax:"*";inherits:false }\n@property --tw-hue-rotate { syntax:"*";inherits:false }\n@property --tw-invert { syntax:"*";inherits:false }\n@property --tw-opacity { syntax:"*";inherits:false }\n@property --tw-saturate { syntax:"*";inherits:false }\n@property --tw-sepia { syntax:"*";inherits:false }\n@property --tw-drop-shadow { syntax:"*";inherits:false }\n@property --tw-drop-shadow-color { syntax:"*";inherits:false }\n@property --tw-drop-shadow-alpha { syntax:"<percentage>";inherits:false;initial-value:100% }\n@property --tw-drop-shadow-size { syntax:"*";inherits:false }\n');
87
+ function cn(...values) {
88
+ return tailwindMerge.twMerge(clsx.clsx(values));
89
+ }
90
+
91
+ // src/functions/nvl/nvl.ts
92
+ function nvl(value, defaultValue) {
93
+ return value != null ? value : defaultValue;
94
+ }
95
+
96
+ // src/core/remove-digits.ts
97
+ function removeDigits(value) {
98
+ return value.replace(/\D/g, "");
99
+ }
100
+ function removeNonDigits(value) {
101
+ return value.replaceAll(/\d/g, "");
102
+ }
103
+ function removeTextOnly(value) {
104
+ return value.replaceAll(/[^\p{L}]/gu, "");
105
+ }
106
+
107
+ // src/functions/format-cpf-cnpj/format-cpf-cnpj.ts
108
+ function formatCpfCnpj(data) {
109
+ if (!data) return "";
110
+ const value = removeDigits(data);
111
+ if (!value) return "";
112
+ if (value.length <= 11) {
113
+ const cpf = value.slice(0, 11);
114
+ return cpf.replace(/(\d{3})(\d)/, "$1.$2").replace(/(\d{3})(\d)/, "$1.$2").replace(/(\d{3})(\d{1,2})$/, "$1-$2");
115
+ }
116
+ const cnpj = value.slice(0, 14);
117
+ return cnpj.replace(/^(\d{2})(\d)/, "$1.$2").replace(/^(\d{2})\.(\d{3})(\d)/, "$1.$2.$3").replace(/\.(\d{3})(\d)/, ".$1/$2").replace(/(\d{4})(\d)/, "$1-$2");
118
+ }
119
+
120
+ // src/functions/format-phone-br/format-phone-br.ts
121
+ function formatPhoneBr(phone) {
122
+ if (!phone) return "";
123
+ const digits = removeDigits(phone).slice(0, 11);
124
+ if (!digits) return "";
125
+ if (digits.length <= 2) return digits;
126
+ if (digits.length <= 6) {
127
+ return digits.replace(/(\d{2})(\d+)/, "($1) $2");
128
+ }
129
+ if (digits.length <= 10) {
130
+ return digits.replace(/(\d{2})(\d{4})(\d+)/, "($1) $2-$3");
131
+ }
132
+ return digits.replace(/(\d{2})(\d{5})(\d+)/, "($1) $2-$3");
133
+ }
134
+
135
+ // src/functions/format-price-brl/format-price-brl.ts
136
+ function formatPriceBrl(value) {
137
+ if (value === void 0 || value === null) return "";
138
+ if (typeof value === "string") {
139
+ const digits = removeDigits(value);
140
+ if (!digits) return "";
141
+ const price = Number(digits) / 100;
142
+ if (Number.isNaN(price)) return "";
143
+ return price.toLocaleString("pt-BR", {
144
+ style: "currency",
145
+ currency: "BRL"
146
+ });
147
+ }
148
+ if (Number.isNaN(value)) return "";
149
+ return value.toLocaleString("pt-BR", { style: "currency", currency: "BRL" });
150
+ }
151
+
152
+ // src/functions/format-item-170/format-item-170.ts
153
+ function formatItem170(item) {
154
+ if (!item) return "";
155
+ const digits = removeDigits(item).slice(0, 12);
156
+ if (!digits) return "";
157
+ return digits.replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})\.(\d)(\d{1,3})$/, "$1.$2.$3");
158
+ }
159
+
160
+ // src/functions/format-item-150/format-item-150.ts
161
+ function formatItem150(item) {
162
+ if (!item) return "";
163
+ const digits = removeDigits(item).slice(0, 10);
164
+ if (!digits) return "";
165
+ return digits.replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})(\d)/, "$1.$2").replace(/(\d{2})\.(\d)(\d{1,3})$/, "$1.$2.$3");
166
+ }
167
+ function Card({
168
+ margin,
169
+ onClick,
170
+ title,
171
+ toolTip,
172
+ className,
173
+ borderTitle,
174
+ children,
175
+ borderRadius,
176
+ width = "100%",
177
+ height = "auto",
178
+ titleWidth = "100%",
179
+ justifyContent = "space-between",
180
+ titleColor = "var(--primary-color)",
181
+ icon
182
+ }) {
183
+ return /* @__PURE__ */ jsxRuntime.jsxs(
184
+ material.Box,
185
+ {
186
+ onClick,
187
+ className: cn(className, "text-sm!"),
188
+ sx: __spreadValues({
189
+ width,
190
+ margin,
191
+ height,
192
+ borderRadius,
193
+ "@media (max-width: 768px)": { width: "100%" },
194
+ boxShadow: "0 0.15rem 0.5rem rgba(0, 0, 0, 0.16)"
195
+ }, onClick && { cursor: "pointer !important" }),
196
+ children: [
197
+ /* @__PURE__ */ jsxRuntime.jsxs(
198
+ material.Box,
199
+ {
200
+ sx: {
201
+ justifyContent,
202
+ height: "24px",
203
+ color: "white",
204
+ display: "flex",
205
+ width: titleWidth,
206
+ overflow: "hidden",
207
+ padding: "0px 15px",
208
+ alignItems: "center",
209
+ flexDirection: "row",
210
+ borderRadius: borderTitle,
211
+ backgroundColor: titleColor
212
+ },
213
+ children: [
214
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "min-w-0 flex-1 font-semibold! truncate!", children: /* @__PURE__ */ jsxRuntime.jsx(
215
+ core.Tooltip,
216
+ {
217
+ withArrow: true,
218
+ radius: "md",
219
+ label: title,
220
+ arrowSize: 6,
221
+ position: "top",
222
+ arrowOffset: 15,
223
+ disabled: !toolTip,
224
+ color: titleColor,
225
+ classNames: { tooltip: "text-xs!" },
226
+ offset: { mainAxis: 11, crossAxis: -21 },
227
+ transitionProps: { transition: "fade", duration: 100 },
228
+ children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "block! truncate!", children: title })
229
+ }
230
+ ) }),
231
+ /* @__PURE__ */ jsxRuntime.jsx("div", { children: icon })
232
+ ]
233
+ }
234
+ ),
235
+ children
236
+ ]
237
+ }
238
+ );
239
+ }
240
+ var card_default = Card;
241
+
242
+ // src/components/ui/dialog/utils/constants.ts
243
+ var DIALOG_BACKDROP_STYLE = {
244
+ backdropFilter: "blur(4px)",
245
+ backgroundColor: "rgba(0, 0, 0, 0.5)"
246
+ };
247
+ var DIALOG_PAPER_FONT_SX = {
248
+ fontFamily: "var(--font-family, inherit) !important",
249
+ "& .MuiDialogTitle-root, & .MuiDialogContent-root, & .MuiDialogActions-root, & .MuiTypography-root": {
250
+ fontFamily: "inherit !important"
251
+ }
252
+ };
253
+ function Dialog({
254
+ open,
255
+ title,
256
+ onClose,
257
+ actions,
258
+ children,
259
+ maxWidth,
260
+ blurBackdrop = false
261
+ }) {
262
+ const backdropStyle = blurBackdrop ? DIALOG_BACKDROP_STYLE : {};
263
+ return /* @__PURE__ */ jsxRuntime.jsxs(
264
+ DialogMui__default.default,
265
+ {
266
+ fullWidth: true,
267
+ open,
268
+ onClose,
269
+ maxWidth,
270
+ slotProps: {
271
+ backdrop: { sx: backdropStyle },
272
+ paper: { sx: DIALOG_PAPER_FONT_SX }
273
+ },
274
+ children: [
275
+ title && /* @__PURE__ */ jsxRuntime.jsx(DialogTitle__default.default, { children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-semibold text-black", children: title }) }),
276
+ /* @__PURE__ */ jsxRuntime.jsx(DialogContent__default.default, { className: "text-black", children }),
277
+ actions && /* @__PURE__ */ jsxRuntime.jsx(DialogActions__default.default, { children: actions })
278
+ ]
279
+ }
280
+ );
281
+ }
282
+ var dialog_default = Dialog;
283
+ var tableFont = "var(--font-family, var(--font-poppins, Poppins, sans-serif))";
284
+ var localeText = __spreadProps(__spreadValues({}, locales.ptBR.components.MuiDataGrid.defaultProps.localeText), {
285
+ noColumnsOverlayLabel: "Nenhuma coluna dispon\xEDvel",
286
+ noColumnsOverlayManageColumns: "Gerenciar colunas",
287
+ columnsManagementSearchTitle: "Buscar coluna",
288
+ columnsManagementNoColumns: "Nenhuma coluna para mostrar",
289
+ columnsManagementShowHideAllText: "Mostrar/Ocultar todas",
290
+ columnsManagementReset: "Redefinir",
291
+ columnsManagementDeleteIconLabel: "Excluir",
292
+ columnMenuManageColumns: "Gerenciar colunas",
293
+ columnMenuShowColumns: "Mostrar colunas",
294
+ columnMenuLabel: "Menu da coluna",
295
+ columnMenuHideColumn: "Ocultar",
296
+ columnMenuUnsort: "Remover ordena\xE7\xE3o",
297
+ columnMenuSortAsc: "Ordenar ASC",
298
+ columnMenuSortDesc: "Ordenar DESC",
299
+ columnMenuFilter: "Filtrar",
300
+ toolbarQuickFilterLabel: "Filtro r\xE1pido",
301
+ toolbarQuickFilterPlaceholder: "Filtrar\u2026",
302
+ toolbarQuickFilterDeleteIconLabel: "Limpar filtro",
303
+ toolbarExport: "Exportar",
304
+ toolbarExportLabel: "Exportar",
305
+ toolbarExportCSV: "Baixar como CSV",
306
+ toolbarExportPrint: "Imprimir",
307
+ toolbarColumns: "Colunas",
308
+ toolbarColumnsLabel: "Selecionar colunas",
309
+ toolbarFilters: "Filtros",
310
+ toolbarFiltersLabel: "Mostrar filtros",
311
+ toolbarFiltersTooltipHide: "Ocultar filtros",
312
+ toolbarFiltersTooltipShow: "Mostrar filtros",
313
+ toolbarFiltersTooltipActive: (count) => count === 1 ? `${count} filtro ativo` : `${count} filtros ativos`,
314
+ toolbarDensity: "Densidade",
315
+ toolbarDensityLabel: "Densidade",
316
+ toolbarDensityCompact: "Compacta",
317
+ toolbarDensityStandard: "Padr\xE3o",
318
+ toolbarDensityComfortable: "Confort\xE1vel",
319
+ filterPanelAddFilter: "Adicionar filtro",
320
+ filterPanelDeleteIconLabel: "Excluir",
321
+ filterPanelOperatorAnd: "E",
322
+ filterPanelOperatorOr: "OU",
323
+ filterPanelColumn: "Colunas",
324
+ filterPanelInputLabel: "Valor",
325
+ filterPanelInputPlaceholder: "Valor do filtro",
326
+ filterOperatorContains: "cont\xE9m",
327
+ filterOperatorEquals: "igual a",
328
+ filterOperatorStartsWith: "come\xE7a com",
329
+ filterOperatorEndsWith: "termina com",
330
+ filterOperatorIs: "\xE9",
331
+ filterOperatorNot: "n\xE3o \xE9",
332
+ filterOperatorAfter: "depois de",
333
+ filterOperatorOnOrAfter: "em ou depois de",
334
+ filterOperatorBefore: "antes de",
335
+ filterOperatorOnOrBefore: "em ou antes de",
336
+ filterOperatorIsEmpty: "est\xE1 vazio",
337
+ filterOperatorIsNotEmpty: "n\xE3o est\xE1 vazio",
338
+ filterOperatorIsAnyOf: "\xE9 qualquer um de",
339
+ footerTotalRows: "Total de linhas:",
340
+ footerRowSelected: (count) => count === 1 ? "1 linha selecionada" : `${count.toLocaleString()} linhas selecionadas`,
341
+ footerTotalVisibleRows: (visibleCount, totalCount) => `${visibleCount.toLocaleString()} de ${totalCount.toLocaleString()}`,
342
+ paginationRowsPerPage: "Linhas por p\xE1gina:",
343
+ paginationItemAriaLabel: (type) => {
344
+ switch (type) {
345
+ case "first":
346
+ return "Primeira p\xE1gina";
347
+ case "last":
348
+ return "\xDAltima p\xE1gina";
349
+ case "next":
350
+ return "Pr\xF3xima p\xE1gina";
351
+ case "previous":
352
+ return "P\xE1gina anterior";
353
+ default:
354
+ return "";
355
+ }
356
+ },
357
+ noRowsLabel: "Nenhum dado encontrado",
358
+ noResultsOverlayLabel: "Nenhum resultado encontrado",
359
+ checkboxSelectionHeaderName: "Sele\xE7\xE3o de checkbox",
360
+ checkboxSelectionSelectAllRows: "Selecionar todas as linhas",
361
+ checkboxSelectionUnselectAllRows: "Desmarcar todas as linhas",
362
+ checkboxSelectionSelectRow: "Selecionar linha",
363
+ checkboxSelectionUnselectRow: "Desmarcar linha",
364
+ columnHeaderSortIconLabel: "Ordenar",
365
+ groupingColumnHeaderName: "Grupo",
366
+ groupColumn: (name) => `Agrupar por ${name}`,
367
+ unGroupColumn: (name) => `Parar de agrupar por ${name}`,
368
+ detailPanelToggle: "Alternar painel de detalhes",
369
+ expandDetailPanel: "Expandir",
370
+ collapseDetailPanel: "Recolher",
371
+ treeDataGroupingHeaderName: "Grupo",
372
+ treeDataExpand: "ver filhos",
373
+ treeDataCollapse: "ocultar filhos",
374
+ aggregationMenuItemHeader: "Agrega\xE7\xE3o",
375
+ aggregationFunctionLabelSum: "soma",
376
+ aggregationFunctionLabelAvg: "m\xE9dia",
377
+ aggregationFunctionLabelMin: "m\xEDn",
378
+ aggregationFunctionLabelMax: "m\xE1x",
379
+ aggregationFunctionLabelSize: "tamanho",
380
+ paginationDisplayedRows: ({ from, to, count }) => {
381
+ const total = count === -1 ? "mais de " + to : count;
382
+ return `${from}\u2013${to} de ${total}`;
383
+ }
384
+ });
385
+ var columnPanelSx = {
386
+ padding: 2,
387
+ width: "350px",
388
+ color: "#000000DE",
389
+ "*": { fontFamily: `${tableFont} !important` }
390
+ };
391
+ var columnMenuSx = {
392
+ "*": { fontFamily: `${tableFont} !important` },
393
+ "& .MuiListItemText-primary": {
394
+ fontSize: "14px !important"
395
+ }
396
+ };
397
+ var filterSx = {
398
+ width: "750px",
399
+ "*": {
400
+ fontSize: "14px !important",
401
+ fontFamily: `${tableFont} !important`
402
+ },
403
+ "& .MuiDataGrid-filterFormColumnInput": { width: "230px" },
404
+ "& .MuiDataGrid-filterFormOperatorInput": { width: "230px" }
405
+ };
406
+ var filterTheme = material.createTheme({
407
+ typography: { fontFamily: tableFont },
408
+ components: {
409
+ MuiList: {
410
+ styleOverrides: {
411
+ root: { fontFamily: tableFont }
412
+ }
413
+ },
414
+ MuiMenuItem: {
415
+ styleOverrides: {
416
+ root: { fontFamily: tableFont }
417
+ }
418
+ }
419
+ }
420
+ });
421
+ var paginationSx = {
422
+ "& .MuiTablePagination-root": {
423
+ fontSize: "12px !important",
424
+ fontFamily: `${tableFont} !important`
425
+ },
426
+ "& .MuiTablePagination-selectLabel": {
427
+ fontSize: "12px !important",
428
+ fontFamily: `${tableFont} !important`
429
+ },
430
+ "& .MuiTablePagination-displayedRows": {
431
+ fontSize: "12px !important",
432
+ fontFamily: `${tableFont} !important`
433
+ },
434
+ "& .MuiTablePagination-select": {
435
+ fontSize: "12px !important",
436
+ fontFamily: `${tableFont} !important`
437
+ },
438
+ "& .MuiTablePagination-toolbar": {
439
+ minHeight: "40px !important",
440
+ padding: "0 8px !important"
441
+ }
442
+ };
443
+ var tableSx = {
444
+ fontSize: "13px",
445
+ fontFamily: `${tableFont} !important`,
446
+ "& *": {
447
+ fontFamily: `${tableFont} !important`
448
+ },
449
+ "& .MuiDataGrid-row:nth-of-type(even)": {
450
+ backgroundColor: "#F9FAFB"
451
+ },
452
+ "& .MuiDataGrid-row:nth-of-type(odd)": {
453
+ backgroundColor: "#FFFFFF"
454
+ },
455
+ "& .MuiDataGrid-row.Mui-selected:nth-of-type(even)": {
456
+ backgroundColor: "#F9FAFB !important"
457
+ },
458
+ "& .MuiDataGrid-row.Mui-selected:nth-of-type(odd)": {
459
+ backgroundColor: "#FFFFFF !important"
460
+ },
461
+ "& .MuiDataGrid-row:hover": { backgroundColor: "#F3F4F6 !important" },
462
+ "& .MuiDataGrid-columnHeaderTitleContainer": {
463
+ color: "#FFFFFF",
464
+ justifyContent: "center",
465
+ "& svg": { color: "#FFFFFF" }
466
+ },
467
+ "& .MuiDataGrid-iconButtonContainer .MuiIconButton-root, & .MuiDataGrid-menuIconButton": {
468
+ color: "#FFFFFF"
469
+ },
470
+ "& .MuiDataGrid-iconButtonContainer .MuiIconButton-root:hover, & .MuiDataGrid-menuIconButton:hover": { backgroundColor: "transparent" },
471
+ "& .MuiDataGrid-iconButtonContainer .MuiIconButton-root.Mui-focusVisible, & .MuiDataGrid-menuIconButton.Mui-focusVisible": { backgroundColor: "transparent" },
472
+ "& .MuiDataGrid-columnHeaders": {
473
+ background: "linear-gradient(to right, #00B2A6 0%, #0AAEB2 100%)"
474
+ },
475
+ "& .MuiDataGrid-columnHeader": {
476
+ color: "#FFFFFF",
477
+ fontWeight: "bold",
478
+ backgroundColor: "transparent",
479
+ "& svg": { color: "#FFFFFF" }
480
+ },
481
+ "& .MuiDataGrid-columnHeader:hover": { backgroundColor: "transparent" },
482
+ "& .MuiDataGrid-columnHeader:hover .MuiIconButton-root": {
483
+ backgroundColor: "transparent"
484
+ },
485
+ "& .MuiDataGrid-columnHeader:focus-within": {
486
+ backgroundColor: "transparent"
487
+ },
488
+ "& .MuiDataGrid-columnHeader--sorted": { backgroundColor: "transparent" },
489
+ "& .MuiDataGrid-columnHeader--sorted .MuiIconButton-root": {
490
+ backgroundColor: "transparent"
491
+ },
492
+ "& .MuiDataGrid-sortIcon": { color: "#FFFFFF" },
493
+ "& .MuiDataGrid-sortIcon:hover": { backgroundColor: "transparent" },
494
+ "& .MuiDataGrid-columnHeaderTitle": { fontWeight: "500", color: "#FFFFFF" }
495
+ };
496
+ var createChange = (item, applyValue) => (index) => ({ target }) => {
497
+ const [start = "", end = ""] = Array.isArray(item.value) ? item.value : [];
498
+ applyValue(__spreadProps(__spreadValues({}, item), {
499
+ value: index === 0 ? [target.value, end] : [start, target.value]
500
+ }));
501
+ };
502
+ var textBetweenOp = {
503
+ label: "entre",
504
+ value: "between",
505
+ getApplyFilterFn: (filter) => {
506
+ if (!filter.value || !Array.isArray(filter.value)) return null;
507
+ const [start, end] = filter.value;
508
+ if (!start || !end) return null;
509
+ return (value) => {
510
+ const cell = (value == null ? void 0 : value.toString()) || "";
511
+ return cell >= start && cell <= end;
512
+ };
513
+ },
514
+ InputComponent: ({ item, applyValue, focusElementRef }) => {
515
+ const onChange = createChange(item, applyValue);
516
+ return /* @__PURE__ */ jsxRuntime.jsxs(material.Box, { sx: { display: "flex", flexDirection: "column", gap: 1 }, children: [
517
+ /* @__PURE__ */ jsxRuntime.jsx(
518
+ material.TextField,
519
+ {
520
+ size: "small",
521
+ label: "De",
522
+ variant: "outlined",
523
+ inputRef: focusElementRef,
524
+ value: (item.value || ["", ""])[0] || "",
525
+ onChange: onChange(0),
526
+ placeholder: "Inicial"
527
+ }
528
+ ),
529
+ /* @__PURE__ */ jsxRuntime.jsx(
530
+ material.TextField,
531
+ {
532
+ size: "small",
533
+ label: "At\xE9",
534
+ variant: "outlined",
535
+ value: (item.value || ["", ""])[1] || "",
536
+ onChange: onChange(1),
537
+ placeholder: "Final"
538
+ }
539
+ )
540
+ ] });
541
+ }
542
+ };
543
+ var numberBetweenOp = {
544
+ label: "entre",
545
+ value: "between",
546
+ getApplyFilterFn: (filter) => {
547
+ if (!filter.value || !Array.isArray(filter.value)) return null;
548
+ const [start, end] = filter.value;
549
+ if (start === "" || end === "" || start == null || end == null) return null;
550
+ return (value) => {
551
+ const number = Number(value);
552
+ return number >= Number(start) && number <= Number(end);
553
+ };
554
+ },
555
+ InputComponent: ({ item, applyValue, focusElementRef }) => {
556
+ const onChange = createChange(item, applyValue);
557
+ return /* @__PURE__ */ jsxRuntime.jsxs(material.Box, { sx: { display: "flex", flexDirection: "column", gap: 1 }, children: [
558
+ /* @__PURE__ */ jsxRuntime.jsx(
559
+ material.TextField,
560
+ {
561
+ size: "small",
562
+ label: "De",
563
+ type: "number",
564
+ variant: "outlined",
565
+ inputRef: focusElementRef,
566
+ value: (item.value || ["", ""])[0] || "",
567
+ onChange: onChange(0),
568
+ placeholder: "M\xEDnimo"
569
+ }
570
+ ),
571
+ /* @__PURE__ */ jsxRuntime.jsx(
572
+ material.TextField,
573
+ {
574
+ size: "small",
575
+ label: "At\xE9",
576
+ type: "number",
577
+ variant: "outlined",
578
+ value: (item.value || ["", ""])[1] || "",
579
+ onChange: onChange(1),
580
+ placeholder: "M\xE1ximo"
581
+ }
582
+ )
583
+ ] });
584
+ }
585
+ };
586
+ var getTextOps = () => {
587
+ return [...xDataGrid.getGridStringOperators(), textBetweenOp];
588
+ };
589
+ var getNumberOps = () => {
590
+ return [...xDataGrid.getGridNumericOperators(), numberBetweenOp];
591
+ };
592
+ xDataGrid.GRID_STRING_COL_DEF.filterOperators = getTextOps();
593
+ xDataGrid.GRID_NUMERIC_COL_DEF.filterOperators = getNumberOps();
594
+ function CustomColumnsPanel(props) {
595
+ return /* @__PURE__ */ jsxRuntime.jsx(xDataGrid.GridColumnsPanel, __spreadProps(__spreadValues({}, props), { sx: columnPanelSx }));
596
+ }
597
+ function CustomColumnMenu(props) {
598
+ return /* @__PURE__ */ jsxRuntime.jsx(material.Box, { sx: columnMenuSx, children: /* @__PURE__ */ jsxRuntime.jsx(xDataGrid.GridColumnMenu, __spreadValues({}, props)) });
599
+ }
600
+ function CustomFilterPanel(props) {
601
+ return /* @__PURE__ */ jsxRuntime.jsx(material.ThemeProvider, { theme: filterTheme, children: /* @__PURE__ */ jsxRuntime.jsx(xDataGrid.GridFilterPanel, __spreadProps(__spreadValues({}, props), { sx: filterSx })) });
602
+ }
603
+ function CustomNoRowsOverlay() {
604
+ return /* @__PURE__ */ jsxRuntime.jsx(xDataGrid.GridOverlay, { children: /* @__PURE__ */ jsxRuntime.jsx(material.Box, { sx: { mt: 1 }, children: "Nenhum dado encontrado." }) });
605
+ }
606
+ function CustomPagination() {
607
+ return /* @__PURE__ */ jsxRuntime.jsx(material.Box, { sx: paginationSx, children: /* @__PURE__ */ jsxRuntime.jsx(xDataGrid.GridPagination, {}) });
608
+ }
609
+ var DataTable = (_a) => {
610
+ var rest = __objRest(_a, []);
611
+ return /* @__PURE__ */ jsxRuntime.jsx(material.Box, { sx: { mb: 2, mt: 2, height: "100%" }, children: /* @__PURE__ */ jsxRuntime.jsx(
612
+ xDataGrid.DataGrid,
613
+ __spreadProps(__spreadValues({
614
+ sx: tableSx
615
+ }, rest), {
616
+ className: "min-h-[210px]!",
617
+ localeText,
618
+ disableRowSelectionOnClick: true,
619
+ slotProps: {
620
+ loadingOverlay: {
621
+ variant: "linear-progress",
622
+ noRowsVariant: "skeleton"
623
+ }
624
+ },
625
+ slots: {
626
+ columnMenu: CustomColumnMenu,
627
+ filterPanel: CustomFilterPanel,
628
+ columnsPanel: CustomColumnsPanel,
629
+ noRowsOverlay: CustomNoRowsOverlay,
630
+ pagination: CustomPagination
631
+ }
632
+ })
633
+ ) });
634
+ };
635
+ var data_table_default = DataTable;
636
+ var DEFAULT_TAB_COLOR = "var(--primary-color)";
637
+ var DEFAULT_TAB_FONT_FAMILY = "var(--font-family, inherit)";
638
+ var Tabs = material.styled(material.Tabs, {
639
+ shouldForwardProp: (prop) => prop !== "color"
640
+ })(({ color = DEFAULT_TAB_COLOR }) => ({
641
+ fontFamily: `${DEFAULT_TAB_FONT_FAMILY} !important`,
642
+ "& .MuiTabs-indicator": { backgroundColor: color }
643
+ }));
644
+ var Tab = material.styled(material.Tab, {
645
+ shouldForwardProp: (prop) => prop !== "color" && prop !== "fontFamily"
646
+ })(
647
+ ({ color = DEFAULT_TAB_COLOR, fontFamily = DEFAULT_TAB_FONT_FAMILY }) => ({
648
+ fontWeight: "500 !important",
649
+ color: "#000000CC !important",
650
+ fontSize: "14px !important",
651
+ textTransform: "uppercase !important",
652
+ fontFamily: `${fontFamily} !important`,
653
+ "&.Mui-selected": { color: `${color} !important` }
654
+ })
655
+ );
656
+
657
+ // src/core/css-var.ts
658
+ function withCssVar(style, name, value) {
659
+ if (value == null || value === "") return style;
660
+ return __spreadProps(__spreadValues({}, style), { [name]: value });
661
+ }
662
+ var DEFAULT_ACCENT = "var(--primary-color)";
663
+ var accent = "var(--primary-color)";
664
+ var errorColor = "#D32F2F";
665
+ var focusLabel = { color: accent };
666
+ var errorLabel = { color: errorColor };
667
+ var borderAccent = { borderColor: accent };
668
+ var borderError = { borderColor: errorColor };
669
+ var underlineAccent = { borderBottomColor: accent };
670
+ var underlineError = { borderBottomColor: errorColor };
671
+ var disabledText = { color: "#9E9E9E", cursor: "not-allowed" };
672
+ var disabledBorder = { borderColor: "#9E9E9E", cursor: "not-allowed" };
673
+ var input = {
674
+ color: "#333",
675
+ fontSize: "13px !important",
676
+ fontFamily: "var(--font-poppins) !important"
677
+ };
678
+ var InputTextField = material.styled(material.TextField)({
679
+ fontFamily: "var(--font-poppins) !important",
680
+ "& input": input,
681
+ "& label": input,
682
+ "& label.Mui-focused": focusLabel,
683
+ "& label.Mui-error": errorLabel,
684
+ "& .MuiInput-underline:after": underlineAccent,
685
+ "& .MuiInput-underline.Mui-error:after": underlineError,
686
+ "& .MuiOutlinedInput-root": {
687
+ "& fieldset": borderAccent,
688
+ "&:hover fieldset": borderAccent,
689
+ "&.Mui-disabled fieldset": disabledBorder,
690
+ "&.Mui-focused fieldset": borderAccent,
691
+ "&.Mui-error fieldset": borderError,
692
+ "&.Mui-error:hover fieldset": borderError,
693
+ "&.Mui-error.Mui-focused fieldset": borderError
694
+ },
695
+ "& .MuiFilledInput-root": {
696
+ backgroundColor: "#F9FAFB",
697
+ "&:after": underlineAccent,
698
+ "&:before": underlineAccent,
699
+ "&:hover:before": underlineAccent,
700
+ "&.Mui-error:after": underlineError,
701
+ "&.Mui-error:before": underlineError,
702
+ "&:hover": { backgroundColor: "#F5F5F5" },
703
+ "&.Mui-error:hover:before": underlineError,
704
+ fontFamily: "var(--font-poppins) !important",
705
+ "&.Mui-disabled": __spreadProps(__spreadValues({}, disabledText), { backgroundColor: "#F9FAFB" })
706
+ },
707
+ "& .MuiInputBase-input": __spreadProps(__spreadValues({}, input), { "&.Mui-disabled": disabledText }),
708
+ "& .MuiFormHelperText-root": {
709
+ fontSize: "11px",
710
+ marginLeft: 2,
711
+ fontFamily: "var(--font-poppins) !important"
712
+ },
713
+ "& .MuiFormHelperText-root.Mui-error": { color: errorColor },
714
+ "& .Mui-disabled": disabledText
715
+ });
716
+ var css_default = react.memo(InputTextField);
717
+ function useInputMasker({ type, onChange }) {
718
+ const formatValue = react.useCallback(
719
+ (v) => {
720
+ if (!v) return "";
721
+ switch (type) {
722
+ case "cpf-cnpj":
723
+ return formatCpfCnpj(v);
724
+ case "numeric":
725
+ return removeDigits(v);
726
+ case "tel":
727
+ return formatPhoneBr(v);
728
+ case "price":
729
+ return formatPriceBrl(v);
730
+ case "text-only":
731
+ return removeTextOnly(v);
732
+ case "text-no-number":
733
+ return removeNonDigits(v);
734
+ case "item-170":
735
+ return formatItem170(v);
736
+ case "item-150":
737
+ return formatItem150(v);
738
+ default:
739
+ return v;
740
+ }
741
+ },
742
+ [type]
743
+ );
744
+ const handleChange = (e) => {
745
+ const newValue = e.target.value;
746
+ onChange == null ? void 0 : onChange(__spreadProps(__spreadValues({}, e), {
747
+ target: __spreadProps(__spreadValues({}, e.target), { value: formatValue(newValue) })
748
+ }));
749
+ };
750
+ return { handleChange };
751
+ }
752
+ function withPasswordToggle({
753
+ showPwd,
754
+ canToggle,
755
+ slotProps,
756
+ setShowPwd,
757
+ color = DEFAULT_ACCENT
758
+ }) {
759
+ if (!canToggle) return slotProps;
760
+ const Icon = showPwd ? md.MdVisibilityOff : md.MdVisibility;
761
+ return __spreadProps(__spreadValues({}, slotProps), {
762
+ input: __spreadProps(__spreadValues({}, slotProps == null ? void 0 : slotProps.input), {
763
+ endAdornment: /* @__PURE__ */ jsxRuntime.jsx(material.InputAdornment, { position: "end", children: /* @__PURE__ */ jsxRuntime.jsx(
764
+ material.IconButton,
765
+ {
766
+ edge: "end",
767
+ size: "small",
768
+ sx: { color },
769
+ onClick: () => setShowPwd((prev) => !prev),
770
+ children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { size: 20 })
771
+ }
772
+ ) })
773
+ })
774
+ });
775
+ }
776
+ function buildSlotProps(args) {
777
+ return withPasswordToggle(args);
778
+ }
779
+ var CUSTOM_INPUT_TYPES = /* @__PURE__ */ new Set([
780
+ "cpf-cnpj",
781
+ "numeric",
782
+ "price",
783
+ "item-170",
784
+ "item-150",
785
+ "text-only",
786
+ "text-no-number"
787
+ ]);
788
+ function resolveHtmlInputType(type) {
789
+ if (!type || CUSTOM_INPUT_TYPES.has(type)) return "text";
790
+ return type;
791
+ }
792
+ var Input = (_a) => {
793
+ var _b = _a, {
794
+ color,
795
+ onChange,
796
+ isPassword,
797
+ type = "text",
798
+ size = "small"
799
+ } = _b, rest = __objRest(_b, [
800
+ "color",
801
+ "onChange",
802
+ "isPassword",
803
+ "type",
804
+ "size"
805
+ ]);
806
+ const [showPwd, setShowPwd] = react.useState(false);
807
+ const isPwd = type === "password";
808
+ const canToggle = isPwd && isPassword;
809
+ const htmlType = resolveHtmlInputType(type);
810
+ const inputType = canToggle && showPwd ? "text" : htmlType;
811
+ const style = react.useMemo(
812
+ () => withCssVar(rest.style, "--primary-color", color),
813
+ [color, rest.style]
814
+ );
815
+ const slotProps = react.useMemo(
816
+ () => buildSlotProps({
817
+ color,
818
+ showPwd,
819
+ canToggle,
820
+ setShowPwd,
821
+ slotProps: rest.slotProps
822
+ }),
823
+ [canToggle, color, showPwd, rest.slotProps]
824
+ );
825
+ const { handleChange } = useInputMasker({ type, onChange });
826
+ return /* @__PURE__ */ jsxRuntime.jsx(
827
+ css_default,
828
+ __spreadProps(__spreadValues({}, rest), {
829
+ size,
830
+ style,
831
+ type: inputType,
832
+ slotProps,
833
+ onChange: handleChange,
834
+ className: cn("select-none", rest.className)
835
+ })
836
+ );
837
+ };
838
+ var input_default = Input;
839
+
840
+ // src/components/ui/input-select/utils/css.ts
841
+ var optionText = {
842
+ fontSize: "13px !important",
843
+ fontFamily: "var(--font-poppins) !important"
844
+ };
845
+ var selectMui = {
846
+ "& .MuiAutocomplete-option": __spreadProps(__spreadValues({
847
+ padding: "8px 12px"
848
+ }, optionText), {
849
+ lineHeight: "25px !important"
850
+ }),
851
+ "& .MuiAutocomplete-noOptions": optionText,
852
+ "& .MuiAutocomplete-listbox": { padding: "5px" }
853
+ };
854
+
855
+ // src/components/ui/input-select/utils/constants.ts
856
+ var locale = {
857
+ noOptionsText: "Nenhum resultado encontrado"
858
+ };
859
+ function InputSelect(_a) {
860
+ var _b = _a, {
861
+ input: input2,
862
+ multiple,
863
+ onChange,
864
+ optionLabel,
865
+ noOptionsText = locale.noOptionsText
866
+ } = _b, rest = __objRest(_b, [
867
+ "input",
868
+ "multiple",
869
+ "onChange",
870
+ "optionLabel",
871
+ "noOptionsText"
872
+ ]);
873
+ const handleChange = (event, value, reason, details) => {
874
+ onChange == null ? void 0 : onChange(event, value, reason, details);
875
+ };
876
+ return /* @__PURE__ */ jsxRuntime.jsx(
877
+ Autocomplete__default.default,
878
+ __spreadProps(__spreadValues({}, rest), {
879
+ size: "small",
880
+ multiple,
881
+ onChange: handleChange,
882
+ noOptionsText,
883
+ slotProps: { paper: { sx: selectMui } },
884
+ getOptionLabel: (option) => typeof option === "string" ? "" : optionLabel(option),
885
+ isOptionEqualToValue: (option, value) => JSON.stringify(option) === JSON.stringify(value),
886
+ renderInput: (params) => {
887
+ var _a2;
888
+ return /* @__PURE__ */ jsxRuntime.jsx(input_default, __spreadProps(__spreadValues(__spreadValues({}, params), input2), { size: (_a2 = input2 == null ? void 0 : input2.size) != null ? _a2 : "small" }));
889
+ }
890
+ })
891
+ );
892
+ }
893
+ var input_select_default = InputSelect;
894
+ var FilterCard = ({
895
+ title,
896
+ setOpen,
897
+ renderFilter
898
+ }) => {
899
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "h-15 flex items-center w-full bg-white mb-2 rounded-md shadow-[0_2px_6px_-1px_rgba(0,0,0,.16),0_6px_18px_-1px_rgba(0,0,0,.06)]", children: [
900
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-full w-2 bg-(--primary-color) rounded-tl-md rounded-bl-md" }),
901
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "w-full flex justify-between items-center p-3", children: [
902
+ /* @__PURE__ */ jsxRuntime.jsx("h1", { className: "font-medium text-lg whitespace-nowrap text-ellipsis overflow-hidden ml-1 text-black/80", children: title }),
903
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center space-x-4", children: renderFilter && /* @__PURE__ */ jsxRuntime.jsx(
904
+ core.Tooltip,
905
+ {
906
+ withArrow: true,
907
+ arrowSize: 4,
908
+ color: "#00b2a6",
909
+ arrowOffset: 20,
910
+ label: "Ver filtros",
911
+ className: "text-xs!",
912
+ transitionProps: { transition: "pop", duration: 300 },
913
+ children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex items-center", children: /* @__PURE__ */ jsxRuntime.jsx(
914
+ core.ActionIcon,
915
+ {
916
+ size: 40,
917
+ radius: "md",
918
+ "aria-label": "Ver filtros",
919
+ color: "var(--primary-color)",
920
+ onClick: () => setOpen(true),
921
+ children: /* @__PURE__ */ jsxRuntime.jsx(fa.FaFilter, { className: "h-5 w-5 text-white" })
922
+ }
923
+ ) })
924
+ }
925
+ ) })
926
+ ] })
927
+ ] });
928
+ };
929
+ var card_default2 = FilterCard;
930
+
931
+ // src/components/ui/filter/utils/constants.ts
932
+ var FILTER_DEFAULT_ORDER = 99;
933
+ var FILTER_DRAWER_PAPER_SX = {
934
+ ["& .MuiDrawer-paper"]: { borderRadius: "0px 0px 20px 20px" }
935
+ };
936
+ function hasFilterFields(inputs, inputSelect) {
937
+ var _a, _b;
938
+ return ((_a = inputs == null ? void 0 : inputs.length) != null ? _a : 0) > 0 || ((_b = inputSelect == null ? void 0 : inputSelect.length) != null ? _b : 0) > 0;
939
+ }
940
+ function isInputSelect(field) {
941
+ return "options" in field;
942
+ }
943
+ function filterInputSelect(props) {
944
+ return props;
945
+ }
946
+ function sortFilterFields(fields) {
947
+ return [...fields].sort(
948
+ (a, b) => {
949
+ var _a, _b;
950
+ return ((_a = a.order) != null ? _a : FILTER_DEFAULT_ORDER) - ((_b = b.order) != null ? _b : FILTER_DEFAULT_ORDER);
951
+ }
952
+ );
953
+ }
954
+ function mergeFilterFields(inputs, inputSelect) {
955
+ return sortFilterFields([...inputs, ...inputSelect]);
956
+ }
957
+ function getFilterGridColumns(isMobile, isTablet) {
958
+ if (isMobile) return 1;
959
+ if (isTablet) return 3;
960
+ return 7;
961
+ }
962
+ var FilterDrawer = ({
963
+ open,
964
+ setOpen,
965
+ onClear,
966
+ onSubmit,
967
+ inputs = [],
968
+ inputSelect = []
969
+ }) => {
970
+ const m640 = material.useMediaQuery("(max-width:640px)");
971
+ const m1120 = material.useMediaQuery("(max-width:1120px)");
972
+ const allInputs = mergeFilterFields(inputs, inputSelect);
973
+ const renderField = (field, index) => {
974
+ var _a, _b, _c;
975
+ if (isInputSelect(field)) {
976
+ if (field.multiple) {
977
+ return /* @__PURE__ */ jsxRuntime.jsx(material.Grid, { size: (_a = field.xs) != null ? _a : 1, children: /* @__PURE__ */ jsxRuntime.jsx(
978
+ input_select_default,
979
+ __spreadProps(__spreadValues({}, field), {
980
+ id: `inputSM${index}`,
981
+ fullWidth: true
982
+ })
983
+ ) }, `inputSelect-${index}`);
984
+ }
985
+ return /* @__PURE__ */ jsxRuntime.jsx(material.Grid, { size: (_b = field.xs) != null ? _b : 1, children: /* @__PURE__ */ jsxRuntime.jsx(
986
+ input_select_default,
987
+ __spreadProps(__spreadValues({}, field), {
988
+ id: `inputSM${index}`,
989
+ fullWidth: true
990
+ })
991
+ ) }, `inputSelect-${index}`);
992
+ }
993
+ return /* @__PURE__ */ jsxRuntime.jsx(material.Grid, { size: (_c = field.xs) != null ? _c : 1, children: /* @__PURE__ */ jsxRuntime.jsx(input_default, __spreadProps(__spreadValues({}, field), { fullWidth: true })) }, `input-${index}`);
994
+ };
995
+ const handleSubmit = (event) => {
996
+ event.preventDefault();
997
+ if (!onSubmit) return;
998
+ onSubmit(event);
999
+ setOpen(false);
1000
+ };
1001
+ return /* @__PURE__ */ jsxRuntime.jsx(
1002
+ material.Drawer,
1003
+ {
1004
+ open,
1005
+ anchor: "top",
1006
+ onClose: () => setOpen(false),
1007
+ sx: FILTER_DRAWER_PAPER_SX,
1008
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
1009
+ "form",
1010
+ {
1011
+ onSubmit: handleSubmit,
1012
+ className: "flex w-full select-none flex-col py-4 pl-5",
1013
+ children: [
1014
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-lg font-medium text-system-900", children: "Filtros" }),
1015
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "pb-5 pt-1 text-sm text-black/80", children: "Para que possamos apresentar dados espec\xEDficos, por favor, preencha os campos abaixo." }),
1016
+ /* @__PURE__ */ jsxRuntime.jsx(
1017
+ material.Grid,
1018
+ {
1019
+ container: true,
1020
+ rowSpacing: 2,
1021
+ className: "pr-5",
1022
+ columnSpacing: 1,
1023
+ columns: getFilterGridColumns(Boolean(m640), Boolean(m1120)),
1024
+ children: allInputs.map((field, index) => renderField(field, index))
1025
+ }
1026
+ ),
1027
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-end space-x-4 pr-4 pt-4", children: [
1028
+ onClear && /* @__PURE__ */ jsxRuntime.jsx(
1029
+ core.Button,
1030
+ {
1031
+ radius: "sm",
1032
+ color: "#253E56",
1033
+ variant: "outline",
1034
+ onClick: onClear,
1035
+ size: "xs",
1036
+ children: "LIMPAR FILTROS"
1037
+ }
1038
+ ),
1039
+ onSubmit && /* @__PURE__ */ jsxRuntime.jsx(
1040
+ core.Button,
1041
+ {
1042
+ size: "xs",
1043
+ radius: "sm",
1044
+ type: "submit",
1045
+ variant: "filled",
1046
+ color: "var(--primary-color)",
1047
+ children: "PESQUISAR"
1048
+ }
1049
+ )
1050
+ ] })
1051
+ ]
1052
+ }
1053
+ )
1054
+ }
1055
+ );
1056
+ };
1057
+ var filter_default = FilterDrawer;
1058
+ var Filter = ({
1059
+ title,
1060
+ inputs,
1061
+ onClear,
1062
+ onSubmit,
1063
+ inputSelect
1064
+ }) => {
1065
+ const [open, setOpen] = react.useState(false);
1066
+ const hasFields = hasFilterFields(inputs, inputSelect);
1067
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
1068
+ /* @__PURE__ */ jsxRuntime.jsx(card_default2, { title, setOpen, renderFilter: hasFields }),
1069
+ /* @__PURE__ */ jsxRuntime.jsx(
1070
+ filter_default,
1071
+ {
1072
+ open,
1073
+ inputs,
1074
+ setOpen,
1075
+ onClear,
1076
+ onSubmit,
1077
+ inputSelect
1078
+ }
1079
+ )
1080
+ ] });
1081
+ };
1082
+ var filter_default2 = Filter;
1083
+ var DEFAULT_SAY_RATE = 1.4;
1084
+ var DEFAULT_SAY_VOLUME = 1;
1085
+ var DEFAULT_SAY_PITCH = 0.8;
1086
+ var DEFAULT_SAY_VIBRATE_DURATION = 500;
1087
+ var DEFAULT_SAY_VOICE = "Google portugu\xEAs do Brasil";
1088
+ var SPEECH_APIS = ["speechSynthesis", "SpeechSynthesisUtterance"];
1089
+ function hasSpeechSupport() {
1090
+ return SPEECH_APIS.every((api) => api in globalThis);
1091
+ }
1092
+ function voicesAreEqual(current, next) {
1093
+ if (current.length !== next.length) return false;
1094
+ return current.every(
1095
+ (v, i) => {
1096
+ var _a, _b;
1097
+ return v.name === ((_a = next[i]) == null ? void 0 : _a.name) && v.lang === ((_b = next[i]) == null ? void 0 : _b.lang);
1098
+ }
1099
+ );
1100
+ }
1101
+ function getSpeechSupport() {
1102
+ if (!hasSpeechSupport()) return null;
1103
+ return {
1104
+ speechSynthesis: globalThis.speechSynthesis,
1105
+ SpeechSynthesisUtterance: globalThis.SpeechSynthesisUtterance
1106
+ };
1107
+ }
1108
+ function defaultShouldVibrate(type) {
1109
+ return type === "warning";
1110
+ }
1111
+ function showSayNotify(text, { type = "success", autoClose = 4500 }) {
1112
+ reactToastify.toast(text, { type, autoClose });
1113
+ }
1114
+ function useSpeechPonyfill() {
1115
+ const ponyfill = react.useMemo(() => getSpeechSupport(), []);
1116
+ const [voices, setVoices] = react.useState([]);
1117
+ react.useEffect(() => {
1118
+ if (!hasSpeechSupport()) return;
1119
+ const synthesis = globalThis.speechSynthesis;
1120
+ const updateVoices = () => {
1121
+ setVoices((current) => {
1122
+ const next = synthesis.getVoices();
1123
+ return voicesAreEqual(current, next) ? current : next;
1124
+ });
1125
+ };
1126
+ synthesis.onvoiceschanged = updateVoices;
1127
+ updateVoices();
1128
+ return () => {
1129
+ synthesis.onvoiceschanged = null;
1130
+ };
1131
+ }, []);
1132
+ return { voices, ponyfill };
1133
+ }
1134
+ function Say({
1135
+ text,
1136
+ onEnd,
1137
+ onStart,
1138
+ isSpeaking,
1139
+ setIsSpeaking,
1140
+ rate = DEFAULT_SAY_RATE,
1141
+ voice = DEFAULT_SAY_VOICE,
1142
+ pitch = DEFAULT_SAY_PITCH,
1143
+ volume = DEFAULT_SAY_VOLUME
1144
+ }) {
1145
+ const { voices, ponyfill } = useSpeechPonyfill();
1146
+ const canSpeak = isSpeaking && voices.length > 0 && ponyfill;
1147
+ const handleEnd = react.useCallback(() => {
1148
+ setIsSpeaking(false);
1149
+ onEnd == null ? void 0 : onEnd();
1150
+ }, [setIsSpeaking, onEnd]);
1151
+ return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1152
+ /* @__PURE__ */ jsxRuntime.jsx(
1153
+ reactToastify.ToastContainer,
1154
+ {
1155
+ limit: 3,
1156
+ draggable: true,
1157
+ newestOnTop: true,
1158
+ pauseOnHover: true,
1159
+ closeOnClick: true,
1160
+ autoClose: 4500,
1161
+ pauseOnFocusLoss: true,
1162
+ closeButton: false,
1163
+ position: "top-right",
1164
+ style: { fontSize: "14px" }
1165
+ }
1166
+ ),
1167
+ canSpeak && /* @__PURE__ */ jsxRuntime.jsx(
1168
+ SayEngine__default.default,
1169
+ {
1170
+ text,
1171
+ rate,
1172
+ pitch,
1173
+ volume,
1174
+ onEnd: handleEnd,
1175
+ onStart,
1176
+ ponyfill,
1177
+ voice: voices.find((v) => v.name === voice)
1178
+ }
1179
+ )
1180
+ ] });
1181
+ }
1182
+ var say_default = Say;
1183
+ function useSay({
1184
+ notifyAutoClose = 4500,
1185
+ vibrateDuration = DEFAULT_SAY_VIBRATE_DURATION,
1186
+ shouldVibrate = defaultShouldVibrate
1187
+ } = {}) {
1188
+ const [isSpeaking, setIsSpeaking] = react.useState(false);
1189
+ const [textSpeaking, setTextSpeaking] = react.useState("");
1190
+ const handleSay = react.useCallback(
1191
+ (text, options) => {
1192
+ const notify = nvl(options.notify, true);
1193
+ const vibrate = nvl(options.vibrate, true);
1194
+ const { type } = options;
1195
+ setIsSpeaking(true);
1196
+ setTextSpeaking(text);
1197
+ if (notify) {
1198
+ showSayNotify(text, {
1199
+ type,
1200
+ autoClose: nvl(options.autoClose, notifyAutoClose)
1201
+ });
1202
+ }
1203
+ if (vibrate && shouldVibrate(type) && navigator.vibrate) {
1204
+ navigator.vibrate(vibrateDuration);
1205
+ }
1206
+ },
1207
+ [shouldVibrate, vibrateDuration, notifyAutoClose]
1208
+ );
1209
+ return { handleSay, isSpeaking, textSpeaking, setIsSpeaking };
1210
+ }
1211
+ var defaultMuiTheme = material.createTheme({
1212
+ typography: { fontFamily: "var(--font-family, inherit)" }
1213
+ });
1214
+ function GrazziotinProviders({
1215
+ children,
1216
+ muiTheme = defaultMuiTheme
1217
+ }) {
1218
+ return /* @__PURE__ */ jsxRuntime.jsxs(material.ThemeProvider, { theme: muiTheme, children: [
1219
+ /* @__PURE__ */ jsxRuntime.jsx(material.CssBaseline, {}),
1220
+ /* @__PURE__ */ jsxRuntime.jsx(core.MantineProvider, { children })
1221
+ ] });
1222
+ }
1223
+
1224
+ exports.Card = card_default;
1225
+ exports.DataTable = data_table_default;
1226
+ exports.Dialog = dialog_default;
1227
+ exports.Filter = filter_default2;
1228
+ exports.GrazziotinProviders = GrazziotinProviders;
1229
+ exports.Input = input_default;
1230
+ exports.InputSelect = input_select_default;
1231
+ exports.Say = say_default;
1232
+ exports.Tab = Tab;
1233
+ exports.Tabs = Tabs;
1234
+ exports.cn = cn;
1235
+ exports.filterInputSelect = filterInputSelect;
1236
+ exports.formatCpfCnpj = formatCpfCnpj;
1237
+ exports.formatItem150 = formatItem150;
1238
+ exports.formatItem170 = formatItem170;
1239
+ exports.formatPhoneBr = formatPhoneBr;
1240
+ exports.formatPriceBrl = formatPriceBrl;
1241
+ exports.nvl = nvl;
1242
+ exports.useSay = useSay;
1243
+ //# sourceMappingURL=index.js.map
1244
+ //# sourceMappingURL=index.js.map