@iotready/nextjs-components-library 1.0.0-preview27 → 1.0.0-preview28

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.
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
3
  import { Box, CircularProgress, Autocomplete, TextField, Input, IconButton, Button, Card, CardContent, CardHeader, Modal, Typography, Stack, Tab } from "@mui/material";
4
- import { cloneElement, isValidElement, useEffect, useMemo, useRef, useState } from "react";
4
+ import { cloneElement, isValidElement, useCallback, useEffect, useMemo, useRef, useState } from "react";
5
5
  import AddIcon from '@mui/icons-material/Add';
6
6
  import PlaylistAddIcon from '@mui/icons-material/PlaylistAdd';
7
7
  import EditIcon from '@mui/icons-material/Edit';
@@ -10,7 +10,7 @@ import ReadMoreIcon from '@mui/icons-material/ReadMore';
10
10
  import PlaylistRemoveIcon from '@mui/icons-material/PlaylistRemove';
11
11
  import CloseIcon from '@mui/icons-material/Close';
12
12
  import { LoadingButton, TabContext, TabList, TabPanel } from "@mui/lab";
13
- import { DataGrid, GridToolbar, GridToolbarExport, GridToolbarQuickFilter } from "@mui/x-data-grid";
13
+ import { DataGrid, GridToolbar, GridToolbarExport, GridToolbarFilterButton, GridToolbarQuickFilter } from "@mui/x-data-grid";
14
14
  import GroupUpdate from "./GroupUpdate";
15
15
  import BackIcon from '@mui/icons-material/ArrowBack';
16
16
  import dynamic from "next/dynamic";
@@ -221,11 +221,11 @@ const GroupsDevices = ({ userInfo, handleGetUsersList, handleAddUserToGroup, han
221
221
  setDeviceSelectedObjs([]);
222
222
  }
223
223
  }, [devicesToAdd]);
224
- const CustomToolbar = () => (_jsxs("div", { style: { display: 'flex', padding: '8px', justifyContent: 'space-between', paddingTop: '2px' }, children: [_jsxs("div", { style: { display: 'flex', gap: 8, marginRight: '20px' }, children: [customToolbar && customToolbar.includes('filters') ?
225
- _jsx(GridToolbarExport, { sx: { mr: 2 } })
224
+ const CustomToolbar = useCallback((props) => (_jsxs("div", { style: { display: 'flex', padding: '8px', justifyContent: 'space-between', paddingTop: '2px' }, children: [_jsxs("div", { style: { display: 'flex', gap: 8, marginRight: '20px' }, children: [customToolbar && customToolbar.includes('filters') ?
225
+ _jsx(GridToolbarFilterButton, {})
226
226
  : '', customToolbar && customToolbar.includes('export') ?
227
227
  _jsx(GridToolbarExport, {})
228
- : ''] }), customToolbar && customToolbar.includes('quickfilter') && _jsx(GridToolbarQuickFilter, {})] }));
228
+ : ''] }), customToolbar && customToolbar.includes('quickfilter') && _jsx(GridToolbarQuickFilter, {})] })), []);
229
229
  const renderDataGrid = (_jsx("div", { style: { display: 'flex', flexDirection: 'column', minHeight: 323 }, children: _jsx(DataGrid, { checkboxSelection: checkboxSelection,
230
230
  // Se siamo in modalità aggiunta, includi gli ID già nel gruppo
231
231
  rowSelectionModel: (checkboxSelection && currentGroup === 'all')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iotready/nextjs-components-library",
3
- "version": "1.0.0-preview27",
3
+ "version": "1.0.0-preview28",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "build": "rm -rf dist && tsc --project tsconfig.build.json && cp package.json dist/",