Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,19 @@ module.exports = [
'no-undef': 2,
'no-undef-init': 2,
'no-tabs': 2,
// The @mui/icons-material barrel re-exports ~10,800 modules that every
// consumer's bundler has to parse. Import icons by path instead.
'no-restricted-imports': [
2,
{
paths: [
{
name: '@mui/icons-material',
message: "Import icons by path, e.g. '@mui/icons-material/Search'.",
},
],
},
],
'react/self-closing-comp': 2,
'react/no-typos': 2,
'react/jsx-no-duplicate-props': 'warn',
Expand Down
3 changes: 2 additions & 1 deletion src/components/ExpandButton.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { IconButton } from '@mui/material';
import { KeyboardArrowRight as KeyboardArrowRightIcon, Remove as RemoveIcon } from '@mui/icons-material';
import KeyboardArrowRightIcon from '@mui/icons-material/KeyboardArrowRight';
import RemoveIcon from '@mui/icons-material/Remove';

const ExpandButton = ({
areAllRowsExpanded,
Expand Down
2 changes: 1 addition & 1 deletion src/components/Popover.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React, { useEffect, useRef, useState } from 'react';
import PropTypes from 'prop-types';
import { Popover as MuiPopover, IconButton } from '@mui/material';
import { Close as CloseIcon } from '@mui/icons-material';
import CloseIcon from '@mui/icons-material/Close';

const Popover = ({ className, trigger, refExit, hide, content, ...providedProps }) => {
const [isOpen, open] = useState(false);
Expand Down
2 changes: 1 addition & 1 deletion src/components/TableHeadCell.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Button, TableCell, TableSortLabel, Tooltip as MuiTooltip } from '@mui/material';
import { Help as HelpIcon } from '@mui/icons-material';
import HelpIcon from '@mui/icons-material/Help';
import clsx from 'clsx';
import PropTypes from 'prop-types';
import React, { useState } from 'react';
Expand Down
3 changes: 2 additions & 1 deletion src/components/TableSearch.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { Grow, TextField, IconButton } from '@mui/material';
import { Search as SearchIcon, Clear as ClearIcon } from '@mui/icons-material';
import SearchIcon from '@mui/icons-material/Search';
import ClearIcon from '@mui/icons-material/Clear';
import { makeStyles } from 'tss-react/mui';

const useStyles = makeStyles({ name: 'MUIDataTableSearch' })((theme) => ({
Expand Down
12 changes: 5 additions & 7 deletions src/components/TableToolbar.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import React from 'react';
import { Typography, Toolbar, IconButton, Tooltip as MuiTooltip } from '@mui/material';
import {
Search as SearchIcon,
CloudDownload as DownloadIcon,
Print as PrintIcon,
ViewColumn as ViewColumnIcon,
FilterList as FilterIcon,
} from '@mui/icons-material';
import SearchIcon from '@mui/icons-material/Search';
import DownloadIcon from '@mui/icons-material/CloudDownload';
import PrintIcon from '@mui/icons-material/Print';
import ViewColumnIcon from '@mui/icons-material/ViewColumn';
import FilterIcon from '@mui/icons-material/FilterList';
import Popover from './Popover';
import TableFilter from './TableFilter';
import TableViewCol from './TableViewCol';
Expand Down
2 changes: 1 addition & 1 deletion src/components/TableToolbarSelect.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import PropTypes from 'prop-types';
import { Paper, IconButton, Typography, Tooltip as MuiTooltip } from '@mui/material';
import { Delete as DeleteIcon } from '@mui/icons-material';
import DeleteIcon from '@mui/icons-material/Delete';
import { withStyles } from 'tss-react/mui';

const defaultToolbarSelectStyles = (theme) => ({
Expand Down
3 changes: 2 additions & 1 deletion src/plug-ins/DebounceSearchRender.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import { Grow, TextField, IconButton } from '@mui/material';
import { Search as SearchIcon, Clear as ClearIcon } from '@mui/icons-material';
import SearchIcon from '@mui/icons-material/Search';
import ClearIcon from '@mui/icons-material/Clear';
import { withStyles } from 'tss-react/mui';

function debounce(func, wait, immediate) {
Expand Down
Loading