@occmundial/occ-atomic 2.0.0-beta.1 → 2.0.0-beta.10
Sign up to get free protection for your applications and to get access to all the features.
- package/.prettierrc +6 -0
- package/.whitesource +12 -0
- package/CHANGELOG.md +1354 -584
- package/CONTRIBUTING.md +24 -0
- package/README.md +21 -21
- package/build/Autocomplete/Autocomplete.js +217 -117
- package/build/Autocomplete/Autocomplete.test.js +90 -74
- package/build/Autocomplete/__snapshots__/Autocomplete.test.js.snap +20 -0
- package/build/Autocomplete/index.js +6 -1
- package/build/Autocomplete/styles.js +2 -5
- package/build/Avatar/Avatar.js +66 -28
- package/build/Avatar/Avatar.test.js +36 -13
- package/build/Avatar/AvatarContent/AvatarContent.js +11 -14
- package/build/Avatar/AvatarContent/AvatarContent.test.js +55 -50
- package/build/Avatar/AvatarContent/__snapshots__/AvatarContent.test.js.snap +41 -0
- package/build/Avatar/AvatarContent/index.js +6 -1
- package/build/Avatar/AvatarContent/styles.js +12 -11
- package/build/Avatar/__snapshots__/Avatar.test.js.snap +17 -0
- package/build/Avatar/index.js +22 -1
- package/build/Avatar/styles.js +2 -6
- package/build/Banner/Banner.js +76 -0
- package/build/Banner/Banner.test.js +40 -0
- package/build/Banner/__snapshots__/Banner.test.js.snap +33 -0
- package/build/Banner/index.js +18 -0
- package/build/Banner/styles.js +41 -0
- package/build/Button/Button.js +134 -61
- package/build/Button/Button.test.js +69 -20
- package/build/Button/Loading.js +82 -0
- package/build/Button/__snapshots__/Button.test.js.snap +322 -0
- package/build/Button/index.js +22 -1
- package/build/Button/styles.js +187 -178
- package/build/ButtonAlign/ButtonAlign.js +20 -16
- package/build/ButtonAlign/ButtonAlign.test.js +3 -3
- package/build/ButtonAlign/__snapshots__/ButtonAlign.test.js.snap +19 -0
- package/build/Card/Card.js +4 -5
- package/build/Card/Card.test.js +40 -35
- package/build/Card/__snapshots__/Card.test.js.snap +46 -0
- package/build/Card/index.js +22 -1
- package/build/Card/styles.js +2 -4
- package/build/Check/Check.js +18 -14
- package/build/Check/Check.test.js +7 -7
- package/build/Check/__snapshots__/Check.test.js.snap +92 -0
- package/build/Check/styles.js +2 -2
- package/build/Checkbox/Checkbox.js +106 -60
- package/build/Checkbox/Checkbox.test.js +58 -42
- package/build/Checkbox/__snapshots__/Checkbox.test.js.snap +92 -0
- package/build/Checkbox/index.js +4 -2
- package/build/Checkbox/styles.js +2 -5
- package/build/Column/Column.js +1 -1
- package/build/Column/Column.test.js +3 -3
- package/build/Column/__snapshots__/Column.test.js.snap +647 -0
- package/build/Container/Container.js +1 -1
- package/build/Container/Container.test.js +4 -4
- package/build/Container/__snapshots__/Container.test.js.snap +43 -0
- package/build/Droplist/Droplist.js +474 -227
- package/build/Droplist/Droplist.test.js +111 -87
- package/build/Droplist/__snapshots__/Droplist.test.js.snap +65 -0
- package/build/Droplist/functions.js +9 -2
- package/build/Droplist/index.js +22 -1
- package/build/Droplist/styles.js +41 -15
- package/build/Flexbox/Flexbox.js +64 -29
- package/build/Flexbox/Flexbox.test.js +32 -14
- package/build/Flexbox/__snapshots__/Flexbox.test.js.snap +106 -0
- package/build/Flexbox/index.js +22 -1
- package/build/Flexbox/styles.js +2 -6
- package/build/Footer/Footer.js +42 -30
- package/build/Footer/Footer.test.js +2 -2
- package/build/Footer/List/List.js +32 -25
- package/build/Footer/__snapshots__/Footer.test.js.snap +90 -0
- package/build/Footer/styles.js +5 -0
- package/build/Grid/Col/Col.js +15 -22
- package/build/Grid/Col/Col.test.js +33 -13
- package/build/Grid/Col/__snapshots__/Col.test.js.snap +963 -0
- package/build/Grid/Col/index.js +22 -1
- package/build/Grid/Col/styles.js +97 -116
- package/build/Grid/Grid.js +18 -12
- package/build/Grid/Row/Row.js +1 -1
- package/build/Grid/Row/Row.test.js +2 -2
- package/build/Grid/Row/__snapshots__/Row.test.js.snap +22 -0
- package/build/Grid/Row/index.js +4 -2
- package/build/Grid/index.js +4 -2
- package/build/Header/Header.js +35 -31
- package/build/Header/Header.test.js +8 -8
- package/build/Header/Menu/Menu.js +23 -19
- package/build/Header/Menu/Menu.test.js +7 -7
- package/build/Header/Menu/__snapshots__/Menu.test.js.snap +113 -0
- package/build/Header/Nav/Nav.js +19 -15
- package/build/Header/Nav/Nav.test.js +5 -5
- package/build/Header/Nav/__snapshots__/Nav.test.js.snap +101 -0
- package/build/Header/__snapshots__/Header.test.js.snap +79 -0
- package/build/Hidden/Hidden.js +17 -13
- package/build/Hidden/Hidden.test.js +6 -6
- package/build/Hidden/__snapshots__/Hidden.test.js.snap +3 -0
- package/build/Hidden/index.js +4 -2
- package/build/Icon/Icon.js +90 -15
- package/build/Icon/Icon.test.js +49 -56
- package/build/Icon/__snapshots__/Icon.test.js.snap +32 -0
- package/build/Icon/index.js +22 -1
- package/build/Icon/styles.js +16 -9
- package/build/Input/Input.js +29 -25
- package/build/Input/Input.test.js +21 -21
- package/build/Input/__snapshots__/Input.test.js.snap +194 -0
- package/build/Input/index.js +17 -13
- package/build/Label/Label.js +17 -13
- package/build/Label/Label.test.js +6 -6
- package/build/Label/__snapshots__/Label.test.js.snap +82 -0
- package/build/LayerApp/LayerApp.js +22 -18
- package/build/LayerApp/LayerApp.test.js +4 -4
- package/build/LayerApp/__snapshots__/LayerApp.test.js.snap +37 -0
- package/build/Modal/Modal.js +55 -37
- package/build/Modal/Modal.test.js +15 -12
- package/build/Modal/__snapshots__/Modal.test.js.snap +208 -0
- package/build/Modal/index.js +19 -13
- package/build/Modal/styles.js +43 -31
- package/build/NavAside/NavAside.js +24 -19
- package/build/NavAside/NavAside.test.js +15 -13
- package/build/NavAside/__snapshots__/NavAside.test.js.snap +116 -0
- package/build/NavAside/index.js +16 -12
- package/build/NavIcon/NavIcon.js +41 -20
- package/build/NavIcon/styles.js +6 -16
- package/build/NavItem/NavItem.js +29 -16
- package/build/NavTab/NavTab.js +38 -29
- package/build/NavTop/NavTop.js +20 -16
- package/build/OrderBy/OrderBy.js +23 -19
- package/build/OrderBy/OrderBy.test.js +6 -6
- package/build/OrderBy/__snapshots__/OrderBy.test.js.snap +54 -0
- package/build/Pager/Break/Break.js +1 -1
- package/build/Pager/Break/Break.test.js +4 -4
- package/build/Pager/Break/__snapshots__/Break.test.js.snap +13 -0
- package/build/Pager/Page/Page.js +1 -1
- package/build/Pager/Page/Page.test.js +5 -5
- package/build/Pager/Page/__snapshots__/Page.test.js.snap +27 -0
- package/build/Pager/Pager.js +21 -17
- package/build/Pager/Pager.test.js +12 -12
- package/build/Pager/__snapshots__/Pager.test.js.snap +50 -0
- package/build/Pager/styles.js +1 -1
- package/build/Pill/Choice/Choice.js +23 -18
- package/build/Pill/Choice/styles.js +8 -3
- package/build/Pill/Group/Group.js +7 -4
- package/build/Pill/Group/styles.js +7 -4
- package/build/Pill/Pill.js +36 -23
- package/build/Pill/Pill.test.js +12 -12
- package/build/Pill/Stack/Stack.js +10 -7
- package/build/Pill/Stack/styles.js +4 -1
- package/build/Pill/__snapshots__/Pill.test.js.snap +62 -0
- package/build/Pill/styles.js +6 -2
- package/build/Placeholder/Placeholder.js +2 -2
- package/build/Placeholder/Placeholder.test.js +3 -3
- package/build/Placeholder/__snapshots__/Placeholder.test.js.snap +130 -0
- package/build/Placeholder/styles.js +23 -16
- package/build/Provider/Provider.js +89 -0
- package/build/Provider/index.js +13 -0
- package/build/Provider/useAtomic.js +17 -0
- package/build/{hooks → Provider}/usePrevious.js +1 -1
- package/build/Radio/Radio.js +29 -15
- package/build/Radio/Radio.test.js +6 -6
- package/build/Radio/__snapshots__/Radio.test.js.snap +83 -0
- package/build/RangeCounter/RangeCounter.js +17 -13
- package/build/RangeCounter/RangeCounter.test.js +3 -3
- package/build/RangeCounter/__snapshots__/RangeCounter.test.js.snap +20 -0
- package/build/RangeCounter/styles.js +1 -1
- package/build/Row/Row.js +1 -1
- package/build/Row/Row.test.js +2 -2
- package/build/Row/__snapshots__/Row.test.js.snap +22 -0
- package/build/SightLogo/SightLogo.js +2 -2
- package/build/SightLogo/SightLogo.test.js +2 -2
- package/build/SightLogo/__snapshots__/SightLogo.test.js.snap +24 -0
- package/build/SlideDown/SlideDown.js +41 -27
- package/build/SlideDown/SlideDown.test.js +22 -16
- package/build/SlideDown/__snapshots__/SlideDown.test.js.snap +42 -0
- package/build/SlideToggle/SlideToggle.js +31 -17
- package/build/SlideToggle/SlideToggle.test.js +7 -7
- package/build/SlideToggle/__snapshots__/SlideToggle.test.js.snap +62 -0
- package/build/SubHeader/SubHeader.js +20 -16
- package/build/SubHeader/SubHeader.test.js +7 -7
- package/build/SubHeader/__snapshots__/SubHeader.test.js.snap +50 -0
- package/build/SwitchGroup/SwitchGroup.js +17 -13
- package/build/SwitchGroup/SwitchGroup.test.js +6 -6
- package/build/SwitchGroup/__snapshots__/SwitchGroup.test.js.snap +52 -0
- package/build/SwitchGroup/styles.js +1 -1
- package/build/Tag/Tag.js +27 -10
- package/build/Tag/Tag.test.js +8 -8
- package/build/Tag/__snapshots__/Tag.test.js.snap +137 -0
- package/build/Tag/styles.js +72 -27
- package/build/Text/Text.js +454 -122
- package/build/Text/Text.test.js +13 -13
- package/build/Text/__snapshots__/Text.test.js.snap +216 -0
- package/build/Text/styles.js +171 -78
- package/build/TextField/TextField.js +455 -302
- package/build/TextField/TextField.test.js +138 -146
- package/build/TextField/__snapshots__/TextField.test.js.snap +258 -0
- package/build/TextField/index.js +6 -1
- package/build/TextField/styles.js +99 -33
- package/build/Tip/Tip.js +91 -27
- package/build/Tip/Tip.test.js +8 -8
- package/build/Tip/__snapshots__/Tip.test.js.snap +49 -0
- package/build/Tip/styles.js +32 -12
- package/build/Title/Title.js +16 -12
- package/build/Title/Title.test.js +3 -3
- package/build/Title/__snapshots__/Title.test.js.snap +31 -0
- package/build/Toaster/Toast/Toast.js +11 -11
- package/build/Toaster/Toaster.js +27 -23
- package/build/Toaster/Toaster.test.js +6 -6
- package/build/Toaster/__snapshots__/Toaster.test.js.snap +5 -0
- package/build/Tooltip/Tooltip.js +210 -0
- package/build/Tooltip/Tooltip.test.js +35 -0
- package/build/Tooltip/__snapshots__/Tooltip.test.js.snap +33 -0
- package/build/Tooltip/hooks.js +132 -0
- package/build/Tooltip/index.js +18 -0
- package/build/Tooltip/styles.js +44 -0
- package/build/TourTip/TourTip.js +15 -11
- package/build/TourTip/TourTip.test.js +2 -2
- package/build/TourTip/__snapshots__/TourTip.test.js.snap +74 -0
- package/build/Visible/Visible.js +16 -12
- package/build/Visible/Visible.test.js +4 -4
- package/build/Visible/__snapshots__/Visible.test.js.snap +3 -0
- package/build/WindowSize/WindowSize.js +17 -11
- package/build/WindowSize/WindowSize.test.js +4 -4
- package/build/WindowSize/__snapshots__/WindowSize.test.js.snap +3 -0
- package/build/index.js +82 -8
- package/build/plugin/babel.js +61 -0
- package/build/subatomic/colors.js +8 -3
- package/build/subatomic/fonts.js +1 -1
- package/build/subatomic/icons/attachment.js +23 -0
- package/build/subatomic/icons/attachmentSolid.js +23 -0
- package/build/subatomic/icons/avatarSmile.js +23 -0
- package/build/subatomic/icons/book.js +23 -0
- package/build/subatomic/icons/cash.js +23 -0
- package/build/subatomic/icons/copy.js +23 -0
- package/build/subatomic/icons/copySolid.js +23 -0
- package/build/subatomic/icons/crossSolid.js +23 -0
- package/build/subatomic/icons/dislike.js +1 -1
- package/build/subatomic/icons/dislikeSolid.js +23 -0
- package/build/subatomic/icons/energy.js +23 -0
- package/build/subatomic/icons/energySolid.js +23 -0
- package/build/subatomic/icons/eye.js +1 -1
- package/build/subatomic/icons/eyeClosed.js +1 -1
- package/build/subatomic/icons/eyeClosedSolid.js +23 -0
- package/build/subatomic/icons/eyeSolid.js +23 -0
- package/build/subatomic/icons/hourGlass.js +23 -0
- package/build/subatomic/icons/like.js +1 -1
- package/build/subatomic/icons/likeSolid.js +23 -0
- package/build/subatomic/icons/location.js +23 -0
- package/build/subatomic/icons/locationSolid.js +23 -0
- package/build/subatomic/icons/matchJob.js +23 -0
- package/build/subatomic/icons/messages.js +1 -1
- package/build/subatomic/icons/messagesSolid.js +1 -1
- package/build/subatomic/icons/moreOptionsHorizontal.js +23 -0
- package/build/subatomic/icons/noMessages.js +23 -0
- package/build/subatomic/icons/noMessagesSolid.js +23 -0
- package/build/subatomic/icons/occDart.js +25 -8
- package/build/subatomic/icons/occHorizontal.js +25 -8
- package/build/subatomic/icons/occLogo.js +65 -0
- package/build/subatomic/icons/occVertical.js +25 -8
- package/build/subatomic/icons/profile.js +23 -0
- package/build/subatomic/icons/profileSolid.js +23 -0
- package/build/subatomic/icons/profileView.js +23 -0
- package/build/subatomic/icons/refresh.js +23 -0
- package/build/subatomic/icons/refreshSolid.js +23 -0
- package/build/subatomic/icons/sendMessage.js +23 -0
- package/build/subatomic/icons/sendMessageSolid.js +23 -0
- package/build/subatomic/icons/starsSolid.js +23 -0
- package/build/subatomic/icons/suitcase.js +23 -0
- package/build/subatomic/icons/suitcaseSolid.js +23 -0
- package/build/subatomic/icons/tag.js +1 -1
- package/build/subatomic/icons/tagSolid.js +23 -0
- package/build/subatomic/icons/trash.js +1 -1
- package/build/subatomic/icons/trashSolid.js +1 -1
- package/build/subatomic/icons/warning.js +23 -0
- package/build/subatomic/icons/warningSolid.js +23 -0
- package/build/subatomic/icons/webSite.js +23 -0
- package/build/subatomic/icons/webSiteSolid.js +23 -0
- package/build/subatomic/icons.js +230 -112
- package/build/subatomic/mappedIcons.js +171 -0
- package/build/tokens/borderRadius.json +8 -0
- package/build/tokens/colors.json +567 -0
- package/build/tokens/fonts.json +231 -0
- package/build/tokens/index.js +47 -0
- package/build/tokens/shadows.json +13 -0
- package/build/tokens/spacing.json +16 -0
- package/commitlint.config.js +6 -0
- package/package.json +124 -113
- package/playroom/FrameComponent.js +31 -0
- package/playroom/styles.js +14 -0
- package/playroom.config.js +7 -7
- package/build/Grid/Grid.test.js +0 -22
- package/build/Grid/Row/Rowdsd.js +0 -39
- package/build/hooks/useEventListener.js +0 -23
- package/yarn-error.log +0 -10737
package/build/Text/Text.js
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
4
|
+
|
3
5
|
Object.defineProperty(exports, "__esModule", {
|
4
6
|
value: true
|
5
7
|
});
|
@@ -11,9 +13,9 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
13
|
|
12
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
13
15
|
|
14
|
-
function
|
16
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
15
17
|
|
16
|
-
function
|
18
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
17
19
|
|
18
20
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
19
21
|
|
@@ -21,36 +23,90 @@ function _defineProperties(target, props) { for (var i = 0; i < props.length; i+
|
|
21
23
|
|
22
24
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
23
25
|
|
24
|
-
function
|
26
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
27
|
+
|
28
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
29
|
+
|
30
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
31
|
+
|
32
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
25
33
|
|
26
34
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
27
35
|
|
36
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
37
|
+
|
28
38
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
29
39
|
|
30
|
-
function
|
40
|
+
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
|
41
|
+
|
42
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
43
|
+
|
44
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
45
|
+
|
46
|
+
var oldToNewClassMapper = {
|
47
|
+
// Text
|
48
|
+
hero: 'h1',
|
49
|
+
headline: 'h2',
|
50
|
+
heading: 'h4',
|
51
|
+
subheading: 'h5',
|
52
|
+
extraLarge: 'bodyXLarge',
|
53
|
+
large: 'bodyLarge',
|
54
|
+
standard: 'bodyRegular',
|
55
|
+
small: 'bodySmall',
|
56
|
+
micro: 'bodyXSmall',
|
57
|
+
// Color
|
58
|
+
primary: 'indigoPrimary',
|
59
|
+
secondary: 'pinkPrimary',
|
60
|
+
white: 'whitePrimary',
|
61
|
+
highEmphasis: 'corpPrimary',
|
62
|
+
midEmphasis: 'corpSecondary',
|
63
|
+
lowEmphasis: 'corpDisabled',
|
64
|
+
// Spacing
|
65
|
+
topXTiny: 'top1',
|
66
|
+
topTiny: 'top2',
|
67
|
+
topSmall: 'top4',
|
68
|
+
topBase: 'top5',
|
69
|
+
topMedium: 'top6',
|
70
|
+
topLarge: 'top8',
|
71
|
+
topXLarge: 'top9',
|
72
|
+
bottomXTiny: 'bottom1',
|
73
|
+
bottomTiny: 'bottom2',
|
74
|
+
bottomSmall: 'bottom4',
|
75
|
+
bottomBase: 'bottom5',
|
76
|
+
bottomMedium: 'bottom6',
|
77
|
+
bottomLarge: 'bottom8',
|
78
|
+
bottomXLarge: 'bottom9'
|
79
|
+
};
|
31
80
|
|
32
|
-
|
81
|
+
var getActiveKey = function getActiveKey(array) {
|
82
|
+
var _iterator = _createForOfIteratorHelper(array),
|
83
|
+
_step;
|
84
|
+
|
85
|
+
try {
|
86
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
87
|
+
var item = _step.value;
|
88
|
+
var key = Object.keys(item)[0];
|
89
|
+
if (item[key]) return key;
|
90
|
+
}
|
91
|
+
} catch (err) {
|
92
|
+
_iterator.e(err);
|
93
|
+
} finally {
|
94
|
+
_iterator.f();
|
95
|
+
}
|
96
|
+
};
|
33
97
|
|
34
|
-
var Text =
|
35
|
-
/*#__PURE__*/
|
36
|
-
function (_Component) {
|
98
|
+
var Text = /*#__PURE__*/function (_Component) {
|
37
99
|
_inherits(Text, _Component);
|
38
100
|
|
101
|
+
var _super = _createSuper(Text);
|
102
|
+
|
39
103
|
function Text() {
|
40
104
|
_classCallCheck(this, Text);
|
41
105
|
|
42
|
-
return
|
106
|
+
return _super.apply(this, arguments);
|
43
107
|
}
|
44
108
|
|
45
109
|
_createClass(Text, [{
|
46
|
-
key: "filter",
|
47
|
-
value: function filter(array) {
|
48
|
-
return array.filter(function (item) {
|
49
|
-
var key = Object.keys(item)[0];
|
50
|
-
if (item[key]) return key;
|
51
|
-
});
|
52
|
-
}
|
53
|
-
}, {
|
54
110
|
key: "getSize",
|
55
111
|
value: function getSize() {
|
56
112
|
var _this$props = this.props,
|
@@ -59,11 +115,57 @@ function (_Component) {
|
|
59
115
|
headline = _this$props.headline,
|
60
116
|
heading = _this$props.heading,
|
61
117
|
subheading = _this$props.subheading,
|
118
|
+
extraLarge = _this$props.extraLarge,
|
62
119
|
large = _this$props.large,
|
63
120
|
standard = _this$props.standard,
|
64
121
|
small = _this$props.small,
|
65
|
-
micro = _this$props.micro
|
66
|
-
|
122
|
+
micro = _this$props.micro,
|
123
|
+
display = _this$props.display,
|
124
|
+
h1 = _this$props.h1,
|
125
|
+
h2 = _this$props.h2,
|
126
|
+
h3 = _this$props.h3,
|
127
|
+
h4 = _this$props.h4,
|
128
|
+
h5 = _this$props.h5,
|
129
|
+
tagText = _this$props.tagText,
|
130
|
+
bodyXLarge = _this$props.bodyXLarge,
|
131
|
+
bodyLargeStrong = _this$props.bodyLargeStrong,
|
132
|
+
bodyLarge = _this$props.bodyLarge,
|
133
|
+
bodyRegularStrong = _this$props.bodyRegularStrong,
|
134
|
+
bodyRegular = _this$props.bodyRegular,
|
135
|
+
bodySmallStrong = _this$props.bodySmallStrong,
|
136
|
+
bodySmall = _this$props.bodySmall,
|
137
|
+
bodyXSmall = _this$props.bodyXSmall;
|
138
|
+
var sizeActive = getActiveKey([{
|
139
|
+
display: display
|
140
|
+
}, {
|
141
|
+
h1: h1
|
142
|
+
}, {
|
143
|
+
h2: h2
|
144
|
+
}, {
|
145
|
+
h3: h3
|
146
|
+
}, {
|
147
|
+
h4: h4
|
148
|
+
}, {
|
149
|
+
h5: h5
|
150
|
+
}, {
|
151
|
+
tag: tagText
|
152
|
+
}, {
|
153
|
+
bodyXLarge: bodyXLarge
|
154
|
+
}, {
|
155
|
+
bodyLargeStrong: bodyLargeStrong
|
156
|
+
}, {
|
157
|
+
bodyLarge: bodyLarge
|
158
|
+
}, {
|
159
|
+
bodyRegularStrong: bodyRegularStrong
|
160
|
+
}, {
|
161
|
+
bodyRegular: bodyRegular
|
162
|
+
}, {
|
163
|
+
bodySmallStrong: bodySmallStrong
|
164
|
+
}, {
|
165
|
+
bodySmall: bodySmall
|
166
|
+
}, {
|
167
|
+
bodyXSmall: bodyXSmall
|
168
|
+
}, {
|
67
169
|
hero: hero
|
68
170
|
}, {
|
69
171
|
headline: headline
|
@@ -71,6 +173,8 @@ function (_Component) {
|
|
71
173
|
heading: heading
|
72
174
|
}, {
|
73
175
|
subheading: subheading
|
176
|
+
}, {
|
177
|
+
extraLarge: extraLarge
|
74
178
|
}, {
|
75
179
|
large: large
|
76
180
|
}, {
|
@@ -79,14 +183,10 @@ function (_Component) {
|
|
79
183
|
small: small
|
80
184
|
}, {
|
81
185
|
micro: micro
|
82
|
-
}];
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
return classes.standard;
|
87
|
-
} else {
|
88
|
-
return classes[Object.keys(filtered[0])[0]];
|
89
|
-
}
|
186
|
+
}]);
|
187
|
+
if (!sizeActive) return classes.bodyRegular;
|
188
|
+
var activeSizeParsed = oldToNewClassMapper[sizeActive];
|
189
|
+
return classes[activeSizeParsed || sizeActive];
|
90
190
|
}
|
91
191
|
}, {
|
92
192
|
key: "getEmphasis",
|
@@ -95,7 +195,7 @@ function (_Component) {
|
|
95
195
|
classes = _this$props2.classes,
|
96
196
|
mid = _this$props2.mid,
|
97
197
|
low = _this$props2.low;
|
98
|
-
if (low) return classes.
|
198
|
+
if (low) return classes.corpDisabled;else if (mid) return classes.corpSecondary;else return classes.corpPrimary;
|
99
199
|
}
|
100
200
|
}, {
|
101
201
|
key: "getColor",
|
@@ -110,8 +210,13 @@ function (_Component) {
|
|
110
210
|
info = _this$props3.info,
|
111
211
|
disabled = _this$props3.disabled,
|
112
212
|
white = _this$props3.white,
|
113
|
-
link = _this$props3.link
|
114
|
-
|
213
|
+
link = _this$props3.link,
|
214
|
+
indigoPrimary = _this$props3.indigoPrimary,
|
215
|
+
indigoSecondary = _this$props3.indigoSecondary,
|
216
|
+
pinkPrimary = _this$props3.pinkPrimary,
|
217
|
+
whiteSecondary = _this$props3.whiteSecondary,
|
218
|
+
whitePrimary = _this$props3.whitePrimary;
|
219
|
+
var colorActive = getActiveKey([{
|
115
220
|
primary: primary
|
116
221
|
}, {
|
117
222
|
secondary: secondary
|
@@ -129,14 +234,20 @@ function (_Component) {
|
|
129
234
|
white: white
|
130
235
|
}, {
|
131
236
|
link: link
|
132
|
-
}
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
237
|
+
}, {
|
238
|
+
indigoPrimary: indigoPrimary
|
239
|
+
}, {
|
240
|
+
indigoSecondary: indigoSecondary
|
241
|
+
}, {
|
242
|
+
pinkPrimary: pinkPrimary
|
243
|
+
}, {
|
244
|
+
whiteSecondary: whiteSecondary
|
245
|
+
}, {
|
246
|
+
whitePrimary: whitePrimary
|
247
|
+
}]);
|
248
|
+
if (!colorActive) return false;
|
249
|
+
var colorActiveParsed = oldToNewClassMapper[colorActive];
|
250
|
+
return classes[colorActiveParsed || colorActive];
|
140
251
|
}
|
141
252
|
}, {
|
142
253
|
key: "getAlign",
|
@@ -159,7 +270,20 @@ function (_Component) {
|
|
159
270
|
topBase = _this$props5.topBase,
|
160
271
|
topMedium = _this$props5.topMedium,
|
161
272
|
topLarge = _this$props5.topLarge,
|
162
|
-
topXLarge = _this$props5.topXLarge
|
273
|
+
topXLarge = _this$props5.topXLarge,
|
274
|
+
top0 = _this$props5.top0,
|
275
|
+
top1 = _this$props5.top1,
|
276
|
+
top2 = _this$props5.top2,
|
277
|
+
top3 = _this$props5.top3,
|
278
|
+
top4 = _this$props5.top4,
|
279
|
+
top5 = _this$props5.top5,
|
280
|
+
top6 = _this$props5.top6,
|
281
|
+
top7 = _this$props5.top7,
|
282
|
+
top8 = _this$props5.top8,
|
283
|
+
top9 = _this$props5.top9,
|
284
|
+
top10 = _this$props5.top10,
|
285
|
+
top11 = _this$props5.top11,
|
286
|
+
top12 = _this$props5.top12;
|
163
287
|
var spacing = [{
|
164
288
|
topXTiny: topXTiny
|
165
289
|
}, {
|
@@ -174,14 +298,37 @@ function (_Component) {
|
|
174
298
|
topLarge: topLarge
|
175
299
|
}, {
|
176
300
|
topXLarge: topXLarge
|
301
|
+
}, {
|
302
|
+
top0: top0
|
303
|
+
}, {
|
304
|
+
top1: top1
|
305
|
+
}, {
|
306
|
+
top2: top2
|
307
|
+
}, {
|
308
|
+
top3: top3
|
309
|
+
}, {
|
310
|
+
top4: top4
|
311
|
+
}, {
|
312
|
+
top5: top5
|
313
|
+
}, {
|
314
|
+
top6: top6
|
315
|
+
}, {
|
316
|
+
top7: top7
|
317
|
+
}, {
|
318
|
+
top8: top8
|
319
|
+
}, {
|
320
|
+
top9: top9
|
321
|
+
}, {
|
322
|
+
top10: top10
|
323
|
+
}, {
|
324
|
+
top11: top11
|
325
|
+
}, {
|
326
|
+
top12: top12
|
177
327
|
}];
|
178
|
-
var
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
} else {
|
183
|
-
return " ".concat(classes[Object.keys(filtered[0])[0]]);
|
184
|
-
}
|
328
|
+
var topSpacingActive = getActiveKey(spacing);
|
329
|
+
if (!topSpacingActive) return '';
|
330
|
+
var topSpacingActiveParsed = oldToNewClassMapper[topSpacingActive];
|
331
|
+
return " ".concat(classes[topSpacingActiveParsed || topSpacingActive]);
|
185
332
|
}
|
186
333
|
}, {
|
187
334
|
key: "getBottomSpacing",
|
@@ -194,7 +341,20 @@ function (_Component) {
|
|
194
341
|
bottomBase = _this$props6.bottomBase,
|
195
342
|
bottomMedium = _this$props6.bottomMedium,
|
196
343
|
bottomLarge = _this$props6.bottomLarge,
|
197
|
-
bottomXLarge = _this$props6.bottomXLarge
|
344
|
+
bottomXLarge = _this$props6.bottomXLarge,
|
345
|
+
bottom0 = _this$props6.bottom0,
|
346
|
+
bottom1 = _this$props6.bottom1,
|
347
|
+
bottom2 = _this$props6.bottom2,
|
348
|
+
bottom3 = _this$props6.bottom3,
|
349
|
+
bottom4 = _this$props6.bottom4,
|
350
|
+
bottom5 = _this$props6.bottom5,
|
351
|
+
bottom6 = _this$props6.bottom6,
|
352
|
+
bottom7 = _this$props6.bottom7,
|
353
|
+
bottom8 = _this$props6.bottom8,
|
354
|
+
bottom9 = _this$props6.bottom9,
|
355
|
+
bottom10 = _this$props6.bottom10,
|
356
|
+
bottom11 = _this$props6.bottom11,
|
357
|
+
bottom12 = _this$props6.bottom12;
|
198
358
|
var spacing = [{
|
199
359
|
bottomXTiny: bottomXTiny
|
200
360
|
}, {
|
@@ -209,14 +369,37 @@ function (_Component) {
|
|
209
369
|
bottomLarge: bottomLarge
|
210
370
|
}, {
|
211
371
|
bottomXLarge: bottomXLarge
|
372
|
+
}, {
|
373
|
+
bottom0: bottom0
|
374
|
+
}, {
|
375
|
+
bottom1: bottom1
|
376
|
+
}, {
|
377
|
+
bottom2: bottom2
|
378
|
+
}, {
|
379
|
+
bottom3: bottom3
|
380
|
+
}, {
|
381
|
+
bottom4: bottom4
|
382
|
+
}, {
|
383
|
+
bottom5: bottom5
|
384
|
+
}, {
|
385
|
+
bottom6: bottom6
|
386
|
+
}, {
|
387
|
+
bottom7: bottom7
|
388
|
+
}, {
|
389
|
+
bottom8: bottom8
|
390
|
+
}, {
|
391
|
+
bottom9: bottom9
|
392
|
+
}, {
|
393
|
+
bottom10: bottom10
|
394
|
+
}, {
|
395
|
+
bottom11: bottom11
|
396
|
+
}, {
|
397
|
+
bottom12: bottom12
|
212
398
|
}];
|
213
|
-
var
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
} else {
|
218
|
-
return " ".concat(classes[Object.keys(filtered[0])[0]]);
|
219
|
-
}
|
399
|
+
var bottomSpacingActive = getActiveKey(spacing);
|
400
|
+
if (!bottomSpacingActive) return '';
|
401
|
+
var bottomSpacingActiveParsed = oldToNewClassMapper[bottomSpacingActive];
|
402
|
+
return " ".concat(classes[bottomSpacingActiveParsed || bottomSpacingActive]);
|
220
403
|
}
|
221
404
|
}, {
|
222
405
|
key: "getWeight",
|
@@ -249,13 +432,9 @@ function (_Component) {
|
|
249
432
|
}, {
|
250
433
|
micro: micro
|
251
434
|
}];
|
252
|
-
var
|
253
|
-
|
254
|
-
|
255
|
-
return " ".concat(classes.strong);
|
256
|
-
} else {
|
257
|
-
return false;
|
258
|
-
}
|
435
|
+
var weightActive = getActiveKey(sizes);
|
436
|
+
if ((!weightActive || large || standard || small || micro) && strong) return " ".concat(classes.strong);
|
437
|
+
return false;
|
259
438
|
}
|
260
439
|
}, {
|
261
440
|
key: "render",
|
@@ -266,7 +445,8 @@ function (_Component) {
|
|
266
445
|
tag = _this$props8.tag,
|
267
446
|
className = _this$props8.className,
|
268
447
|
style = _this$props8.style,
|
269
|
-
id = _this$props8.id
|
448
|
+
id = _this$props8.id,
|
449
|
+
testId = _this$props8.testId;
|
270
450
|
var TextType = tag;
|
271
451
|
var size = this.getSize();
|
272
452
|
var color = this.getColor();
|
@@ -275,10 +455,11 @@ function (_Component) {
|
|
275
455
|
var topSpacing = this.getTopSpacing();
|
276
456
|
var bottomSpacing = this.getBottomSpacing();
|
277
457
|
var strong = this.getWeight();
|
278
|
-
return _react["default"].createElement(TextType, {
|
458
|
+
return /*#__PURE__*/_react["default"].createElement(TextType, {
|
279
459
|
className: "".concat(classes.text, " ").concat(size, " ").concat(color ? color : emphasis).concat(topSpacing).concat(bottomSpacing).concat(align ? " ".concat(align) : '').concat(strong ? " ".concat(strong) : '').concat(className ? " ".concat(className) : ''),
|
280
460
|
style: style,
|
281
|
-
id: id
|
461
|
+
id: id,
|
462
|
+
"data-testid": testId
|
282
463
|
}, children);
|
283
464
|
}
|
284
465
|
}]);
|
@@ -287,125 +468,276 @@ function (_Component) {
|
|
287
468
|
}(_react.Component);
|
288
469
|
|
289
470
|
Text.propTypes = {
|
471
|
+
/** display typography style. */
|
472
|
+
display: _propTypes["default"].bool,
|
473
|
+
|
474
|
+
/** h1 typography style. */
|
475
|
+
h1: _propTypes["default"].bool,
|
476
|
+
|
477
|
+
/** h2 typography style. */
|
478
|
+
h2: _propTypes["default"].bool,
|
479
|
+
|
480
|
+
/** h3 typography style. */
|
481
|
+
h3: _propTypes["default"].bool,
|
482
|
+
|
483
|
+
/** h4 typography style. */
|
484
|
+
h4: _propTypes["default"].bool,
|
485
|
+
|
486
|
+
/** h5 typography style. */
|
487
|
+
h5: _propTypes["default"].bool,
|
488
|
+
|
489
|
+
/** tagText typography style. */
|
490
|
+
tagText: _propTypes["default"].bool,
|
491
|
+
|
492
|
+
/** bodyXLarge typography style. */
|
493
|
+
bodyXLarge: _propTypes["default"].bool,
|
494
|
+
|
495
|
+
/** bodyLargeStrong typography style. */
|
496
|
+
bodyLargeStrong: _propTypes["default"].bool,
|
497
|
+
|
498
|
+
/** bodyLarge typography style. */
|
499
|
+
bodyLarge: _propTypes["default"].bool,
|
500
|
+
|
501
|
+
/** bodyRegularStrong typography style. */
|
502
|
+
bodyRegularStrong: _propTypes["default"].bool,
|
503
|
+
|
504
|
+
/** bodyRegular typography style. */
|
505
|
+
bodyRegular: _propTypes["default"].bool,
|
506
|
+
|
507
|
+
/** bodySmallStrong typography style. */
|
508
|
+
bodySmallStrong: _propTypes["default"].bool,
|
509
|
+
|
510
|
+
/** bodySmall typography style. */
|
511
|
+
bodySmall: _propTypes["default"].bool,
|
512
|
+
|
513
|
+
/** bodyXSmall typography style. */
|
514
|
+
bodyXSmall: _propTypes["default"].bool,
|
515
|
+
|
516
|
+
/** Indigo primary emphasis color style. */
|
517
|
+
indigoPrimary: _propTypes["default"].bool,
|
518
|
+
|
519
|
+
/** Indigo secondary emphasis color style. */
|
520
|
+
indigoSecondary: _propTypes["default"].bool,
|
521
|
+
|
522
|
+
/** Pink primary emphasis color style. */
|
523
|
+
pinkPrimary: _propTypes["default"].bool,
|
524
|
+
|
525
|
+
/** White secondary emphasis color style. */
|
526
|
+
whiteSecondary: _propTypes["default"].bool,
|
527
|
+
|
528
|
+
/** White emphasis color style. */
|
529
|
+
whitePrimary: _propTypes["default"].bool,
|
530
|
+
|
531
|
+
/** Corp secondary emphasis color style. */
|
532
|
+
corpSecondary: _propTypes["default"].bool,
|
533
|
+
|
534
|
+
/** Corp disabled emphasis color style. */
|
535
|
+
corpDisabled: _propTypes["default"].bool,
|
536
|
+
|
537
|
+
/** Top0 spacing style (2px). */
|
538
|
+
top0: _propTypes["default"].bool,
|
539
|
+
|
540
|
+
/** Top1 spacing style (4px). */
|
541
|
+
top1: _propTypes["default"].bool,
|
542
|
+
|
543
|
+
/** Top2 spacing style (8px). */
|
544
|
+
top2: _propTypes["default"].bool,
|
545
|
+
|
546
|
+
/** Top3 spacing style (12px). */
|
547
|
+
top3: _propTypes["default"].bool,
|
548
|
+
|
549
|
+
/** Top4 spacing style (16px). */
|
550
|
+
top4: _propTypes["default"].bool,
|
551
|
+
|
552
|
+
/** Top5 spacing style (24px). */
|
553
|
+
top5: _propTypes["default"].bool,
|
554
|
+
|
555
|
+
/** Top6 spacing style (32px). */
|
556
|
+
top6: _propTypes["default"].bool,
|
557
|
+
|
558
|
+
/** Top7 spacing style (40px). */
|
559
|
+
top7: _propTypes["default"].bool,
|
560
|
+
|
561
|
+
/** Top8 spacing style (48px). */
|
562
|
+
top8: _propTypes["default"].bool,
|
563
|
+
|
564
|
+
/** Top9 spacing style (64px). */
|
565
|
+
top9: _propTypes["default"].bool,
|
566
|
+
|
567
|
+
/** Top10 spacing style (80px). */
|
568
|
+
top10: _propTypes["default"].bool,
|
569
|
+
|
570
|
+
/** Top11 spacing style (120px). */
|
571
|
+
top11: _propTypes["default"].bool,
|
572
|
+
|
573
|
+
/** Top12 spacing style (160px). */
|
574
|
+
top12: _propTypes["default"].bool,
|
575
|
+
|
576
|
+
/** Bottom0 spacing style (2px). */
|
577
|
+
bottom0: _propTypes["default"].bool,
|
578
|
+
|
579
|
+
/** Bottom1 spacing style (4px). */
|
580
|
+
bottom1: _propTypes["default"].bool,
|
581
|
+
|
582
|
+
/** Bottom2 spacing style (8px). */
|
583
|
+
bottom2: _propTypes["default"].bool,
|
584
|
+
|
585
|
+
/** Bottom3 spacing style (12px). */
|
586
|
+
bottom3: _propTypes["default"].bool,
|
587
|
+
|
588
|
+
/** Bottom4 spacing style (16px). */
|
589
|
+
bottom4: _propTypes["default"].bool,
|
590
|
+
|
591
|
+
/** Bottom5 spacing style (24px). */
|
592
|
+
bottom5: _propTypes["default"].bool,
|
593
|
+
|
594
|
+
/** Bottom6 spacing style (32px). */
|
595
|
+
bottom6: _propTypes["default"].bool,
|
596
|
+
|
597
|
+
/** Bottom7 spacing style (40px). */
|
598
|
+
bottom7: _propTypes["default"].bool,
|
599
|
+
|
600
|
+
/** Bottom8 spacing style (48px). */
|
601
|
+
bottom8: _propTypes["default"].bool,
|
602
|
+
|
603
|
+
/** Bottom9 spacing style (64px). */
|
604
|
+
bottom9: _propTypes["default"].bool,
|
605
|
+
|
606
|
+
/** Bottom10 spacing style (80px). */
|
607
|
+
bottom10: _propTypes["default"].bool,
|
608
|
+
|
609
|
+
/** Bottom11 spacing style (120px). */
|
610
|
+
bottom11: _propTypes["default"].bool,
|
611
|
+
|
612
|
+
/** Bottom12 spacing style (160px). */
|
613
|
+
bottom12: _propTypes["default"].bool,
|
290
614
|
classes: _propTypes["default"].object.isRequired,
|
291
615
|
children: _propTypes["default"].node.isRequired,
|
292
616
|
|
293
|
-
/**
|
617
|
+
/** Strong style. Only applies in large, standard or small sizes. */
|
618
|
+
strong: _propTypes["default"].bool,
|
619
|
+
|
620
|
+
/** Success color style. */
|
621
|
+
success: _propTypes["default"].bool,
|
622
|
+
|
623
|
+
/** Error color style. */
|
624
|
+
error: _propTypes["default"].bool,
|
625
|
+
|
626
|
+
/** Warning color style. */
|
627
|
+
warning: _propTypes["default"].bool,
|
628
|
+
|
629
|
+
/** Left align style. */
|
630
|
+
left: _propTypes["default"].bool,
|
631
|
+
|
632
|
+
/** Center align style. */
|
633
|
+
center: _propTypes["default"].bool,
|
634
|
+
|
635
|
+
/** Right align style. */
|
636
|
+
right: _propTypes["default"].bool,
|
637
|
+
|
638
|
+
/** Html tag. */
|
639
|
+
tag: _propTypes["default"].string.isRequired,
|
640
|
+
|
641
|
+
/** The className of the text container. */
|
642
|
+
className: _propTypes["default"].string,
|
643
|
+
|
644
|
+
/** The style of the text container. */
|
645
|
+
style: _propTypes["default"].object,
|
646
|
+
id: _propTypes["default"].string,
|
647
|
+
testId: _propTypes["default"].string,
|
648
|
+
|
649
|
+
/** [Legacy prop] h1 typography style.*/
|
294
650
|
hero: _propTypes["default"].bool,
|
295
651
|
|
296
|
-
/**
|
652
|
+
/** [Legacy prop] h2 typography style.*/
|
297
653
|
headline: _propTypes["default"].bool,
|
298
654
|
|
299
|
-
/**
|
655
|
+
/** [Legacy prop] h4 typography style.*/
|
300
656
|
heading: _propTypes["default"].bool,
|
301
657
|
|
302
|
-
/**
|
658
|
+
/** [Legacy prop] h5 typography style.*/
|
303
659
|
subheading: _propTypes["default"].bool,
|
304
660
|
|
305
|
-
/**
|
661
|
+
/** [Legacy prop] bodyXLarge typography style.*/
|
662
|
+
extraLarge: _propTypes["default"].bool,
|
663
|
+
|
664
|
+
/** [Legacy prop] bodyLarge typography style.*/
|
306
665
|
large: _propTypes["default"].bool,
|
307
666
|
|
308
|
-
/**
|
667
|
+
/** [Legacy prop] bodyRegular typography style.*/
|
309
668
|
standard: _propTypes["default"].bool,
|
310
669
|
|
311
|
-
/**
|
670
|
+
/** [Legacy prop] bodySmall typography style.*/
|
312
671
|
small: _propTypes["default"].bool,
|
313
672
|
|
314
|
-
/**
|
673
|
+
/** [Legacy prop] bodyXSmall typography style.*/
|
315
674
|
micro: _propTypes["default"].bool,
|
316
675
|
|
317
|
-
/**
|
318
|
-
strong: _propTypes["default"].bool,
|
319
|
-
|
320
|
-
/** Medium emphasis color style. */
|
676
|
+
/** [Legacy prop] Corp secondary emphasis color style.*/
|
321
677
|
mid: _propTypes["default"].bool,
|
322
678
|
|
323
|
-
/**
|
679
|
+
/** [Legacy prop] Corp disabled emphasis color style.*/
|
324
680
|
low: _propTypes["default"].bool,
|
325
681
|
|
326
|
-
/**
|
682
|
+
/** [Legacy prop] Indigo primary emphasis color style.*/
|
327
683
|
primary: _propTypes["default"].bool,
|
328
684
|
|
329
|
-
/**
|
685
|
+
/** [Legacy prop] Pink primary emphasis color style.*/
|
330
686
|
secondary: _propTypes["default"].bool,
|
331
687
|
|
332
|
-
/**
|
333
|
-
success: _propTypes["default"].bool,
|
334
|
-
|
335
|
-
/** Error color style. */
|
336
|
-
error: _propTypes["default"].bool,
|
337
|
-
|
338
|
-
/** Warning color style. */
|
339
|
-
warning: _propTypes["default"].bool,
|
340
|
-
|
341
|
-
/** Info color style. */
|
688
|
+
/** [Legacy prop] Info color style.*/
|
342
689
|
info: _propTypes["default"].bool,
|
343
690
|
|
344
|
-
/** Disabled color style
|
691
|
+
/** [Legacy prop] Disabled emphasis color style.*/
|
345
692
|
disabled: _propTypes["default"].bool,
|
346
693
|
|
347
|
-
/** White color style
|
694
|
+
/** [Legacy prop] White emphasis color style.*/
|
348
695
|
white: _propTypes["default"].bool,
|
349
696
|
|
350
|
-
/** Link color style
|
697
|
+
/** [Legacy prop] Link emphasis color style.*/
|
351
698
|
link: _propTypes["default"].bool,
|
352
699
|
|
353
|
-
/**
|
354
|
-
left: _propTypes["default"].bool,
|
355
|
-
|
356
|
-
/** Center align style. */
|
357
|
-
center: _propTypes["default"].bool,
|
358
|
-
|
359
|
-
/** Right align style. */
|
360
|
-
right: _propTypes["default"].bool,
|
361
|
-
|
362
|
-
/** X-Tiny top spacing style. */
|
700
|
+
/** [Legacy prop] Top1 spacing style (4px).*/
|
363
701
|
topXTiny: _propTypes["default"].bool,
|
364
702
|
|
365
|
-
/**
|
703
|
+
/** [Legacy prop] Top2 spacing style (8px).*/
|
366
704
|
topTiny: _propTypes["default"].bool,
|
367
705
|
|
368
|
-
/**
|
706
|
+
/** [Legacy prop] Top4 spacing style (16px).*/
|
369
707
|
topSmall: _propTypes["default"].bool,
|
370
708
|
|
371
|
-
/**
|
709
|
+
/** [Legacy prop] Top5 spacing style (24px).*/
|
372
710
|
topBase: _propTypes["default"].bool,
|
373
711
|
|
374
|
-
/**
|
712
|
+
/** [Legacy prop] Top6 spacing style (32px).*/
|
375
713
|
topMedium: _propTypes["default"].bool,
|
376
714
|
|
377
|
-
/**
|
715
|
+
/** [Legacy prop] Top8 spacing style (48px).*/
|
378
716
|
topLarge: _propTypes["default"].bool,
|
379
717
|
|
380
|
-
/**
|
718
|
+
/** [Legacy prop] Top9 spacing style (64px).*/
|
381
719
|
topXLarge: _propTypes["default"].bool,
|
382
720
|
|
383
|
-
/**
|
721
|
+
/** [Legacy prop] Bottom1 spacing style (4px).*/
|
384
722
|
bottomXTiny: _propTypes["default"].bool,
|
385
723
|
|
386
|
-
/**
|
724
|
+
/** [Legacy prop] Bottom2 spacing style (8px).*/
|
387
725
|
bottomTiny: _propTypes["default"].bool,
|
388
726
|
|
389
|
-
/**
|
727
|
+
/** [Legacy prop] Bottom4 spacing style (16px).*/
|
390
728
|
bottomSmall: _propTypes["default"].bool,
|
391
729
|
|
392
|
-
/**
|
730
|
+
/** [Legacy prop] Bottom5 spacing style (24px).*/
|
393
731
|
bottomBase: _propTypes["default"].bool,
|
394
732
|
|
395
|
-
/**
|
733
|
+
/** [Legacy prop] Bottom6 spacing style (32px).*/
|
396
734
|
bottomMedium: _propTypes["default"].bool,
|
397
735
|
|
398
|
-
/**
|
736
|
+
/** [Legacy prop] Bottom8 spacing style (48px).*/
|
399
737
|
bottomLarge: _propTypes["default"].bool,
|
400
738
|
|
401
|
-
/**
|
402
|
-
bottomXLarge: _propTypes["default"].bool
|
403
|
-
|
404
|
-
/** Html tag. */
|
405
|
-
tag: _propTypes["default"].string.isRequired,
|
406
|
-
className: _propTypes["default"].string,
|
407
|
-
style: _propTypes["default"].object,
|
408
|
-
id: _propTypes["default"].string
|
739
|
+
/** [Legacy prop] Bottom9 spacing style (64px).*/
|
740
|
+
bottomXLarge: _propTypes["default"].bool
|
409
741
|
};
|
410
742
|
Text.defaultProps = {
|
411
743
|
tag: 'p'
|