@pareto-engineering/design-system 4.0.0-alpha.5 → 4.0.0-alpha.9

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 (136) hide show
  1. package/dist/cjs/a/AnimatedBlobs/AnimatedBlobs.js +90 -0
  2. package/dist/cjs/a/AnimatedBlobs/index.js +13 -0
  3. package/dist/cjs/a/AnimatedBlobs/styles.scss +87 -0
  4. package/dist/cjs/a/AnimatedGradient/AnimatedGradient.js +56 -0
  5. package/dist/cjs/a/AnimatedGradient/index.js +13 -0
  6. package/dist/cjs/a/AnimatedGradient/styles.scss +14 -0
  7. package/dist/cjs/a/AnimatedGradient/webGIRenderer.js +528 -0
  8. package/dist/cjs/a/ContentTree/ContentTree.js +1 -1
  9. package/dist/cjs/a/Label/Label.js +12 -4
  10. package/dist/cjs/a/Label/styles.scss +1 -1
  11. package/dist/cjs/a/MetaCard/MetaCard.js +60 -0
  12. package/dist/cjs/a/MetaCard/index.js +13 -0
  13. package/dist/cjs/a/MetaCard/styles.scss +28 -0
  14. package/dist/cjs/a/Popover/Popover.js +1 -1
  15. package/dist/cjs/a/SnapScroller/styles.scss +18 -10
  16. package/dist/cjs/a/TextSteps/TextSteps.js +70 -0
  17. package/dist/cjs/a/TextSteps/index.js +13 -0
  18. package/dist/cjs/a/TextSteps/styles.scss +29 -0
  19. package/dist/cjs/a/Tip/Tip.js +72 -0
  20. package/dist/cjs/a/Tip/index.js +13 -0
  21. package/dist/cjs/a/Tip/styles.scss +22 -0
  22. package/dist/cjs/a/index.js +36 -1
  23. package/dist/cjs/b/Button/styles.scss +2 -0
  24. package/dist/cjs/b/Card/Card.js +74 -0
  25. package/dist/cjs/b/Card/common/Group/Group.js +73 -0
  26. package/dist/cjs/b/Card/common/Group/index.js +13 -0
  27. package/dist/cjs/b/Card/common/Group/styles.scss +42 -0
  28. package/dist/cjs/b/Card/common/Section/Section.js +59 -0
  29. package/dist/cjs/b/Card/common/Section/index.js +13 -0
  30. package/dist/cjs/b/Card/common/index.js +19 -0
  31. package/dist/cjs/b/Card/index.js +13 -0
  32. package/dist/cjs/b/Card/styles.scss +46 -0
  33. package/dist/cjs/b/Page/Page.js +9 -2
  34. package/dist/cjs/b/Page/common/Section/Section.js +6 -1
  35. package/dist/cjs/b/Page/styles.scss +22 -4
  36. package/dist/cjs/b/index.js +8 -1
  37. package/dist/cjs/f/fields/ChoicesInput/ChoicesInput.js +15 -7
  38. package/dist/cjs/f/fields/ChoicesInput/styles.scss +21 -33
  39. package/dist/cjs/f/fields/SelectInput/SelectInput.js +2 -2
  40. package/dist/cjs/f/fields/SelectInput/styles.scss +31 -21
  41. package/dist/cjs/f/fields/TextInput/TextInput.js +4 -2
  42. package/dist/cjs/f/fields/TextInput/styles.scss +26 -17
  43. package/dist/es/a/AnimatedBlobs/AnimatedBlobs.js +82 -0
  44. package/dist/es/a/AnimatedBlobs/index.js +1 -0
  45. package/dist/es/a/AnimatedBlobs/styles.scss +87 -0
  46. package/dist/es/a/AnimatedGradient/AnimatedGradient.js +48 -0
  47. package/dist/es/a/AnimatedGradient/index.js +1 -0
  48. package/dist/es/a/AnimatedGradient/styles.scss +14 -0
  49. package/dist/es/a/AnimatedGradient/webGIRenderer.js +492 -0
  50. package/dist/es/a/ContentTree/ContentTree.js +1 -1
  51. package/dist/es/a/Label/Label.js +12 -4
  52. package/dist/es/a/Label/styles.scss +1 -1
  53. package/dist/es/a/MetaCard/MetaCard.js +52 -0
  54. package/dist/es/a/MetaCard/index.js +1 -0
  55. package/dist/es/a/MetaCard/styles.scss +28 -0
  56. package/dist/es/a/Popover/Popover.js +1 -1
  57. package/dist/es/a/SnapScroller/styles.scss +18 -10
  58. package/dist/es/a/TextSteps/TextSteps.js +61 -0
  59. package/dist/es/a/TextSteps/index.js +1 -0
  60. package/dist/es/a/TextSteps/styles.scss +29 -0
  61. package/dist/es/a/Tip/Tip.js +64 -0
  62. package/dist/es/a/Tip/index.js +2 -0
  63. package/dist/es/a/Tip/styles.scss +22 -0
  64. package/dist/es/a/index.js +6 -1
  65. package/dist/es/b/Button/styles.scss +2 -0
  66. package/dist/es/b/Card/Card.js +66 -0
  67. package/dist/es/b/Card/common/Group/Group.js +65 -0
  68. package/dist/es/b/Card/common/Group/index.js +1 -0
  69. package/dist/es/b/Card/common/Group/styles.scss +42 -0
  70. package/dist/es/b/Card/common/Section/Section.js +48 -0
  71. package/dist/es/b/Card/common/Section/index.js +1 -0
  72. package/dist/es/b/Card/common/index.js +2 -0
  73. package/dist/es/b/Card/index.js +1 -0
  74. package/dist/es/b/Card/styles.scss +46 -0
  75. package/dist/es/b/Page/Page.js +9 -2
  76. package/dist/es/b/Page/common/Section/Section.js +6 -1
  77. package/dist/es/b/Page/styles.scss +22 -4
  78. package/dist/es/b/index.js +2 -1
  79. package/dist/es/f/fields/ChoicesInput/ChoicesInput.js +16 -8
  80. package/dist/es/f/fields/ChoicesInput/styles.scss +21 -33
  81. package/dist/es/f/fields/SelectInput/SelectInput.js +2 -2
  82. package/dist/es/f/fields/SelectInput/styles.scss +31 -21
  83. package/dist/es/f/fields/TextInput/TextInput.js +4 -2
  84. package/dist/es/f/fields/TextInput/styles.scss +26 -17
  85. package/package.json +15 -15
  86. package/src/stories/a/MetaCard.stories.jsx +35 -0
  87. package/src/stories/a/TextSteps.stories.jsx +19 -0
  88. package/src/stories/a/Tip.stories.jsx +28 -0
  89. package/src/stories/b/Card/Card.stories.jsx +59 -0
  90. package/src/stories/b/Card/Group.stories.jsx +59 -0
  91. package/src/stories/b/Page.stories.jsx +19 -3
  92. package/src/stories/f/SelectInput.stories.jsx +7 -0
  93. package/src/stories/f/TextInput.stories.jsx +4 -4
  94. package/src/ui/a/AnimatedBlobs/AnimatedBlobs.jsx +102 -0
  95. package/src/ui/a/AnimatedBlobs/index.js +1 -0
  96. package/src/ui/a/AnimatedBlobs/styles.scss +87 -0
  97. package/src/ui/a/AnimatedGradient/AnimatedGradient.jsx +69 -0
  98. package/src/ui/a/AnimatedGradient/index.js +1 -0
  99. package/src/ui/a/AnimatedGradient/styles.scss +14 -0
  100. package/src/ui/a/AnimatedGradient/webGIRenderer.js +541 -0
  101. package/src/ui/a/ContentTree/ContentTree.jsx +1 -1
  102. package/src/ui/a/Label/Label.jsx +11 -2
  103. package/src/ui/a/Label/styles.scss +1 -1
  104. package/src/ui/a/MetaCard/MetaCard.jsx +74 -0
  105. package/src/ui/a/MetaCard/index.js +1 -0
  106. package/src/ui/a/MetaCard/styles.scss +28 -0
  107. package/src/ui/a/Popover/Popover.jsx +1 -1
  108. package/src/ui/a/SnapScroller/styles.scss +18 -10
  109. package/src/ui/a/TextSteps/TextSteps.jsx +87 -0
  110. package/src/ui/a/TextSteps/index.js +1 -0
  111. package/src/ui/a/TextSteps/styles.scss +29 -0
  112. package/src/ui/a/Tip/Tip.jsx +88 -0
  113. package/src/ui/a/Tip/index.js +2 -0
  114. package/src/ui/a/Tip/styles.scss +22 -0
  115. package/src/ui/a/index.js +5 -0
  116. package/src/ui/b/Button/styles.scss +2 -0
  117. package/src/ui/b/Card/Card.jsx +94 -0
  118. package/src/ui/b/Card/common/Group/Group.jsx +91 -0
  119. package/src/ui/b/Card/common/Group/index.js +1 -0
  120. package/src/ui/b/Card/common/Group/styles.scss +42 -0
  121. package/src/ui/b/Card/common/Section/Section.jsx +70 -0
  122. package/src/ui/b/Card/common/Section/index.js +1 -0
  123. package/src/ui/b/Card/common/index.js +2 -0
  124. package/src/ui/b/Card/index.js +1 -0
  125. package/src/ui/b/Card/styles.scss +46 -0
  126. package/src/ui/b/Page/Page.jsx +7 -1
  127. package/src/ui/b/Page/common/Section/Section.jsx +8 -0
  128. package/src/ui/b/Page/styles.scss +22 -4
  129. package/src/ui/b/index.js +1 -0
  130. package/src/ui/f/fields/ChoicesInput/ChoicesInput.jsx +10 -5
  131. package/src/ui/f/fields/ChoicesInput/styles.scss +21 -33
  132. package/src/ui/f/fields/SelectInput/SelectInput.jsx +2 -2
  133. package/src/ui/f/fields/SelectInput/styles.scss +31 -21
  134. package/src/ui/f/fields/TextInput/TextInput.jsx +11 -9
  135. package/src/ui/f/fields/TextInput/styles.scss +26 -17
  136. package/tests/__snapshots__/Storyshots.test.js.snap +1049 -485
@@ -8,7 +8,7 @@ import styleNames from '@pareto-engineering/bem/exports';
8
8
  // Local Definitions
9
9
 
10
10
  import { Choice } from "./common";
11
- import { FormLabel } from "../../common";
11
+ import { FormDescription, FormLabel } from "../../common";
12
12
  const baseClassName = styleNames.base;
13
13
  const componentClassName = 'choices-input';
14
14
 
@@ -26,10 +26,10 @@ const ChoicesInput = ({
26
26
  gridColumnsMobile,
27
27
  gridColumnsDesktop,
28
28
  color,
29
- colorChecked,
30
29
  label,
31
30
  optional,
32
- disabled
31
+ disabled,
32
+ description
33
33
  // ...otherProps
34
34
  }) => {
35
35
  useInsertionEffect(() => {
@@ -37,7 +37,7 @@ const ChoicesInput = ({
37
37
  }, []);
38
38
  return /*#__PURE__*/React.createElement("div", {
39
39
  id: id,
40
- className: [baseClassName, componentClassName, userClassName, multiple && 'multiple', color && `x-${color}`, colorChecked && `y-${colorChecked}`].filter(e => e).join(' '),
40
+ className: [baseClassName, componentClassName, userClassName, multiple && 'multiple', color && `x-${color}`].filter(e => e).join(' '),
41
41
  style: {
42
42
  '--grid-columns-desktop': gridColumnsDesktop,
43
43
  '--grid-columns-mobile': gridColumnsMobile,
@@ -50,13 +50,18 @@ const ChoicesInput = ({
50
50
  }, label), /*#__PURE__*/React.createElement("div", {
51
51
  className: "choices"
52
52
  }, options.map(choice => /*#__PURE__*/React.createElement(Choice, _extends({
53
+ labelClassName: "with-faded-border",
53
54
  key: choice.value,
54
55
  name: name,
55
56
  id: `${name}-${choice.value}`,
56
57
  multiple: multiple,
57
58
  validate: validate,
58
59
  disabled: disabled
59
- }, choice)))));
60
+ }, choice)))), /*#__PURE__*/React.createElement(FormDescription, {
61
+ className: "v50 mt-v s-1",
62
+ description: description,
63
+ name: name
64
+ }));
60
65
  };
61
66
  ChoicesInput.propTypes = {
62
67
  /**
@@ -117,13 +122,16 @@ ChoicesInput.propTypes = {
117
122
  /**
118
123
  * Whether the input is optional or not
119
124
  */
120
- optional: PropTypes.bool
125
+ optional: PropTypes.bool,
126
+ /**
127
+ * The select input description
128
+ */
129
+ description: PropTypes.string
121
130
  };
122
131
  ChoicesInput.defaultProps = {
123
132
  gridColumnsMobile: 2,
124
133
  gridColumnsDesktop: 3,
125
- color: 'background2',
126
- colorChecked: 'main2',
134
+ color: 'main',
127
135
  disabled: false
128
136
  };
129
137
  export default /*#__PURE__*/memo(ChoicesInput);
@@ -5,21 +5,18 @@
5
5
  @use "@pareto-engineering/styles/src/mixins";
6
6
  @use "@pareto-engineering/styles/src/globals" as *;
7
7
 
8
- $default-grid-gap:var(--u, 1em);
9
- $default-padding:var(--u, 1em);
10
- $default-transition:all .3s;
8
+ $default-flex-separator:calc(1em / 2) calc(.75em / 2);
9
+ $default-transition:var(--theme-default-transition);
10
+ $default-label-padding: .3em 1em calc(2em - .3em);
11
+ $default-label-height: .5em;
11
12
 
12
13
  .#{bem.$base}.choices-input {
13
- .choices {
14
- display: grid;
15
- gap: $default-grid-gap;
16
- grid-template-columns: repeat(var(--grid-columns-mobile), 1fr);
14
+ >.choices {
15
+ display: flex;
16
+ flex-wrap: wrap;
17
+ gap: $default-flex-separator;
17
18
 
18
- @include mixins.media($from:$sm-md) {
19
- grid-template-columns: repeat(var(--grid-columns-desktop), 1fr);
20
- }
21
-
22
- .choice {
19
+ >.choice {
23
20
  display: flex;
24
21
 
25
22
  input {
@@ -33,35 +30,26 @@ $default-transition:all .3s;
33
30
  background-color: var(--hard-x);
34
31
  }
35
32
 
36
- input:not(:disabled) + label {
37
- &:hover {
38
- border-color: var(--soft-y);
39
- }
40
- }
41
-
42
33
  label {
43
- background: var(--soft-x);
44
- border: var(--theme-border-style) var(--hard-x);
45
- border-radius: var(--theme-border-radius);
46
- color: var(--on-x);
34
+ background-color: var(--background-inputs);
35
+ border-radius: var(--theme-default-border-radius);
47
36
  cursor: pointer;
48
37
  display: block;
49
- height: 100%;
50
- padding: $default-padding;
38
+ height: $default-label-height;
39
+ max-width: 100%;
40
+ padding: $default-label-padding;
41
+ position: relative;
51
42
  transition: $default-transition;
52
- width: 100%;
53
- }
54
-
55
- input:checked + label {
56
- background: var(--y);
57
- color: var(--on-y);
58
43
 
59
44
  &:hover {
60
- border-color: var(--y);
45
+ box-shadow: var(--theme-default-input-box-shadow);
61
46
  }
62
47
  }
48
+
49
+ input:checked + label {
50
+ background: var(--x);
51
+ color: var(--on-x);
52
+ }
63
53
  }
64
54
  }
65
55
  }
66
-
67
-
@@ -48,7 +48,7 @@ const SelectInput = ({
48
48
  name: name,
49
49
  optional: optional
50
50
  }, label), /*#__PURE__*/React.createElement("div", {
51
- className: "select-wrapper"
51
+ className: "select-wrapper with-faded-border"
52
52
  }, /*#__PURE__*/React.createElement("select", _extends({
53
53
  className: "input"
54
54
  }, field, {
@@ -135,6 +135,6 @@ SelectInput.propTypes = {
135
135
  };
136
136
  SelectInput.defaultProps = {
137
137
  disabled: false,
138
- color: 'background2'
138
+ color: 'interactive'
139
139
  };
140
140
  export default /*#__PURE__*/memo(SelectInput);
@@ -5,20 +5,32 @@
5
5
  @use "../../../form.scss";
6
6
 
7
7
 
8
+ $default-spacing-size: 1em;
8
9
  $default-padding: .75em;
9
- $default-margin: 1em;
10
+ $default-bg-gradient: var(--background-far);
11
+ $default-input-border-radius: var(--theme-default-input-border-radius);
10
12
 
11
13
  .#{bem.$base}.select-input {
12
14
  display: flex;
13
15
  flex-direction: column;
14
16
 
15
17
  .#{bem.$base}.label {
16
- margin-bottom: $default-margin;
18
+ margin-bottom: $default-spacing-size;
17
19
  }
18
20
 
19
- .select-wrapper {
21
+ >.select-wrapper {
22
+ background-color: var(--background-inputs);
23
+ border-radius: $default-input-border-radius;
24
+ padding: $default-padding;
20
25
  position: relative;
21
26
 
27
+ &::after {
28
+ border-radius: $default-input-border-radius;
29
+ }
30
+
31
+ &:not(:disabled):hover {
32
+ box-shadow: var(--default-input-box-shadow);
33
+ }
22
34
  >.#{bem.$base}.loading-circle {
23
35
  position: absolute;
24
36
  right: 0;
@@ -26,24 +38,22 @@ $default-margin: 1em;
26
38
  transform: translateY(-50%);
27
39
  }
28
40
 
29
- >.input {
30
- background: var(--soft-y);
31
- border: var(--theme-border-style) var(--hard-y);
32
- color: var(--on-y);
33
- padding: $default-padding;
34
- width: 100%;
35
-
36
- &:not(:disabled):hover {
37
- border: var(--theme-border-style) var(--soft-background4);
38
- }
39
-
40
- &:disabled {
41
- appearance: none;
42
- background-color: var(--hard-y);
43
- }
44
-
45
- &:focus {
46
- background: var(--y);
41
+ select {
42
+ appearance: none;
43
+ background-color: inherit;
44
+ background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMTIiIHZpZXdCb3g9IjAgMCAyMCAxMiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTE5IDEuNUwxMCAxMC41TDEgMS41IiBzdHJva2U9IiM0QzRENTMiIHN0cm9rZS13aWR0aD0iMiIvPgo8L3N2Zz4=");
45
+ background-position: calc(100% - $default-spacing-size);
46
+ background-repeat: no-repeat;
47
+ background-size: $default-spacing-size;
48
+ padding-right: $default-spacing-size;
49
+
50
+ &.input {
51
+ width: 100%;
52
+
53
+ &:disabled {
54
+ appearance: none;
55
+ opacity: 35%;
56
+ }
47
57
  }
48
58
  }
49
59
  }
@@ -50,14 +50,16 @@ const TextInput = ({
50
50
  name: name,
51
51
  color: labelColor,
52
52
  optional: optional
53
- }, label), /*#__PURE__*/React.createElement("input", _extends({
53
+ }, label), /*#__PURE__*/React.createElement("div", {
54
+ className: "input-wrapper with-faded-border"
55
+ }, /*#__PURE__*/React.createElement("input", _extends({
54
56
  id: name,
55
57
  className: "input",
56
58
  type: type,
57
59
  disabled: disabled,
58
60
  placeholder: placeholder,
59
61
  autoComplete: autoComplete
60
- }, field)), /*#__PURE__*/React.createElement(FormDescription, {
62
+ }, field))), /*#__PURE__*/React.createElement(FormDescription, {
61
63
  className: "v50 mt-v s-1",
62
64
  description: description,
63
65
  name: name
@@ -4,31 +4,40 @@
4
4
  @use "../../../form.scss";
5
5
 
6
6
  $default-padding: .75em .75em .55em;
7
+ $default-input-border-radius: var(--theme-default-input-border-radius);
8
+
7
9
 
8
10
  .#{bem.$base}.text-input {
9
11
  display: flex;
10
12
  flex-direction: column;
11
13
 
12
- .input {
13
- background: var(--soft-y);
14
- border: var(--theme-border-style) var(--hard-y);
15
- color: var(--on-y);
16
- padding: $default-padding;
17
-
18
- &::placeholder {
19
- color: var(--metadata);
20
- }
21
-
22
- &:not(:disabled):hover {
23
- border: var(--theme-border-style) var(--soft-background4);
24
- }
14
+ >.input-wrapper {
15
+ position: relative;
25
16
 
26
- &:disabled {
27
- background-color: var(--hard-y);
17
+ &::after {
18
+ border-radius: $default-input-border-radius;
28
19
  }
29
20
 
30
- &:focus {
31
- background: var(--soft-background4);
21
+ > input {
22
+ background-color: var(--background-inputs);
23
+ border-radius: $default-input-border-radius;
24
+ color: var(--x);
25
+ height: 100%;
26
+ padding: $default-padding;
27
+ width: 100%;
28
+
29
+ &::placeholder {
30
+ color: var(--metadata);
31
+ }
32
+
33
+ &:disabled {
34
+ background-color: var(--hard-x);
35
+ }
36
+
37
+ &:not(:disabled):hover {
38
+ border-radius: $default-input-border-radius;
39
+ box-shadow: var(--theme-default-input-box-shadow);
40
+ }
32
41
  }
33
42
  }
34
43
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pareto-engineering/design-system",
3
- "version": "4.0.0-alpha.5",
3
+ "version": "4.0.0-alpha.9",
4
4
  "description": "",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/es/index.js",
@@ -32,27 +32,27 @@
32
32
  "@babel/cli": "^7.21.0",
33
33
  "@pareto-engineering/eslint-config": "*",
34
34
  "@pareto-engineering/stylelint-config": "*",
35
- "@storybook/addon-essentials": "^7.0.0-rc.3",
36
- "@storybook/addon-interactions": "^7.0.0-rc.3",
37
- "@storybook/addon-links": "^7.0.0-rc.3",
38
- "@storybook/addon-storyshots": "^7.0.0-rc.3",
39
- "@storybook/blocks": "^7.0.0-rc.3",
40
- "@storybook/react": "^7.0.0-rc.3",
41
- "@storybook/react-webpack5": "^7.0.0-rc.3",
42
- "@storybook/testing-library": "^0.0.14-next.1",
35
+ "@storybook/addon-essentials": "^7.0.6",
36
+ "@storybook/addon-interactions": "^7.0.6",
37
+ "@storybook/addon-links": "^7.0.6",
38
+ "@storybook/addon-storyshots": "^7.0.6",
39
+ "@storybook/blocks": "^7.0.6",
40
+ "@storybook/react": "^7.0.6",
41
+ "@storybook/react-webpack5": "^7.0.6",
42
+ "@storybook/testing-library": "^0.1.0",
43
43
  "babel-plugin-relay": "^15.0.0",
44
44
  "copyfiles": "^2.4.1",
45
45
  "css-loader": "^6.7.3",
46
46
  "identity-obj-proxy": "^3.0.0",
47
47
  "jest-environment-jsdom": "^29.5.0",
48
- "sass-loader": "^13.2.0",
49
- "storybook": "^7.0.0-rc.3",
48
+ "sass-loader": "^13.2.2",
49
+ "storybook": "^7.0.6",
50
50
  "style-loader": "^3.3.2"
51
51
  },
52
52
  "dependencies": {
53
- "@pareto-engineering/assets": "^4.0.0-alpha.3",
54
- "@pareto-engineering/bem": "^4.0.0-alpha.5",
55
- "@pareto-engineering/styles": "^4.0.0-alpha.5",
53
+ "@pareto-engineering/assets": "^4.0.0-alpha.9",
54
+ "@pareto-engineering/bem": "^4.0.0-alpha.9",
55
+ "@pareto-engineering/styles": "^4.0.0-alpha.9",
56
56
  "date-fns": "^2.29.3",
57
57
  "downshift": "^6.1.12",
58
58
  "formik": "^2.2.9",
@@ -67,5 +67,5 @@
67
67
  "relay-test-utils": "^15.0.0"
68
68
  },
69
69
  "browserslist": "> 2%",
70
- "gitHead": "dd704a71588b078c1c13bc1aa54b26474df3d311"
70
+ "gitHead": "2101215054a810e3f9d8d82c9ff475a07e54c670"
71
71
  }
@@ -0,0 +1,35 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+
4
+ import { MetaCard } from 'ui'
5
+
6
+ export default {
7
+ title :'a/MetaCard',
8
+ component :MetaCard,
9
+ subcomponents:{},
10
+ decorators :[],
11
+ controls :{
12
+ hasBackgroundBlur:{ type: 'boolean' },
13
+ },
14
+ }
15
+
16
+ const Template = (args) => (
17
+ <div style={{ backgroundImage: 'linear-gradient(purple, white)', padding: '1em' }}>
18
+ <MetaCard {...args}>
19
+ <h3 style={{ gridColumn: '2/-1' }}>
20
+ Column 2
21
+ </h3>
22
+ <p style={{ gridColumn: '3/-1' }}>
23
+ Column 3
24
+ </p>
25
+ </MetaCard>
26
+ </div>
27
+ )
28
+
29
+ export const Base = Template.bind({})
30
+ Base.args = {}
31
+
32
+ export const WithBlur = Template.bind({})
33
+ WithBlur.args = {
34
+ hasBackgroundBlur:true,
35
+ }
@@ -0,0 +1,19 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+
4
+ import { TextSteps } from 'ui'
5
+
6
+ export default {
7
+ title :'a/TextSteps',
8
+ component:TextSteps,
9
+ }
10
+
11
+ const items = [
12
+ 'Join Pareto in minutes. Share your business goals to match with a Project Partner.',
13
+ 'Receive initial output in 24 hours. Give feedback to fine-tune results and level up your Pareto team.',
14
+ 'Tap into economies of scale with tried and true playbooks: Benefit from strategic project recommendations. Enjoy continuous workflow improvement and documented learnings.',
15
+ ]
16
+
17
+ export const Base = () => (
18
+ <div className="grid span-8 md-span-14"><TextSteps items={items} /></div>
19
+ )
@@ -0,0 +1,28 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+
4
+ import { Tip } from 'ui'
5
+
6
+ export default {
7
+ title :'a/Tip',
8
+ component :Tip,
9
+ subcomponents:{
10
+ // Item:Quote.Item
11
+ },
12
+ decorators:[
13
+ // storyfn => <div className="">{ storyfn() }</div>,
14
+ ],
15
+ argTypes:{
16
+ color:{ control: 'color' },
17
+ },
18
+ }
19
+
20
+ const Template = (args) => (
21
+ <Tip {...args} />
22
+ )
23
+
24
+ export const Base = Template.bind({})
25
+ Base.args = {
26
+ children:'Remember to wash your vegetables before eating them.',
27
+ color :'main',
28
+ }
@@ -0,0 +1,59 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+
4
+ import { Card } from 'ui'
5
+
6
+ export default {
7
+ title :'b/Card',
8
+ component :Card,
9
+ subcomponents:{
10
+ 'Card.Section':Card.Section,
11
+ 'Card.Group' :Card.Group,
12
+ },
13
+ decorators:[
14
+ // (storyfn) => <Router>{storyfn()}</Router>,
15
+ ],
16
+ argTypes:{
17
+ progress:{ control: 'number' },
18
+ },
19
+ }
20
+
21
+ const Template = ({ isImage, ...args }) => (
22
+ <Card
23
+ {...args}
24
+ >
25
+ { isImage && (
26
+ <Card.Section isImage>
27
+ <img src="https://miro.medium.com/max/1124/1*v9We8Bevk2FFA5YadZNwcQ.jpeg" alt="test" />
28
+ </Card.Section>
29
+ )}
30
+ <Card.Section>
31
+ <h1>
32
+ Section One
33
+ </h1>
34
+ </Card.Section>
35
+ <Card.Section>
36
+ <h2>
37
+ Section Two
38
+ </h2>
39
+ </Card.Section>
40
+ <Card.Section>
41
+ <h3>
42
+ Section Three
43
+ </h3>
44
+ </Card.Section>
45
+ </Card>
46
+ )
47
+
48
+ export const Base = Template.bind({})
49
+ Base.args = {}
50
+
51
+ export const CardWithProgress = Template.bind({})
52
+ CardWithProgress.args = {
53
+ progress:50,
54
+ }
55
+
56
+ export const CardWithImageSection = Template.bind({})
57
+ CardWithImageSection.args = {
58
+ isImage:true,
59
+ }
@@ -0,0 +1,59 @@
1
+ /* @pareto-engineering/generator-front 1.0.12 */
2
+ import * as React from 'react'
3
+
4
+ import { Card } from 'ui'
5
+
6
+ export default {
7
+ title :'b/Card/Group',
8
+ component :Card.Group,
9
+ decorators:[
10
+ // (storyfn) => <Router>{storyfn()}</Router>,
11
+ ],
12
+ argTypes:{
13
+ type :{ control: 'select', options: ['vertical-flexbox', 'grid', 'snap-scroller'] },
14
+ desktopType:{ control: 'select', options: ['vertical-flexbox', 'grid'] },
15
+ },
16
+ }
17
+
18
+ const Template = ({ ...args }) => (
19
+ <Card.Group
20
+ className="span-8"
21
+ {...args}
22
+ >
23
+ <Card className="span-2">
24
+ <Card.Section>
25
+ <h1>
26
+ Span Two on Grid
27
+ </h1>
28
+ </Card.Section>
29
+ </Card>
30
+ <Card>
31
+ <Card.Section>
32
+ <h1>
33
+ Card Two
34
+ </h1>
35
+ </Card.Section>
36
+ </Card>
37
+ <Card>
38
+ <Card.Section>
39
+ <h1>
40
+ Card Three
41
+ </h1>
42
+ </Card.Section>
43
+ </Card>
44
+ </Card.Group>
45
+ )
46
+
47
+ export const Base = Template.bind({})
48
+ Base.args = {}
49
+
50
+ export const CardGroupGridOnDesktop = Template.bind({})
51
+ CardGroupGridOnDesktop.args = {
52
+ desktopType:'grid',
53
+ }
54
+
55
+ export const CardGroupNotSnapScroller = Template.bind({})
56
+ CardGroupNotSnapScroller.args = {
57
+ type :'vertical-flexbox',
58
+ desktopType:'vertical-flexbox',
59
+ }
@@ -1,7 +1,11 @@
1
1
  /* @pareto-engineering/generator-front 1.0.0 */
2
2
  import * as React from 'react'
3
3
 
4
- import { Page } from 'ui'
4
+ import {
5
+ Page,
6
+ // AnimatedGradient,
7
+ // AnimatedBlobs,
8
+ } from 'ui'
5
9
  import { HelmetProvider } from 'react-helmet-async'
6
10
 
7
11
  export default {
@@ -52,9 +56,21 @@ export const WithSections = () => (
52
56
  <Page.Section id="s1">
53
57
  Section 1
54
58
  </Page.Section>
55
- <Page.Section id="s2">
59
+ <Page.Section id="s2" spaced className="x-main b-x">
56
60
  Section 2.
57
- Inspect source for details.
61
+ This section is spaced
58
62
  </Page.Section>
59
63
  </Page>
60
64
  )
65
+
66
+ // Story is commented out due to snapshots and animations
67
+ // export const WithAnimatedBlobsBackground = () => (
68
+ // <Page
69
+ // id="with-sections"
70
+ // Background={AnimatedBlobs}
71
+ // >
72
+ // <Page.Section id="s1">
73
+ // Section 1
74
+ // </Page.Section>
75
+ // </Page>
76
+ // )
@@ -78,3 +78,10 @@ DisabledSelectInput.args = {
78
78
  ...Base.args,
79
79
  disabled:true,
80
80
  }
81
+
82
+ export const DisabledWithDescriptionSelectInput = Template.bind({})
83
+ DisabledWithDescriptionSelectInput.args = {
84
+ ...Base.args,
85
+ disabled :true,
86
+ description:'This is a description',
87
+ }
@@ -16,7 +16,7 @@ export default {
16
16
  decorators:[
17
17
  (storyfn) => (
18
18
  <Formik
19
- initialValues={{ firstName: '', date: '', time: '' }}
19
+ initialValues={{ email: '', name: '', company: '' }}
20
20
  >
21
21
  <Form>
22
22
 
@@ -47,8 +47,8 @@ const Template = (args) => (
47
47
 
48
48
  export const Base = Template.bind({})
49
49
  Base.args = {
50
- name :'firstName',
51
- label:"What's your first name ?",
50
+ name :'email',
51
+ label:'How can we reach you ?',
52
52
  }
53
53
 
54
54
  export const Optional = Template.bind({})
@@ -76,7 +76,7 @@ WithValidation.args = {
76
76
  export const WithPlaceholder = Template.bind({})
77
77
  WithPlaceholder.args = {
78
78
  ...Base.args,
79
- placeholder:'First Name',
79
+ placeholder:'Email address',
80
80
  }
81
81
 
82
82
  export const WithAutoCompleteOff = Template.bind({})