@jsonforms/material-renderers 3.0.0 → 3.1.0-alpha.0

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.
@@ -5,7 +5,7 @@ import isEmpty from 'lodash/isEmpty';
5
5
  import union from 'lodash/union';
6
6
  import startCase from 'lodash/startCase';
7
7
  import range from 'lodash/range';
8
- import { TableCell, styled as styled$1, Badge, Tooltip, TableRow, Grid, Typography, Hidden, IconButton, FormHelperText, Table, TableHead, TableBody, Dialog, DialogTitle, DialogContent, DialogContentText, DialogActions, Button, Tabs, Tab, Checkbox, TextField, Select, MenuItem, Input, useTheme, InputAdornment, FormControl, FormGroup, FormControlLabel, Toolbar, ListItem, ListItemAvatar, Avatar, ListItemText, ListItemSecondaryAction, List, Switch, InputLabel, Autocomplete, FormLabel, Slider, RadioGroup, Radio, Card, CardHeader, CardContent, AppBar, Accordion, AccordionSummary, AccordionDetails, Stepper, Step, StepButton } from '@mui/material';
8
+ import { TableCell, styled as styled$1, Badge, Tooltip, TableRow, Grid, Typography, IconButton, FormHelperText, Hidden, Table, TableHead, TableBody, Dialog, DialogTitle, DialogContent, DialogContentText, DialogActions, Button, Tabs, Tab, Checkbox, TextField, Select, MenuItem, Input, useTheme, InputAdornment, FormControl, FormGroup, FormControlLabel, Toolbar, ListItem, ListItemAvatar, Avatar, ListItemText, ListItemSecondaryAction, List, Switch, InputLabel, Autocomplete, FormLabel, Slider, RadioGroup, Radio, Card, CardHeader, CardContent, AppBar, Accordion, AccordionSummary, AccordionDetails, Stepper, Step, StepButton } from '@mui/material';
9
9
  import DeleteIcon from '@mui/icons-material/Delete';
10
10
  import ArrowDownward from '@mui/icons-material/ArrowDownward';
11
11
  import ArrowUpward from '@mui/icons-material/ArrowUpward';
@@ -48,10 +48,9 @@ const TableToolbar = React.memo(({ numColumns, errors, label, path, addItem, sch
48
48
  React.createElement(Grid, { container: true, justifyContent: 'flex-start', alignItems: 'center', spacing: 2 },
49
49
  React.createElement(Grid, { item: true },
50
50
  React.createElement(Typography, { variant: 'h6' }, label)),
51
- React.createElement(Grid, { item: true },
52
- React.createElement(Hidden, { smUp: errors.length === 0 },
53
- React.createElement(Grid, { item: true },
54
- React.createElement(ValidationIcon, { id: 'tooltip-validation', errorMessages: errors })))))),
51
+ React.createElement(Grid, { item: true }, errors.length !== 0 &&
52
+ React.createElement(Grid, { item: true },
53
+ React.createElement(ValidationIcon, { id: 'tooltip-validation', errorMessages: errors }))))),
55
54
  enabled ? (React.createElement(NoBorderTableCell, { align: 'right', style: fixedCellSmall },
56
55
  React.createElement(Tooltip, { id: 'tooltip-add', title: `Add to ${label}`, placement: 'bottom' },
57
56
  React.createElement(IconButton, { "aria-label": `Add to ${label}`, onClick: addItem(path, createDefaultValue(schema)), size: 'large' },
@@ -537,9 +536,9 @@ const ArrayLayoutToolbar = React.memo(({ label, errors, addItem, path, createDef
537
536
  React.createElement(Grid, { container: true, alignItems: 'center', justifyContent: 'space-between' },
538
537
  React.createElement(Grid, { item: true },
539
538
  React.createElement(Typography, { variant: 'h6' }, label)),
540
- React.createElement(Hidden, { smUp: errors.length === 0 },
539
+ errors.length !== 0 &&
541
540
  React.createElement(Grid, { item: true },
542
- React.createElement(ValidationIcon, { id: 'tooltip-validation', errorMessages: errors }))),
541
+ React.createElement(ValidationIcon, { id: 'tooltip-validation', errorMessages: errors })),
543
542
  React.createElement(Grid, { item: true },
544
543
  React.createElement(Grid, { container: true },
545
544
  React.createElement(Grid, { item: true },