@wordpress/date
Advanced tools
Comparing version 2.0.3 to 2.1.0
@@ -6,3 +6,8 @@ /** | ||
import 'moment-timezone'; | ||
import 'moment-timezone/moment-timezone-utils'; // Changes made here will likely need to be made in `lib/client-assets.php` as | ||
import 'moment-timezone/moment-timezone-utils'; | ||
/** | ||
* WordPress dependencies | ||
*/ | ||
import deprecated from '@wordpress/deprecated'; // Changes made here will likely need to be made in `lib/client-assets.php` as | ||
// well because it uses the `setSettings()` function to change these settings. | ||
@@ -98,3 +103,13 @@ | ||
export function __experimentalGetSettings() { | ||
return settings; | ||
} // deprecations | ||
export function getSettings() { | ||
deprecated('wp.date.getSettings', { | ||
version: '4.4', | ||
alternative: 'wp.date.__experimentalGetSettings', | ||
plugin: 'Gutenberg', | ||
hint: 'Unstable APIs are strongly discouraged to be used, and are subject to removal without notice.' | ||
}); | ||
return settings; | ||
@@ -101,0 +116,0 @@ } |
@@ -9,2 +9,3 @@ "use strict"; | ||
exports.setSettings = setSettings; | ||
exports.__experimentalGetSettings = __experimentalGetSettings; | ||
exports.getSettings = getSettings; | ||
@@ -23,5 +24,11 @@ exports.format = format; | ||
var _deprecated = _interopRequireDefault(require("@wordpress/deprecated")); | ||
/** | ||
* External dependencies | ||
*/ | ||
/** | ||
* WordPress dependencies | ||
*/ | ||
// Changes made here will likely need to be made in `lib/client-assets.php` as | ||
@@ -121,3 +128,14 @@ // well because it uses the `setSettings()` function to change these settings. | ||
function __experimentalGetSettings() { | ||
return settings; | ||
} // deprecations | ||
function getSettings() { | ||
(0, _deprecated.default)('wp.date.getSettings', { | ||
version: '4.4', | ||
alternative: 'wp.date.__experimentalGetSettings', | ||
plugin: 'Gutenberg', | ||
hint: 'Unstable APIs are strongly discouraged to be used, and are subject to removal without notice.' | ||
}); | ||
return settings; | ||
@@ -124,0 +142,0 @@ } |
@@ -1,3 +0,9 @@ | ||
## 2.1.0 (2018-09-26) | ||
## 2.1.0 (2018-10-29) | ||
### Breaking Change | ||
- Marked getSettings as experimental | ||
## 2.0.3 (2018-09-26) | ||
### New Features | ||
@@ -4,0 +10,0 @@ |
{ | ||
"name": "@wordpress/date", | ||
"version": "2.0.3", | ||
"version": "2.1.0", | ||
"description": "Date module for WordPress.", | ||
@@ -29,3 +29,3 @@ "author": "The WordPress Contributors", | ||
}, | ||
"gitHead": "840439b92819b8e46abb46bfd8768faed61f799e" | ||
"gitHead": "308f6aa950705531ef9d360dc88bb9f4194542f5" | ||
} |
@@ -8,2 +8,7 @@ /** | ||
/** | ||
* WordPress dependencies | ||
*/ | ||
import deprecated from '@wordpress/deprecated'; | ||
// Changes made here will likely need to be made in `lib/client-assets.php` as | ||
@@ -89,3 +94,14 @@ // well because it uses the `setSettings()` function to change these settings. | ||
*/ | ||
export function __experimentalGetSettings() { | ||
return settings; | ||
} | ||
// deprecations | ||
export function getSettings() { | ||
deprecated( 'wp.date.getSettings', { | ||
version: '4.4', | ||
alternative: 'wp.date.__experimentalGetSettings', | ||
plugin: 'Gutenberg', | ||
hint: 'Unstable APIs are strongly discouraged to be used, and are subject to removal without notice.', | ||
} ); | ||
return settings; | ||
@@ -92,0 +108,0 @@ } |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
95691
1119