@data-c/ui 0.2.82 → 0.2.84

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 CHANGED
@@ -2903,6 +2903,9 @@ var prefixes = {
2903
2903
  context: "$",
2904
2904
  value: "."
2905
2905
  };
2906
+ function create$9(key2, options) {
2907
+ return new Reference(key2, options);
2908
+ }
2906
2909
  var Reference = class {
2907
2910
  constructor(key2, options = {}) {
2908
2911
  this.key = void 0;
@@ -5051,6 +5054,7 @@ var TupleSchema = class extends Schema {
5051
5054
  create$1.prototype = TupleSchema.prototype;
5052
5055
 
5053
5056
  // src/AlterarSenha/index.tsx
5057
+ var _iconsmaterial = require('@mui/icons-material');
5054
5058
 
5055
5059
 
5056
5060
 
@@ -5073,7 +5077,7 @@ var _VisibilityOff = require('@mui/icons-material/VisibilityOff'); var _Visibili
5073
5077
 
5074
5078
 
5075
5079
  function PasswordTextField(props) {
5076
- const { name, label, value, onChange, onKeyDown } = props;
5080
+ const { name, label, value, onChange, onKeyDown, ...rest } = props;
5077
5081
  const [showPassword, setShowPassword] = _react.useState.call(void 0, false);
5078
5082
  function handleClickShowPassword() {
5079
5083
  setShowPassword(!showPassword);
@@ -5087,17 +5091,20 @@ function PasswordTextField(props) {
5087
5091
  onChange,
5088
5092
  onKeyDown,
5089
5093
  type: showPassword ? "text" : "password",
5090
- InputProps: {
5091
- endAdornment: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.InputAdornment, { position: "end", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5092
- _material.IconButton,
5093
- {
5094
- tabIndex: -1,
5095
- onClick: handleClickShowPassword,
5096
- edge: "end",
5097
- children: showPassword ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _VisibilityOff2.default, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _Visibility2.default, {})
5098
- }
5099
- ) })
5100
- }
5094
+ slotProps: {
5095
+ input: {
5096
+ endAdornment: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.InputAdornment, { position: "end", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5097
+ _material.IconButton,
5098
+ {
5099
+ tabIndex: -1,
5100
+ onClick: handleClickShowPassword,
5101
+ edge: "end",
5102
+ children: showPassword ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _VisibilityOff2.default, {}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _Visibility2.default, {})
5103
+ }
5104
+ ) })
5105
+ }
5106
+ },
5107
+ ...rest
5101
5108
  }
5102
5109
  );
5103
5110
  }
@@ -5437,11 +5444,13 @@ function ValidatorMessage(props) {
5437
5444
 
5438
5445
  var defaultData = {
5439
5446
  senhaAtual: "",
5440
- senhaNova: ""
5447
+ senhaNova: "",
5448
+ senhaNovaConfirmar: ""
5441
5449
  };
5442
5450
  var schema = create$3().shape({
5443
5451
  senhaAtual: create$6().required("Informe a Senha Atual."),
5444
- senhaNova: create$6().required("Informe a Nova Senha.")
5452
+ senhaNova: create$6().required("Informe a Nova Senha."),
5453
+ senhaNovaConfirmar: create$6().required("Informe a Nova Senha.").oneOf([create$9("senhaNova")], "As senhas devem ser iguais.")
5445
5454
  });
5446
5455
  function AlterarSenha(props) {
5447
5456
  const {
@@ -5499,6 +5508,8 @@ function AlterarSenha(props) {
5499
5508
  setError("Ocorreu um erro ao tentar alterar a senha");
5500
5509
  }
5501
5510
  }).catch((error2) => {
5511
+ console.log("Erros por campo:", error2.inner);
5512
+ console.log("Primeiro erro:", error2.errors);
5502
5513
  setValidationErrors(error2);
5503
5514
  });
5504
5515
  }
@@ -5533,6 +5544,11 @@ function AlterarSenha(props) {
5533
5544
  }
5534
5545
  return false;
5535
5546
  }
5547
+ function asSenhasSaoIguais() {
5548
+ if (_optionalChain([data, 'optionalAccess', _24 => _24.senhaNova]) === "")
5549
+ return false;
5550
+ return _optionalChain([data, 'optionalAccess', _25 => _25.senhaNova]) === _optionalChain([data, 'optionalAccess', _26 => _26.senhaNovaConfirmar]);
5551
+ }
5536
5552
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Dialog_default.Root, { open: isOpen, onClose: (_) => onClose(), maxWidth: "md", children: [
5537
5553
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Dialog_default.Header, { children: [
5538
5554
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Dialog_default.Title, { children: "Alterar Senha" }),
@@ -5544,26 +5560,61 @@ function AlterarSenha(props) {
5544
5560
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "br", {}),
5545
5561
  "Cadastre uma senha segura para deixar sua conta mais protegida."
5546
5562
  ] }) }),
5547
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Grid, { size: 12, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5548
- PasswordTextField,
5549
- {
5550
- name: "senhaAtual",
5551
- label: "Senha Atual",
5552
- value: _optionalChain([data, 'optionalAccess', _24 => _24.senhaAtual]) || "",
5553
- onChange: handleChange,
5554
- ...validationProps("senhaAtual")
5555
- }
5556
- ) }),
5563
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.Grid, { size: 12, children: [
5564
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5565
+ PasswordTextField,
5566
+ {
5567
+ name: "senhaAtual",
5568
+ label: "Senha Atual",
5569
+ value: _optionalChain([data, 'optionalAccess', _27 => _27.senhaAtual]) || "",
5570
+ onChange: handleChange,
5571
+ ...validationProps("senhaAtual")
5572
+ }
5573
+ ),
5574
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
5575
+ _material.Box,
5576
+ {
5577
+ sx: { display: "flex", alignItems: "center", gap: 0.5, mt: 0.5 },
5578
+ children: [
5579
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _iconsmaterial.InfoOutlined, { sx: { fontSize: 14, color: "text.secondary" } }),
5580
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Typography, { variant: "caption", color: "text.secondary", children: "Essa \xE9 a senha que voc\xEA utiliza para acessar o sistema atualmente." })
5581
+ ]
5582
+ }
5583
+ )
5584
+ ] }),
5585
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Grid, { size: 12, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Divider, {}) }),
5557
5586
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Grid, { size: 12, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5558
5587
  PasswordTextField,
5559
5588
  {
5560
5589
  name: "senhaNova",
5561
5590
  label: "Nova Senha",
5562
- value: _optionalChain([data, 'optionalAccess', _25 => _25.senhaNova]) || "",
5591
+ value: _optionalChain([data, 'optionalAccess', _28 => _28.senhaNova]) || "",
5563
5592
  onChange: handleChange,
5564
5593
  ...validationProps("senhaNova")
5565
5594
  }
5566
5595
  ) }),
5596
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.Grid, { size: 12, children: [
5597
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5598
+ PasswordTextField,
5599
+ {
5600
+ name: "senhaNovaConfirmar",
5601
+ label: "Confirmar Nova Senha",
5602
+ value: _optionalChain([data, 'optionalAccess', _29 => _29.senhaNovaConfirmar]) || "",
5603
+ onChange: handleChange,
5604
+ ...validationProps("senhaNovaConfirmar")
5605
+ }
5606
+ ),
5607
+ /* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
5608
+ _material.Box,
5609
+ {
5610
+ sx: { display: "flex", alignItems: "center", gap: 0.5, mt: 0.5 },
5611
+ children: [
5612
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _iconsmaterial.InfoOutlined, { sx: { fontSize: 14, color: "text.secondary" } }),
5613
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Typography, { variant: "caption", color: "text.secondary", children: "Informe nos campos acima a nova senha que deseja utilizar." })
5614
+ ]
5615
+ }
5616
+ )
5617
+ ] }),
5567
5618
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.Grid, { size: 12, children: [
5568
5619
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5569
5620
  ValidatorMessage,
@@ -5599,6 +5650,13 @@ function AlterarSenha(props) {
5599
5650
  isValid: temCaracterEspecial(),
5600
5651
  message: "A nova senha deve ter ao menos um caracter especial"
5601
5652
  }
5653
+ ),
5654
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
5655
+ ValidatorMessage,
5656
+ {
5657
+ isValid: asSenhasSaoIguais(),
5658
+ message: "A confirma\xE7\xE3o da nova senha deve ser igual \xE0 nova senha"
5659
+ }
5602
5660
  )
5603
5661
  ] }),
5604
5662
  error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Grid, { size: 12, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Alert, { severity: "error", children: error }) })
@@ -5647,11 +5705,11 @@ function LoginForm(props) {
5647
5705
  } catch (err) {
5648
5706
  if (_axios.isAxiosError.call(void 0, err)) {
5649
5707
  const axiosError = err;
5650
- if (_optionalChain([axiosError, 'access', _26 => _26.response, 'optionalAccess', _27 => _27.data, 'access', _28 => _28.code]) === "E_FIRST_ACCESS") {
5708
+ if (_optionalChain([axiosError, 'access', _30 => _30.response, 'optionalAccess', _31 => _31.data, 'access', _32 => _32.code]) === "E_FIRST_ACCESS") {
5651
5709
  setExibirAlterarSenha(true);
5652
5710
  return;
5653
5711
  }
5654
- setError(_optionalChain([err, 'access', _29 => _29.response, 'optionalAccess', _30 => _30.data, 'access', _31 => _31.message]));
5712
+ setError(_optionalChain([err, 'access', _33 => _33.response, 'optionalAccess', _34 => _34.data, 'access', _35 => _35.message]));
5655
5713
  }
5656
5714
  onLoginFailed(err);
5657
5715
  }
@@ -5813,7 +5871,7 @@ function EsqueciSenhaForm(props) {
5813
5871
  await recuperarSenha(email);
5814
5872
  setSucessoRecuperarSenha(true);
5815
5873
  } catch (error2) {
5816
- setError(_optionalChain([error2, 'access', _32 => _32.response, 'optionalAccess', _33 => _33.data, 'access', _34 => _34.message]));
5874
+ setError(_optionalChain([error2, 'access', _36 => _36.response, 'optionalAccess', _37 => _37.data, 'access', _38 => _38.message]));
5817
5875
  } finally {
5818
5876
  setSubmitting(false);
5819
5877
  }
@@ -5905,14 +5963,14 @@ function LicencaForm(props) {
5905
5963
  const [empresaId, setEmpresaId] = _react.useState.call(void 0, "");
5906
5964
  const { selecionarLicenca, isSubmitting } = _hooks.useCredentials.call(void 0, credentialsConfig);
5907
5965
  _react.useEffect.call(void 0, () => {
5908
- if (Array.isArray(_optionalChain([loginData, 'optionalAccess', _35 => _35.empresas]))) {
5909
- const empresa = _optionalChain([loginData, 'optionalAccess', _36 => _36.empresas, 'access', _37 => _37[0]]);
5910
- setEmpresaId(_optionalChain([empresa, 'optionalAccess', _38 => _38.uuid]));
5966
+ if (Array.isArray(_optionalChain([loginData, 'optionalAccess', _39 => _39.empresas]))) {
5967
+ const empresa = _optionalChain([loginData, 'optionalAccess', _40 => _40.empresas, 'access', _41 => _41[0]]);
5968
+ setEmpresaId(_optionalChain([empresa, 'optionalAccess', _42 => _42.uuid]));
5911
5969
  }
5912
5970
  }, [loginData]);
5913
5971
  async function handleSelecionarLicenca() {
5914
5972
  try {
5915
- const tokens = await selecionarLicenca(_optionalChain([loginData, 'optionalAccess', _39 => _39.token]), empresaId);
5973
+ const tokens = await selecionarLicenca(_optionalChain([loginData, 'optionalAccess', _43 => _43.token]), empresaId);
5916
5974
  if (tokens) {
5917
5975
  onLoginSuccess(tokens);
5918
5976
  } else {
@@ -5934,7 +5992,7 @@ function LicencaForm(props) {
5934
5992
  onChange: (e) => {
5935
5993
  setEmpresaId(e.target.value);
5936
5994
  },
5937
- children: _optionalChain([loginData, 'optionalAccess', _40 => _40.empresas, 'optionalAccess', _41 => _41.map, 'call', _42 => _42((empresa) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.MenuItem, { value: empresa.uuid, children: empresa.nome }, empresa.uuid))])
5995
+ children: _optionalChain([loginData, 'optionalAccess', _44 => _44.empresas, 'optionalAccess', _45 => _45.map, 'call', _46 => _46((empresa) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.MenuItem, { value: empresa.uuid, children: empresa.nome }, empresa.uuid))])
5938
5996
  }
5939
5997
  ),
5940
5998
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -6042,12 +6100,12 @@ function VerificationCodeInput({
6042
6100
  const updatedValue = nextValue.join("");
6043
6101
  onChange(updatedValue);
6044
6102
  if (cleanDigit && index < length - 1) {
6045
- _optionalChain([inputsRef, 'access', _43 => _43.current, 'access', _44 => _44[index + 1], 'optionalAccess', _45 => _45.focus, 'call', _46 => _46()]);
6103
+ _optionalChain([inputsRef, 'access', _47 => _47.current, 'access', _48 => _48[index + 1], 'optionalAccess', _49 => _49.focus, 'call', _50 => _50()]);
6046
6104
  }
6047
6105
  };
6048
6106
  const handleKeyDown = (index, event) => {
6049
6107
  if (event.key === "Backspace" && !value[index] && index > 0) {
6050
- _optionalChain([inputsRef, 'access', _47 => _47.current, 'access', _48 => _48[index - 1], 'optionalAccess', _49 => _49.focus, 'call', _50 => _50()]);
6108
+ _optionalChain([inputsRef, 'access', _51 => _51.current, 'access', _52 => _52[index - 1], 'optionalAccess', _53 => _53.focus, 'call', _54 => _54()]);
6051
6109
  }
6052
6110
  };
6053
6111
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Box, { display: "flex", gap: 1, children: Array.from({ length }).map((_, i) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -6324,10 +6382,10 @@ function LoginSection(props) {
6324
6382
  }, [isAuthenticated]);
6325
6383
  async function handleLoginSuccess(_loginData) {
6326
6384
  try {
6327
- if (Array.isArray(_optionalChain([_loginData, 'optionalAccess', _51 => _51.empresas]))) {
6328
- if (_optionalChain([_loginData, 'optionalAccess', _52 => _52.empresas, 'access', _53 => _53.length]) === 1) {
6385
+ if (Array.isArray(_optionalChain([_loginData, 'optionalAccess', _55 => _55.empresas]))) {
6386
+ if (_optionalChain([_loginData, 'optionalAccess', _56 => _56.empresas, 'access', _57 => _57.length]) === 1) {
6329
6387
  const tokens = await selecionarLicenca(
6330
- _optionalChain([_loginData, 'optionalAccess', _54 => _54.token]),
6388
+ _optionalChain([_loginData, 'optionalAccess', _58 => _58.token]),
6331
6389
  _loginData.empresas[0].uuid
6332
6390
  );
6333
6391
  if (tokens) {
@@ -7893,7 +7951,7 @@ function cloneMenuItems(childrenProp, open) {
7893
7951
  if (!_react2.default.isValidElement(child)) {
7894
7952
  return child;
7895
7953
  }
7896
- const newChildren = _optionalChain([child, 'access', _55 => _55.props, 'optionalAccess', _56 => _56.children]) ? cloneMenuItems(child.props.children, open) : null;
7954
+ const newChildren = _optionalChain([child, 'access', _59 => _59.props, 'optionalAccess', _60 => _60.children]) ? cloneMenuItems(child.props.children, open) : null;
7897
7955
  return _react2.default.cloneElement(child, {
7898
7956
  open,
7899
7957
  children: newChildren
@@ -7954,14 +8012,14 @@ function MinMenuItem(props) {
7954
8012
  children: [
7955
8013
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.ListItemIcon, { children: renderIcon(icon) }),
7956
8014
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.ListItemText, { primary: _truncate2.default.call(void 0, label, { length: 12 }) }),
7957
- _optionalChain([opened, 'optionalAccess', _57 => _57.id]) === id && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
8015
+ _optionalChain([opened, 'optionalAccess', _61 => _61.id]) === id && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
7958
8016
  _material.Popper,
7959
8017
  {
7960
8018
  sx: {
7961
8019
  zIndex: 999999
7962
8020
  },
7963
- anchorEl: _optionalChain([opened, 'optionalAccess', _58 => _58.element]),
7964
- open: Boolean(_optionalChain([opened, 'optionalAccess', _59 => _59.element])),
8021
+ anchorEl: _optionalChain([opened, 'optionalAccess', _62 => _62.element]),
8022
+ open: Boolean(_optionalChain([opened, 'optionalAccess', _63 => _63.element])),
7965
8023
  placement: "right-start",
7966
8024
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
7967
8025
  Surface,
@@ -7986,7 +8044,7 @@ function MinMenuItem(props) {
7986
8044
  transition: "transform 0.2s ease-in-out"
7987
8045
  },
7988
8046
  p: 1,
7989
- width: (theme2) => _optionalChain([theme2, 'access', _60 => _60.mixins, 'access', _61 => _61.menu, 'optionalAccess', _62 => _62.width])
8047
+ width: (theme2) => _optionalChain([theme2, 'access', _64 => _64.mixins, 'access', _65 => _65.menu, 'optionalAccess', _66 => _66.width])
7990
8048
  // borderTop: (theme) => `1px solid ${theme.palette.grey[400]}`,
7991
8049
  // borderRight: (theme) => `1px solid ${theme.palette.grey[400]}`,
7992
8050
  // borderBottom: (theme) => `1px solid ${theme.palette.grey[400]}`,
@@ -8054,7 +8112,7 @@ function useMenu() {
8054
8112
 
8055
8113
 
8056
8114
  var openedMixin = (theme2) => ({
8057
- width: _optionalChain([theme2, 'optionalAccess', _63 => _63.mixins, 'optionalAccess', _64 => _64.menu, 'optionalAccess', _65 => _65.width]) || 64,
8115
+ width: _optionalChain([theme2, 'optionalAccess', _67 => _67.mixins, 'optionalAccess', _68 => _68.menu, 'optionalAccess', _69 => _69.width]) || 64,
8058
8116
  background: "#FFFFFF",
8059
8117
  transition: theme2.transitions.create("width", {
8060
8118
  easing: theme2.transitions.easing.sharp,
@@ -8078,7 +8136,7 @@ var closedMixin = (theme2) => ({
8078
8136
  var Drawer = _styles.styled.call(void 0, _material.Drawer, {
8079
8137
  shouldForwardProp: (prop) => prop !== "open"
8080
8138
  })(({ theme: theme2, open }) => ({
8081
- width: _optionalChain([theme2, 'optionalAccess', _66 => _66.mixins, 'optionalAccess', _67 => _67.menu, 'optionalAccess', _68 => _68.width]) || 64,
8139
+ width: _optionalChain([theme2, 'optionalAccess', _70 => _70.mixins, 'optionalAccess', _71 => _71.menu, 'optionalAccess', _72 => _72.width]) || 64,
8082
8140
  // boxShadow: '2px 3px 20px -16px rgb(32 32 36 / 30%)',
8083
8141
  borderRightStyle: "none",
8084
8142
  whiteSpace: "nowrap",
@@ -8098,12 +8156,12 @@ function cloneMenuItems2(childrenProp, pathName, open, onClickItem) {
8098
8156
  if (!_react2.default.isValidElement(child)) {
8099
8157
  return child;
8100
8158
  }
8101
- const splittedLink = _optionalChain([child, 'access', _69 => _69.props, 'access', _70 => _70.link, 'optionalAccess', _71 => _71.split, 'call', _72 => _72("/"), 'access', _73 => _73.filter, 'call', _74 => _74(Boolean)]) || [];
8159
+ const splittedLink = _optionalChain([child, 'access', _73 => _73.props, 'access', _74 => _74.link, 'optionalAccess', _75 => _75.split, 'call', _76 => _76("/"), 'access', _77 => _77.filter, 'call', _78 => _78(Boolean)]) || [];
8102
8160
  const linkName = child.props.link || "";
8103
- const splittedPath = _optionalChain([pathName, 'optionalAccess', _75 => _75.split, 'call', _76 => _76("/"), 'access', _77 => _77.filter, 'call', _78 => _78(Boolean)]) || [];
8161
+ const splittedPath = _optionalChain([pathName, 'optionalAccess', _79 => _79.split, 'call', _80 => _80("/"), 'access', _81 => _81.filter, 'call', _82 => _82(Boolean)]) || [];
8104
8162
  const slicedPathName = splittedPath.slice(0, splittedLink.length);
8105
8163
  const reconstructedPath = "/" + slicedPathName.join("/");
8106
- const newChildren = _optionalChain([child, 'access', _79 => _79.props, 'optionalAccess', _80 => _80.children]) ? cloneMenuItems2(child.props.children, pathName, open, onClickItem) : null;
8164
+ const newChildren = _optionalChain([child, 'access', _83 => _83.props, 'optionalAccess', _84 => _84.children]) ? cloneMenuItems2(child.props.children, pathName, open, onClickItem) : null;
8107
8165
  return _react2.default.cloneElement(child, {
8108
8166
  open,
8109
8167
  selected: reconstructedPath === linkName,
@@ -8294,8 +8352,8 @@ function reducer(state, action) {
8294
8352
  case "loadFiltersFromStorage":
8295
8353
  return {
8296
8354
  ...state,
8297
- filterValues: _optionalChain([action, 'optionalAccess', _81 => _81.storageValues, 'optionalAccess', _82 => _82.filterValues]),
8298
- appliedValues: _optionalChain([action, 'optionalAccess', _83 => _83.storageValues, 'optionalAccess', _84 => _84.appliedValues])
8355
+ filterValues: _optionalChain([action, 'optionalAccess', _85 => _85.storageValues, 'optionalAccess', _86 => _86.filterValues]),
8356
+ appliedValues: _optionalChain([action, 'optionalAccess', _87 => _87.storageValues, 'optionalAccess', _88 => _88.appliedValues])
8299
8357
  };
8300
8358
  case "updateFilterValues":
8301
8359
  return { ...state, filterValues: action.filterValues };
@@ -8314,7 +8372,7 @@ function reducer(state, action) {
8314
8372
  const [key2] = Object.keys(filters);
8315
8373
  asArray = [{ [key2]: filters[key2] }];
8316
8374
  }
8317
- if (_optionalChain([action, 'optionalAccess', _85 => _85.storagePath])) {
8375
+ if (_optionalChain([action, 'optionalAccess', _89 => _89.storagePath])) {
8318
8376
  localStorage.setItem(
8319
8377
  action.storagePath,
8320
8378
  JSON.stringify({
@@ -8343,7 +8401,7 @@ function reducer(state, action) {
8343
8401
  case "deleteAppliedValue":
8344
8402
  const { [action.filterName]: _, ...rest } = state.appliedValues || {};
8345
8403
  const { [action.filterName]: __, ...restFilterValues } = state.filterValues || {};
8346
- if (_optionalChain([action, 'optionalAccess', _86 => _86.storagePath])) {
8404
+ if (_optionalChain([action, 'optionalAccess', _90 => _90.storagePath])) {
8347
8405
  const storage = JSON.parse(
8348
8406
  localStorage.getItem(action.storagePath) || "{}"
8349
8407
  );
@@ -8404,7 +8462,7 @@ function FilterProvider(props) {
8404
8462
  dispatch({
8405
8463
  type: "updateIsOpen",
8406
8464
  isOpen: true,
8407
- target: _optionalChain([event, 'optionalAccess', _87 => _87.target]) || void 0
8465
+ target: _optionalChain([event, 'optionalAccess', _91 => _91.target]) || void 0
8408
8466
  });
8409
8467
  }
8410
8468
  function closeFilter() {
@@ -8639,7 +8697,7 @@ function FilterChips({
8639
8697
  },
8640
8698
  children: [
8641
8699
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Box, { pt: 2, pl: 1, pr: 1, pb: 2, children: _react2.default.Children.map(childrenProp, (child) => {
8642
- if (_react2.default.isValidElement(child) && child.props.name === _optionalChain([popoverData, 'optionalAccess', _88 => _88.name])) {
8700
+ if (_react2.default.isValidElement(child) && child.props.name === _optionalChain([popoverData, 'optionalAccess', _92 => _92.name])) {
8643
8701
  return child.props.children;
8644
8702
  }
8645
8703
  return null;
@@ -8656,13 +8714,13 @@ function FilterChips({
8656
8714
  justifyContent: "flex-end",
8657
8715
  spacing: 1,
8658
8716
  children: [
8659
- !_optionalChain([popoverData, 'optionalAccess', _89 => _89.disabledDelete]) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
8717
+ !_optionalChain([popoverData, 'optionalAccess', _93 => _93.disabledDelete]) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
8660
8718
  _material.Button,
8661
8719
  {
8662
8720
  color: "error",
8663
8721
  onClick: () => {
8664
8722
  if (deleteFilterValue)
8665
- deleteFilterValue(_optionalChain([popoverData, 'optionalAccess', _90 => _90.name]) || "");
8723
+ deleteFilterValue(_optionalChain([popoverData, 'optionalAccess', _94 => _94.name]) || "");
8666
8724
  close();
8667
8725
  },
8668
8726
  children: "Apagar"
@@ -8997,8 +9055,8 @@ function Table(props) {
8997
9055
  ...col,
8998
9056
  flex: col.flex || 1,
8999
9057
  minWidth: col.minWidth || 100,
9000
- headerClassName: _optionalChain([col, 'optionalAccess', _91 => _91.enableStickyColumns]) ? "sticky-header" : "",
9001
- cellClassName: _optionalChain([col, 'optionalAccess', _92 => _92.enableStickyColumns]) ? "sticky-cell" : ""
9058
+ headerClassName: _optionalChain([col, 'optionalAccess', _95 => _95.enableStickyColumns]) ? "sticky-header" : "",
9059
+ cellClassName: _optionalChain([col, 'optionalAccess', _96 => _96.enableStickyColumns]) ? "sticky-cell" : ""
9002
9060
  };
9003
9061
  });
9004
9062
  };
@@ -9038,7 +9096,7 @@ function Table(props) {
9038
9096
  case "ctrl+e":
9039
9097
  event.preventDefault();
9040
9098
  const handleExport = (options) => {
9041
- if (_optionalChain([apiRef, 'optionalAccess', _93 => _93.current])) {
9099
+ if (_optionalChain([apiRef, 'optionalAccess', _97 => _97.current])) {
9042
9100
  apiRef.current.exportDataAsCsv(options);
9043
9101
  }
9044
9102
  };
@@ -9464,7 +9522,7 @@ var getFilteredRows2 = ({ apiRef }) => _xdatagrid.gridFilteredSortedRowIdsSelect
9464
9522
  function ExportCsvButton() {
9465
9523
  const { apiRef } = useTableRootContext();
9466
9524
  const handleExport = (options) => {
9467
- if (_optionalChain([apiRef, 'optionalAccess', _94 => _94.current])) {
9525
+ if (_optionalChain([apiRef, 'optionalAccess', _98 => _98.current])) {
9468
9526
  apiRef.current.exportDataAsCsv(options);
9469
9527
  }
9470
9528
  };
@@ -9523,7 +9581,7 @@ function Pagination(props) {
9523
9581
  } = props;
9524
9582
  const { page, pageSize = 15, totalRecords } = pagination || {};
9525
9583
  const pages = _react.useMemo.call(void 0, () => {
9526
- if (_optionalChain([pagination, 'optionalAccess', _95 => _95.lastPage]))
9584
+ if (_optionalChain([pagination, 'optionalAccess', _99 => _99.lastPage]))
9527
9585
  return pagination.lastPage;
9528
9586
  if ((totalRecords || 0) < pageSize)
9529
9587
  return 1;
@@ -9655,7 +9713,7 @@ function Root({ children, height, ...rest }) {
9655
9713
  function SelectionCounter(props) {
9656
9714
  const { countTitle, gender } = props;
9657
9715
  const { rowsSelectedId } = useTableRootContext();
9658
- const countQuantidade = _optionalChain([rowsSelectedId, 'optionalAccess', _96 => _96.ids, 'access', _97 => _97.size]) || 0;
9716
+ const countQuantidade = _optionalChain([rowsSelectedId, 'optionalAccess', _100 => _100.ids, 'access', _101 => _101.size]) || 0;
9659
9717
  const flexSufixCountTitle = _react.useMemo.call(void 0, () => {
9660
9718
  if (!countTitle)
9661
9719
  return "";
@@ -9810,12 +9868,12 @@ var PopoverProvider = ({
9810
9868
  const open = _react.useCallback.call(void 0, (anchor) => {
9811
9869
  setAnchorEl(anchor);
9812
9870
  setIsOpen(true);
9813
- _optionalChain([onOpenChange, 'optionalCall', _98 => _98(true)]);
9871
+ _optionalChain([onOpenChange, 'optionalCall', _102 => _102(true)]);
9814
9872
  }, []);
9815
9873
  const close = _react.useCallback.call(void 0, () => {
9816
9874
  setIsOpen(false);
9817
9875
  setAnchorEl(null);
9818
- _optionalChain([onOpenChange, 'optionalCall', _99 => _99(false)]);
9876
+ _optionalChain([onOpenChange, 'optionalCall', _103 => _103(false)]);
9819
9877
  }, []);
9820
9878
  _react.useEffect.call(void 0, () => {
9821
9879
  setIsOpen(Boolean(_open));
@@ -9957,12 +10015,12 @@ function ButtonGroupRoot(props) {
9957
10015
  const children = _react.Children.map(childrenProp, (child, index) => {
9958
10016
  options.push({
9959
10017
  label: child.props.children,
9960
- value: _optionalChain([child, 'access', _100 => _100.props, 'optionalAccess', _101 => _101.value]) || index
10018
+ value: _optionalChain([child, 'access', _104 => _104.props, 'optionalAccess', _105 => _105.value]) || index
9961
10019
  });
9962
10020
  const clonedChild = _react2.default.cloneElement(child, {
9963
10021
  isLoading,
9964
10022
  sx: { maxWidth: "300px", width: "120px" },
9965
- value: _optionalChain([child, 'access', _102 => _102.props, 'optionalAccess', _103 => _103.value]) || index
10023
+ value: _optionalChain([child, 'access', _106 => _106.props, 'optionalAccess', _107 => _107.value]) || index
9966
10024
  });
9967
10025
  if (!Boolean(value) && index === 0)
9968
10026
  return clonedChild;
@@ -10295,7 +10353,7 @@ function Autocomplete(props) {
10295
10353
  function resetEndAdornment(endAdornment, isLoading2 = false, disabled2 = false) {
10296
10354
  if (endAdornment) {
10297
10355
  const children = _react2.default.Children.toArray(
10298
- _optionalChain([endAdornment, 'access', _104 => _104.props, 'optionalAccess', _105 => _105.children])
10356
+ _optionalChain([endAdornment, 'access', _108 => _108.props, 'optionalAccess', _109 => _109.children])
10299
10357
  );
10300
10358
  const pos = children.length === 1 ? 0 : 1;
10301
10359
  children.splice(
@@ -10370,7 +10428,10 @@ function Autocomplete(props) {
10370
10428
  inputLabel: { shrink: true },
10371
10429
  input: {
10372
10430
  ...params.InputProps,
10373
- startAdornment: _endAdornment
10431
+ startAdornment: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
10432
+ _endAdornment,
10433
+ params.InputProps.startAdornment
10434
+ ] })
10374
10435
  }
10375
10436
  },
10376
10437
  ...params,
@@ -10427,7 +10488,7 @@ function createTransporterScope(id) {
10427
10488
  }
10428
10489
  const current = get().value;
10429
10490
  const exists = current.find(
10430
- (item) => _optionalChain([item, 'optionalAccess', _106 => _106.id]) === result.id
10491
+ (item) => _optionalChain([item, 'optionalAccess', _110 => _110.id]) === result.id
10431
10492
  );
10432
10493
  const updated = exists ? current.filter((item) => item !== result) : [...current, result];
10433
10494
  get().triggerOnChange(updated);
@@ -10439,7 +10500,7 @@ function createTransporterScope(id) {
10439
10500
  onChange: void 0,
10440
10501
  setOnChange: (fn) => set({ onChange: fn }),
10441
10502
  triggerOnChange: (item) => {
10442
- _optionalChain([get, 'call', _107 => _107(), 'access', _108 => _108.onChange, 'optionalCall', _109 => _109(item)]);
10503
+ _optionalChain([get, 'call', _111 => _111(), 'access', _112 => _112.onChange, 'optionalCall', _113 => _113(item)]);
10443
10504
  }
10444
10505
  }));
10445
10506
  transporterStores.set(id, store);
@@ -10495,13 +10556,15 @@ function TransporterContainer(props) {
10495
10556
  function TransporterRoot(props) {
10496
10557
  const { scope, onChange, value, children } = props;
10497
10558
  const store = createTransporterScope(scope);
10498
- store.getState().setValue(value);
10559
+ _react.useEffect.call(void 0, () => {
10560
+ store.getState().setValue(value);
10561
+ }, [value, store]);
10499
10562
  _react.useEffect.call(void 0, () => {
10500
10563
  store.getState().setOnChange(onChange);
10501
10564
  return () => {
10502
10565
  store.getState().setOnChange(void 0);
10503
10566
  };
10504
- }, [scope, onChange]);
10567
+ }, [scope, onChange, store]);
10505
10568
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TransporterScopeProvider, { value: scope, children });
10506
10569
  }
10507
10570
 
@@ -10549,7 +10612,7 @@ function TextField12(props) {
10549
10612
  {
10550
10613
  ...props,
10551
10614
  slotProps: {
10552
- input: { readOnly: props.readonly, ..._optionalChain([props, 'access', _110 => _110.slotProps, 'optionalAccess', _111 => _111.input]) },
10615
+ input: { readOnly: props.readonly, ..._optionalChain([props, 'access', _114 => _114.slotProps, 'optionalAccess', _115 => _115.input]) },
10553
10616
  ...props.slotProps
10554
10617
  }
10555
10618
  }
@@ -10633,7 +10696,7 @@ function DocumentoTextField(props) {
10633
10696
  slotProps: {
10634
10697
  htmlInput: {
10635
10698
  maxLength: maxLen,
10636
- ..._optionalChain([slotProps, 'optionalAccess', _112 => _112.htmlInput])
10699
+ ..._optionalChain([slotProps, 'optionalAccess', _116 => _116.htmlInput])
10637
10700
  },
10638
10701
  ...slotProps
10639
10702
  // Allow additional slotProps to be passed
@@ -10681,7 +10744,7 @@ function CEPTextField(props) {
10681
10744
  slotProps: {
10682
10745
  htmlInput: {
10683
10746
  maxLength: 9,
10684
- ..._optionalChain([slotProps, 'optionalAccess', _113 => _113.htmlInput])
10747
+ ..._optionalChain([slotProps, 'optionalAccess', _117 => _117.htmlInput])
10685
10748
  },
10686
10749
  ...slotProps
10687
10750
  // Allow additional slotProps to be passed
@@ -10848,7 +10911,7 @@ function NotaVersaoItem(props) {
10848
10911
  "div",
10849
10912
  {
10850
10913
  dangerouslySetInnerHTML: {
10851
- __html: _optionalChain([article, 'optionalAccess', _114 => _114.body, 'optionalAccess', _115 => _115.replace, 'call', _116 => _116('width="560"', 'width="412px"'), 'access', _117 => _117.replace, 'call', _118 => _118('height="315"', 'height="240px"'), 'access', _119 => _119.replace, 'call', _120 => _120("h2", "h3")]) || ""
10914
+ __html: _optionalChain([article, 'optionalAccess', _118 => _118.body, 'optionalAccess', _119 => _119.replace, 'call', _120 => _120('width="560"', 'width="412px"'), 'access', _121 => _121.replace, 'call', _122 => _122('height="315"', 'height="240px"'), 'access', _123 => _123.replace, 'call', _124 => _124("h2", "h3")]) || ""
10852
10915
  }
10853
10916
  }
10854
10917
  ) })
@@ -10965,7 +11028,7 @@ function NotaVersao(props) {
10965
11028
  ") est\xE1 dispon\xEDvel!"
10966
11029
  ] }),
10967
11030
  error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Alert, { severity: "error", children: "N\xE3o foi poss\xEDvel carregar o conte\xFAdo" }),
10968
- _optionalChain([articles, 'optionalAccess', _121 => _121.map, 'call', _122 => _122((a, index) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, NotaVersaoItem, { isOpen: index === 0, article: a }, a.id))])
11031
+ _optionalChain([articles, 'optionalAccess', _125 => _125.map, 'call', _126 => _126((a, index) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, NotaVersaoItem, { isOpen: index === 0, article: a }, a.id))])
10969
11032
  ] })
10970
11033
  ]
10971
11034
  }
@@ -10982,8 +11045,8 @@ var _luxon = require('luxon');
10982
11045
  function DatePicker(props) {
10983
11046
  const { value, error, onChange, fromFormat, format: format2, ...rest } = props;
10984
11047
  function handleChange(date2) {
10985
- if (_optionalChain([date2, 'optionalAccess', _123 => _123.isValid])) {
10986
- onChange(_optionalChain([date2, 'optionalAccess', _124 => _124.toFormat, 'call', _125 => _125("yyyy-MM-dd")]));
11048
+ if (_optionalChain([date2, 'optionalAccess', _127 => _127.isValid])) {
11049
+ onChange(_optionalChain([date2, 'optionalAccess', _128 => _128.toFormat, 'call', _129 => _129("yyyy-MM-dd")]));
10987
11050
  return;
10988
11051
  }
10989
11052
  if (date2 === null) {
@@ -11231,14 +11294,14 @@ function DateRangePicker(props) {
11231
11294
  value: dates.tipo,
11232
11295
  onChange: (e) => {
11233
11296
  const _periodo = e.target.value;
11234
- definirPeriodo(_periodo, _optionalChain([dates, 'optionalAccess', _126 => _126.firstDate]) || null);
11297
+ definirPeriodo(_periodo, _optionalChain([dates, 'optionalAccess', _130 => _130.firstDate]) || null);
11235
11298
  },
11236
11299
  select: true,
11237
11300
  fullWidth: true,
11238
11301
  size: "small",
11239
11302
  variant: "outlined",
11240
11303
  InputProps: {
11241
- startAdornment: _optionalChain([dates, 'optionalAccess', _127 => _127.tipo]) !== "livre" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.InputAdornment, { position: "start", children: [
11304
+ startAdornment: _optionalChain([dates, 'optionalAccess', _131 => _131.tipo]) !== "livre" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.InputAdornment, { position: "start", children: [
11242
11305
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.IconButton, { size: "small", onClick: handleBackToPrevious, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _xdatepickers.ArrowLeftIcon, { fontSize: "small" }) }),
11243
11306
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.IconButton, { size: "small", onClick: handleGoToNext, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _xdatepickers.ArrowRightIcon, { fontSize: "small" }) })
11244
11307
  ] })
@@ -11264,7 +11327,7 @@ function DateRangePicker(props) {
11264
11327
  slots: dates.tipo === "week" ? { day: Day } : void 0,
11265
11328
  slotProps: dates.tipo === "week" ? {
11266
11329
  day: (ownerState) => ({
11267
- selectedDay: _optionalChain([dates, 'optionalAccess', _128 => _128.firstDate]) ? _luxon.DateTime.fromFormat(
11330
+ selectedDay: _optionalChain([dates, 'optionalAccess', _132 => _132.firstDate]) ? _luxon.DateTime.fromFormat(
11268
11331
  dates.firstDate,
11269
11332
  "yyyy-MM-dd"
11270
11333
  ).startOf("week") : _luxon.DateTime.now(),
@@ -11279,8 +11342,8 @@ function DateRangePicker(props) {
11279
11342
  dates.tipo !== "day" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11280
11343
  DatePicker,
11281
11344
  {
11282
- disabled: dates.tipo !== "livre" || !Boolean(_optionalChain([dates, 'optionalAccess', _129 => _129.firstDate])),
11283
- minDate: _optionalChain([dates, 'optionalAccess', _130 => _130.firstDate]) ? _luxon.DateTime.fromFormat(dates.firstDate, "yyyy-MM-dd") : void 0,
11345
+ disabled: dates.tipo !== "livre" || !Boolean(_optionalChain([dates, 'optionalAccess', _133 => _133.firstDate])),
11346
+ minDate: _optionalChain([dates, 'optionalAccess', _134 => _134.firstDate]) ? _luxon.DateTime.fromFormat(dates.firstDate, "yyyy-MM-dd") : void 0,
11284
11347
  showDaysOutsideCurrentMonth: true,
11285
11348
  label: "Fim",
11286
11349
  onChange: handleChangeSecondDate,
@@ -11300,14 +11363,14 @@ function DateRangePicker(props) {
11300
11363
  value: dates.tipo,
11301
11364
  onChange: (e) => {
11302
11365
  const _periodo = e.target.value;
11303
- definirPeriodo(_periodo, _optionalChain([dates, 'optionalAccess', _131 => _131.firstDate]) || null);
11366
+ definirPeriodo(_periodo, _optionalChain([dates, 'optionalAccess', _135 => _135.firstDate]) || null);
11304
11367
  },
11305
11368
  select: true,
11306
11369
  fullWidth: true,
11307
11370
  size: "small",
11308
11371
  variant: "outlined",
11309
11372
  InputProps: {
11310
- startAdornment: _optionalChain([dates, 'optionalAccess', _132 => _132.tipo]) !== "livre" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.InputAdornment, { position: "start", children: [
11373
+ startAdornment: _optionalChain([dates, 'optionalAccess', _136 => _136.tipo]) !== "livre" && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.InputAdornment, { position: "start", children: [
11311
11374
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.IconButton, { size: "small", onClick: handleBackToPrevious, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _xdatepickers.ArrowLeftIcon, { fontSize: "small" }) }),
11312
11375
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.IconButton, { size: "small", onClick: handleGoToNext, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _xdatepickers.ArrowRightIcon, { fontSize: "small" }) })
11313
11376
  ] })
@@ -11333,7 +11396,7 @@ function DateRangePicker(props) {
11333
11396
  slots: dates.tipo === "week" ? { day: Day } : void 0,
11334
11397
  slotProps: dates.tipo === "week" ? {
11335
11398
  day: (ownerState) => ({
11336
- selectedDay: _optionalChain([dates, 'optionalAccess', _133 => _133.firstDate]) ? _luxon.DateTime.fromFormat(
11399
+ selectedDay: _optionalChain([dates, 'optionalAccess', _137 => _137.firstDate]) ? _luxon.DateTime.fromFormat(
11337
11400
  dates.firstDate,
11338
11401
  "yyyy-MM-dd"
11339
11402
  ).startOf("week") : _luxon.DateTime.now(),
@@ -11348,8 +11411,8 @@ function DateRangePicker(props) {
11348
11411
  dates.tipo !== "day" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11349
11412
  DatePicker,
11350
11413
  {
11351
- disabled: dates.tipo !== "livre" || !Boolean(_optionalChain([dates, 'optionalAccess', _134 => _134.firstDate])),
11352
- minDate: _optionalChain([dates, 'optionalAccess', _135 => _135.firstDate]) ? _luxon.DateTime.fromFormat(dates.firstDate, "yyyy-MM-dd") : void 0,
11414
+ disabled: dates.tipo !== "livre" || !Boolean(_optionalChain([dates, 'optionalAccess', _138 => _138.firstDate])),
11415
+ minDate: _optionalChain([dates, 'optionalAccess', _139 => _139.firstDate]) ? _luxon.DateTime.fromFormat(dates.firstDate, "yyyy-MM-dd") : void 0,
11353
11416
  showDaysOutsideCurrentMonth: true,
11354
11417
  label: "Fim",
11355
11418
  onChange: (date2) => {
@@ -11582,7 +11645,7 @@ function FullMenuItem2(props) {
11582
11645
  if (!menuItem.visible)
11583
11646
  return null;
11584
11647
  const isExpandable = Boolean(
11585
- _optionalChain([menuItem, 'optionalAccess', _136 => _136.items]) && _optionalChain([menuItem, 'optionalAccess', _137 => _137.items, 'access', _138 => _138.length]) > 0
11648
+ _optionalChain([menuItem, 'optionalAccess', _140 => _140.items]) && _optionalChain([menuItem, 'optionalAccess', _141 => _141.items, 'access', _142 => _142.length]) > 0
11586
11649
  );
11587
11650
  function toggleExpand() {
11588
11651
  setExpanded(!expanded);
@@ -11592,7 +11655,7 @@ function FullMenuItem2(props) {
11592
11655
  MenuItem_default,
11593
11656
  {
11594
11657
  onClick: () => {
11595
- if (_optionalChain([menuItem, 'optionalAccess', _139 => _139.link])) {
11658
+ if (_optionalChain([menuItem, 'optionalAccess', _143 => _143.link])) {
11596
11659
  onMenuClick(menuItem.link);
11597
11660
  return;
11598
11661
  }
@@ -11607,14 +11670,14 @@ function FullMenuItem2(props) {
11607
11670
  ]
11608
11671
  }
11609
11672
  ),
11610
- _optionalChain([menuItem, 'optionalAccess', _140 => _140.items]) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Collapse, { in: expanded, timeout: "auto", unmountOnExit: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11673
+ _optionalChain([menuItem, 'optionalAccess', _144 => _144.items]) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Collapse, { in: expanded, timeout: "auto", unmountOnExit: true, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11611
11674
  FullMenu,
11612
11675
  {
11613
11676
  activeMenu,
11614
11677
  sx: {
11615
11678
  pl: (theme2) => theme2.spacing(1.5)
11616
11679
  },
11617
- menus: _optionalChain([menuItem, 'optionalAccess', _141 => _141.items]) || [],
11680
+ menus: _optionalChain([menuItem, 'optionalAccess', _145 => _145.items]) || [],
11618
11681
  onMenuClick
11619
11682
  }
11620
11683
  ) })
@@ -11662,38 +11725,38 @@ function MinMenu(props) {
11662
11725
  MenuItem_default,
11663
11726
  {
11664
11727
  onMouseEnter: (e) => {
11665
- if (!_optionalChain([menuItem, 'optionalAccess', _142 => _142.link])) {
11728
+ if (!_optionalChain([menuItem, 'optionalAccess', _146 => _146.link])) {
11666
11729
  handleOpen(e, menuItem.id, menuItem.items);
11667
11730
  }
11668
11731
  },
11669
11732
  onMouseLeave: () => {
11670
- if (!_optionalChain([menuItem, 'optionalAccess', _143 => _143.link])) {
11733
+ if (!_optionalChain([menuItem, 'optionalAccess', _147 => _147.link])) {
11671
11734
  handleClose();
11672
11735
  }
11673
11736
  },
11674
11737
  onClick: () => {
11675
- if (_optionalChain([menuItem, 'optionalAccess', _144 => _144.link])) {
11738
+ if (_optionalChain([menuItem, 'optionalAccess', _148 => _148.link])) {
11676
11739
  onMenuClick(menuItem.link);
11677
11740
  }
11678
11741
  },
11679
11742
  selected: activeMenu === menuItem.link,
11680
11743
  children: [
11681
11744
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.ListItemIcon, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Icon, { children: menuItem.icon }) }),
11682
- _optionalChain([opened, 'optionalAccess', _145 => _145.id]) === menuItem.id && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11745
+ _optionalChain([opened, 'optionalAccess', _149 => _149.id]) === menuItem.id && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11683
11746
  _material.Popper,
11684
11747
  {
11685
11748
  sx: {
11686
11749
  zIndex: 999999
11687
11750
  },
11688
- anchorEl: _optionalChain([opened, 'optionalAccess', _146 => _146.element]),
11689
- open: Boolean(_optionalChain([opened, 'optionalAccess', _147 => _147.element])),
11751
+ anchorEl: _optionalChain([opened, 'optionalAccess', _150 => _150.element]),
11752
+ open: Boolean(_optionalChain([opened, 'optionalAccess', _151 => _151.element])),
11690
11753
  placement: "right-start",
11691
11754
  children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11692
11755
  FullMenu,
11693
11756
  {
11694
11757
  activeMenu,
11695
11758
  onMenuClick,
11696
- menus: _optionalChain([menuItem, 'optionalAccess', _148 => _148.items]) || [],
11759
+ menus: _optionalChain([menuItem, 'optionalAccess', _152 => _152.items]) || [],
11697
11760
  sx: {
11698
11761
  minWidth: "240px",
11699
11762
  backgroundColor: theme_default.palette.background.paper,
@@ -11810,7 +11873,7 @@ function Avatar(props) {
11810
11873
  return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
11811
11874
  _Avatar2.default,
11812
11875
  {
11813
- src: _optionalChain([user, 'optionalAccess', _149 => _149.avatarUrl]),
11876
+ src: _optionalChain([user, 'optionalAccess', _153 => _153.avatarUrl]),
11814
11877
  sx: { width: 64, height: 64, margin: "auto", mb: 2 },
11815
11878
  ...props
11816
11879
  }
@@ -11921,7 +11984,7 @@ var AvatarUploader = ({ onSave, src }) => {
11921
11984
  }
11922
11985
  };
11923
11986
  const handleFileChange = (event) => {
11924
- const file = _optionalChain([event, 'access', _150 => _150.target, 'access', _151 => _151.files, 'optionalAccess', _152 => _152[0]]);
11987
+ const file = _optionalChain([event, 'access', _154 => _154.target, 'access', _155 => _155.files, 'optionalAccess', _156 => _156[0]]);
11925
11988
  if (!file)
11926
11989
  return;
11927
11990
  const reader = new FileReader();
@@ -12050,7 +12113,7 @@ function MinhaConta(props) {
12050
12113
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
12051
12114
  AvatarUploader_default,
12052
12115
  {
12053
- src: _optionalChain([data, 'optionalAccess', _153 => _153.avatarUrl]),
12116
+ src: _optionalChain([data, 'optionalAccess', _157 => _157.avatarUrl]),
12054
12117
  onSave: (croppedImage) => {
12055
12118
  try {
12056
12119
  uploadAvatar(croppedImage);
@@ -12076,7 +12139,7 @@ function MinhaConta(props) {
12076
12139
  disabled: true,
12077
12140
  fullWidth: true,
12078
12141
  label: "E-mail",
12079
- value: _optionalChain([data, 'optionalAccess', _154 => _154.email]) || ""
12142
+ value: _optionalChain([data, 'optionalAccess', _158 => _158.email]) || ""
12080
12143
  }
12081
12144
  ) }),
12082
12145
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Grid, { size: { xl: 4, lg: 4, md: 4, sm: 12, xs: 12 }, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
@@ -12085,7 +12148,7 @@ function MinhaConta(props) {
12085
12148
  name: "name",
12086
12149
  fullWidth: true,
12087
12150
  label: "Nome",
12088
- value: _optionalChain([data, 'optionalAccess', _155 => _155.name]) || "",
12151
+ value: _optionalChain([data, 'optionalAccess', _159 => _159.name]) || "",
12089
12152
  onChange: handleChange,
12090
12153
  ...validationErrors("name")
12091
12154
  }
@@ -12096,7 +12159,7 @@ function MinhaConta(props) {
12096
12159
  name: "surname",
12097
12160
  fullWidth: true,
12098
12161
  label: "Sobrenome",
12099
- value: _optionalChain([data, 'optionalAccess', _156 => _156.surname]) || "",
12162
+ value: _optionalChain([data, 'optionalAccess', _160 => _160.surname]) || "",
12100
12163
  onChange: handleChange
12101
12164
  }
12102
12165
  ) })
@@ -12179,7 +12242,7 @@ function DialogVerificarWhastapp(props) {
12179
12242
  /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.Typography, { variant: "body1", sx: { fontSize: "10pt" }, children: [
12180
12243
  "Enviamos um c\xF3digo via WhatsApp para +55",
12181
12244
  " ",
12182
- /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "b", { children: `(${_optionalChain([payload, 'optionalAccess', _157 => _157.whatsappNumber, 'optionalAccess', _158 => _158.slice, 'call', _159 => _159(0, 2)])}) ${_optionalChain([payload, 'optionalAccess', _160 => _160.whatsappNumber, 'optionalAccess', _161 => _161.slice, 'call', _162 => _162(2, 7)])}-${_optionalChain([payload, 'optionalAccess', _163 => _163.whatsappNumber, 'optionalAccess', _164 => _164.slice, 'call', _165 => _165(7)])}` }),
12245
+ /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "b", { children: `(${_optionalChain([payload, 'optionalAccess', _161 => _161.whatsappNumber, 'optionalAccess', _162 => _162.slice, 'call', _163 => _163(0, 2)])}) ${_optionalChain([payload, 'optionalAccess', _164 => _164.whatsappNumber, 'optionalAccess', _165 => _165.slice, 'call', _166 => _166(2, 7)])}-${_optionalChain([payload, 'optionalAccess', _167 => _167.whatsappNumber, 'optionalAccess', _168 => _168.slice, 'call', _169 => _169(7)])}` }),
12183
12246
  ". ",
12184
12247
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "br", {}),
12185
12248
  "Digite o c\xF3digo abaixo para confirmar que este n\xFAmero \xE9 seu."
@@ -12279,7 +12342,7 @@ function LoginSeguranca(props) {
12279
12342
  /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
12280
12343
  WhatsAppTextField,
12281
12344
  {
12282
- disabled: Boolean(_optionalChain([data, 'optionalAccess', _166 => _166.whatsappVerifiedAt])),
12345
+ disabled: Boolean(_optionalChain([data, 'optionalAccess', _170 => _170.whatsappVerifiedAt])),
12283
12346
  fullWidth: false,
12284
12347
  name: "whatsappNumber",
12285
12348
  label: "Whastapp",