From 94dd7adcb2c927db3cd3723be071ced53d7b910a Mon Sep 17 00:00:00 2001 From: flavien Date: Thu, 7 Nov 2024 13:25:52 +0100 Subject: [PATCH] [docs] Improve migration guide for the removal of LicenseInfo from the pickers package --- .../migration-pickers-v7/migration-pickers-v7.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docs/data/migration/migration-pickers-v7/migration-pickers-v7.md b/docs/data/migration/migration-pickers-v7/migration-pickers-v7.md index eec0a9ec1419..c78ed186f4d5 100644 --- a/docs/data/migration/migration-pickers-v7/migration-pickers-v7.md +++ b/docs/data/migration/migration-pickers-v7/migration-pickers-v7.md @@ -365,6 +365,18 @@ If you were using them, you need to replace them with the following code: UseDateTimeFieldProps; ``` +## Stop using `LicenseInfo` from `@mui/x-date-pickers-pro` + +The `LicenseInfo` object is not exported from the `@mui/x-date-pickers-pro` package anymore. +You can import it from `@mui/x-license` instead: + +```diff +-import { LicenseInfo } from '@mui/x-date-pickers-pro'; ++import { LicenseInfo } from '@mui/x-license'; + + LicenseInfo.setLicenseKey('YOUR_LICENSE_KEY'); +``` + ## Stop passing `utils` and the date object to some translation keys Some translation keys no longer require `utils` and the date object as parameters, but only the formatted value as a string. The keys affected by this changes are: `clockLabelText`, `openDatePickerDialogue` and `openTimePickerDialogue`.