Skip to content

Commit

Permalink
release v2.0.0-beta.0
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinVandy committed Oct 13, 2023
1 parent d3c4259 commit 33a67cb
Show file tree
Hide file tree
Showing 12 changed files with 949 additions and 748 deletions.
Expand Up @@ -5,7 +5,7 @@ import { SampleCodeSnippet } from './SampleCodeSnippet';
type Tab = 'npm' | 'pnpm' | 'yarn';

const defaultPackagesString =
'material-react-table@alpha @mui/material @mui/x-date-pickers @mui/icons-material @emotion/react @emotion/styled';
'material-react-table@beta @mui/material @mui/x-date-pickers @mui/icons-material @emotion/react @emotion/styled';

export const InstallCommand = ({
packagesString = defaultPackagesString,
Expand Down
Expand Up @@ -32,7 +32,7 @@ export const makeData = (numberOfRows: number) =>
state: faker.location.state(),
country: faker.location.country(),
petName: faker.animal.cat(),
age: faker.datatype.float({ min: 0, max: 100 }),
age: faker.number.float({ min: 0, max: 100 }),
salary: faker.datatype
.float({ min: 0, max: 1000000 })
.toLocaleString('en-US', {
Expand Down
20 changes: 10 additions & 10 deletions apps/material-react-table-docs/package.json
Expand Up @@ -22,16 +22,16 @@
"@fortawesome/react-fontawesome": "^0.2.0",
"@mdx-js/loader": "^2.3.0",
"@mdx-js/react": "^2.3.0",
"@mui/icons-material": "^5.14.12",
"@mui/material": "^5.14.12",
"@mui/x-date-pickers": "^6.16.1",
"@mui/icons-material": "^5.14.13",
"@mui/material": "^5.14.13",
"@mui/x-date-pickers": "^6.16.2",
"@next/mdx": "^13.5.4",
"@tanstack/react-query": "^4.36.1",
"@types/mdx": "^2.0.8",
"dayjs": "^1.11.10",
"export-to-csv": "^1.1.0",
"export-to-csv": "^1.2.0",
"jspdf": "^2.5.1",
"jspdf-autotable": "^3.6.0",
"jspdf-autotable": "^3.7.0",
"material-react-table": "workspace:*",
"next": "13.5.4",
"next-sitemap": "^4.2.3",
Expand All @@ -40,11 +40,11 @@
"react-dom": "18.2.0"
},
"devDependencies": {
"@types/node": "^20.8.3",
"@types/react": "^18.2.25",
"@types/react-dom": "^18.2.11",
"@typescript-eslint/eslint-plugin": "^6.7.4",
"@typescript-eslint/parser": "^6.7.4",
"@types/node": "^20.8.5",
"@types/react": "^18.2.28",
"@types/react-dom": "^18.2.13",
"@typescript-eslint/eslint-plugin": "^6.7.5",
"@typescript-eslint/parser": "^6.7.5",
"eslint": "8.51.0",
"eslint-config-next": "13.5.4",
"next-plausible": "^3.11.1",
Expand Down
Expand Up @@ -24,7 +24,7 @@ import { FAQs } from '../../../components/mdx/FAQs';
### Quick Install

<InstallCommand packagesString="material-react-table@alpha" />
<InstallCommand packagesString="material-react-table@beta" />

### Install With Required Peer Dependencies (Recommended)

Expand Down
3 changes: 1 addition & 2 deletions package.json
Expand Up @@ -30,6 +30,5 @@
},
"engines": {
"node": ">=14.0.0"
},
"packageManager": "pnpm@8.5.1"
}
}
22 changes: 11 additions & 11 deletions packages/material-react-table/package.json
@@ -1,5 +1,5 @@
{
"version": "2.0.0-alpha.6",
"version": "2.0.0-beta.0",
"license": "MIT",
"name": "material-react-table",
"description": "A fully featured Material UI V5 implementation of TanStack React Table V8, written from the ground up in TypeScript.",
Expand Down Expand Up @@ -60,16 +60,16 @@
"storybook:dev": "storybook dev -p 6006"
},
"devDependencies": {
"@babel/core": "^7.23.0",
"@babel/core": "^7.23.2",
"@babel/preset-react": "^7.22.15",
"@emotion/react": "^11.11.1",
"@emotion/styled": "^11.11.0",
"@faker-js/faker": "^8.1.0",
"@mui/icons-material": "^5.14.12",
"@mui/material": "^5.14.12",
"@mui/x-date-pickers": "^6.16.1",
"@mui/icons-material": "^5.14.13",
"@mui/material": "^5.14.13",
"@mui/x-date-pickers": "^6.16.2",
"@rollup/plugin-babel": "^6.0.4",
"@rollup/plugin-node-resolve": "^15.2.2",
"@rollup/plugin-node-resolve": "^15.2.3",
"@rollup/plugin-typescript": "^11.1.5",
"@size-limit/preset-small-lib": "^9.0.0",
"@storybook/addon-a11y": "^7.4.6",
Expand All @@ -81,11 +81,11 @@
"@storybook/react": "^7.4.6",
"@storybook/react-vite": "^7.4.6",
"@storybook/testing-library": "^0.2.2",
"@types/node": "^20.8.3",
"@types/react": "^18.2.25",
"@types/react-dom": "^18.2.11",
"@typescript-eslint/eslint-plugin": "^6.7.4",
"@typescript-eslint/parser": "^6.7.4",
"@types/node": "^20.8.5",
"@types/react": "^18.2.28",
"@types/react-dom": "^18.2.13",
"@typescript-eslint/eslint-plugin": "^6.7.5",
"@typescript-eslint/parser": "^6.7.5",
"@vitejs/plugin-react": "^4.1.0",
"eslint": "^8.51.0",
"eslint-plugin-mui-path-imports": "^0.0.15",
Expand Down
Expand Up @@ -38,6 +38,7 @@ export const MRT_TableBodyRowGrabHandle = <TData extends Record<string, any>>({
return (
<MRT_GrabHandleButton
iconButtonProps={iconButtonProps}
location="row"
onDragEnd={handleDragEnd}
onDragStart={handleDragStart}
table={table}
Expand Down
Expand Up @@ -6,13 +6,15 @@ import { type MRT_TableInstance } from '../types';

interface Props<TData extends Record<string, any>> {
iconButtonProps?: IconButtonProps;
location?: 'column' | 'row';
onDragEnd: DragEventHandler<HTMLButtonElement>;
onDragStart: DragEventHandler<HTMLButtonElement>;
table: MRT_TableInstance<TData>;
}

export const MRT_GrabHandleButton = <TData extends Record<string, any>>({
iconButtonProps,
location,
onDragEnd,
onDragStart,
table,
Expand Down Expand Up @@ -53,7 +55,7 @@ export const MRT_GrabHandleButton = <TData extends Record<string, any>>({
},
cursor: 'grab',
m: '0 -0.1rem',
opacity: 0.3,
opacity: location === 'row' ? 1 : 0.3,
p: '2px',
transition: 'all 150ms ease-in-out',
...(parseFromValuesOrFunc(iconButtonProps?.sx, theme) as any),
Expand Down
Expand Up @@ -65,7 +65,7 @@ export const MRT_TableHeadCellColumnActionsButton = <
opacity: 1,
},
height: '2rem',
m: '-8px -4px',
m: '-4px',
opacity: 0.3,
transform: `scale(0.85) ${
columnFilterDisplayMode !== 'popover' ? 'translateX(-4px)' : ''
Expand Down
4 changes: 2 additions & 2 deletions packages/material-react-table/src/locales/sv.ts
Expand Up @@ -44,11 +44,11 @@ export const MRT_Localization_SV: MRT_Localization = {
filterWeakEquals: 'Lika med',
filteringByColumn: 'Filtrering efter {column} - {filterType} {filterValue}',
goToFirstPage: 'Gå till första sidan',
goToLastPage: 'Gå till sista sidan ',
goToLastPage: 'Gå till sista sidan',
goToNextPage: 'Gå till nästa sida',
goToPreviousPage: 'Gå till föregående sida',
grab: 'Greppa',
groupByColumn: 'Guppera efter {column}',
groupByColumn: 'Gruppera efter {column}',
groupedBy: 'Gruppera efter ',
hideAll: 'Göm alla',
hideColumn: 'Göm {column} kolumn',
Expand Down
Expand Up @@ -37,7 +37,7 @@ const columns: MRT_ColumnDef<(typeof data)[0]>[] = [

const data = [...Array(200)].map(() => ({
address: faker.location.streetAddress(),
age: +faker.datatype.float({ max: 100, min: 0 }),
age: +faker.number.float({ max: 100, min: 0 }),
firstName: faker.person.firstName(),
lastName: faker.person.lastName(),
phoneNumber: faker.phone.number(),
Expand Down

0 comments on commit 33a67cb

Please sign in to comment.