@pareto-engineering/design-system 2.0.0-alpha.4 → 2.0.0-alpha.42

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.
Files changed (225) hide show
  1. package/dist/cjs/a/BackgroundGradient/BackgroundGradient.js +77 -0
  2. package/dist/cjs/a/BackgroundGradient/index.js +15 -0
  3. package/dist/cjs/a/BackgroundGradient/styles.scss +16 -0
  4. package/dist/cjs/a/ContentTree/ContentTree.js +83 -0
  5. package/dist/cjs/a/ContentTree/common/Tree/Tree.js +116 -0
  6. package/dist/cjs/a/ContentTree/common/Tree/index.js +15 -0
  7. package/dist/cjs/a/ContentTree/common/index.js +31 -0
  8. package/dist/cjs/a/ContentTree/common/useContentTree.js +82 -0
  9. package/dist/cjs/a/ContentTree/common/useFirstVisibleNode.js +65 -0
  10. package/dist/cjs/a/ContentTree/index.js +15 -0
  11. package/dist/cjs/a/ContentTree/styles.scss +33 -0
  12. package/dist/cjs/a/Conversation/Conversation.js +14 -8
  13. package/dist/cjs/a/Conversation/common/Message/Message.js +32 -6
  14. package/dist/cjs/a/Conversation/styles.scss +132 -33
  15. package/dist/cjs/a/OvalIllustration/OvalIllustration.js +133 -0
  16. package/dist/cjs/a/OvalIllustration/index.js +15 -0
  17. package/dist/cjs/a/OvalIllustration/styles.scss +102 -0
  18. package/dist/cjs/a/Popover/Popover.js +134 -0
  19. package/dist/cjs/a/Popover/common/Divider/Divider.js +67 -0
  20. package/dist/cjs/a/Popover/common/Divider/index.js +15 -0
  21. package/dist/cjs/a/Popover/common/Item/Item.js +67 -0
  22. package/dist/cjs/a/Popover/common/Item/index.js +15 -0
  23. package/dist/cjs/a/Popover/common/index.js +21 -0
  24. package/dist/cjs/a/Popover/index.js +15 -0
  25. package/dist/cjs/a/Popover/styles.scss +43 -0
  26. package/dist/cjs/a/Shapes/Shapes.js +39 -9
  27. package/dist/cjs/a/Shapes/styles.scss +78 -22
  28. package/dist/cjs/a/SnapScroller/SnapScroller.js +77 -0
  29. package/dist/cjs/a/SnapScroller/index.js +15 -0
  30. package/dist/cjs/a/SnapScroller/styles.scss +38 -0
  31. package/dist/cjs/a/index.js +49 -1
  32. package/dist/cjs/b/Button/Button.js +10 -4
  33. package/dist/cjs/b/Button/styles.scss +55 -10
  34. package/dist/cjs/b/Logo/Logo.js +41 -41
  35. package/dist/cjs/b/Logo/styles.scss +0 -138
  36. package/dist/cjs/b/Page/common/Section/Section.js +56 -5
  37. package/dist/cjs/b/Page/styles.scss +8 -2
  38. package/dist/cjs/c/ContentSlides/common/HorizontalMenu/HorizontalMenu.js +16 -9
  39. package/dist/cjs/c/ContentSlides/common/Navigator/Navigator.js +4 -3
  40. package/dist/cjs/c/ContentSlides/styles.scss +10 -4
  41. package/dist/cjs/c/SocialMediaShareButton/SocialMediaShareButton.js +105 -0
  42. package/dist/cjs/c/SocialMediaShareButton/index.js +15 -0
  43. package/dist/cjs/c/SocialMediaShareButton/styles.scss +39 -0
  44. package/dist/cjs/c/index.js +9 -1
  45. package/dist/cjs/f/common/Debugger/Debugger.js +1 -1
  46. package/dist/cjs/f/common/Label/Label.js +1 -1
  47. package/dist/cjs/f/common/Label/styles.scss +1 -1
  48. package/dist/cjs/f/fields/ChoicesInput/ChoicesInput.js +1 -1
  49. package/dist/cjs/f/fields/ChoicesInput/styles.scss +17 -2
  50. package/dist/cjs/f/fields/RatingsInput/RatingsInput.js +39 -6
  51. package/dist/cjs/f/fields/RatingsInput/styles.scss +29 -20
  52. package/dist/cjs/f/fields/SelectInput/SelectInput.js +36 -10
  53. package/dist/cjs/f/fields/SelectInput/styles.scss +13 -8
  54. package/dist/cjs/f/fields/TaskRecommendationInput/TaskRecommendationInput.js +1 -1
  55. package/dist/cjs/f/fields/TextInput/TextInput.js +35 -7
  56. package/dist/cjs/f/fields/TextInput/styles.scss +16 -7
  57. package/dist/cjs/f/fields/TextareaInput/TextareaInput.js +15 -8
  58. package/dist/cjs/f/fields/TextareaInput/styles.scss +19 -6
  59. package/dist/cjs/f/fields/index.js +0 -24
  60. package/dist/cjs/form-reset.scss +1 -1
  61. package/dist/cjs/index.js +13 -0
  62. package/dist/cjs/utils/hooks/index.js +23 -0
  63. package/dist/cjs/utils/hooks/useDynamicPosition.js +107 -0
  64. package/dist/cjs/utils/hooks/useWindowSize.js +39 -0
  65. package/dist/cjs/utils/index.js +19 -0
  66. package/dist/es/a/BackgroundGradient/BackgroundGradient.js +55 -0
  67. package/dist/es/a/BackgroundGradient/index.js +2 -0
  68. package/dist/es/a/BackgroundGradient/styles.scss +16 -0
  69. package/dist/es/a/ContentTree/ContentTree.js +67 -0
  70. package/dist/es/a/ContentTree/common/Tree/Tree.js +98 -0
  71. package/dist/es/a/ContentTree/common/Tree/index.js +2 -0
  72. package/dist/es/a/ContentTree/common/index.js +3 -0
  73. package/dist/es/a/ContentTree/common/useContentTree.js +74 -0
  74. package/dist/es/a/ContentTree/common/useFirstVisibleNode.js +54 -0
  75. package/dist/es/a/ContentTree/index.js +2 -0
  76. package/dist/es/a/ContentTree/styles.scss +33 -0
  77. package/dist/es/a/Conversation/Conversation.js +14 -8
  78. package/dist/es/a/Conversation/common/Message/Message.js +32 -6
  79. package/dist/es/a/Conversation/styles.scss +132 -33
  80. package/dist/es/a/OvalIllustration/OvalIllustration.js +111 -0
  81. package/dist/es/a/OvalIllustration/index.js +2 -0
  82. package/dist/es/a/OvalIllustration/styles.scss +102 -0
  83. package/dist/es/a/Popover/Popover.js +118 -0
  84. package/dist/es/a/Popover/common/Divider/Divider.js +47 -0
  85. package/dist/es/a/Popover/common/Divider/index.js +2 -0
  86. package/dist/es/a/Popover/common/Item/Item.js +47 -0
  87. package/dist/es/a/Popover/common/Item/index.js +2 -0
  88. package/dist/es/a/Popover/common/index.js +2 -0
  89. package/dist/es/a/Popover/index.js +2 -0
  90. package/dist/es/a/Popover/styles.scss +43 -0
  91. package/dist/es/a/Shapes/Shapes.js +39 -9
  92. package/dist/es/a/Shapes/styles.scss +78 -22
  93. package/dist/es/a/SnapScroller/SnapScroller.js +61 -0
  94. package/dist/es/a/SnapScroller/index.js +2 -0
  95. package/dist/es/a/SnapScroller/styles.scss +38 -0
  96. package/dist/es/a/index.js +7 -1
  97. package/dist/es/b/Button/Button.js +8 -2
  98. package/dist/es/b/Button/styles.scss +55 -10
  99. package/dist/es/b/Logo/Logo.js +41 -41
  100. package/dist/es/b/Logo/styles.scss +0 -138
  101. package/dist/es/b/Page/common/Section/Section.js +55 -4
  102. package/dist/es/b/Page/styles.scss +8 -2
  103. package/dist/es/c/ContentSlides/common/HorizontalMenu/HorizontalMenu.js +16 -9
  104. package/dist/es/c/ContentSlides/common/Navigator/Navigator.js +4 -3
  105. package/dist/es/c/ContentSlides/styles.scss +10 -4
  106. package/dist/es/c/SocialMediaShareButton/SocialMediaShareButton.js +89 -0
  107. package/dist/es/c/SocialMediaShareButton/index.js +2 -0
  108. package/dist/es/c/SocialMediaShareButton/styles.scss +39 -0
  109. package/dist/es/c/index.js +2 -1
  110. package/dist/es/f/common/Debugger/Debugger.js +1 -1
  111. package/dist/es/f/common/Label/Label.js +1 -1
  112. package/dist/es/f/common/Label/styles.scss +1 -1
  113. package/dist/es/f/fields/ChoicesInput/ChoicesInput.js +1 -1
  114. package/dist/es/f/fields/ChoicesInput/styles.scss +17 -2
  115. package/dist/es/f/fields/RatingsInput/RatingsInput.js +38 -6
  116. package/dist/es/f/fields/RatingsInput/styles.scss +29 -20
  117. package/dist/es/f/fields/SelectInput/SelectInput.js +36 -10
  118. package/dist/es/f/fields/SelectInput/styles.scss +13 -8
  119. package/dist/es/f/fields/TaskRecommendationInput/TaskRecommendationInput.js +1 -1
  120. package/dist/es/f/fields/TextInput/TextInput.js +35 -7
  121. package/dist/es/f/fields/TextInput/styles.scss +16 -7
  122. package/dist/es/f/fields/TextareaInput/TextareaInput.js +15 -8
  123. package/dist/es/f/fields/TextareaInput/styles.scss +19 -6
  124. package/dist/es/f/fields/index.js +0 -3
  125. package/dist/es/form-reset.scss +1 -1
  126. package/dist/es/index.js +2 -1
  127. package/dist/es/utils/hooks/index.js +2 -0
  128. package/dist/es/utils/hooks/useDynamicPosition.js +93 -0
  129. package/dist/es/utils/hooks/useWindowSize.js +27 -0
  130. package/dist/es/utils/index.js +1 -0
  131. package/package.json +4 -3
  132. package/src/__snapshots__/Storyshots.test.js.snap +4755 -1734
  133. package/src/local.scss +2 -0
  134. package/src/stories/StyleGuide/Sprites.stories.mdx +25 -0
  135. package/src/stories/StyleGuide/helpers.js +16 -0
  136. package/src/stories/a/BackgroundGradient.stories.jsx +38 -0
  137. package/src/stories/a/ContentTree.stories.jsx +662 -0
  138. package/src/stories/a/Conversation.stories.jsx +78 -1
  139. package/src/stories/a/OvalIllustration.stories.jsx +59 -0
  140. package/src/stories/a/Popover.stories.jsx +106 -0
  141. package/src/stories/a/Shapes.stories.jsx +143 -0
  142. package/src/stories/a/SnapScroller.stories.jsx +98 -0
  143. package/src/stories/b/Button.stories.jsx +27 -4
  144. package/src/stories/b/Logo.stories.jsx +17 -9
  145. package/src/stories/b/Page.stories.jsx +51 -1
  146. package/src/stories/c/ContentSlides.stories.jsx +154 -2
  147. package/src/stories/c/SocialMediaShareButton.stories.jsx +25 -0
  148. package/src/stories/f/RatingsInput.stories.jsx +3 -2
  149. package/src/stories/f/SelectInput.stories.jsx +36 -5
  150. package/src/stories/f/TextInput.stories.jsx +15 -4
  151. package/src/stories/f/TextareaInput.stories.jsx +42 -6
  152. package/src/stories/utils/lorem.js +15 -0
  153. package/src/ui/a/BackgroundGradient/BackgroundGradient.jsx +76 -0
  154. package/src/ui/a/BackgroundGradient/index.js +2 -0
  155. package/src/ui/a/BackgroundGradient/styles.scss +16 -0
  156. package/src/ui/a/ContentTree/ContentTree.jsx +88 -0
  157. package/src/ui/a/ContentTree/common/Tree/Tree.jsx +138 -0
  158. package/src/ui/a/ContentTree/common/Tree/index.js +2 -0
  159. package/src/ui/a/ContentTree/common/index.js +3 -0
  160. package/src/ui/a/ContentTree/common/useContentTree.js +83 -0
  161. package/src/ui/a/ContentTree/common/useFirstVisibleNode.js +59 -0
  162. package/src/ui/a/ContentTree/index.js +2 -0
  163. package/src/ui/a/ContentTree/styles.scss +33 -0
  164. package/src/ui/a/Conversation/Conversation.jsx +15 -7
  165. package/src/ui/a/Conversation/common/Message/Message.jsx +38 -6
  166. package/src/ui/a/Conversation/styles.scss +132 -33
  167. package/src/ui/a/OvalIllustration/OvalIllustration.jsx +134 -0
  168. package/src/ui/a/OvalIllustration/index.js +2 -0
  169. package/src/ui/a/OvalIllustration/styles.scss +102 -0
  170. package/src/ui/a/Popover/Popover.jsx +157 -0
  171. package/src/ui/a/Popover/index.js +2 -0
  172. package/src/ui/a/Popover/styles.scss +43 -0
  173. package/src/ui/a/Shapes/Shapes.jsx +191 -0
  174. package/src/ui/a/Shapes/index.js +2 -0
  175. package/src/ui/a/Shapes/styles.scss +255 -0
  176. package/src/ui/a/SnapScroller/SnapScroller.jsx +83 -0
  177. package/src/ui/a/SnapScroller/index.js +2 -0
  178. package/src/ui/a/SnapScroller/styles.scss +38 -0
  179. package/src/ui/a/index.js +6 -0
  180. package/src/ui/b/Button/Button.jsx +9 -1
  181. package/src/ui/b/Button/styles.scss +55 -10
  182. package/src/ui/b/Logo/Logo.jsx +41 -41
  183. package/src/ui/b/Logo/styles.scss +0 -138
  184. package/src/ui/b/Page/common/Section/Section.jsx +68 -2
  185. package/src/ui/b/Page/styles.scss +8 -2
  186. package/src/ui/c/ContentSlides/common/HorizontalMenu/HorizontalMenu.jsx +12 -5
  187. package/src/ui/c/ContentSlides/common/Navigator/Navigator.jsx +3 -2
  188. package/src/ui/c/ContentSlides/styles.scss +10 -4
  189. package/src/ui/c/SocialMediaShareButton/SocialMediaShareButton.jsx +113 -0
  190. package/src/ui/c/SocialMediaShareButton/index.js +2 -0
  191. package/src/ui/c/SocialMediaShareButton/styles.scss +39 -0
  192. package/src/ui/c/index.js +1 -0
  193. package/src/ui/f/common/Debugger/Debugger.jsx +1 -1
  194. package/src/ui/f/common/Label/Label.jsx +1 -1
  195. package/src/ui/f/common/Label/styles.scss +1 -1
  196. package/src/ui/f/fields/ChoicesInput/ChoicesInput.jsx +1 -1
  197. package/src/ui/f/fields/ChoicesInput/styles.scss +17 -2
  198. package/src/ui/f/fields/RatingsInput/RatingsInput.jsx +54 -19
  199. package/src/ui/f/fields/RatingsInput/styles.scss +29 -20
  200. package/src/ui/f/fields/SelectInput/SelectInput.jsx +43 -5
  201. package/src/ui/f/fields/SelectInput/styles.scss +13 -8
  202. package/src/ui/f/fields/TextInput/TextInput.jsx +31 -3
  203. package/src/ui/f/fields/TextInput/styles.scss +16 -7
  204. package/src/ui/f/fields/TextareaInput/TextareaInput.jsx +24 -13
  205. package/src/ui/f/fields/TextareaInput/styles.scss +19 -6
  206. package/src/ui/f/fields/index.js +0 -3
  207. package/src/ui/form-reset.scss +1 -1
  208. package/src/ui/index.js +1 -0
  209. package/src/ui/utils/hooks/index.js +2 -0
  210. package/src/ui/utils/hooks/useDynamicPosition.js +104 -0
  211. package/src/ui/utils/hooks/useWindowSize.js +32 -0
  212. package/src/ui/utils/index.js +1 -0
  213. package/stylelint.config.js +13 -13
  214. package/src/stories/f/CheckboxInput.stories.jsx +0 -37
  215. package/src/stories/f/RadioInput.stories.jsx +0 -37
  216. package/src/stories/f/TaskRecommendationInput.stories.jsx +0 -38
  217. package/src/ui/f/fields/CheckboxInput/CheckboxInput.jsx +0 -107
  218. package/src/ui/f/fields/CheckboxInput/index.js +0 -2
  219. package/src/ui/f/fields/CheckboxInput/styles.scss +0 -28
  220. package/src/ui/f/fields/RadioInput/RadioInput.jsx +0 -112
  221. package/src/ui/f/fields/RadioInput/index.js +0 -2
  222. package/src/ui/f/fields/RadioInput/styles.scss +0 -26
  223. package/src/ui/f/fields/TaskRecommendationInput/TaskRecommendationInput.jsx +0 -130
  224. package/src/ui/f/fields/TaskRecommendationInput/index.js +0 -2
  225. package/src/ui/f/fields/TaskRecommendationInput/styles.scss +0 -41
@@ -0,0 +1,67 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+
8
+ var React = _interopRequireWildcard(require("react"));
9
+
10
+ var _propTypes = _interopRequireDefault(require("prop-types"));
11
+
12
+ var _bem = _interopRequireDefault(require("@pareto-engineering/bem"));
13
+
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
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); }
17
+
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; }
19
+
20
+ /* @pareto-engineering/generator-front 1.0.12 */
21
+ // Local Definitions
22
+ var baseClassName = _bem.default.base;
23
+ var componentClassName = 'item';
24
+ /**
25
+ * This is the component description.
26
+ */
27
+
28
+ var Item = _ref => {
29
+ var {
30
+ id,
31
+ className: userClassName,
32
+ style,
33
+ children // ...otherProps
34
+
35
+ } = _ref;
36
+ return /*#__PURE__*/React.createElement("div", {
37
+ id: id,
38
+ className: [baseClassName, componentClassName, userClassName].filter(e => e).join(' '),
39
+ style: style
40
+ }, children);
41
+ };
42
+
43
+ Item.propTypes = {
44
+ /**
45
+ * The HTML id for this element
46
+ */
47
+ id: _propTypes.default.string,
48
+
49
+ /**
50
+ * The HTML class names for this element
51
+ */
52
+ className: _propTypes.default.string,
53
+
54
+ /**
55
+ * The React-written, css properties for this element.
56
+ */
57
+ style: _propTypes.default.objectOf(_propTypes.default.string),
58
+
59
+ /**
60
+ * The children JSX
61
+ */
62
+ children: _propTypes.default.node
63
+ };
64
+ Item.defaultProps = {// someProp:false
65
+ };
66
+ var _default = Item;
67
+ exports.default = _default;
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "Item", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _Item.default;
10
+ }
11
+ });
12
+
13
+ var _Item = _interopRequireDefault(require("./Item"));
14
+
15
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "Item", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _Item.Item;
10
+ }
11
+ });
12
+ Object.defineProperty(exports, "Divider", {
13
+ enumerable: true,
14
+ get: function get() {
15
+ return _Divider.Divider;
16
+ }
17
+ });
18
+
19
+ var _Item = require("./Item");
20
+
21
+ var _Divider = require("./Divider");
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "Popover", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _Popover.default;
10
+ }
11
+ });
12
+
13
+ var _Popover = _interopRequireDefault(require("./Popover"));
14
+
15
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -0,0 +1,43 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ @use "@pareto-engineering/bem";
3
+
4
+ $default-padding: 1em;
5
+ $default-margin: 1em;
6
+ $default-border: var(--theme-border-style) var(--metadata);
7
+
8
+ .#{bem.$base}.popover{
9
+ position: absolute;
10
+ z-index: 1;
11
+ background-color: var(--x);
12
+ padding: $default-padding;
13
+ border: $default-border;
14
+
15
+ &:not(.open) {
16
+ display: none;
17
+ }
18
+
19
+ > *:not(:last-child) {
20
+ margin-bottom: $default-margin / 2;
21
+ }
22
+
23
+ &.bottom {
24
+ top: 100%;
25
+ // bottom: 0;
26
+ }
27
+
28
+ &.left {
29
+ left: 0;
30
+ }
31
+
32
+ &.right {
33
+ right: 0;
34
+ }
35
+
36
+ &.top {
37
+ bottom: 100%;
38
+ top: auto;
39
+ }
40
+ }
41
+
42
+
43
+
@@ -35,9 +35,11 @@ var Shapes = _ref => {
35
35
  id,
36
36
  className: userClassName,
37
37
  style,
38
- pin,
39
38
  shape,
40
- height // ...otherProps
39
+ height,
40
+ overflow,
41
+ verticalAlign,
42
+ horizontalAlign // ...otherProps
41
43
 
42
44
  } = _ref;
43
45
  (0, React.useLayoutEffect)(() => {
@@ -47,12 +49,16 @@ var Shapes = _ref => {
47
49
  id: id,
48
50
  className: [baseClassName, componentClassName, userClassName].filter(e => e).join(' '),
49
51
  style: _objectSpread(_objectSpread({}, style), {}, {
50
- '--pin': pin,
51
- '--shape-height': height
52
+ '--shape-height': height,
53
+ '--overflow': overflow,
54
+ '--vertical-align': verticalAlign,
55
+ '--horizontal-align': horizontalAlign
52
56
  }) // {...otherProps}
53
57
 
54
58
  }, shape === 'triangle' && /*#__PURE__*/React.createElement("div", {
55
59
  className: "triangle"
60
+ }), shape === 'inverted-triangle' && /*#__PURE__*/React.createElement("div", {
61
+ className: "inverted-triangle"
56
62
  }), shape === 'half-ellipses' && /*#__PURE__*/React.createElement("div", {
57
63
  className: "half-ellipses"
58
64
  }, /*#__PURE__*/React.createElement("div", {
@@ -99,6 +105,18 @@ var Shapes = _ref => {
99
105
  className: "circle-three"
100
106
  }), /*#__PURE__*/React.createElement("div", {
101
107
  className: "circle-four"
108
+ })), shape === 'rotated-ellipses' && /*#__PURE__*/React.createElement("div", {
109
+ className: "rotated-ellipses"
110
+ }, /*#__PURE__*/React.createElement("div", {
111
+ className: "ellipse-one"
112
+ }), /*#__PURE__*/React.createElement("div", {
113
+ className: "ellipse-two"
114
+ })), shape === 'intersecting-circles' && /*#__PURE__*/React.createElement("div", {
115
+ className: "intersecting-circles"
116
+ }, /*#__PURE__*/React.createElement("div", {
117
+ className: "left"
118
+ }), /*#__PURE__*/React.createElement("div", {
119
+ className: "right"
102
120
  })));
103
121
  };
104
122
 
@@ -124,18 +142,30 @@ Shapes.propTypes = {
124
142
  height: _propTypes.default.string,
125
143
 
126
144
  /**
127
- * Where to pin the shapes
145
+ * The vertical alignment of the shape.
146
+ */
147
+ verticalAlign: _propTypes.default.oneOf(['flex-start', 'center', 'flex-end']),
148
+
149
+ /**
150
+ * The horizontal alignment of the shape.
128
151
  */
129
- pin: _propTypes.default.oneOf(['flex-start', 'center', 'flex-end']),
152
+ horizontalAlign: _propTypes.default.oneOf(['flex-start', 'center', 'flex-end']),
130
153
 
131
154
  /**
132
155
  * The options of a shape to use
133
156
  */
134
- shape: _propTypes.default.oneOf(['triangle', 'ellipse', 'half-ellipse', 'half-ellipses', 'spiral', 'diamonds', 'circle', 'half-circle', 'ellipses', 'rectangles'])
157
+ shape: _propTypes.default.oneOf(['triangle', 'ellipse', 'half-ellipse', 'half-ellipses', 'spiral', 'diamonds', 'circle', 'half-circle', 'ellipses', 'rectangles', 'rotated-ellipses', 'inverted-triangle', 'intersecting-circles']),
158
+
159
+ /**
160
+ * The overflow of the shape.
161
+ */
162
+ overflow: _propTypes.default.oneOf(['hidden', 'visible'])
135
163
  };
136
164
  Shapes.defaultProps = {
137
- pin: 'center',
138
- shape: 'triangle'
165
+ verticalAlign: 'center',
166
+ horizontalAlign: 'center',
167
+ shape: 'triangle',
168
+ overflow: 'hidden'
139
169
  };
140
170
  var _default = Shapes;
141
171
  exports.default = _default;
@@ -15,8 +15,9 @@ $default-shapes-opacity:.8;
15
15
  left: 0;
16
16
  display: flex;
17
17
  flex-direction: column;
18
- justify-content: var(--pin);
19
- align-items: center;
18
+ overflow: var(--overflow);
19
+ justify-content: var(--vertical-align);
20
+ align-items: var(--horizontal-align);
20
21
  height: 100%;
21
22
  width: 100%;
22
23
 
@@ -28,30 +29,37 @@ $default-shapes-opacity:.8;
28
29
  width: var(--shape-height, #{$default-triangle-height});
29
30
  }
30
31
 
32
+ .inverted-triangle {
33
+ background-image: linear-gradient(var(--dark-y), var(--light-y));
34
+ clip-path: polygon(50% 0, 0 100%, 100% 100%);
35
+ height: calc(var(--shape-height, #{$default-triangle-height}) * 0.86);
36
+ opacity: $default-shapes-opacity;
37
+ width: var(--shape-height, #{$default-triangle-height});
38
+ }
39
+
31
40
  .half-ellipses {
32
41
  height: var(--shape-height, #{$default-ellipse-height});
33
42
  opacity: $default-shapes-opacity;
34
43
  width: calc(var(--shape-height, #{$default-ellipse-height}) * 2);
35
44
 
36
45
  .up {
37
- background-image: linear-gradient(var(--light-y), var(--y));
38
- clip-path: ellipse(40% 100% at 50% 0%);
46
+ background-image: radial-gradient(ellipse at center bottom, var(--y) 5%, transparent 65%);
47
+ clip-path: ellipse(35% 100% at 50% 0%);
39
48
  height: 50%;
40
49
  }
41
50
 
42
51
  .down {
43
- background-image: linear-gradient(to top, var(--light-y), var(--y));
44
- clip-path: ellipse(40% 100% at 50% 100%);
52
+ background-image: radial-gradient(ellipse at center top, var(--y) 5%, transparent 65%);
53
+ clip-path: ellipse(35% 100% at 50% 100%);
45
54
  height: 50%;
46
55
  }
47
56
  }
48
57
 
49
58
  .ellipse {
50
- background-image: linear-gradient(to top left, var(--dark-y), var(--light-y), var(--dark-y));
51
- clip-path: ellipse(50% 25% at 50% 50%);
59
+ background-image: linear-gradient(var(--dark-y), var(--light-y));
60
+ clip-path: ellipse(50% 50% at 50% 50%);
52
61
  height: var(--shape-height, #{$default-ellipse-height});
53
62
  opacity: $default-shapes-opacity;
54
- transform: rotate3d(0, 0, -1, 10deg);
55
63
  width: calc(var(--shape-height, #{$default-ellipse-height}) * 2);
56
64
  }
57
65
 
@@ -109,15 +117,15 @@ $default-shapes-opacity:.8;
109
117
  }
110
118
 
111
119
  .half-ellipse {
112
- background-image: linear-gradient(var(--light-y), var(--dark-y));
113
- clip-path: ellipse(50% 50% at 50% 0);
120
+ background-image: radial-gradient(ellipse at center bottom, var(--y) 10%, var(--light-y) 65%);
121
+ clip-path: ellipse(60% 100% at 50% 0%);
114
122
  height: var(--shape-height, #{$default-ellipse-height});
115
123
  opacity: $default-shapes-opacity;
116
124
  width: calc(var(--shape-height, #{$default-ellipse-height}) * 2);
117
125
  }
118
126
 
119
127
  .circle {
120
- background-image: linear-gradient(var(--light-y), var(--dark-y));
128
+ background-image: linear-gradient(var(--dark-y), var(--light-y));
121
129
  clip-path: circle(50% at 50% 50%);
122
130
  height: var(--shape-height, #{$default-circle-height});
123
131
  opacity: $default-shapes-opacity;
@@ -139,7 +147,7 @@ $default-shapes-opacity:.8;
139
147
  width: var(--shape-height, #{$default-ellipse-height});
140
148
 
141
149
  .first {
142
- background-image: linear-gradient(to top, var(--dark-y), var(--y), var(--light-y) 50%, transparent);
150
+ background-image: linear-gradient(to top, var(--dark-y), var(--y), var(--light-y) 50%, var(--background1));
143
151
  clip-path: ellipse(50% 20% at 50% 60%);
144
152
  height: 100%;
145
153
  position: absolute;
@@ -148,7 +156,7 @@ $default-shapes-opacity:.8;
148
156
  }
149
157
 
150
158
  .second {
151
- background-image: linear-gradient(to bottom,var(--dark-y), var(--y), var(--light-y) 45%, transparent);
159
+ background-image: linear-gradient(to bottom,var(--dark-y), var(--y), var(--light-y) 45%, var(--background1));
152
160
  clip-path: ellipse(50% 20% at 50% 40%);
153
161
  height: 100%;
154
162
  position: absolute;
@@ -167,33 +175,81 @@ $default-shapes-opacity:.8;
167
175
 
168
176
  > * {
169
177
  border-radius: 50%;
170
- background: radial-gradient(ellipse at center bottom ,var(--dark-y) 10%, transparent 60%);
178
+ background: radial-gradient(ellipse at center bottom, var(--dark-y) 10%, var(--light-y) 60%);
171
179
  position: absolute;
172
180
  opacity: .5;
173
181
  }
174
182
 
175
183
  .circle-one {
176
184
  transform: rotate(45deg);
177
- height: 55%;
178
- width: 55%;
185
+ height:calc(var(--shape-height, #{$default-ellipse-height})* 0.4);
186
+ width: calc(var(--shape-height, #{$default-ellipse-height})* 0.4);
179
187
  }
180
188
 
181
189
  .circle-two {
182
- height: 70%;
183
- width: 70%;
190
+ height: calc(var(--shape-height, #{$default-ellipse-height})* 0.6);
191
+ width: calc(var(--shape-height, #{$default-ellipse-height})* 0.6);
184
192
  }
185
193
 
186
194
  .circle-three {
187
195
  transform: rotate(-45deg);
188
- height: 85%;
189
- width: 85%;
196
+ height: calc(var(--shape-height, #{$default-ellipse-height})* 0.8);
197
+ width: calc(var(--shape-height, #{$default-ellipse-height})* 0.8);
190
198
  }
191
199
 
192
200
  .circle-four {
193
201
  transform: rotate(-90deg);
194
- height: 100%;
202
+ height: calc(var(--shape-height, #{$default-ellipse-height})* 1);
203
+ width: calc(var(--shape-height, #{$default-ellipse-height})* 1);
204
+ }
205
+ }
206
+ .rotated-ellipses {
207
+ height: var(--shape-height, #{$default-ellipse-height});
208
+ opacity: $default-shapes-opacity;
209
+ width: var(--shape-height, #{$default-ellipse-height});
210
+ display: flex;
211
+
212
+ > *{
195
213
  width: 100%;
214
+ height: 100%;
215
+ }
216
+
217
+ .ellipse-one {
218
+ background-image: radial-gradient(ellipse at bottom left, var(--y) 30%, transparent 65%);
219
+ transform: rotate(-15deg);
220
+ clip-path: ellipse(50% 35% at 50% 50%);
221
+ }
222
+
223
+ .ellipse-two {
224
+ background-image: radial-gradient(ellipse at top right, var(--y) 30%, transparent 65%);
225
+ transform: rotate(-15deg);
226
+ clip-path: ellipse(50% 35% at 50% 50%);
196
227
  }
197
228
  }
198
229
 
230
+ .intersecting-circles {
231
+ height: var(--shape-height, #{$default-circle-height});
232
+ opacity: $default-shapes-opacity;
233
+ width: calc(var(--shape-height, #{$default-circle-height}) * 2);
234
+ display: grid;
235
+ grid-template-columns: repeat(7, 1fr);
236
+ position: relative;
237
+
238
+ > * {
239
+ border-radius: 50%;
240
+ height: 100%;
241
+ width: 100%;
242
+ position: absolute;
243
+ opacity: .8;
244
+ }
245
+
246
+ .left {
247
+ background-image: linear-gradient(to right ,var(--dark-y),var(--y), var(--light-y));
248
+ grid-column: 1 / 5;
249
+ }
250
+ .right {
251
+ background-image: linear-gradient(to left, var(--dark-y), var(--y), var(--light-y));
252
+ grid-column: 4 / 8;
253
+ }
254
+ }
199
255
  }
@@ -0,0 +1,77 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+
8
+ var React = _interopRequireWildcard(require("react"));
9
+
10
+ var _propTypes = _interopRequireDefault(require("prop-types"));
11
+
12
+ var _bem = _interopRequireDefault(require("@pareto-engineering/bem"));
13
+
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
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); }
17
+
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; }
19
+
20
+ // Local Definitions
21
+ var baseClassName = _bem.default.base;
22
+ var componentClassName = 'snap-scroller';
23
+ /**
24
+ * This is the component description.
25
+ */
26
+
27
+ var SnapScroller = _ref => {
28
+ var {
29
+ id,
30
+ className: userClassName,
31
+ style,
32
+ children,
33
+ noScrollOnDesktop // ...otherProps
34
+
35
+ } = _ref;
36
+ (0, React.useLayoutEffect)(() => {
37
+ Promise.resolve().then(() => _interopRequireWildcard(require("./styles.scss")));
38
+ }, []);
39
+ return /*#__PURE__*/React.createElement("div", {
40
+ id: id,
41
+ className: [baseClassName, componentClassName, userClassName, noScrollOnDesktop && 'desktop-no-scroll'].filter(e => e).join(' '),
42
+ style: style // {...otherProps}
43
+
44
+ }, children);
45
+ };
46
+
47
+ SnapScroller.propTypes = {
48
+ /**
49
+ * The HTML id for this element
50
+ */
51
+ id: _propTypes.default.string,
52
+
53
+ /**
54
+ * The HTML class names for this element
55
+ */
56
+ className: _propTypes.default.string,
57
+
58
+ /**
59
+ * The React-written, css properties for this element.
60
+ */
61
+ style: _propTypes.default.objectOf(_propTypes.default.string),
62
+
63
+ /**
64
+ * The children JSX
65
+ */
66
+ children: _propTypes.default.node,
67
+
68
+ /**
69
+ * Whether to snap scroll on desktop (false will enable a flexbox)
70
+ */
71
+ noScrollOnDesktop: _propTypes.default.bool
72
+ };
73
+ SnapScroller.defaultProps = {
74
+ noScrollOnDesktop: false
75
+ };
76
+ var _default = SnapScroller;
77
+ exports.default = _default;
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "SnapScroller", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _SnapScroller.default;
10
+ }
11
+ });
12
+
13
+ var _SnapScroller = _interopRequireDefault(require("./SnapScroller"));
14
+
15
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -0,0 +1,38 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+
3
+ @use "@pareto-engineering/bem";
4
+ @use "@aztlan/stylebook/src/mixins";
5
+ @use "@aztlan/stylebook/src/globals" as *;
6
+
7
+ $default-spacing:var(--spacing, var(--u));
8
+
9
+ .#{bem.$base}.snap-scroller {
10
+ display: flex;
11
+ -ms-overflow-style: none; /* for Internet Explorer, Edge */
12
+ overflow-x: auto;
13
+ scroll-padding: calc(#{$default-spacing} *2);
14
+ scroll-snap-type: x mandatory;
15
+ scrollbar-width: none;
16
+
17
+
18
+ > * {
19
+ &:first-child {
20
+ margin-left: $default-spacing;
21
+ }
22
+ display: inline-block;
23
+ margin-right: $default-spacing;
24
+ scroll-snap-align: start;
25
+ }
26
+
27
+
28
+ @include mixins.media($from:$sm-md) {
29
+ &.desktop-no-scroll {
30
+ overflow: auto;
31
+ -ms-overflow-style: unset; /* for Internet Explorer, Edge */
32
+ scroll-snap-type: none;
33
+ scrollbar-width: unset;
34
+ }
35
+ }
36
+ }
37
+
38
+
@@ -141,6 +141,42 @@ Object.defineProperty(exports, "Timestamp", {
141
141
  return _Timestamp.Timestamp;
142
142
  }
143
143
  });
144
+ Object.defineProperty(exports, "Shapes", {
145
+ enumerable: true,
146
+ get: function get() {
147
+ return _Shapes.Shapes;
148
+ }
149
+ });
150
+ Object.defineProperty(exports, "OvalIllustration", {
151
+ enumerable: true,
152
+ get: function get() {
153
+ return _OvalIllustration.OvalIllustration;
154
+ }
155
+ });
156
+ Object.defineProperty(exports, "SnapScroller", {
157
+ enumerable: true,
158
+ get: function get() {
159
+ return _SnapScroller.SnapScroller;
160
+ }
161
+ });
162
+ Object.defineProperty(exports, "BackgroundGradient", {
163
+ enumerable: true,
164
+ get: function get() {
165
+ return _BackgroundGradient.BackgroundGradient;
166
+ }
167
+ });
168
+ Object.defineProperty(exports, "ContentTree", {
169
+ enumerable: true,
170
+ get: function get() {
171
+ return _ContentTree.ContentTree;
172
+ }
173
+ });
174
+ Object.defineProperty(exports, "Popover", {
175
+ enumerable: true,
176
+ get: function get() {
177
+ return _Popover.Popover;
178
+ }
179
+ });
144
180
 
145
181
  var _SVG = require("./SVG");
146
182
 
@@ -180,4 +216,16 @@ var _ContentCard = require("./ContentCard");
180
216
 
181
217
  var _DotInfo = require("./DotInfo");
182
218
 
183
- var _Timestamp = require("./Timestamp");
219
+ var _Timestamp = require("./Timestamp");
220
+
221
+ var _Shapes = require("./Shapes");
222
+
223
+ var _OvalIllustration = require("./OvalIllustration");
224
+
225
+ var _SnapScroller = require("./SnapScroller");
226
+
227
+ var _BackgroundGradient = require("./BackgroundGradient");
228
+
229
+ var _ContentTree = require("./ContentTree");
230
+
231
+ var _Popover = require("./Popover");
@@ -13,7 +13,7 @@ var _bem = _interopRequireDefault(require("@pareto-engineering/bem"));
13
13
 
14
14
  var _ = require("../..");
15
15
 
16
- var _excluded = ["id", "className", "style", "children", "isLoading", "color", "isCompact", "isGhost", "isSimple"];
16
+ var _excluded = ["id", "className", "style", "children", "isLoading", "color", "isCompact", "isGhost", "isSimple", "arrowDirection"];
17
17
 
18
18
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
19
19
 
@@ -43,7 +43,8 @@ var Button = _ref => {
43
43
  color,
44
44
  isCompact,
45
45
  isGhost,
46
- isSimple
46
+ isSimple,
47
+ arrowDirection
47
48
  } = _ref,
48
49
  otherProps = _objectWithoutProperties(_ref, _excluded);
49
50
 
@@ -52,7 +53,7 @@ var Button = _ref => {
52
53
  }, []);
53
54
  return /*#__PURE__*/React.createElement("button", _extends({
54
55
  id: id,
55
- className: [baseClassName, componentClassName, userClassName, "x-".concat(color), isGhost && _bem.default.modifierGhost, isCompact && _bem.default.modifierCompact, isSimple && _bem.default.modifierSimple].filter(e => e).join(' '),
56
+ className: [baseClassName, componentClassName, userClassName, "x-".concat(color), isGhost && _bem.default.modifierGhost, isCompact && _bem.default.modifierCompact, isSimple && _bem.default.modifierSimple, arrowDirection && "arrow-".concat(arrowDirection)].filter(e => e).join(' '),
56
57
  style: style,
57
58
  type: "button"
58
59
  }, otherProps), isLoading ? /*#__PURE__*/React.createElement(_.LoadingCircle, {
@@ -107,7 +108,12 @@ Button.propTypes = {
107
108
  /**
108
109
  * Button loading state
109
110
  */
110
- isLoading: _propTypes.default.bool
111
+ isLoading: _propTypes.default.bool,
112
+
113
+ /**
114
+ * The direction of the arrow if the button has one
115
+ */
116
+ arrowDirection: _propTypes.default.string
111
117
  };
112
118
  Button.defaultProps = {
113
119
  color: 'main1'