@mui/x-data-grid-generator 6.5.0 → 6.6.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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,82 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## 6.6.0
7
+
8
+ _Jun 1, 2023_
9
+
10
+ We'd like to offer a big thanks to the 15 contributors who made this release possible. Here are some highlights ✨:
11
+
12
+ - 🚀 New date time picking UI on [`DesktopDateTimePicker`](https://mui.com/x/react-date-pickers/date-time-picker/)
13
+
14
+ <img src="https://user-images.githubusercontent.com/4941090/242533399-2b106390-8158-4aba-9ca4-b621c6310977.gif" width="628" />
15
+
16
+ - 🚀 Performance improvements
17
+ - 🐞 Bugfixes
18
+ - 📚 Documentation improvements
19
+ - 🌍 Improve Dutch (nl-NL) and French (fr-FR) locales on the data grid
20
+ - 🌍 Add Vietnamese (vi-VN) locale on the pickers
21
+
22
+ ### `@mui/x-data-grid@v6.6.0` / `@mui/x-data-grid-pro@v6.6.0` / `@mui/x-data-grid-premium@v6.6.0`
23
+
24
+ #### Changes
25
+
26
+ - [DataGrid] Support data attributes (#8845) @romgrk
27
+ - [DataGrid] Avoid allocations in `hydrateRowsMeta` (#9121) @romgrk
28
+ - [DataGrid] Fix filter input select accessibility (#9018) @Jul13nT
29
+ - [DataGrid] Fix accessibility issues in panels and toolbar buttons (#8862) @romgrk
30
+ - [DataGrid] Fix `onCellEditStop` not invoked (#8857) @romgrk
31
+ - [DataGridPro] Fix auto-scroll when reordering columns (#8856) @m4theushw
32
+ - [DataGridPro] Fix row ID type casting in detail panels lookup (#8976) @minchaej
33
+ - [DataGridPro] Emit `columnWidthChange` event on `touchEnd` of column resize (#8669) @MBilalShafi
34
+ - [DataGridPro] Do not apply filters on `rowExpansionChange` (#8671) @cherniavskii
35
+ - [DataGridPro] Prevent click event on sorting after a resize (#9117) @romgrk
36
+ - [DataGridPremium] Improve Excel export interface (#9128) @TiagoPortfolio
37
+ - [l10n] Improve Dutch (nl-NL) locale (#9043) @thedutchruben
38
+ - [l10n] Improve French (fr-FR) locale (#9109) @Jul13nT
39
+
40
+ ### `@mui/x-date-pickers@v6.6.0` / `@mui/x-date-pickers-pro@v6.6.0`
41
+
42
+ #### Changes
43
+
44
+ - [fields] Allow to explicitly define the reference value and improve its default value (#9019) @flaviendelangle
45
+ - [l10n] Add Vietnamese (vi-VN) locale (#9099) @nhannt201
46
+ - [pickers] Add `DigitalClock` to `DesktopDateTimePicker` (#8946) @LukasTy
47
+ - [pickers] Add support for timezones on the adapters (#9068) @flaviendelangle
48
+ - [pickers] Fix `MonthCalendar` and `YearCalendar` disabled validation (#9149) @LukasTy
49
+ - [pickers] Fix bug when fields have a unique section (#9110) @alexfauquette
50
+ - [pickers] Fix focus jumping on Safari (#9072) @LukasTy
51
+ - [pickers] Use the locale start of the week in `getWeekArray` (#9176) @flaviendelangle
52
+
53
+ ### Docs
54
+
55
+ - [docs] Add single input range picker demo (#9159) @LukasTy
56
+ - [docs] Align `DateCalendar` demo views with labels (#9152) @LukasTy
57
+ - [docs] Clarify the peer dependency with React (#9067) @oliviertassinari
58
+ - [docs] Fix Norwegian locale typo (#9168) @LukasTy
59
+ - [docs] Fix column menu item demo (#9071) @MBilalShafi
60
+ - [docs] Improve localization table progress bars (#9033) @noraleonte
61
+ - [docs] Smooth performance animation (#8986) @oliviertassinari
62
+ - [docs] Use responsive time and date time pickers and the views sections (#9127) @flaviendelangle
63
+ - [docs] Reduce layout shift in grid demo (#9132) @oliviertassinari
64
+ - [docs] Fix tree data children lazy-loading demo (#8840) @yaredtsy
65
+ - [docs] Improve filtering docs discoverability (#9074) @MBilalShafi
66
+
67
+ ### Core
68
+
69
+ - [core] Allow string literals as keys in `localesText` (#9045) @MBilalShafi
70
+ - [core] Fix `randomInt` producing values exceeding `max` value (#9086) @cherniavskii
71
+ - [core] Fix flaky test on `dateWithTimezone` adapter test (#9129) @flaviendelangle
72
+ - [core] Lock `@types/node` on v18 (#9107) @LukasTy
73
+ - [core] Remove `cross-fetch` dependency (#9108) @LukasTy
74
+ - [core] Remove `createDetectElementResize()` replaced with `ResizeObserver` (#9015) @oliviertassinari
75
+ - [core] Upgrade monorepo (#9027) @m4theushw
76
+ - [core] Upgrade monorepo (#9106) @LukasTy
77
+ - [charts] Fix proptypes (#9125) @LukasTy
78
+ - [charts] Generate the charts proptypes (#9010) @alexfauquette
79
+ - [charts] Manage series stacking (#8888) @alexfauquette
80
+ - [license] List side effects in the license package (#9092) @cherniavskii
81
+
6
82
  ## v6.5.0
7
83
 
8
84
  _May 19, 2023_
@@ -102,7 +178,7 @@ We'd like to offer a big thanks to the 12 contributors who made this release pos
102
178
 
103
179
  ### Docs
104
180
 
105
- - [docs] Fix date pickers typo in the docs (#8939) @richbustos
181
+ - [docs] Fix date pickers typo in the docs (#8939) @richbustos
106
182
  - [docs] Fix master detail demo (#8894) @m4theushw
107
183
  - [docs] Fix typo in clipboard docs (#8971) @MBilalShafi
108
184
  - [docs] Reduce list of dependencies in Codesandbox/Stackblitz demos (#8535) @cherniavskii
@@ -4440,7 +4516,7 @@ We'd like to offer a big thanks to the 15 contributors who made this release pos
4440
4516
 
4441
4517
  - 👔 **Excel export**. You can find this new Premium feature at: https://mui.com/x/react-data-grid/export/#excel-export.
4442
4518
 
4443
- - 🔎 **Quick filtering**. You can now add a quick filtering search bar to your grid. To do so, either pass `showQuickFilter` prop to the `<GridToolbar />` or use the `<GridToolbarQuickFilter />` component in your custom toolbar. More information about how to customize the filtering logic is in the [documentation](https://mui.com/x/react-data-grid/filtering/#quick-filter).
4519
+ - 🔎 **Quick filtering**. You can now add a quick filtering search bar to your grid. To do so, either pass `showQuickFilter` prop to the `<GridToolbar />` or use the `<GridToolbarQuickFilter />` component in your custom toolbar. More information about how to customize the filtering logic is in the [documentation](https://mui.com/x/react-data-grid/filtering/quick-filter/).
4444
4520
 
4445
4521
  <img src="https://user-images.githubusercontent.com/13808724/167700105-5a5acc7c-5463-4871-8514-3d09e2f365ae.png" width="724">
4446
4522
 
package/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-generator v6.5.0
2
+ * @mui/x-data-grid-generator v6.6.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
package/legacy/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-generator v6.5.0
2
+ * @mui/x-data-grid-generator v6.6.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -79,7 +79,10 @@ export var random = function random(min, max) {
79
79
  });
80
80
  };
81
81
  export var randomInt = function randomInt(min, max) {
82
- return Math.floor(random(0, 1) * (max - min + 1) + min);
82
+ return chance.integer({
83
+ min: min,
84
+ max: max
85
+ });
83
86
  };
84
87
  export var randomPrice = function randomPrice() {
85
88
  var min = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
package/modern/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-generator v6.5.0
2
+ * @mui/x-data-grid-generator v6.6.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -71,7 +71,10 @@ export const random = (min, max) => chance.floating({
71
71
  min,
72
72
  max
73
73
  });
74
- export const randomInt = (min, max) => Math.floor(random(0, 1) * (max - min + 1) + min);
74
+ export const randomInt = (min, max) => chance.integer({
75
+ min,
76
+ max
77
+ });
75
78
  export const randomPrice = (min = 0, max = 100000) => Number(random(min, max).toFixed(2));
76
79
  export const randomRate = () => random(0, 1);
77
80
  export const randomDate = (start, end) => new Date(start.getTime() + chance.floating({
package/node/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @mui/x-data-grid-generator v6.5.0
2
+ * @mui/x-data-grid-generator v6.6.0
3
3
  *
4
4
  * @license MUI X Commercial
5
5
  * This source code is licensed under the commercial license found in the
@@ -79,7 +79,10 @@ const random = (min, max) => chance.floating({
79
79
  max
80
80
  });
81
81
  exports.random = random;
82
- const randomInt = (min, max) => Math.floor(random(0, 1) * (max - min + 1) + min);
82
+ const randomInt = (min, max) => chance.integer({
83
+ min,
84
+ max
85
+ });
83
86
  exports.randomInt = randomInt;
84
87
  const randomPrice = (min = 0, max = 100000) => Number(random(min, max).toFixed(2));
85
88
  exports.randomPrice = randomPrice;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mui/x-data-grid-generator",
3
- "version": "6.5.0",
3
+ "version": "6.6.0",
4
4
  "description": "Generate fake data for demo purposes only.",
5
5
  "author": "MUI Team",
6
6
  "main": "./node/index.js",
@@ -20,8 +20,8 @@
20
20
  },
21
21
  "dependencies": {
22
22
  "@babel/runtime": "^7.21.0",
23
- "@mui/base": "^5.0.0-beta.0",
24
- "@mui/x-data-grid-premium": "6.5.0",
23
+ "@mui/base": "^5.0.0-beta.2",
24
+ "@mui/x-data-grid-premium": "6.6.0",
25
25
  "chance": "^1.1.11",
26
26
  "clsx": "^1.2.1",
27
27
  "lru-cache": "^7.18.3"
@@ -29,7 +29,7 @@
29
29
  "peerDependencies": {
30
30
  "@mui/icons-material": "^5.4.1",
31
31
  "@mui/material": "^5.4.1",
32
- "react": "^17.0.2 || ^18.0.0"
32
+ "react": "^17.0.0 || ^18.0.0"
33
33
  },
34
34
  "setupFiles": [
35
35
  "<rootDir>/src/setupTests.js"
@@ -1,6 +1,6 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
3
  export declare function renderAvatar(params: GridRenderCellParams<{
4
4
  name: string;
5
5
  color: string;
6
- }, any, any>): "" | JSX.Element;
6
+ }, any, any>): "" | React.JSX.Element;
@@ -1,4 +1,4 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
3
  import { CountryIsoOption } from '../services/static-data';
4
- export declare function renderCountry(params: GridRenderCellParams<CountryIsoOption, any, any>): "" | JSX.Element | null;
4
+ export declare function renderCountry(params: GridRenderCellParams<CountryIsoOption, any, any>): "" | React.JSX.Element | null;
@@ -1,4 +1,4 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderEditCellParams } from '@mui/x-data-grid-premium';
3
3
  import { CountryIsoOption } from '../services/static-data';
4
- export declare function renderEditCountry(params: GridRenderEditCellParams<CountryIsoOption>): JSX.Element;
4
+ export declare function renderEditCountry(params: GridRenderEditCellParams<CountryIsoOption>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderEditCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderEditCurrency(params: GridRenderEditCellParams<any, string>): JSX.Element;
3
+ export declare function renderEditCurrency(params: GridRenderEditCellParams<any, string>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderEditCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderEditIncoterm(params: GridRenderEditCellParams<any, string | null>): JSX.Element;
3
+ export declare function renderEditIncoterm(params: GridRenderEditCellParams<any, string | null>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderEditCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderEditProgress(params: GridRenderEditCellParams<any, number>): JSX.Element;
3
+ export declare function renderEditProgress(params: GridRenderEditCellParams<any, number>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderEditCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderEditRating(params: GridRenderEditCellParams<any, number>): JSX.Element;
3
+ export declare function renderEditRating(params: GridRenderEditCellParams<any, number>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderEditCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderEditStatus(params: GridRenderEditCellParams<any, string>): JSX.Element;
3
+ export declare function renderEditStatus(params: GridRenderEditCellParams<any, string>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderEmail(params: GridRenderCellParams<any, string, any>): JSX.Element;
3
+ export declare function renderEmail(params: GridRenderCellParams<any, string, any>): React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderIncoterm(params: GridRenderCellParams<any, string | null, any>): JSX.Element;
3
+ export declare function renderIncoterm(params: GridRenderCellParams<any, string | null, any>): React.JSX.Element;
@@ -6,5 +6,5 @@ interface DemoLinkProps {
6
6
  tabIndex: number;
7
7
  }
8
8
  export declare const DemoLink: React.NamedExoticComponent<DemoLinkProps>;
9
- export declare function renderLink(params: GridRenderCellParams<any, string, any>): "" | JSX.Element;
9
+ export declare function renderLink(params: GridRenderCellParams<any, string, any>): "" | React.JSX.Element;
10
10
  export {};
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderPnl(params: GridRenderCellParams<any, number, any>): "" | JSX.Element;
3
+ export declare function renderPnl(params: GridRenderCellParams<any, number, any>): "" | React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderProgress(params: GridRenderCellParams<any, number, any>): "" | JSX.Element | null;
3
+ export declare function renderProgress(params: GridRenderCellParams<any, number, any>): "" | React.JSX.Element | null;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderRating(params: GridRenderCellParams<any, number, any>): "" | JSX.Element | null;
3
+ export declare function renderRating(params: GridRenderCellParams<any, number, any>): "" | React.JSX.Element | null;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderStatus(params: GridRenderCellParams<any, string>): "" | JSX.Element;
3
+ export declare function renderStatus(params: GridRenderCellParams<any, string>): "" | React.JSX.Element;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
1
+ import * as React from 'react';
2
2
  import { GridRenderCellParams } from '@mui/x-data-grid-premium';
3
- export declare function renderTotalPrice(params: GridRenderCellParams<any, number>): "" | JSX.Element | null;
3
+ export declare function renderTotalPrice(params: GridRenderCellParams<any, number>): "" | React.JSX.Element | null;
@@ -72,7 +72,10 @@ export const random = (min, max) => chance.floating({
72
72
  min,
73
73
  max
74
74
  });
75
- export const randomInt = (min, max) => Math.floor(random(0, 1) * (max - min + 1) + min);
75
+ export const randomInt = (min, max) => chance.integer({
76
+ min,
77
+ max
78
+ });
76
79
  export const randomPrice = (min = 0, max = 100000) => Number(random(min, max).toFixed(2));
77
80
  export const randomRate = () => random(0, 1);
78
81
  export const randomDate = (start, end) => new Date(start.getTime() + chance.floating({