From 01591e412384d1e203a0c88db483460c2c4d54c1 Mon Sep 17 00:00:00 2001 From: Kevin Vandy Date: Tue, 18 Jul 2023 02:04:28 -0500 Subject: [PATCH] release v1.0.0 - Initial Stable Release! --- README.md | 4 +- .../components/mdx/BlogAuthor.tsx | 56 +++++ .../components/mdx/mdxComponents.tsx | 2 +- .../components/navigation/Footer.tsx | 3 +- .../components/navigation/TopBar.tsx | 2 +- .../components/navigation/routes.ts | 20 +- .../example-groups/BasicExamples.tsx | 1 - .../examples/advanced/index.tsx | 2 +- .../examples/basic/index.tsx | 2 +- .../custom-headless/sandbox/src/JS.js | 2 +- .../custom-headless/sandbox/src/TS.tsx | 2 +- .../enable-column-pinning/sandbox/src/JS.js | 2 +- .../enable-sticky-header/sandbox/src/JS.js | 2 +- .../localization-i18n-da/sandbox/src/JS.js | 2 +- .../localization-i18n-nl/sandbox/src/JS.js | 2 +- .../sandbox/src/JS.js | 2 +- .../examples/minimal/index.tsx | 2 +- .../pages/blog/index.mdx | 14 ++ .../blog/introducing-mantine-react-table.mdx | 205 ++++++++++++++++++ .../pages/changelog.mdx | 6 + .../pages/docs/guides/data-columns.mdx | 10 +- .../pages/docs/guides/density-toggle.mdx | 16 +- .../pages/docs/guides/detail-panel.mdx | 34 +-- .../pages/docs/guides/display-columns.mdx | 50 +++-- .../pages/docs/guides/event-listeners.mdx | 32 +-- .../pages/docs/guides/expanding-sub-rows.mdx | 90 ++++---- .../pages/docs/guides/global-filtering.mdx | 119 +++++----- .../pages/docs/guides/localization.mdx | 16 +- .../pages/docs/index.mdx | 2 +- .../public/sitemap-0.xml | 66 +----- packages/mantine-react-table/README.md | 4 +- packages/mantine-react-table/package.json | 2 +- 32 files changed, 495 insertions(+), 279 deletions(-) create mode 100644 apps/mantine-react-table-docs/components/mdx/BlogAuthor.tsx create mode 100644 apps/mantine-react-table-docs/pages/blog/index.mdx create mode 100644 apps/mantine-react-table-docs/pages/blog/introducing-mantine-react-table.mdx diff --git a/README.md b/README.md index a19bae0ab..4947037c2 100644 --- a/README.md +++ b/README.md @@ -2,9 +2,9 @@ View the [Docs Site](https://www.mantine-react-table.com/) -A work in progress fork of [Material React Table](https://www.material-react-table.com) +A fork of [Material React Table](https://www.material-react-table.com) -Coming soon in early 2023, but you can try out the beta now. +V1 released July 18, 2023 diff --git a/apps/mantine-react-table-docs/components/mdx/BlogAuthor.tsx b/apps/mantine-react-table-docs/components/mdx/BlogAuthor.tsx new file mode 100644 index 000000000..a669370be --- /dev/null +++ b/apps/mantine-react-table-docs/components/mdx/BlogAuthor.tsx @@ -0,0 +1,56 @@ +import Image from 'next/image'; +import { Box, Anchor, Stack, Title, Text } from '@mantine/core'; + +interface Props { + author?: string; + authorImage?: string; + authorLink?: string; + publishDate: string; +} + +export const BlogAuthor = ({ + author = 'Kevin Van Cott', + authorImage = '/contributors/kevinvancott.jpg', + authorLink = 'https://www.kevinvancott.dev', + publishDate, +}: Props) => { + return ( + + + + By{' '} + + {author} + + + author + + + Published: {new Date(publishDate).toLocaleDateString()} + + + ); +}; diff --git a/apps/mantine-react-table-docs/components/mdx/mdxComponents.tsx b/apps/mantine-react-table-docs/components/mdx/mdxComponents.tsx index 0b4ec8183..4161f0452 100644 --- a/apps/mantine-react-table-docs/components/mdx/mdxComponents.tsx +++ b/apps/mantine-react-table-docs/components/mdx/mdxComponents.tsx @@ -1,4 +1,4 @@ -import { Divider, Text, Title } from '@mantine/core'; +import { Divider, Text, Title } from '@mantine/core'; import { Blockquote } from './Blockquote'; import { SampleCodeSnippet } from './SampleCodeSnippet'; import { LinkHeading } from './LinkHeading'; diff --git a/apps/mantine-react-table-docs/components/navigation/Footer.tsx b/apps/mantine-react-table-docs/components/navigation/Footer.tsx index 5f91415ae..ce693509f 100644 --- a/apps/mantine-react-table-docs/components/navigation/Footer.tsx +++ b/apps/mantine-react-table-docs/components/navigation/Footer.tsx @@ -103,8 +103,7 @@ export const Footer = () => { items={ routes .find((item) => item.href === '/docs/api') - ?.items?.find((item) => item.label === 'Options') - ?.items ?? [] + ?.items?.find((item) => item.label === 'Options')?.items ?? [] } isFooter /> diff --git a/apps/mantine-react-table-docs/components/navigation/TopBar.tsx b/apps/mantine-react-table-docs/components/navigation/TopBar.tsx index 4757ce6ce..9d7707f69 100644 --- a/apps/mantine-react-table-docs/components/navigation/TopBar.tsx +++ b/apps/mantine-react-table-docs/components/navigation/TopBar.tsx @@ -86,7 +86,7 @@ export const TopBar = ({ navOpen, setNavOpen }: Props) => { })} > - {(!isDesktop || pathname === "/") && ( + {(!isDesktop || pathname === '/') && ( = [ }, ], }, - // { - // label: 'Blog', - // href: '/blog', - // items: [ - // { - // href: '/blog', - // label: 'Blog', - // }, - // ], - // }, + { + label: 'Blog', + href: '/blog', + items: [ + { + href: '/blog/introducing-mantine-react-table', + label: 'Introducing Mantine React Table', + }, + ], + }, { label: 'Other', href: '#', diff --git a/apps/mantine-react-table-docs/example-groups/BasicExamples.tsx b/apps/mantine-react-table-docs/example-groups/BasicExamples.tsx index 85935bbe1..a01105a4a 100644 --- a/apps/mantine-react-table-docs/example-groups/BasicExamples.tsx +++ b/apps/mantine-react-table-docs/example-groups/BasicExamples.tsx @@ -20,7 +20,6 @@ const BasicExamples = ({ isPage = false }) => { isPage ? push(newPath as string) : setActiveTab(newPath as string) } keepMounted={false} - > Basic diff --git a/apps/mantine-react-table-docs/examples/advanced/index.tsx b/apps/mantine-react-table-docs/examples/advanced/index.tsx index 43a6b9d6c..e1b52987d 100644 --- a/apps/mantine-react-table-docs/examples/advanced/index.tsx +++ b/apps/mantine-react-table-docs/examples/advanced/index.tsx @@ -4,7 +4,7 @@ const JS = require('!!raw-loader!./sandbox/src/JS.js').default; const TS = require('!!raw-loader!./sandbox/src/TS.tsx').default; const Legacy = require('!!raw-loader!./sandbox/src/Legacy.tsx').default; -const ExampleTable = ({showTopRow = true}) => { +const ExampleTable = ({ showTopRow = true }) => { return ( { +const ExampleTable = ({ showTopRow = true }) => { return ( { mantinePaginationProps: { rowsPerPageOptions: ['5', '10', '15'], }, - paginationDisplayMode: 'pages' + paginationDisplayMode: 'pages', }); return ( diff --git a/apps/mantine-react-table-docs/examples/custom-headless/sandbox/src/TS.tsx b/apps/mantine-react-table-docs/examples/custom-headless/sandbox/src/TS.tsx index fb82455ba..5fe6b6d81 100644 --- a/apps/mantine-react-table-docs/examples/custom-headless/sandbox/src/TS.tsx +++ b/apps/mantine-react-table-docs/examples/custom-headless/sandbox/src/TS.tsx @@ -46,7 +46,7 @@ const Example = () => { mantinePaginationProps: { rowsPerPageOptions: ['5', '10', '15'], }, - paginationDisplayMode: 'pages' + paginationDisplayMode: 'pages', }); return ( diff --git a/apps/mantine-react-table-docs/examples/enable-column-pinning/sandbox/src/JS.js b/apps/mantine-react-table-docs/examples/enable-column-pinning/sandbox/src/JS.js index 0e6f7ea67..dd2a7962a 100644 --- a/apps/mantine-react-table-docs/examples/enable-column-pinning/sandbox/src/JS.js +++ b/apps/mantine-react-table-docs/examples/enable-column-pinning/sandbox/src/JS.js @@ -1,5 +1,5 @@ import { useMemo } from 'react'; -import { MantineReactTable, type MRT_ColumnDef } from 'mantine-react-table'; +import { MantineReactTable } from 'mantine-react-table'; import { data } from './makeData'; const Example = () => { diff --git a/apps/mantine-react-table-docs/examples/enable-sticky-header/sandbox/src/JS.js b/apps/mantine-react-table-docs/examples/enable-sticky-header/sandbox/src/JS.js index a8bd0a617..e5318fd45 100644 --- a/apps/mantine-react-table-docs/examples/enable-sticky-header/sandbox/src/JS.js +++ b/apps/mantine-react-table-docs/examples/enable-sticky-header/sandbox/src/JS.js @@ -1,6 +1,6 @@ import { useMemo } from 'react'; import { MantineReactTable } from 'mantine-react-table'; -import { data, type Person } from './makeData'; +import { data } from './makeData'; const Example = () => { const columns = useMemo( diff --git a/apps/mantine-react-table-docs/examples/localization-i18n-da/sandbox/src/JS.js b/apps/mantine-react-table-docs/examples/localization-i18n-da/sandbox/src/JS.js index c9d77dd60..6ec4a7308 100644 --- a/apps/mantine-react-table-docs/examples/localization-i18n-da/sandbox/src/JS.js +++ b/apps/mantine-react-table-docs/examples/localization-i18n-da/sandbox/src/JS.js @@ -7,7 +7,7 @@ import { MRT_Localization_DA } from 'mantine-react-table/locales/da'; //mock data import { data } from './makeData'; -const columns: MRT_ColumnDef[] = [ +const columns = [ { accessorKey: 'firstName', header: 'Fornavn', diff --git a/apps/mantine-react-table-docs/examples/localization-i18n-nl/sandbox/src/JS.js b/apps/mantine-react-table-docs/examples/localization-i18n-nl/sandbox/src/JS.js index 9391b039b..51d08e7c3 100644 --- a/apps/mantine-react-table-docs/examples/localization-i18n-nl/sandbox/src/JS.js +++ b/apps/mantine-react-table-docs/examples/localization-i18n-nl/sandbox/src/JS.js @@ -1,5 +1,5 @@ //Import Mantine React Table and its Types -import { MantineReactTable, type MRT_ColumnDef } from 'mantine-react-table'; +import { MantineReactTable } from 'mantine-react-table'; //Import Mantine React Table Translations import { MRT_Localization_NL } from 'mantine-react-table/locales/nl'; diff --git a/apps/mantine-react-table-docs/examples/localization-i18n-sr-Cyrl-RS/sandbox/src/JS.js b/apps/mantine-react-table-docs/examples/localization-i18n-sr-Cyrl-RS/sandbox/src/JS.js index cffd5053e..9f8b191fa 100644 --- a/apps/mantine-react-table-docs/examples/localization-i18n-sr-Cyrl-RS/sandbox/src/JS.js +++ b/apps/mantine-react-table-docs/examples/localization-i18n-sr-Cyrl-RS/sandbox/src/JS.js @@ -5,7 +5,7 @@ import { MantineReactTable } from 'mantine-react-table'; import { MRT_Localization_SR_CYRL_RS } from 'mantine-react-table/locales/sr-Cyrl-RS'; //mock data -import { data, type Person } from './makeData'; +import { data } from './makeData'; const columns = [ { diff --git a/apps/mantine-react-table-docs/examples/minimal/index.tsx b/apps/mantine-react-table-docs/examples/minimal/index.tsx index a381fa3a4..30bcfc4e2 100644 --- a/apps/mantine-react-table-docs/examples/minimal/index.tsx +++ b/apps/mantine-react-table-docs/examples/minimal/index.tsx @@ -4,7 +4,7 @@ const JS = require('!!raw-loader!./sandbox/src/JS.js').default; const TS = require('!!raw-loader!./sandbox/src/TS.tsx').default; const Legacy = require('!!raw-loader!./sandbox/src/Legacy.tsx').default; -const ExampleTable = ({showTopRow = true}) => { +const ExampleTable = ({ showTopRow = true }) => { return ( + Mantine React Table Blog + + + +## Blog + + item.href === '/blog').items} +/> diff --git a/apps/mantine-react-table-docs/pages/blog/introducing-mantine-react-table.mdx b/apps/mantine-react-table-docs/pages/blog/introducing-mantine-react-table.mdx new file mode 100644 index 000000000..2f0ed31cf --- /dev/null +++ b/apps/mantine-react-table-docs/pages/blog/introducing-mantine-react-table.mdx @@ -0,0 +1,205 @@ +import Head from 'next/head'; +import Image from 'next/image'; +import { BlogAuthor } from '../../components/mdx/BlogAuthor'; + + + {'Introducing Mantine React Table V1 - MRT Blog'} + +