componentes-sinco 1.1.13 → 1.1.15-rc.2
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.cjs +44 -76
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -3
- package/dist/index.d.ts +5 -3
- package/dist/index.js +48 -80
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
package/dist/index.cjs
CHANGED
|
@@ -2338,7 +2338,8 @@ var DrawerHeader = ({
|
|
|
2338
2338
|
title,
|
|
2339
2339
|
colorTitle,
|
|
2340
2340
|
onClose,
|
|
2341
|
-
anchor
|
|
2341
|
+
anchor,
|
|
2342
|
+
filterSideCard
|
|
2342
2343
|
}) => {
|
|
2343
2344
|
return /* @__PURE__ */ import_react19.default.createElement(
|
|
2344
2345
|
import_Grid3.default,
|
|
@@ -2356,7 +2357,7 @@ var DrawerHeader = ({
|
|
|
2356
2357
|
}
|
|
2357
2358
|
},
|
|
2358
2359
|
/* @__PURE__ */ import_react19.default.createElement(import_material13.Typography, { variant: "h6", color: colorTitle || "text.primary" }, title != null ? title : "Personaliza tu b\xFAsqueda"),
|
|
2359
|
-
/* @__PURE__ */ import_react19.default.createElement(import_material13.IconButton, { onClick: onClose }, /* @__PURE__ */ import_react19.default.createElement(import_Close.default, { "data-testid": "test-button-close", sx: { color: "text.primary" } }))
|
|
2360
|
+
filterSideCard ? /* @__PURE__ */ import_react19.default.createElement(import_react19.default.Fragment, null, filterSideCard) : /* @__PURE__ */ import_react19.default.createElement(import_material13.IconButton, { onClick: onClose }, /* @__PURE__ */ import_react19.default.createElement(import_Close.default, { "data-testid": "test-button-close", sx: { color: "text.primary" } }))
|
|
2360
2361
|
);
|
|
2361
2362
|
};
|
|
2362
2363
|
|
|
@@ -2372,7 +2373,8 @@ function SCDrawer({
|
|
|
2372
2373
|
open,
|
|
2373
2374
|
setOpen,
|
|
2374
2375
|
chipFilters,
|
|
2375
|
-
heightDrawer = 456
|
|
2376
|
+
heightDrawer = 456,
|
|
2377
|
+
filterSideCard
|
|
2376
2378
|
}) {
|
|
2377
2379
|
const drawerBleeding = heightDrawer;
|
|
2378
2380
|
const { drawerOpen, handleDrawerClose, toggleDrawer } = useDrawerState({ open, setOpen });
|
|
@@ -2441,7 +2443,7 @@ function SCDrawer({
|
|
|
2441
2443
|
import_material14.Drawer,
|
|
2442
2444
|
{
|
|
2443
2445
|
open: drawerOpen,
|
|
2444
|
-
onClose: toggleDrawer(false),
|
|
2446
|
+
onClose: filterSideCard ? void 0 : toggleDrawer(false),
|
|
2445
2447
|
anchor: anchor != null ? anchor : "left",
|
|
2446
2448
|
sx: {
|
|
2447
2449
|
"& .MuiDrawer-paper": {
|
|
@@ -2456,7 +2458,9 @@ function SCDrawer({
|
|
|
2456
2458
|
{
|
|
2457
2459
|
title,
|
|
2458
2460
|
colorTitle,
|
|
2459
|
-
onClose: handleDrawerClose
|
|
2461
|
+
onClose: handleDrawerClose,
|
|
2462
|
+
anchor,
|
|
2463
|
+
filterSideCard
|
|
2460
2464
|
}
|
|
2461
2465
|
), /* @__PURE__ */ import_react20.default.createElement(DrawerContent, { arrayElements }), /* @__PURE__ */ import_react20.default.createElement(DrawerActions, { actions: drawerActions, anchor }))
|
|
2462
2466
|
) : /* @__PURE__ */ import_react20.default.createElement(
|
|
@@ -2885,7 +2889,7 @@ var import_x_license2 = require("@mui/x-license");
|
|
|
2885
2889
|
var import_KeyboardArrowDown = __toESM(require("@mui/icons-material/KeyboardArrowDown"), 1);
|
|
2886
2890
|
var import_KeyboardArrowUp = __toESM(require("@mui/icons-material/KeyboardArrowUp"), 1);
|
|
2887
2891
|
var import_styles = require("@mui/material/styles");
|
|
2888
|
-
function SCDataGridInitial({ data, columns, getRowId, groupColumns, rowsTable, checkboxSelection, width, maxHeight,
|
|
2892
|
+
function SCDataGridInitial({ data, columns, getRowId, groupColumns, rowsTable, checkboxSelection, width, maxHeight, disableColumnMenu, disableColumnSorting }) {
|
|
2889
2893
|
import_x_license2.LicenseInfo.setLicenseKey(
|
|
2890
2894
|
"77d49a57fbc5f4af35ddb05c5f1742e0Tz0xMTI3MjgsRT0xNzc4MzcxMTk5MDAwLFM9cHJvLExNPXN1YnNjcmlwdGlvbixQVj1RMy0yMDI0LEtWPTI="
|
|
2891
2895
|
);
|
|
@@ -3036,11 +3040,12 @@ function SCDataGridInitial({ data, columns, getRowId, groupColumns, rowsTable, c
|
|
|
3036
3040
|
}
|
|
3037
3041
|
}
|
|
3038
3042
|
};
|
|
3043
|
+
let densityC = "compact";
|
|
3039
3044
|
let validationTreeData = groupColumns ? true : false;
|
|
3040
3045
|
let validationCheckboxSelection = checkboxSelection || false;
|
|
3041
|
-
let styleDensity =
|
|
3046
|
+
let styleDensity = densityC || "compact";
|
|
3042
3047
|
let styleTopContainerHeight = styleDensity === "compact" ? "26px" : styleDensity === "standard" ? "38px" : styleDensity === "comfortable" ? "60px" : "27px";
|
|
3043
|
-
let styleRowHeight =
|
|
3048
|
+
let styleRowHeight = densityC == "compact" ? 32 : densityC == "standard" ? 28 : densityC == "comfortable" ? 36 : 32;
|
|
3044
3049
|
let rows = rowsTable ? rowsTable : validationTreeData != false ? parseInt(data.length.toString()) : data.length < 10 ? parseInt(data.length.toString()) : 10;
|
|
3045
3050
|
let validationGroupingColDef = groupingColDefs || {};
|
|
3046
3051
|
const [groupDataLenght, setGroupDataLengh] = (0, import_react27.useState)(0);
|
|
@@ -3114,6 +3119,24 @@ function SCDataGridInitial({ data, columns, getRowId, groupColumns, rowsTable, c
|
|
|
3114
3119
|
flex: 1
|
|
3115
3120
|
});
|
|
3116
3121
|
});
|
|
3122
|
+
const columnVisibilityModel = {};
|
|
3123
|
+
processedColumns.forEach((col) => {
|
|
3124
|
+
if (col.hide === true) {
|
|
3125
|
+
columnVisibilityModel[col.field] = false;
|
|
3126
|
+
}
|
|
3127
|
+
});
|
|
3128
|
+
console.log("columnVisibilityModel:", columnVisibilityModel);
|
|
3129
|
+
const initialState = {
|
|
3130
|
+
pagination: { paginationModel: { pageSize: rows } }
|
|
3131
|
+
};
|
|
3132
|
+
if (Object.keys(columnVisibilityModel).length > 0) {
|
|
3133
|
+
initialState.columns = { columnVisibilityModel };
|
|
3134
|
+
}
|
|
3135
|
+
(0, import_react27.useEffect)(() => {
|
|
3136
|
+
if (apiRef.current && Object.keys(columnVisibilityModel).length > 0) {
|
|
3137
|
+
apiRef.current.setColumnVisibilityModel(columnVisibilityModel);
|
|
3138
|
+
}
|
|
3139
|
+
}, [columnVisibilityModel, apiRef]);
|
|
3117
3140
|
return /* @__PURE__ */ import_react27.default.createElement(import_react27.default.Fragment, null, data && /* @__PURE__ */ import_react27.default.createElement(import_react27.default.Fragment, null, /* @__PURE__ */ import_react27.default.createElement("div", { style: { width: width || "100%", maxHeight: maxHeight ? `${maxHeight}px` : "none" } }, /* @__PURE__ */ import_react27.default.createElement(
|
|
3118
3141
|
import_x_data_grid_pro.DataGridPro,
|
|
3119
3142
|
{
|
|
@@ -3131,6 +3154,8 @@ function SCDataGridInitial({ data, columns, getRowId, groupColumns, rowsTable, c
|
|
|
3131
3154
|
pagination: { paginationModel: { pageSize: rows } }
|
|
3132
3155
|
},
|
|
3133
3156
|
scrollbarSize: 0,
|
|
3157
|
+
disableColumnMenu: disableColumnMenu ? disableColumnMenu : false,
|
|
3158
|
+
disableColumnSorting: disableColumnSorting ? disableColumnSorting : false,
|
|
3134
3159
|
checkboxSelection: validationCheckboxSelection,
|
|
3135
3160
|
rowSelectionModel: selectionModel,
|
|
3136
3161
|
onRowSelectionModelChange: (newSelection) => handleSelectionChange(newSelection),
|
|
@@ -3259,7 +3284,7 @@ function SCDataGridInitial({ data, columns, getRowId, groupColumns, rowsTable, c
|
|
|
3259
3284
|
))));
|
|
3260
3285
|
}
|
|
3261
3286
|
var SCDataGrid = import_react27.default.memo(SCDataGridInitial, (prevProps, nextProps) => {
|
|
3262
|
-
const isEqual = prevProps.rowsTable === nextProps.rowsTable && prevProps.checkboxSelection === nextProps.checkboxSelection && prevProps.width === nextProps.width && prevProps.maxHeight === nextProps.maxHeight
|
|
3287
|
+
const isEqual = prevProps.rowsTable === nextProps.rowsTable && prevProps.checkboxSelection === nextProps.checkboxSelection && prevProps.width === nextProps.width && prevProps.maxHeight === nextProps.maxHeight;
|
|
3263
3288
|
return isEqual;
|
|
3264
3289
|
});
|
|
3265
3290
|
|
|
@@ -3526,7 +3551,7 @@ var SCDialog = ({ title, iconTitle, subtitle, content, actions, buttonDialog, di
|
|
|
3526
3551
|
);
|
|
3527
3552
|
})) : /* @__PURE__ */ import_react33.default.createElement(import_material20.Box, { sx: { width: "100%", display: "flex", flexDirection: "row", justifyContent: "center" } }, /* @__PURE__ */ import_react33.default.createElement(import_ToggleButtonGroup.default, { size: "large", fullWidth: true }, dialogActions.map((boton, index) => {
|
|
3528
3553
|
var _a;
|
|
3529
|
-
return /* @__PURE__ */ import_react33.default.createElement(import_ToggleButton.default, { disabled: boton.disabled || false, fullWidth: boton.text ? true : false, size: "medium", value: "text", onClick: boton.fn }, (_a = boton.text) != null ? _a : /* @__PURE__ */ import_react33.default.createElement(import_material20.SvgIcon, { fontSize: "small", component: boton.icon }));
|
|
3554
|
+
return /* @__PURE__ */ import_react33.default.createElement(import_ToggleButton.default, { sx: { color: "primary.main" }, disabled: boton.disabled || false, fullWidth: boton.text ? true : false, size: "medium", value: "text", onClick: boton.fn }, (_a = boton.text) != null ? _a : /* @__PURE__ */ import_react33.default.createElement(import_material20.SvgIcon, { fontSize: "small", component: boton.icon }));
|
|
3530
3555
|
})))) : "" : ""
|
|
3531
3556
|
)));
|
|
3532
3557
|
};
|
|
@@ -4661,6 +4686,7 @@ var SCTime = ({
|
|
|
4661
4686
|
const [anchorEl, setAnchorEl] = (0, import_react48.useState)(null);
|
|
4662
4687
|
const [isOpenPopover, setIsOpenPopover] = (0, import_react48.useState)(false);
|
|
4663
4688
|
const [popoverPlacement, setPopoverPlacement] = (0, import_react48.useState)("bottom");
|
|
4689
|
+
const [popoverWidth, setPopoverWidth] = (0, import_react48.useState)(void 0);
|
|
4664
4690
|
const detectPlacement = (element) => {
|
|
4665
4691
|
const rect = element.getBoundingClientRect();
|
|
4666
4692
|
const windowHeight = window.innerHeight;
|
|
@@ -4677,6 +4703,7 @@ var SCTime = ({
|
|
|
4677
4703
|
if (!disabled) {
|
|
4678
4704
|
const target = event2.currentTarget;
|
|
4679
4705
|
setAnchorEl(target);
|
|
4706
|
+
setPopoverWidth(target.offsetWidth);
|
|
4680
4707
|
detectPlacement(target);
|
|
4681
4708
|
setIsOpenPopover(true);
|
|
4682
4709
|
}
|
|
@@ -4757,7 +4784,8 @@ var SCTime = ({
|
|
|
4757
4784
|
border: "1px solid #e0e0e0",
|
|
4758
4785
|
maxHeight: "300px",
|
|
4759
4786
|
overflow: "visible",
|
|
4760
|
-
width:
|
|
4787
|
+
width: popoverWidth ? `${popoverWidth}px` : "100%",
|
|
4788
|
+
maxWidth: "none"
|
|
4761
4789
|
}
|
|
4762
4790
|
}
|
|
4763
4791
|
}
|
|
@@ -4874,11 +4902,6 @@ var import_KeyboardDoubleArrowDown2 = __toESM(require("@mui/icons-material/Keybo
|
|
|
4874
4902
|
var import_KeyboardDoubleArrowUp2 = __toESM(require("@mui/icons-material/KeyboardDoubleArrowUp"), 1);
|
|
4875
4903
|
var import_ArrowForward = __toESM(require("@mui/icons-material/ArrowForward"), 1);
|
|
4876
4904
|
var import_LightModeOutlined = __toESM(require("@mui/icons-material/LightModeOutlined"), 1);
|
|
4877
|
-
var import_FilterList = __toESM(require("@mui/icons-material/FilterList"), 1);
|
|
4878
|
-
var import_CalendarMonthOutlined = __toESM(require("@mui/icons-material/CalendarMonthOutlined"), 1);
|
|
4879
|
-
var import_CheckCircleOutlineOutlined = __toESM(require("@mui/icons-material/CheckCircleOutlineOutlined"), 1);
|
|
4880
|
-
var import_EventBusyOutlined = __toESM(require("@mui/icons-material/EventBusyOutlined"), 1);
|
|
4881
|
-
var import_PendingOutlined = __toESM(require("@mui/icons-material/PendingOutlined"), 1);
|
|
4882
4905
|
var SCActivityCalendar = ({
|
|
4883
4906
|
//informativas
|
|
4884
4907
|
//apariencia
|
|
@@ -4895,9 +4918,6 @@ var SCActivityCalendar = ({
|
|
|
4895
4918
|
const [fechaSeleccionada, setFechaSeleccionada] = (0, import_react50.useState)();
|
|
4896
4919
|
const [stateVal, setstateVal] = import_react50.default.useState(/* @__PURE__ */ new Date());
|
|
4897
4920
|
const [openCalendar, setOpenCalendar] = import_react50.default.useState(false);
|
|
4898
|
-
const [anchorPopoverFiltro, setAnchorPopoverFiltro] = (0, import_react50.useState)(null);
|
|
4899
|
-
const [datosEventos, setDatosEventos] = import_react50.default.useState(events);
|
|
4900
|
-
const openPopoverFiltro = Boolean(anchorPopoverFiltro);
|
|
4901
4921
|
const hoy = /* @__PURE__ */ new Date();
|
|
4902
4922
|
const inicioSemana = (0, import_date_fns2.startOfWeek)(fecha, { weekStartsOn: 0 });
|
|
4903
4923
|
const diasSemana = Array.from({ length: 7 }, (_, i) => (0, import_date_fns2.addDays)(inicioSemana, i));
|
|
@@ -4925,22 +4945,6 @@ var SCActivityCalendar = ({
|
|
|
4925
4945
|
// 0 = domingo, 1 = lunes
|
|
4926
4946
|
})
|
|
4927
4947
|
});
|
|
4928
|
-
const handleClickPopoverFiltro = (event2) => {
|
|
4929
|
-
setAnchorPopoverFiltro(event2.currentTarget);
|
|
4930
|
-
};
|
|
4931
|
-
const handleClosePopoverFiltro = () => {
|
|
4932
|
-
setAnchorPopoverFiltro(null);
|
|
4933
|
-
};
|
|
4934
|
-
const filtrarActividad = (event2, filtro) => {
|
|
4935
|
-
if (filtro === "Todo") {
|
|
4936
|
-
setDatosEventos(events);
|
|
4937
|
-
} else {
|
|
4938
|
-
const resultado = events.filter(
|
|
4939
|
-
(item) => item.state === filtro
|
|
4940
|
-
);
|
|
4941
|
-
setDatosEventos(resultado);
|
|
4942
|
-
}
|
|
4943
|
-
};
|
|
4944
4948
|
return /* @__PURE__ */ import_react50.default.createElement(import_react50.default.Fragment, null, /* @__PURE__ */ import_react50.default.createElement(import_LocalizationProvider4.LocalizationProvider, { dateAdapter: import_AdapterDateFns2.AdapterDateFns, adapterLocale: locale }, openCalendar == false ? /* @__PURE__ */ import_react50.default.createElement(import_material34.Box, { "data-testid": "calendar-mobile", sx: { width: "100%", background: background ? background : "white", display: "flex", flexDirection: "column", alignItems: "center" } }, /* @__PURE__ */ import_react50.default.createElement(import_material34.Box, { sx: { width: "100%", padding: "0px", background: "transparent" } }, /* @__PURE__ */ import_react50.default.createElement(import_Grid9.default, { container: true, gap: 0.5, sx: { justifyContent: "space-between", padding: "12px 16px", background: "transparent" } }, diasSemana.map((dia) => /* @__PURE__ */ import_react50.default.createElement(import_Grid9.default, { sx: { width: "36px" }, key: dia.toString() }, /* @__PURE__ */ import_react50.default.createElement(import_material34.Box, { sx: { width: "36px", height: "40px", display: "flex", alignItems: "center", justifyContent: "center" } }, /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, { sx: { fontSize: "12px !important", color: "#10184099" } }, (0, import_date_fns2.format)(dia, "EEEE", { locale: import_locale2.es }).charAt(0).toUpperCase())), /* @__PURE__ */ import_react50.default.createElement(
|
|
4945
4949
|
import_material34.Box,
|
|
4946
4950
|
{
|
|
@@ -4980,36 +4984,7 @@ var SCActivityCalendar = ({
|
|
|
4980
4984
|
},
|
|
4981
4985
|
onChange: (newValue) => setFecha(newValue)
|
|
4982
4986
|
}
|
|
4983
|
-
), /* @__PURE__ */ import_react50.default.createElement(import_Grid9.default, { container: true, justifyContent: "center" }, /* @__PURE__ */ import_react50.default.createElement(import_material34.IconButton, { "data-testid": "close-calendar-button", onClick: toggleCalendar(false) }, /* @__PURE__ */ import_react50.default.createElement(import_KeyboardDoubleArrowUp2.default, { color: "action" }))))), /* @__PURE__ */ import_react50.default.createElement(import_material34.
|
|
4984
|
-
import_material34.Popover,
|
|
4985
|
-
{
|
|
4986
|
-
open: openPopoverFiltro,
|
|
4987
|
-
anchorEl: anchorPopoverFiltro,
|
|
4988
|
-
onClose: handleClosePopoverFiltro,
|
|
4989
|
-
anchorOrigin: {
|
|
4990
|
-
vertical: "bottom",
|
|
4991
|
-
horizontal: "right"
|
|
4992
|
-
}
|
|
4993
|
-
},
|
|
4994
|
-
/* @__PURE__ */ import_react50.default.createElement(
|
|
4995
|
-
import_material34.Menu,
|
|
4996
|
-
{
|
|
4997
|
-
id: "basic-menu",
|
|
4998
|
-
anchorEl: anchorPopoverFiltro,
|
|
4999
|
-
open: openPopoverFiltro,
|
|
5000
|
-
onClose: handleClosePopoverFiltro,
|
|
5001
|
-
slotProps: {
|
|
5002
|
-
list: {
|
|
5003
|
-
"aria-labelledby": "basic-button"
|
|
5004
|
-
}
|
|
5005
|
-
}
|
|
5006
|
-
},
|
|
5007
|
-
/* @__PURE__ */ import_react50.default.createElement(import_material34.MenuItem, { onClick: (event2) => filtrarActividad(event2, "Todo") }, /* @__PURE__ */ import_react50.default.createElement(import_material34.ListItemIcon, null, /* @__PURE__ */ import_react50.default.createElement(import_CalendarMonthOutlined.default, { fontSize: "small" })), /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, { variant: "inherit" }, "Ver todo")),
|
|
5008
|
-
/* @__PURE__ */ import_react50.default.createElement(import_material34.MenuItem, { onClick: (event2) => filtrarActividad(event2, "Finalizada") }, /* @__PURE__ */ import_react50.default.createElement(import_material34.ListItemIcon, null, /* @__PURE__ */ import_react50.default.createElement(import_CheckCircleOutlineOutlined.default, { fontSize: "small" })), /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, { variant: "inherit" }, "Ver finalizadas")),
|
|
5009
|
-
/* @__PURE__ */ import_react50.default.createElement(import_material34.MenuItem, { onClick: (event2) => filtrarActividad(event2, "Aplazada") }, /* @__PURE__ */ import_react50.default.createElement(import_material34.ListItemIcon, null, /* @__PURE__ */ import_react50.default.createElement(import_EventBusyOutlined.default, { fontSize: "small" })), /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, { variant: "inherit" }, "Ver aplazadas")),
|
|
5010
|
-
/* @__PURE__ */ import_react50.default.createElement(import_material34.MenuItem, { onClick: (event2) => filtrarActividad(event2, "En progreso") }, /* @__PURE__ */ import_react50.default.createElement(import_material34.ListItemIcon, null, /* @__PURE__ */ import_react50.default.createElement(import_PendingOutlined.default, { fontSize: "small" })), /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, { variant: "inherit" }, "Ver en progreso"))
|
|
5011
|
-
)
|
|
5012
|
-
), /* @__PURE__ */ import_react50.default.createElement(import_material34.Box, { sx: { boxSizing: "border-box", padding: "0px 16px", width: "100%", height: openCalendar ? "calc(91% - 260px)" : "calc(91% - 100px)", background: "white", display: "flex", flexDirection: "column", overflowY: "auto", gap: "8px", scrollSnapType: "x mandatory", paddingBottom: "10px" } }, diasSemana.map((day, dayIndex) => /* @__PURE__ */ import_react50.default.createElement(
|
|
4987
|
+
), /* @__PURE__ */ import_react50.default.createElement(import_Grid9.default, { container: true, justifyContent: "center" }, /* @__PURE__ */ import_react50.default.createElement(import_material34.IconButton, { "data-testid": "close-calendar-button", onClick: toggleCalendar(false) }, /* @__PURE__ */ import_react50.default.createElement(import_KeyboardDoubleArrowUp2.default, { color: "action" }))))), /* @__PURE__ */ import_react50.default.createElement(import_material34.Box, { sx: { boxSizing: "border-box", padding: "0px 16px", width: "100%", height: openCalendar ? "calc(91% - 260px)" : "calc(91% - 100px)", background: "white", display: "flex", flexDirection: "column", overflowY: "auto", gap: "8px", scrollSnapType: "x mandatory", paddingBottom: "10px" } }, diasSemana.map((day, dayIndex) => /* @__PURE__ */ import_react50.default.createElement(
|
|
5013
4988
|
import_material34.Box,
|
|
5014
4989
|
{
|
|
5015
4990
|
key: dayIndex
|
|
@@ -5026,7 +5001,7 @@ var SCActivityCalendar = ({
|
|
|
5026
5001
|
flexDirection: "column"
|
|
5027
5002
|
} }, (() => {
|
|
5028
5003
|
const esDomingo = day.getDay() === 0;
|
|
5029
|
-
const eventosDelDia =
|
|
5004
|
+
const eventosDelDia = events.filter(
|
|
5030
5005
|
(event2) => new Date(event2.date).toDateString() === day.toDateString()
|
|
5031
5006
|
);
|
|
5032
5007
|
if (eventosDelDia.length > 0) {
|
|
@@ -5039,7 +5014,7 @@ var SCActivityCalendar = ({
|
|
|
5039
5014
|
subtitle: /* @__PURE__ */ import_react50.default.createElement(import_react50.default.Fragment, null, configRangeHour && new Date(event2.date.replace("00:00:00", event2.startTime)).getHours() === new Date(event2.date.replace("00:00:00", configRangeHour.split("-")[0])).getHours() && new Date(event2.date.replace("00:00:00", event2.finalTime)).getHours() === new Date(event2.date.replace("00:00:00", configRangeHour.split("-")[1])).getHours() && new Date(event2.date.replace("00:00:00", event2.startTime)).getMinutes() === new Date(event2.date.replace("00:00:00", configRangeHour.split("-")[0])).getMinutes() && new Date(event2.date.replace("00:00:00", event2.finalTime)).getMinutes() === new Date(event2.date.replace("00:00:00", configRangeHour.split("-")[1])).getMinutes() ? /* @__PURE__ */ import_react50.default.createElement(import_react50.default.Fragment, null, /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, null, "Todo el dia"), /* @__PURE__ */ import_react50.default.createElement(import_LightModeOutlined.default, { fontSize: "small" })) : /* @__PURE__ */ import_react50.default.createElement(import_react50.default.Fragment, null, /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, null, new Date(event2.date.replace("00:00:00", event2.startTime)).toLocaleTimeString([], { hour: "2-digit", minute: "2-digit", hour12: true })), /* @__PURE__ */ import_react50.default.createElement(import_ArrowForward.default, { fontSize: "small" }), /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, null, new Date(event2.date.replace("00:00:00", event2.finalTime)).toLocaleTimeString([], { hour: "2-digit", minute: "2-digit", hour12: true })))),
|
|
5040
5015
|
iconLeftColor: event2.state === "Finalizada" ? "#C7E49D" : "action",
|
|
5041
5016
|
iconLeft: event2.state === "Finalizada" ? "CheckCircle" : event2.state === "Aplazada" ? "EventBusyOutlined" : event2.state === "En progreso" ? "PendingOutlined" : "RadioButtonUnchecked",
|
|
5042
|
-
description: /* @__PURE__ */ import_react50.default.createElement(
|
|
5017
|
+
description: /* @__PURE__ */ import_react50.default.createElement(import_Grid9.default, { display: "flex", flexDirection: "column", alignItems: "flex-start" }, event2.state === "Aplazada" || event2.state === "En progreso" || event2.state === "Auto asignada" ? /* @__PURE__ */ import_react50.default.createElement(import_Grid9.default, { display: "flex", flexDirection: "row", alignItems: "center", gap: 0.5, sx: { marginLeft: "7px" } }, /* @__PURE__ */ import_react50.default.createElement(import_material34.Badge, { variant: "dot", badgeContent: "", sx: { display: "flex", alignItems: "center", "& .MuiBadge-badge": { top: "50%", transform: "translateY(-50%)" }, color: "action" } }), /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, null, event2.state == "Auto asignada" ? "Adicional" : event2.state)) : null, /* @__PURE__ */ import_react50.default.createElement(import_material34.Typography, { variant: "body2" }, event2.equipmentDescription)),
|
|
5043
5018
|
divider: eventosDelDia.length === idx + 1 ? false : true,
|
|
5044
5019
|
colorDisabled: event2.state === "Finalizada" || event2.state === "Aplazada" || event2.state === "En progreso" ? true : false,
|
|
5045
5020
|
fn: fn ? () => fn(event2) : void 0
|
|
@@ -5388,7 +5363,7 @@ var AttachmentMobile = ({
|
|
|
5388
5363
|
screenshotFormat: "image/jpeg",
|
|
5389
5364
|
videoConstraints: {
|
|
5390
5365
|
//facingMode: { exact: "environment" }
|
|
5391
|
-
facingMode: "
|
|
5366
|
+
facingMode: "environment"
|
|
5392
5367
|
//facingMode: "environment" // cámara trasera
|
|
5393
5368
|
},
|
|
5394
5369
|
style: {
|
|
@@ -5653,7 +5628,6 @@ var SCDatePicker = ({ label, required, disabled, background, state, setState, wi
|
|
|
5653
5628
|
maxDate: (0, import_dayjs11.default)().add(3, "month"),
|
|
5654
5629
|
sx: {
|
|
5655
5630
|
minWidth: 140,
|
|
5656
|
-
padding: "13px 0px",
|
|
5657
5631
|
width: width || "100%",
|
|
5658
5632
|
"& .MuiPickersInputBase-sectionsContainer": {
|
|
5659
5633
|
padding: "8px 0px"
|
|
@@ -5668,13 +5642,7 @@ var SCDatePicker = ({ label, required, disabled, background, state, setState, wi
|
|
|
5668
5642
|
},
|
|
5669
5643
|
textField: {
|
|
5670
5644
|
required: required || false,
|
|
5671
|
-
|
|
5672
|
-
sx: {
|
|
5673
|
-
"&.MuiInputLabel-shrink": {
|
|
5674
|
-
transform: "translate(10px, 5px) scale(0.9) !important"
|
|
5675
|
-
}
|
|
5676
|
-
}
|
|
5677
|
-
}
|
|
5645
|
+
size: "small"
|
|
5678
5646
|
}
|
|
5679
5647
|
},
|
|
5680
5648
|
slots: {
|