diff --git a/docs/src/Pages/GettingStarted/Installation.jsx b/docs/src/Pages/GettingStarted/Installation.jsx index 4e809b4683da16..4783d6d9531542 100644 --- a/docs/src/Pages/GettingStarted/Installation.jsx +++ b/docs/src/Pages/GettingStarted/Installation.jsx @@ -5,7 +5,7 @@ import { Typography } from '@material-ui/core'; // eslint-disable-next-line import muiPickerProviderCode from '!raw-loader!./MuiPickersProvider.example.jsx'; -const installLibCode = `npm i @date-io/date-fns date-fns@2.0.0-alpha.16 +const installLibCode = `npm i @date-io/date-fns date-fns@2.0.0-alpha.25 // or npm i @date-io/moment moment // or @@ -17,7 +17,7 @@ const Installation = () => ( Installation - Available as + Available as{' '} ( - We are providing interfaces for + We are providing interfaces for{' '} moment -  , + ,{' '} - date-fns 2 + date-fns 2{' '} - and + and{' '} luxon - . P.S. If you are not using moment in the project (or dont have it in the + P.S. If you are not using moment in the project (or dont have it in the bundle already) we suggest using date-fns, because it is much more lightweight and will be correctly tree-shaken from the bundle. - Note, that we support only 2.0.0-alpha.16 version of date-fns for now (see -   - - #414 - - ). Stay tuned! + Note, that we support only 2.0.0-alpha versions of date-fns for now. - + Teach pickers how to use one of that library using MuiPickersUtilsProvider. This component takes an utils property, and makes it available down the React diff --git a/docs/src/Pages/GettingStarted/ParsingDates.jsx b/docs/src/Pages/GettingStarted/ParsingDates.jsx index d6043754596f1d..d335c0311b201b 100644 --- a/docs/src/Pages/GettingStarted/ParsingDates.jsx +++ b/docs/src/Pages/GettingStarted/ParsingDates.jsx @@ -7,15 +7,15 @@ const ParsingDates = () => ( Parsing dates - + Material-UI pickers rely on the date management library when the date should be parsed. For any prop-types, that accept actually the date (e.g. - minDate, - maxDate) accept string, number, Date - object and so on. + minDate , + maxDate ) accept string, number, + Date object and so on. - + Find more information about parsing dates in docs for your library: @@ -35,10 +35,10 @@ const ParsingDates = () => ( - + Pass any value to the picker, and if it won`t be parsed as expected feel - free to open issue on our - github + free to open issue on our{' '} + github{' '} 😎 diff --git a/lib/.size-snapshot.json b/lib/.size-snapshot.json index 4c39ca306acfc1..470b2b5e764a80 100644 --- a/lib/.size-snapshot.json +++ b/lib/.size-snapshot.json @@ -1,15 +1,15 @@ { "build/dist/material-ui-pickers.esm.js": { - "bundled": 114113, - "minified": 67041, - "gzipped": 14575, + "bundled": 114136, + "minified": 67061, + "gzipped": 14590, "treeshaked": { "rollup": { - "code": 49331, + "code": 49351, "import_statements": 1317 }, "webpack": { - "code": 56135 + "code": 56155 } } }, diff --git a/lib/src/DateTimePicker/DateTimePickerModal.tsx b/lib/src/DateTimePicker/DateTimePickerModal.tsx index 7ca260706846a9..6464ee1e2174a8 100644 --- a/lib/src/DateTimePicker/DateTimePickerModal.tsx +++ b/lib/src/DateTimePicker/DateTimePickerModal.tsx @@ -41,7 +41,8 @@ export const DateTimePickerModal: React.SFC< } = props; // do not show tabs for small screens - const toShowTabs = showTabs && window && window.innerHeight > 667; + const toShowTabs = + showTabs && typeof window !== 'undefined' && window.innerHeight > 667; return ( {({