@instructure/ui-i18n 8.12.1-snapshot.7 → 8.13.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,10 @@
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
+ # [8.13.0](https://github.com/instructure/instructure-ui/compare/v8.12.0...v8.13.0) (2021-12-01)
7
+
8
+ **Note:** Version bump only for package @instructure/ui-i18n
9
+
6
10
  # [8.12.0](https://github.com/instructure/instructure-ui/compare/v8.11.1...v8.12.0) (2021-11-17)
7
11
 
8
12
  ### Features
@@ -31,11 +31,10 @@ category: components/utilities
31
31
  ---
32
32
  @tsProps
33
33
  **/
34
- export const ApplyLocale = ({
35
- children,
36
- locale,
37
- timezone
38
- }) => {
34
+ export const ApplyLocale = _ref => {
35
+ let children = _ref.children,
36
+ locale = _ref.locale,
37
+ timezone = _ref.timezone;
39
38
  return /*#__PURE__*/React.createElement(ApplyLocaleContext.Provider, {
40
39
  value: {
41
40
  locale,
package/es/Locale.js CHANGED
@@ -38,7 +38,8 @@ const Locale = {
38
38
  * Return the locale from the browser
39
39
  * @returns {String} locale (defaults to 'en-US' if DOM cannot be accessed)
40
40
  */
41
- browserLocale(nav, hasDOM = canUseDOM) {
41
+ browserLocale(nav) {
42
+ let hasDOM = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : canUseDOM;
42
43
  if (nav) return nav.language;
43
44
  if (!hasDOM) return defaultLocale;
44
45
  const documentLanguage = window.document.documentElement.lang;
@@ -43,11 +43,10 @@ category: components/utilities
43
43
  ---
44
44
  @tsProps
45
45
  **/
46
- const ApplyLocale = ({
47
- children,
48
- locale,
49
- timezone
50
- }) => {
46
+ const ApplyLocale = _ref => {
47
+ let children = _ref.children,
48
+ locale = _ref.locale,
49
+ timezone = _ref.timezone;
51
50
  return /*#__PURE__*/_react.default.createElement(_ApplyLocaleContext.ApplyLocaleContext.Provider, {
52
51
  value: {
53
52
  locale,
package/lib/DateTime.js CHANGED
@@ -5,7 +5,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- exports.DateTime = exports.default = void 0;
8
+ exports.default = exports.DateTime = void 0;
9
9
 
10
10
  var _momentTimezone = _interopRequireDefault(require("moment-timezone"));
11
11
 
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.I18nPropTypes = exports.default = void 0;
6
+ exports.default = exports.I18nPropTypes = void 0;
7
7
 
8
8
  var _makeRequirable = require("@instructure/ui-prop-types/lib/makeRequirable.js");
9
9
 
package/lib/Locale.js CHANGED
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.Locale = exports.default = void 0;
6
+ exports.default = exports.Locale = void 0;
7
7
 
8
8
  var _canUseDOM = require("@instructure/ui-dom-utils/lib/canUseDOM.js");
9
9
 
@@ -46,7 +46,8 @@ const Locale = {
46
46
  * Return the locale from the browser
47
47
  * @returns {String} locale (defaults to 'en-US' if DOM cannot be accessed)
48
48
  */
49
- browserLocale(nav, hasDOM = _canUseDOM.canUseDOM) {
49
+ browserLocale(nav) {
50
+ let hasDOM = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : _canUseDOM.canUseDOM;
50
51
  if (nav) return nav.language;
51
52
  if (!hasDOM) return defaultLocale;
52
53
  const documentLanguage = window.document.documentElement.lang;
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.DIRECTION = exports.TextDirectionContext = exports.default = void 0;
6
+ exports.default = exports.TextDirectionContext = exports.DIRECTION = void 0;
7
7
 
8
8
  var _react = require("react");
9
9
 
@@ -7,7 +7,7 @@ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWild
7
7
  Object.defineProperty(exports, "__esModule", {
8
8
  value: true
9
9
  });
10
- exports.bidirectional = exports.default = void 0;
10
+ exports.default = exports.bidirectional = void 0;
11
11
 
12
12
  var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
13
13
 
@@ -3,8 +3,8 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.getTextDirection = getTextDirection;
7
6
  exports.default = void 0;
7
+ exports.getTextDirection = getTextDirection;
8
8
 
9
9
  var _canUseDOM = require("@instructure/ui-dom-utils/lib/canUseDOM.js");
10
10
 
package/lib/index.js CHANGED
@@ -15,16 +15,16 @@ Object.defineProperty(exports, "ApplyLocaleContext", {
15
15
  return _ApplyLocaleContext.ApplyLocaleContext;
16
16
  }
17
17
  });
18
- Object.defineProperty(exports, "bidirectional", {
18
+ Object.defineProperty(exports, "ApplyTextDirection", {
19
19
  enumerable: true,
20
20
  get: function () {
21
- return _bidirectional.bidirectional;
21
+ return _ApplyTextDirection.ApplyTextDirection;
22
22
  }
23
23
  });
24
- Object.defineProperty(exports, "textDirectionContextConsumer", {
24
+ Object.defineProperty(exports, "DIRECTION", {
25
25
  enumerable: true,
26
26
  get: function () {
27
- return _textDirectionContextConsumer.textDirectionContextConsumer;
27
+ return _TextDirectionContext.DIRECTION;
28
28
  }
29
29
  });
30
30
  Object.defineProperty(exports, "DateTime", {
@@ -33,12 +33,6 @@ Object.defineProperty(exports, "DateTime", {
33
33
  return _DateTime.DateTime;
34
34
  }
35
35
  });
36
- Object.defineProperty(exports, "getTextDirection", {
37
- enumerable: true,
38
- get: function () {
39
- return _getTextDirection.getTextDirection;
40
- }
41
- });
42
36
  Object.defineProperty(exports, "I18nPropTypes", {
43
37
  enumerable: true,
44
38
  get: function () {
@@ -51,22 +45,28 @@ Object.defineProperty(exports, "Locale", {
51
45
  return _Locale.Locale;
52
46
  }
53
47
  });
54
- Object.defineProperty(exports, "DIRECTION", {
48
+ Object.defineProperty(exports, "TextDirectionContext", {
55
49
  enumerable: true,
56
50
  get: function () {
57
- return _TextDirectionContext.DIRECTION;
51
+ return _TextDirectionContext.TextDirectionContext;
58
52
  }
59
53
  });
60
- Object.defineProperty(exports, "TextDirectionContext", {
54
+ Object.defineProperty(exports, "bidirectional", {
61
55
  enumerable: true,
62
56
  get: function () {
63
- return _TextDirectionContext.TextDirectionContext;
57
+ return _bidirectional.bidirectional;
64
58
  }
65
59
  });
66
- Object.defineProperty(exports, "ApplyTextDirection", {
60
+ Object.defineProperty(exports, "getTextDirection", {
67
61
  enumerable: true,
68
62
  get: function () {
69
- return _ApplyTextDirection.ApplyTextDirection;
63
+ return _getTextDirection.getTextDirection;
64
+ }
65
+ });
66
+ Object.defineProperty(exports, "textDirectionContextConsumer", {
67
+ enumerable: true,
68
+ get: function () {
69
+ return _textDirectionContextConsumer.textDirectionContextConsumer;
70
70
  }
71
71
  });
72
72
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@instructure/ui-i18n",
3
- "version": "8.12.1-snapshot.7+1e7ac8219",
3
+ "version": "8.13.0",
4
4
  "description": "Helper components and utilities for internationalization.",
5
5
  "author": "Instructure, Inc. Engineering and Product Design",
6
6
  "type": "commonjs",
@@ -24,18 +24,18 @@
24
24
  },
25
25
  "license": "MIT",
26
26
  "devDependencies": {
27
- "@instructure/ui-babel-preset": "8.12.1-snapshot.7+1e7ac8219",
28
- "@instructure/ui-test-utils": "8.12.1-snapshot.7+1e7ac8219",
27
+ "@instructure/ui-babel-preset": "8.13.0",
28
+ "@instructure/ui-test-utils": "8.13.0",
29
29
  "@types/hoist-non-react-statics": "^3.3.1"
30
30
  },
31
31
  "dependencies": {
32
32
  "@babel/runtime": "^7.13.10",
33
- "@instructure/shared-types": "8.12.1-snapshot.7+1e7ac8219",
34
- "@instructure/ui-decorator": "8.12.1-snapshot.7+1e7ac8219",
35
- "@instructure/ui-dom-utils": "8.12.1-snapshot.7+1e7ac8219",
36
- "@instructure/ui-prop-types": "8.12.1-snapshot.7+1e7ac8219",
37
- "@instructure/ui-react-utils": "8.12.1-snapshot.7+1e7ac8219",
38
- "@instructure/ui-utils": "8.12.1-snapshot.7+1e7ac8219",
33
+ "@instructure/shared-types": "8.13.0",
34
+ "@instructure/ui-decorator": "8.13.0",
35
+ "@instructure/ui-dom-utils": "8.13.0",
36
+ "@instructure/ui-prop-types": "8.13.0",
37
+ "@instructure/ui-react-utils": "8.13.0",
38
+ "@instructure/ui-utils": "8.13.0",
39
39
  "hoist-non-react-statics": "^3.3.2",
40
40
  "moment-timezone": "^0.5",
41
41
  "prop-types": "^15"
@@ -46,6 +46,5 @@
46
46
  "publishConfig": {
47
47
  "access": "public"
48
48
  },
49
- "sideEffects": false,
50
- "gitHead": "1e7ac821932a91fe9ef761c96f747c7ea1f3925a"
49
+ "sideEffects": false
51
50
  }
package/LICENSE.md DELETED
@@ -1,27 +0,0 @@
1
- ---
2
- title: The MIT License (MIT)
3
- category: Getting Started
4
- order: 9
5
- ---
6
-
7
- # The MIT License (MIT)
8
-
9
- Copyright (c) 2015 Instructure, Inc.
10
-
11
- **Permission is hereby granted, free of charge, to any person obtaining a copy
12
- of this software and associated documentation files (the "Software"), to deal
13
- in the Software without restriction, including without limitation the rights
14
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15
- copies of the Software, and to permit persons to whom the Software is
16
- furnished to do so, subject to the following conditions.**
17
-
18
- The above copyright notice and this permission notice shall be included in all
19
- copies or substantial portions of the Software.
20
-
21
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27
- SOFTWARE.