From a1710fce8b0ba0002d1de799e217c9b6c98da861 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Fri, 10 Sep 2021 12:20:43 +0100 Subject: [PATCH 1/6] Promote the storybook, replace old website --- .github/workflows/ci.yml | 21 +++++---------------- CHANGELOG.md | 4 ++-- README.md | 31 +++++++++++++++---------------- src/DataGrid.tsx | 5 +++++ 4 files changed, 27 insertions(+), 34 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8466ba1758..e4ae94c44d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -63,25 +63,14 @@ jobs: run: | git config --global user.email 'action@github.com' git config --global user.name 'GitHub Action' - # - name: Deploy main - # if: github.ref == 'refs/heads/main' - # run: | - # git fetch origin gh-pages - # git worktree add gh-pages gh-pages - # git rm -r . - # git checkout gh-pages -- canary - # mv ../storybook-static/* . - # git add . - # git commit --allow-empty -m "main storybook deployment" - # git push -f https://adazzle:${{secrets.GITHUB_TOKEN}}@github.com/adazzle/react-data-grid.git - - name: Deploy main + - name: Deploy gh-pages if: github.ref == 'refs/heads/main' run: | git fetch origin gh-pages git worktree add gh-pages gh-pages cd gh-pages - git rm -r --ignore-unmatch canary - mv ../storybook-static canary - git add canary - git commit --allow-empty -m "beta storybook deployment" + git rm -r . + mv ../storybook-static/* . + git add . + git commit --allow-empty -m "gh-pages deployment" git push -f https://adazzle:${{secrets.GITHUB_TOKEN}}@github.com/adazzle/react-data-grid.git diff --git a/CHANGELOG.md b/CHANGELOG.md index 21d609b52f..1c080a858c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -136,7 +136,7 @@ ## v7.0.0-canary.22 -- Add Grouping ([PR](https://github.com/adazzle/react-data-grid/pull/2106)). Check the new [example](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--grouping). +- Add Grouping ([PR](https://github.com/adazzle/react-data-grid/pull/2106)). Check the new [example](https://adazzle.github.io/react-data-grid/?path=/story/demos--grouping). - (Breaking) Removed `height` and `width` props and added new `className` and `style` props. We are now using `ResizeObserver` to calculate all the grid dimensions ([PR](https://github.com/adazzle/react-data-grid/pull/2130)) - (Breaking) Removed formatterOptions. Grid now handles formatter focus internally so this prop is no longer required ([PR](https://github.com/adazzle/react-data-grid/pull/2138)) - Added support for React 17 @@ -217,7 +217,7 @@ - ⚠️ `height` - ⚠️ `cellContentRenderer` - ⚠️ `contextMenu` - - Check the [Context Menu](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--context-menu) example + - Check the [Context Menu](https://adazzle.github.io/react-data-grid/?path=/story/demos--context-menu) example - ⚠️ `enableCellSelect` - ⚠️ `enableCellAutoFocus` - ⚠️ `getValidFilterValues` diff --git a/README.md b/README.md index 9c6b79ee3a..45dbfaff98 100644 --- a/README.md +++ b/README.md @@ -23,29 +23,28 @@ - Tree-shaking support and only [one npm dependency](package.json) to keep your bundles slim - Great performance thanks to virtualization: columns and rows outside the viewport are not rendered - Strictly typed with TypeScript -- [Keyboard accessibility](<(https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features)>) +- [Keyboard accessibility](<(https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features)>) - Light and dark mode support out of the box. The light or dark themes can be enforced using the `rdg-light` or `rdg-dark` classes. -- [Frozen columns](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) -- [Column resizing](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) -- [Multi-column sorting](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) +- [Frozen columns](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) +- [Column resizing](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) +- [Multi-column sorting](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) - Click on a sortable column header to toggle between its ascending/descending sort order - Ctrl+Click / Meta+Click to sort an additional column -- [Column spanning](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--column-spanning) -- [Row selection](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) -- [Row grouping](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--grouping) -- [Summary rows](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) -- [Dynamic row heights](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--variable-row-height) -- [No rows fallback](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--no-rows) -- [Cell formatting](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) -- [Cell editing](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--common-features) -- [Cell copy / pasting](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--all-features) -- [Cell value dragging / filling](https://adazzle.github.io/react-data-grid/canary/?path=/story/demos--all-features) +- [Column spanning](https://adazzle.github.io/react-data-grid/?path=/story/demos--column-spanning) +- [Row selection](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) +- [Row grouping](https://adazzle.github.io/react-data-grid/?path=/story/demos--grouping) +- [Summary rows](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) +- [Dynamic row heights](https://adazzle.github.io/react-data-grid/?path=/story/demos--variable-row-height) +- [No rows fallback](https://adazzle.github.io/react-data-grid/?path=/story/demos--no-rows) +- [Cell formatting](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) +- [Cell editing](https://adazzle.github.io/react-data-grid/?path=/story/demos--common-features) +- [Cell copy / pasting](https://adazzle.github.io/react-data-grid/?path=/story/demos--all-features) +- [Cell value dragging / filling](https://adazzle.github.io/react-data-grid/?path=/story/demos--all-features) ## Links -- [Website](https://adazzle.github.io/react-data-grid/canary/) +- [Website](https://adazzle.github.io/react-data-grid/) - [Source code](stories) -- [Old website for react-data-grid v5](https://adazzle.github.io/react-data-grid/) - [Changelog](CHANGELOG.md) - [Contributing](CONTRIBUTING.md) diff --git a/src/DataGrid.tsx b/src/DataGrid.tsx index 3cdc22836e..793524df95 100644 --- a/src/DataGrid.tsx +++ b/src/DataGrid.tsx @@ -1141,6 +1141,11 @@ function DataGrid( ); } +/** + * Check the README for API documentation: + * https://github.com/adazzle/react-data-grid/blob/main/README.md#api + * @see {@link DataGridProps} + */ export default forwardRef(DataGrid) as ( props: DataGridProps & RefAttributes ) => JSX.Element; From 1c7efee37e3cc03f20e05af4a1ef3c79cc18bde4 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Fri, 10 Sep 2021 12:30:06 +0100 Subject: [PATCH 2/6] tweak link text --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 45dbfaff98..01ee7edbbc 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ ## Links -- [Website](https://adazzle.github.io/react-data-grid/) +- [Examples website](https://adazzle.github.io/react-data-grid/) - [Source code](stories) - [Changelog](CHANGELOG.md) - [Contributing](CONTRIBUTING.md) From 2df1ae4e44b867c158ad6042a18725e1813055a1 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Fri, 10 Sep 2021 12:41:01 +0100 Subject: [PATCH 3/6] let's not push empty commits --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e4ae94c44d..a226de4361 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -72,5 +72,5 @@ jobs: git rm -r . mv ../storybook-static/* . git add . - git commit --allow-empty -m "gh-pages deployment" + git commit -m "gh-pages deployment" || echo "Nothing to commit" git push -f https://adazzle:${{secrets.GITHUB_TOKEN}}@github.com/adazzle/react-data-grid.git From baa43d6d50a4c44c3b8d4355afe21c11558f4c17 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Fri, 10 Sep 2021 12:44:56 +0100 Subject: [PATCH 4/6] This isn't actually preserved in the built types --- src/DataGrid.tsx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/DataGrid.tsx b/src/DataGrid.tsx index 793524df95..3cdc22836e 100644 --- a/src/DataGrid.tsx +++ b/src/DataGrid.tsx @@ -1141,11 +1141,6 @@ function DataGrid( ); } -/** - * Check the README for API documentation: - * https://github.com/adazzle/react-data-grid/blob/main/README.md#api - * @see {@link DataGridProps} - */ export default forwardRef(DataGrid) as ( props: DataGridProps & RefAttributes ) => JSX.Element; From eec47b0ca95ff5142c66af14d03d5ee6e3457c4a Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Mon, 13 Sep 2021 13:06:56 +0100 Subject: [PATCH 5/6] restore old pages --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a226de4361..dabbaf8b07 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -70,6 +70,7 @@ jobs: git worktree add gh-pages gh-pages cd gh-pages git rm -r . + git checkout gh-pages -- old mv ../storybook-static/* . git add . git commit -m "gh-pages deployment" || echo "Nothing to commit" From b2dab6fb2d22ff41e6309c102b1faaed9dae9fc8 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Mon, 13 Sep 2021 13:54:19 +0100 Subject: [PATCH 6/6] Bring back this line --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index acffc75f1e..da9a3b0603 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,7 @@ - [Examples website](https://adazzle.github.io/react-data-grid/) - [Source code](stories) +- [Old website for react-data-grid v6](https://adazzle.github.io/react-data-grid/old/) - [Changelog](CHANGELOG.md) - [Contributing](CONTRIBUTING.md)