@coorpacademy/components 11.15.2 → 11.15.3

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 (189) hide show
  1. package/es/molecule/expandable-item/index.d.ts +19 -0
  2. package/es/molecule/expandable-item/index.d.ts.map +1 -0
  3. package/es/molecule/expandable-item/index.js +44 -0
  4. package/es/molecule/expandable-item/index.js.map +1 -0
  5. package/es/molecule/expandable-item/style.css +129 -0
  6. package/es/molecule/expandable-item/types.d.ts +20 -0
  7. package/es/molecule/expandable-item/types.d.ts.map +1 -0
  8. package/es/molecule/expandable-item/types.js +11 -0
  9. package/es/molecule/expandable-item/types.js.map +1 -0
  10. package/es/molecule/expandable-list/index.d.ts +18 -0
  11. package/es/molecule/expandable-list/index.d.ts.map +1 -0
  12. package/es/molecule/expandable-list/index.js +23 -0
  13. package/es/molecule/expandable-list/index.js.map +1 -0
  14. package/es/molecule/expandable-list/style.css +20 -0
  15. package/es/molecule/expandable-list/types.d.ts +17 -0
  16. package/es/molecule/expandable-list/types.d.ts.map +1 -0
  17. package/es/molecule/expandable-list/types.js +6 -0
  18. package/es/molecule/expandable-list/types.js.map +1 -0
  19. package/es/molecule/hero/index.d.ts +30 -26
  20. package/es/molecule/hero/index.d.ts.map +1 -1
  21. package/es/molecule/hero/index.js +14 -13
  22. package/es/molecule/hero/index.js.map +1 -1
  23. package/es/molecule/hero/style.css +42 -0
  24. package/es/molecule/hero/types.d.ts +22 -0
  25. package/es/molecule/hero/types.d.ts.map +1 -0
  26. package/es/molecule/hero/types.js +14 -0
  27. package/es/molecule/hero/types.js.map +1 -0
  28. package/es/molecule/menu-links/index.d.ts +23 -0
  29. package/es/molecule/menu-links/index.d.ts.map +1 -0
  30. package/es/molecule/menu-links/index.js +75 -0
  31. package/es/molecule/menu-links/index.js.map +1 -0
  32. package/es/molecule/menu-links/style.css +166 -0
  33. package/es/molecule/menu-links/types.d.ts +37 -0
  34. package/es/molecule/menu-links/types.d.ts.map +1 -0
  35. package/es/molecule/menu-links/types.js +18 -0
  36. package/es/molecule/menu-links/types.js.map +1 -0
  37. package/es/molecule/privacy-policy-contact/index.d.ts +14 -0
  38. package/es/molecule/privacy-policy-contact/index.d.ts.map +1 -0
  39. package/es/molecule/privacy-policy-contact/index.js +28 -0
  40. package/es/molecule/privacy-policy-contact/index.js.map +1 -0
  41. package/es/molecule/privacy-policy-contact/style.css +39 -0
  42. package/es/molecule/privacy-policy-contact/types.d.ts +10 -0
  43. package/es/molecule/privacy-policy-contact/types.d.ts.map +1 -0
  44. package/es/molecule/privacy-policy-contact/types.js +6 -0
  45. package/es/molecule/privacy-policy-contact/types.js.map +1 -0
  46. package/es/molecule/quick-access-card/index.d.ts +1 -0
  47. package/es/molecule/quick-access-card/index.d.ts.map +1 -1
  48. package/es/molecule/quick-access-card/index.js +88 -25
  49. package/es/molecule/quick-access-card/index.js.map +1 -1
  50. package/es/molecule/quick-access-card/style.css +32 -21
  51. package/es/molecule/quick-access-cards-group/index.d.ts +1 -0
  52. package/es/organism/brand-dashboard/index.d.ts +1 -0
  53. package/es/template/back-office/brand-update/index.d.ts +1 -0
  54. package/es/template/common/faq-article-page/index.d.ts +27 -0
  55. package/es/template/common/faq-article-page/index.d.ts.map +1 -0
  56. package/es/template/common/faq-article-page/index.js +55 -0
  57. package/es/template/common/faq-article-page/index.js.map +1 -0
  58. package/es/template/common/faq-article-page/style.css +125 -0
  59. package/es/template/common/faq-article-page/types.d.ts +41 -0
  60. package/es/template/common/faq-article-page/types.d.ts.map +1 -0
  61. package/es/template/common/faq-article-page/types.js +20 -0
  62. package/es/template/common/faq-article-page/types.js.map +1 -0
  63. package/es/template/common/faq-cards-page/index.d.ts +33 -0
  64. package/es/template/common/faq-cards-page/index.d.ts.map +1 -0
  65. package/es/template/common/faq-cards-page/index.js +45 -0
  66. package/es/template/common/faq-cards-page/index.js.map +1 -0
  67. package/es/template/common/faq-cards-page/style.css +106 -0
  68. package/es/template/common/faq-cards-page/types.d.ts +45 -0
  69. package/es/template/common/faq-cards-page/types.d.ts.map +1 -0
  70. package/es/template/common/faq-cards-page/types.js +18 -0
  71. package/es/template/common/faq-cards-page/types.js.map +1 -0
  72. package/es/template/common/faq-page/index.d.ts +50 -0
  73. package/es/template/common/faq-page/index.d.ts.map +1 -0
  74. package/es/template/common/faq-page/index.js +44 -0
  75. package/es/template/common/faq-page/index.js.map +1 -0
  76. package/es/template/common/faq-page/style.css +112 -0
  77. package/es/template/common/faq-page/types.d.ts +55 -0
  78. package/es/template/common/faq-page/types.d.ts.map +1 -0
  79. package/es/template/common/faq-page/types.js +12 -0
  80. package/es/template/common/faq-page/types.js.map +1 -0
  81. package/es/template/common/privacy-policy-page/index.d.ts +50 -0
  82. package/es/template/common/privacy-policy-page/index.d.ts.map +1 -0
  83. package/es/template/common/privacy-policy-page/index.js +44 -0
  84. package/es/template/common/privacy-policy-page/index.js.map +1 -0
  85. package/es/template/common/privacy-policy-page/style.css +111 -0
  86. package/es/template/common/privacy-policy-page/types.d.ts +55 -0
  87. package/es/template/common/privacy-policy-page/types.d.ts.map +1 -0
  88. package/es/template/common/privacy-policy-page/types.js +12 -0
  89. package/es/template/common/privacy-policy-page/types.js.map +1 -0
  90. package/es/util/button-icons.d.ts +1 -0
  91. package/es/util/button-icons.d.ts.map +1 -1
  92. package/es/util/button-icons.js +3 -2
  93. package/es/util/button-icons.js.map +1 -1
  94. package/es/variables/breakpoints.css +1 -1
  95. package/lib/molecule/expandable-item/index.d.ts +19 -0
  96. package/lib/molecule/expandable-item/index.d.ts.map +1 -0
  97. package/lib/molecule/expandable-item/index.js +58 -0
  98. package/lib/molecule/expandable-item/index.js.map +1 -0
  99. package/lib/molecule/expandable-item/style.css +129 -0
  100. package/lib/molecule/expandable-item/types.d.ts +20 -0
  101. package/lib/molecule/expandable-item/types.d.ts.map +1 -0
  102. package/lib/molecule/expandable-item/types.js +20 -0
  103. package/lib/molecule/expandable-item/types.js.map +1 -0
  104. package/lib/molecule/expandable-list/index.d.ts +18 -0
  105. package/lib/molecule/expandable-list/index.d.ts.map +1 -0
  106. package/lib/molecule/expandable-list/index.js +34 -0
  107. package/lib/molecule/expandable-list/index.js.map +1 -0
  108. package/lib/molecule/expandable-list/style.css +20 -0
  109. package/lib/molecule/expandable-list/types.d.ts +17 -0
  110. package/lib/molecule/expandable-list/types.d.ts.map +1 -0
  111. package/lib/molecule/expandable-list/types.js +16 -0
  112. package/lib/molecule/expandable-list/types.js.map +1 -0
  113. package/lib/molecule/hero/index.d.ts +30 -26
  114. package/lib/molecule/hero/index.d.ts.map +1 -1
  115. package/lib/molecule/hero/index.js +15 -14
  116. package/lib/molecule/hero/index.js.map +1 -1
  117. package/lib/molecule/hero/style.css +42 -0
  118. package/lib/molecule/hero/types.d.ts +22 -0
  119. package/lib/molecule/hero/types.d.ts.map +1 -0
  120. package/lib/molecule/hero/types.js +25 -0
  121. package/lib/molecule/hero/types.js.map +1 -0
  122. package/lib/molecule/menu-links/index.d.ts +23 -0
  123. package/lib/molecule/menu-links/index.d.ts.map +1 -0
  124. package/lib/molecule/menu-links/index.js +95 -0
  125. package/lib/molecule/menu-links/index.js.map +1 -0
  126. package/lib/molecule/menu-links/style.css +166 -0
  127. package/lib/molecule/menu-links/types.d.ts +37 -0
  128. package/lib/molecule/menu-links/types.d.ts.map +1 -0
  129. package/lib/molecule/menu-links/types.js +27 -0
  130. package/lib/molecule/menu-links/types.js.map +1 -0
  131. package/lib/molecule/privacy-policy-contact/index.d.ts +14 -0
  132. package/lib/molecule/privacy-policy-contact/index.d.ts.map +1 -0
  133. package/lib/molecule/privacy-policy-contact/index.js +41 -0
  134. package/lib/molecule/privacy-policy-contact/index.js.map +1 -0
  135. package/lib/molecule/privacy-policy-contact/style.css +39 -0
  136. package/lib/molecule/privacy-policy-contact/types.d.ts +10 -0
  137. package/lib/molecule/privacy-policy-contact/types.d.ts.map +1 -0
  138. package/lib/molecule/privacy-policy-contact/types.js +15 -0
  139. package/lib/molecule/privacy-policy-contact/types.js.map +1 -0
  140. package/lib/molecule/quick-access-card/index.d.ts +1 -0
  141. package/lib/molecule/quick-access-card/index.d.ts.map +1 -1
  142. package/lib/molecule/quick-access-card/index.js +87 -24
  143. package/lib/molecule/quick-access-card/index.js.map +1 -1
  144. package/lib/molecule/quick-access-card/style.css +32 -21
  145. package/lib/molecule/quick-access-cards-group/index.d.ts +1 -0
  146. package/lib/organism/brand-dashboard/index.d.ts +1 -0
  147. package/lib/template/back-office/brand-update/index.d.ts +1 -0
  148. package/lib/template/common/faq-article-page/index.d.ts +27 -0
  149. package/lib/template/common/faq-article-page/index.d.ts.map +1 -0
  150. package/lib/template/common/faq-article-page/index.js +69 -0
  151. package/lib/template/common/faq-article-page/index.js.map +1 -0
  152. package/lib/template/common/faq-article-page/style.css +125 -0
  153. package/lib/template/common/faq-article-page/types.d.ts +41 -0
  154. package/lib/template/common/faq-article-page/types.d.ts.map +1 -0
  155. package/lib/template/common/faq-article-page/types.js +30 -0
  156. package/lib/template/common/faq-article-page/types.js.map +1 -0
  157. package/lib/template/common/faq-cards-page/index.d.ts +33 -0
  158. package/lib/template/common/faq-cards-page/index.d.ts.map +1 -0
  159. package/lib/template/common/faq-cards-page/index.js +58 -0
  160. package/lib/template/common/faq-cards-page/index.js.map +1 -0
  161. package/lib/template/common/faq-cards-page/style.css +106 -0
  162. package/lib/template/common/faq-cards-page/types.d.ts +45 -0
  163. package/lib/template/common/faq-cards-page/types.d.ts.map +1 -0
  164. package/lib/template/common/faq-cards-page/types.js +29 -0
  165. package/lib/template/common/faq-cards-page/types.js.map +1 -0
  166. package/lib/template/common/faq-page/index.d.ts +50 -0
  167. package/lib/template/common/faq-page/index.d.ts.map +1 -0
  168. package/lib/template/common/faq-page/index.js +58 -0
  169. package/lib/template/common/faq-page/index.js.map +1 -0
  170. package/lib/template/common/faq-page/style.css +112 -0
  171. package/lib/template/common/faq-page/types.d.ts +55 -0
  172. package/lib/template/common/faq-page/types.d.ts.map +1 -0
  173. package/lib/template/common/faq-page/types.js +25 -0
  174. package/lib/template/common/faq-page/types.js.map +1 -0
  175. package/lib/template/common/privacy-policy-page/index.d.ts +50 -0
  176. package/lib/template/common/privacy-policy-page/index.d.ts.map +1 -0
  177. package/lib/template/common/privacy-policy-page/index.js +58 -0
  178. package/lib/template/common/privacy-policy-page/index.js.map +1 -0
  179. package/lib/template/common/privacy-policy-page/style.css +111 -0
  180. package/lib/template/common/privacy-policy-page/types.d.ts +55 -0
  181. package/lib/template/common/privacy-policy-page/types.d.ts.map +1 -0
  182. package/lib/template/common/privacy-policy-page/types.js +25 -0
  183. package/lib/template/common/privacy-policy-page/types.js.map +1 -0
  184. package/lib/util/button-icons.d.ts +1 -0
  185. package/lib/util/button-icons.d.ts.map +1 -1
  186. package/lib/util/button-icons.js +2 -1
  187. package/lib/util/button-icons.js.map +1 -1
  188. package/lib/variables/breakpoints.css +1 -1
  189. package/package.json +2 -2
@@ -1,37 +1,41 @@
1
- export default Hero;
2
- declare function Hero(props: any, context: any): JSX.Element;
3
- declare namespace Hero {
4
- namespace contextTypes {
5
- const skin: PropTypes.Requireable<PropTypes.InferProps<{
6
- common: PropTypes.Requireable<{
1
+ /// <reference types="react" />
2
+ import { WebContextValues } from '../../atom/provider/web-context';
3
+ import { Props } from './types';
4
+ declare const Hero: {
5
+ (props: Props, context: WebContextValues): JSX.Element;
6
+ contextTypes: {
7
+ skin: import("prop-types").Requireable<import("prop-types").InferProps<{
8
+ common: import("prop-types").Requireable<{
7
9
  [x: string]: any;
8
10
  }>;
9
- images: PropTypes.Requireable<PropTypes.InferProps<{
10
- 'logo-mobile': PropTypes.Requireable<any>;
11
- logo: PropTypes.Requireable<any>;
12
- 'logo-email': PropTypes.Requireable<any>;
13
- login: PropTypes.Requireable<any>;
11
+ images: import("prop-types").Requireable<import("prop-types").InferProps<{
12
+ 'logo-mobile': import("prop-types").Requireable<any>;
13
+ logo: import("prop-types").Requireable<any>;
14
+ 'logo-email': import("prop-types").Requireable<any>;
15
+ login: import("prop-types").Requireable<any>;
14
16
  }>>;
15
- icons: PropTypes.Requireable<{
17
+ icons: import("prop-types").Requireable<{
16
18
  [x: string]: any;
17
19
  }>;
18
- mod: PropTypes.Requireable<{
20
+ mod: import("prop-types").Requireable<{
19
21
  [x: string]: any;
20
22
  }>;
21
- courses: PropTypes.Requireable<any[]>;
22
- texts: PropTypes.Requireable<{
23
+ courses: import("prop-types").Requireable<any[]>;
24
+ texts: import("prop-types").Requireable<{
23
25
  [x: string]: any;
24
26
  }>;
25
27
  }>>;
26
- }
27
- namespace propTypes {
28
- const image: PropTypes.Requireable<string>;
29
- const title: PropTypes.Requireable<string>;
30
- const author: PropTypes.Requireable<string>;
31
- const progress: PropTypes.Requireable<number>;
32
- const onClick: PropTypes.Requireable<(...args: any[]) => any>;
33
- const submitValue: PropTypes.Requireable<string>;
34
- }
35
- }
36
- import PropTypes from "prop-types";
28
+ };
29
+ propTypes: {
30
+ image: import("prop-types").Requireable<string>;
31
+ mode: import("prop-types").Requireable<string>;
32
+ description: import("prop-types").Requireable<string>;
33
+ title: import("prop-types").Requireable<string>;
34
+ author: import("prop-types").Requireable<string>;
35
+ progress: import("prop-types").Requireable<number>;
36
+ onClick: import("prop-types").Requireable<(...args: any[]) => any>;
37
+ submitValue: import("prop-types").Requireable<string>;
38
+ };
39
+ };
40
+ export default Hero;
37
41
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/hero/index.js"],"names":[],"mappings":";AASA,6DAgCC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/hero/index.tsx"],"names":[],"mappings":";AAMA,OAAO,EAAC,gBAAgB,EAAC,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAY,KAAK,EAAC,MAAM,SAAS,CAAC;AAGzC,QAAA,MAAM,IAAI;YAAW,KAAK,WAAW,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkDpD,CAAC;AAQF,eAAe,IAAI,CAAC"}
@@ -7,8 +7,6 @@ var _get2 = _interopRequireDefault(require("lodash/fp/get"));
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
 
10
- var _propTypes = _interopRequireDefault(require("prop-types"));
11
-
12
10
  var _classnames = _interopRequireDefault(require("classnames"));
13
11
 
14
12
  var _provider = _interopRequireDefault(require("../../atom/provider"));
@@ -17,6 +15,8 @@ var _button = _interopRequireDefault(require("../../atom/button"));
17
15
 
18
16
  var _cardContent = _interopRequireWildcard(require("../card-content"));
19
17
 
18
+ var _types = require("./types");
19
+
20
20
  var _style = _interopRequireDefault(require("./style.css"));
21
21
 
22
22
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
@@ -35,7 +35,9 @@ const Hero = (props, context) => {
35
35
  author,
36
36
  progress,
37
37
  onClick,
38
- submitValue
38
+ submitValue,
39
+ description,
40
+ mode = _cardContent.MODES.HERO
39
41
  } = props;
40
42
  const primaryColor = (0, _get2.default)('common.primary', skin);
41
43
  const cardStyle = (0, _classnames.default)(_style.default.hero, title ? null : _style.default.lazy);
@@ -51,12 +53,18 @@ const Hero = (props, context) => {
51
53
  backgroundColor: primaryColor,
52
54
  backgroundImage: image ? `url('${image}')` : 'none'
53
55
  }
54
- })), /*#__PURE__*/_react.default.createElement(_cardContent.default, {
56
+ })), mode === _cardContent.MODES.HERO ? /*#__PURE__*/_react.default.createElement(_cardContent.default, {
55
57
  mode: _cardContent.MODES.HERO,
56
58
  author: author,
57
59
  progress: progress,
58
60
  title: title
59
- }), /*#__PURE__*/_react.default.createElement("div", {
61
+ }) : /*#__PURE__*/_react.default.createElement("div", {
62
+ className: _style.default.infoWrapper
63
+ }, /*#__PURE__*/_react.default.createElement("h1", {
64
+ className: _style.default.title
65
+ }, title), /*#__PURE__*/_react.default.createElement("p", {
66
+ className: _style.default.description
67
+ }, description)), mode === _cardContent.MODES.HERO ? /*#__PURE__*/_react.default.createElement("div", {
60
68
  className: _style.default.heroButtonWrapper
61
69
  }, /*#__PURE__*/_react.default.createElement(_button.default, {
62
70
  type: "link",
@@ -67,20 +75,13 @@ const Hero = (props, context) => {
67
75
  style: {
68
76
  backgroundColor: primaryColor
69
77
  }
70
- })));
78
+ })) : null);
71
79
  };
72
80
 
73
81
  Hero.contextTypes = {
74
82
  skin: _provider.default.childContextTypes.skin
75
83
  };
76
- Hero.propTypes = process.env.NODE_ENV !== "production" ? {
77
- image: _propTypes.default.string,
78
- title: _cardContent.default.propTypes.title,
79
- author: _cardContent.default.propTypes.author,
80
- progress: _cardContent.default.propTypes.progress,
81
- onClick: _button.default.propTypes.onClick,
82
- submitValue: _button.default.propTypes.submitValue
83
- } : {};
84
+ Hero.propTypes = process.env.NODE_ENV !== "production" ? _types.propTypes : {};
84
85
  var _default = Hero;
85
86
  exports.default = _default;
86
87
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["Hero","props","context","skin","image","title","author","progress","onClick","submitValue","primaryColor","cardStyle","classnames","style","hero","lazy","imageWrapper","backgroundColor","backgroundImage","MODES","HERO","heroButtonWrapper","heroButton","contextTypes","Provider","childContextTypes","propTypes","PropTypes","string","CardContentInfo","Button"],"sources":["../../../src/molecule/hero/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {get} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport Button from '../../atom/button';\nimport CardContentInfo, {MODES} from '../card-content';\nimport style from './style.css';\n\nconst Hero = (props, context) => {\n const {skin} = context;\n const {image, title, author, progress, onClick, submitValue} = props;\n\n const primaryColor = get('common.primary', skin);\n const cardStyle = classnames(style.hero, title ? null : style.lazy);\n\n return (\n <div className={cardStyle} data-name=\"hero\">\n <div className={style.imageWrapper}>\n <div\n data-name=\"cover\"\n className={style.image}\n style={{\n backgroundColor: primaryColor,\n backgroundImage: image ? `url('${image}')` : 'none'\n }}\n />\n </div>\n <CardContentInfo mode={MODES.HERO} author={author} progress={progress} title={title} />\n <div className={style.heroButtonWrapper}>\n <Button\n type=\"link\"\n data-name=\"hero-button\"\n onClick={onClick}\n submitValue={submitValue}\n className={style.heroButton}\n style={{backgroundColor: primaryColor}}\n />\n </div>\n </div>\n );\n};\n\nHero.contextTypes = {\n skin: Provider.childContextTypes.skin\n};\n\nHero.propTypes = {\n image: PropTypes.string,\n title: CardContentInfo.propTypes.title,\n author: CardContentInfo.propTypes.author,\n progress: CardContentInfo.propTypes.progress,\n onClick: Button.propTypes.onClick,\n submitValue: Button.propTypes.submitValue\n};\n\nexport default Hero;\n"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AAEA;;AACA;;AACA;;AACA;;;;;;;;AAEA,MAAMA,IAAI,GAAG,CAACC,KAAD,EAAQC,OAAR,KAAoB;EAC/B,MAAM;IAACC;EAAD,IAASD,OAAf;EACA,MAAM;IAACE,KAAD;IAAQC,KAAR;IAAeC,MAAf;IAAuBC,QAAvB;IAAiCC,OAAjC;IAA0CC;EAA1C,IAAyDR,KAA/D;EAEA,MAAMS,YAAY,GAAG,mBAAI,gBAAJ,EAAsBP,IAAtB,CAArB;EACA,MAAMQ,SAAS,GAAG,IAAAC,mBAAA,EAAWC,cAAA,CAAMC,IAAjB,EAAuBT,KAAK,GAAG,IAAH,GAAUQ,cAAA,CAAME,IAA5C,CAAlB;EAEA,oBACE;IAAK,SAAS,EAAEJ,SAAhB;IAA2B,aAAU;EAArC,gBACE;IAAK,SAAS,EAAEE,cAAA,CAAMG;EAAtB,gBACE;IACE,aAAU,OADZ;IAEE,SAAS,EAAEH,cAAA,CAAMT,KAFnB;IAGE,KAAK,EAAE;MACLa,eAAe,EAAEP,YADZ;MAELQ,eAAe,EAAEd,KAAK,GAAI,QAAOA,KAAM,IAAjB,GAAuB;IAFxC;EAHT,EADF,CADF,eAWE,6BAAC,oBAAD;IAAiB,IAAI,EAAEe,kBAAA,CAAMC,IAA7B;IAAmC,MAAM,EAAEd,MAA3C;IAAmD,QAAQ,EAAEC,QAA7D;IAAuE,KAAK,EAAEF;EAA9E,EAXF,eAYE;IAAK,SAAS,EAAEQ,cAAA,CAAMQ;EAAtB,gBACE,6BAAC,eAAD;IACE,IAAI,EAAC,MADP;IAEE,aAAU,aAFZ;IAGE,OAAO,EAAEb,OAHX;IAIE,WAAW,EAAEC,WAJf;IAKE,SAAS,EAAEI,cAAA,CAAMS,UALnB;IAME,KAAK,EAAE;MAACL,eAAe,EAAEP;IAAlB;EANT,EADF,CAZF,CADF;AAyBD,CAhCD;;AAkCAV,IAAI,CAACuB,YAAL,GAAoB;EAClBpB,IAAI,EAAEqB,iBAAA,CAASC,iBAAT,CAA2BtB;AADf,CAApB;AAIAH,IAAI,CAAC0B,SAAL,2CAAiB;EACftB,KAAK,EAAEuB,kBAAA,CAAUC,MADF;EAEfvB,KAAK,EAAEwB,oBAAA,CAAgBH,SAAhB,CAA0BrB,KAFlB;EAGfC,MAAM,EAAEuB,oBAAA,CAAgBH,SAAhB,CAA0BpB,MAHnB;EAIfC,QAAQ,EAAEsB,oBAAA,CAAgBH,SAAhB,CAA0BnB,QAJrB;EAKfC,OAAO,EAAEsB,eAAA,CAAOJ,SAAP,CAAiBlB,OALX;EAMfC,WAAW,EAAEqB,eAAA,CAAOJ,SAAP,CAAiBjB;AANf,CAAjB;eASeT,I"}
1
+ {"version":3,"file":"index.js","names":["Hero","props","context","skin","image","title","author","progress","onClick","submitValue","description","mode","MODES","HERO","primaryColor","cardStyle","classnames","style","hero","lazy","imageWrapper","backgroundColor","backgroundImage","infoWrapper","heroButtonWrapper","heroButton","contextTypes","Provider","childContextTypes","propTypes"],"sources":["../../../src/molecule/hero/index.tsx"],"sourcesContent":["import React from 'react';\nimport classnames from 'classnames';\nimport {get} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport Button from '../../atom/button';\nimport CardContentInfo, {MODES} from '../card-content';\nimport {WebContextValues} from '../../atom/provider/web-context';\nimport {propTypes, Props} from './types';\nimport style from './style.css';\n\nconst Hero = (props: Props, context: WebContextValues) => {\n const {skin} = context;\n const {\n image,\n title,\n author,\n progress,\n onClick,\n submitValue,\n description,\n mode = MODES.HERO\n } = props;\n\n const primaryColor = get('common.primary', skin);\n const cardStyle = classnames(style.hero, title ? null : style.lazy);\n\n return (\n <div className={cardStyle} data-name=\"hero\">\n <div className={style.imageWrapper}>\n <div\n data-name=\"cover\"\n className={style.image}\n style={{\n backgroundColor: primaryColor,\n backgroundImage: image ? `url('${image}')` : 'none'\n }}\n />\n </div>\n {mode === MODES.HERO ? (\n <CardContentInfo mode={MODES.HERO} author={author} progress={progress} title={title} />\n ) : (\n <div className={style.infoWrapper}>\n <h1 className={style.title}>{title}</h1>\n <p className={style.description}>{description}</p>\n </div>\n )}\n {mode === MODES.HERO ? (\n <div className={style.heroButtonWrapper}>\n <Button\n type=\"link\"\n data-name=\"hero-button\"\n onClick={onClick}\n submitValue={submitValue}\n className={style.heroButton}\n style={{backgroundColor: primaryColor}}\n />\n </div>\n ) : null}\n </div>\n );\n};\n\nHero.contextTypes = {\n skin: Provider.childContextTypes.skin\n};\n\nHero.propTypes = propTypes;\n\nexport default Hero;\n"],"mappings":";;;;;;;AAAA;;AACA;;AAEA;;AACA;;AACA;;AAEA;;AACA;;;;;;;;AAEA,MAAMA,IAAI,GAAG,CAACC,KAAD,EAAeC,OAAf,KAA6C;EACxD,MAAM;IAACC;EAAD,IAASD,OAAf;EACA,MAAM;IACJE,KADI;IAEJC,KAFI;IAGJC,MAHI;IAIJC,QAJI;IAKJC,OALI;IAMJC,WANI;IAOJC,WAPI;IAQJC,IAAI,GAAGC,kBAAA,CAAMC;EART,IASFZ,KATJ;EAWA,MAAMa,YAAY,GAAG,mBAAI,gBAAJ,EAAsBX,IAAtB,CAArB;EACA,MAAMY,SAAS,GAAG,IAAAC,mBAAA,EAAWC,cAAA,CAAMC,IAAjB,EAAuBb,KAAK,GAAG,IAAH,GAAUY,cAAA,CAAME,IAA5C,CAAlB;EAEA,oBACE;IAAK,SAAS,EAAEJ,SAAhB;IAA2B,aAAU;EAArC,gBACE;IAAK,SAAS,EAAEE,cAAA,CAAMG;EAAtB,gBACE;IACE,aAAU,OADZ;IAEE,SAAS,EAAEH,cAAA,CAAMb,KAFnB;IAGE,KAAK,EAAE;MACLiB,eAAe,EAAEP,YADZ;MAELQ,eAAe,EAAElB,KAAK,GAAI,QAAOA,KAAM,IAAjB,GAAuB;IAFxC;EAHT,EADF,CADF,EAWGO,IAAI,KAAKC,kBAAA,CAAMC,IAAf,gBACC,6BAAC,oBAAD;IAAiB,IAAI,EAAED,kBAAA,CAAMC,IAA7B;IAAmC,MAAM,EAAEP,MAA3C;IAAmD,QAAQ,EAAEC,QAA7D;IAAuE,KAAK,EAAEF;EAA9E,EADD,gBAGC;IAAK,SAAS,EAAEY,cAAA,CAAMM;EAAtB,gBACE;IAAI,SAAS,EAAEN,cAAA,CAAMZ;EAArB,GAA6BA,KAA7B,CADF,eAEE;IAAG,SAAS,EAAEY,cAAA,CAAMP;EAApB,GAAkCA,WAAlC,CAFF,CAdJ,EAmBGC,IAAI,KAAKC,kBAAA,CAAMC,IAAf,gBACC;IAAK,SAAS,EAAEI,cAAA,CAAMO;EAAtB,gBACE,6BAAC,eAAD;IACE,IAAI,EAAC,MADP;IAEE,aAAU,aAFZ;IAGE,OAAO,EAAEhB,OAHX;IAIE,WAAW,EAAEC,WAJf;IAKE,SAAS,EAAEQ,cAAA,CAAMQ,UALnB;IAME,KAAK,EAAE;MAACJ,eAAe,EAAEP;IAAlB;EANT,EADF,CADD,GAWG,IA9BN,CADF;AAkCD,CAlDD;;AAoDAd,IAAI,CAAC0B,YAAL,GAAoB;EAClBvB,IAAI,EAAEwB,iBAAA,CAASC,iBAAT,CAA2BzB;AADf,CAApB;AAIAH,IAAI,CAAC6B,SAAL,2CAAiBA,gBAAjB;eAEe7B,I"}
@@ -156,3 +156,45 @@
156
156
  opacity: 0;
157
157
  }
158
158
  }
159
+
160
+ .infoWrapper {
161
+ display: flex;
162
+ flex-direction: column;
163
+ position: relative;
164
+ justify-content: center;
165
+ padding: 0 40px;
166
+ width: 100%;
167
+ box-sizing: border-box;
168
+ color: white;
169
+ align-self: center;
170
+ }
171
+
172
+ .title {
173
+ font-family: Gilroy;
174
+ font-size: 28px;
175
+ font-weight: 500;
176
+ line-height: 36px;
177
+ letter-spacing: 0px;
178
+ text-align: center;
179
+ overflow: hidden;
180
+ user-select: none;
181
+ margin: 0;
182
+ align-self: center;
183
+ }
184
+
185
+ .description {
186
+ text-align: center;
187
+ margin-top: 12px;
188
+ font-size: 18px;
189
+ font-family: Gilroy;
190
+ font-size: 18px;
191
+ font-weight: 500;
192
+ line-height: 24px;
193
+ letter-spacing: 0px;
194
+ overflow: hidden;
195
+ user-select: none;
196
+ max-width: 650px;
197
+ padding: 0;
198
+ margin: 0;
199
+ align-self: center;
200
+ }
@@ -0,0 +1,22 @@
1
+ import PropTypes from 'prop-types';
2
+ export declare const propTypes: {
3
+ image: PropTypes.Requireable<string>;
4
+ mode: PropTypes.Requireable<string>;
5
+ description: PropTypes.Requireable<string>;
6
+ title: PropTypes.Requireable<string>;
7
+ author: PropTypes.Requireable<string>;
8
+ progress: PropTypes.Requireable<number>;
9
+ onClick: PropTypes.Requireable<(...args: any[]) => any>;
10
+ submitValue: PropTypes.Requireable<string>;
11
+ };
12
+ export declare type Props = {
13
+ image?: string;
14
+ mode?: string;
15
+ description?: string;
16
+ title?: string;
17
+ author?: string;
18
+ progress?: number;
19
+ onClick?: () => void;
20
+ submitValue?: string;
21
+ };
22
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/molecule/hero/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAInC,eAAO,MAAM,SAAS;;;;;;;;;CASrB,CAAC;AAEF,oBAAY,KAAK,GAAG;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC"}
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+
3
+ exports.__esModule = true;
4
+ exports.propTypes = void 0;
5
+
6
+ var _propTypes = _interopRequireDefault(require("prop-types"));
7
+
8
+ var _cardContent = _interopRequireDefault(require("../card-content"));
9
+
10
+ var _button = _interopRequireDefault(require("../../atom/button"));
11
+
12
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
13
+
14
+ const propTypes = {
15
+ image: _propTypes.default.string,
16
+ mode: _propTypes.default.string,
17
+ description: _propTypes.default.string,
18
+ title: _cardContent.default.propTypes.title,
19
+ author: _cardContent.default.propTypes.author,
20
+ progress: _cardContent.default.propTypes.progress,
21
+ onClick: _button.default.propTypes.onClick,
22
+ submitValue: _button.default.propTypes.submitValue
23
+ };
24
+ exports.propTypes = propTypes;
25
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","names":["propTypes","image","PropTypes","string","mode","description","title","CardContentInfo","author","progress","onClick","Button","submitValue"],"sources":["../../../src/molecule/hero/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\nimport CardContentInfo from '../card-content';\nimport Button from '../../atom/button';\n\nexport const propTypes = {\n image: PropTypes.string,\n mode: PropTypes.string,\n description: PropTypes.string,\n title: CardContentInfo.propTypes.title,\n author: CardContentInfo.propTypes.author,\n progress: CardContentInfo.propTypes.progress,\n onClick: Button.propTypes.onClick,\n submitValue: Button.propTypes.submitValue\n};\n\nexport type Props = {\n image?: string;\n mode?: string;\n description?: string;\n title?: string;\n author?: string;\n progress?: number;\n onClick?: () => void;\n submitValue?: string;\n};\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;;;AAEO,MAAMA,SAAS,GAAG;EACvBC,KAAK,EAAEC,kBAAA,CAAUC,MADM;EAEvBC,IAAI,EAAEF,kBAAA,CAAUC,MAFO;EAGvBE,WAAW,EAAEH,kBAAA,CAAUC,MAHA;EAIvBG,KAAK,EAAEC,oBAAA,CAAgBP,SAAhB,CAA0BM,KAJV;EAKvBE,MAAM,EAAED,oBAAA,CAAgBP,SAAhB,CAA0BQ,MALX;EAMvBC,QAAQ,EAAEF,oBAAA,CAAgBP,SAAhB,CAA0BS,QANb;EAOvBC,OAAO,EAAEC,eAAA,CAAOX,SAAP,CAAiBU,OAPH;EAQvBE,WAAW,EAAED,eAAA,CAAOX,SAAP,CAAiBY;AARP,CAAlB"}
@@ -0,0 +1,23 @@
1
+ /// <reference types="react" />
2
+ import { Props } from './types';
3
+ declare const MenuLinks: {
4
+ ({ items, title, showMoreItem, numberOfDisplayedItems, isDesktopMode, withScroll }: Props): JSX.Element;
5
+ propTypes: {
6
+ title: import("prop-types").Requireable<string>;
7
+ numberOfDisplayedItems: import("prop-types").Requireable<number>;
8
+ isDesktopMode: import("prop-types").Requireable<boolean>;
9
+ withScroll: import("prop-types").Requireable<boolean>;
10
+ showMoreItem: import("prop-types").Requireable<import("prop-types").InferProps<{
11
+ showMoreText: import("prop-types").Requireable<string>;
12
+ showLessText: import("prop-types").Requireable<string>;
13
+ isSelected: import("prop-types").Requireable<boolean>;
14
+ }>>;
15
+ items: import("prop-types").Requireable<(import("prop-types").InferProps<{
16
+ text: import("prop-types").Requireable<string>;
17
+ isSelected: import("prop-types").Requireable<boolean>;
18
+ handleOnclick: import("prop-types").Requireable<(...args: any[]) => any>;
19
+ }> | null | undefined)[]>;
20
+ };
21
+ };
22
+ export default MenuLinks;
23
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/menu-links/index.tsx"],"names":[],"mappings":";AAWA,OAAO,EAAY,KAAK,EAAC,MAAM,SAAS,CAAC;AAWzC,QAAA,MAAM,SAAS;wFAOZ,KAAK;;;;;;;;;;;;;;;;;CAsEP,CAAC;AAIF,eAAe,SAAS,CAAC"}
@@ -0,0 +1,95 @@
1
+ "use strict";
2
+
3
+ exports.__esModule = true;
4
+ exports.default = void 0;
5
+
6
+ var _slice2 = _interopRequireDefault(require("lodash/fp/slice"));
7
+
8
+ var _react = _interopRequireWildcard(require("react"));
9
+
10
+ var _classnames = _interopRequireDefault(require("classnames"));
11
+
12
+ var _novaIcons = require("@coorpacademy/nova-icons");
13
+
14
+ var _types = require("./types");
15
+
16
+ var _style = _interopRequireDefault(require("./style.css"));
17
+
18
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
19
+
20
+ 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; }
21
+
22
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
+
24
+ const ICONS = {
25
+ mobilePhone: _novaIcons.NovaLinePhoneMobilePhone,
26
+ chatBubbleCircleQuestionMark: _novaIcons.NovaLineMessagesChatChatBubbleCircleQuestionMark,
27
+ networkAlert: _novaIcons.NovaLineNetworkNetworkAlert,
28
+ binoculaire: _novaIcons.NovaLineObjectsBinoculars,
29
+ contentBook: _novaIcons.NovaLineContentEditionContentBook
30
+ };
31
+
32
+ const MenuLinks = ({
33
+ items,
34
+ title,
35
+ showMoreItem,
36
+ numberOfDisplayedItems,
37
+ isDesktopMode,
38
+ withScroll = false
39
+ }) => {
40
+ const [isOpen, setIsOpen] = (0, _react.useState)(false);
41
+ const itemsToDisplay = isDesktopMode || isOpen ? items : (0, _slice2.default)(0, numberOfDisplayedItems, items);
42
+
43
+ const handleOnclickShowMore = () => setIsOpen(!isOpen);
44
+
45
+ return /*#__PURE__*/_react.default.createElement("div", {
46
+ className: _style.default.container
47
+ }, /*#__PURE__*/_react.default.createElement("h2", {
48
+ className: _style.default.title
49
+ }, title), /*#__PURE__*/_react.default.createElement("ul", {
50
+ className: _style.default.list,
51
+ "data-name": "menu-links"
52
+ }, itemsToDisplay.map((item, index) => {
53
+ const {
54
+ handleOnclick
55
+ } = item;
56
+ const Icon = item.icon ? ICONS[item.icon] : null;
57
+
58
+ const Item = /*#__PURE__*/_react.default.createElement("div", {
59
+ className: _style.default.flexContainer
60
+ }, /*#__PURE__*/_react.default.createElement("span", {
61
+ className: item.isSelected ? _style.default.selectedItem : undefined
62
+ }, item.text), Icon ? /*#__PURE__*/_react.default.createElement(_novaIcons.NovaCompositionNavigationArrowDown, {
63
+ className: (0, _classnames.default)(_style.default.arrowIcon, item.isSelected ? _style.default.selectedIcon : null)
64
+ }) : null);
65
+
66
+ return /*#__PURE__*/_react.default.createElement("li", {
67
+ onClick: handleOnclick,
68
+ key: `menu-link-item-${index}`,
69
+ className: _style.default.item
70
+ }, /*#__PURE__*/_react.default.createElement("div", {
71
+ className: (0, _classnames.default)(_style.default.border, item.isSelected ? _style.default.selectedBorder : null)
72
+ }), /*#__PURE__*/_react.default.createElement("div", {
73
+ className: _style.default.flexContainer
74
+ }, Icon ? /*#__PURE__*/_react.default.createElement(Icon, {
75
+ className: (0, _classnames.default)(_style.default.icon, item.isSelected ? _style.default.selectedIcon : null)
76
+ }) : null, withScroll ? /*#__PURE__*/_react.default.createElement("a", {
77
+ className: _style.default.link,
78
+ href: `#menu-link-item-${index}`
79
+ }, Item) : Item));
80
+ }), !isDesktopMode ? /*#__PURE__*/_react.default.createElement("li", {
81
+ // eslint-disable-next-line react/jsx-no-bind
82
+ onClick: handleOnclickShowMore,
83
+ key: `menu-link-item-show-more`,
84
+ className: (0, _classnames.default)(_style.default.showMoreItem, _style.default.item)
85
+ }, /*#__PURE__*/_react.default.createElement("div", {
86
+ className: _style.default.border
87
+ }), /*#__PURE__*/_react.default.createElement("span", null, isOpen ? showMoreItem.showLessText : showMoreItem.showMoreText, /*#__PURE__*/_react.default.createElement(_novaIcons.NovaCompositionNavigationArrowDown, {
88
+ className: isOpen ? _style.default.showLessIcon : _style.default.showMoreIcon
89
+ }))) : null));
90
+ };
91
+
92
+ MenuLinks.propTypes = process.env.NODE_ENV !== "production" ? _types.propTypes : {};
93
+ var _default = MenuLinks;
94
+ exports.default = _default;
95
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["ICONS","mobilePhone","MobilePhone","chatBubbleCircleQuestionMark","ChatBubbleCircleQuestionMark","networkAlert","NetworkAlert","binoculaire","Binoculaire","contentBook","ContentBook","MenuLinks","items","title","showMoreItem","numberOfDisplayedItems","isDesktopMode","withScroll","isOpen","setIsOpen","useState","itemsToDisplay","handleOnclickShowMore","styles","container","list","map","item","index","handleOnclick","Icon","icon","Item","flexContainer","isSelected","selectedItem","undefined","text","classnames","arrowIcon","selectedIcon","border","selectedBorder","link","showLessText","showMoreText","showLessIcon","showMoreIcon","propTypes"],"sources":["../../../src/molecule/menu-links/index.tsx"],"sourcesContent":["import React, {useState} from 'react';\nimport classnames from 'classnames';\nimport {\n NovaCompositionNavigationArrowDown as ArrowIcon,\n NovaLinePhoneMobilePhone as MobilePhone,\n NovaLineMessagesChatChatBubbleCircleQuestionMark as ChatBubbleCircleQuestionMark,\n NovaLineNetworkNetworkAlert as NetworkAlert,\n NovaLineObjectsBinoculars as Binoculaire,\n NovaLineContentEditionContentBook as ContentBook\n} from '@coorpacademy/nova-icons';\nimport {slice} from 'lodash/fp';\nimport {propTypes, Props} from './types';\nimport styles from './style.css';\n\nconst ICONS = {\n mobilePhone: MobilePhone,\n chatBubbleCircleQuestionMark: ChatBubbleCircleQuestionMark,\n networkAlert: NetworkAlert,\n binoculaire: Binoculaire,\n contentBook: ContentBook\n};\n\nconst MenuLinks = ({\n items,\n title,\n showMoreItem,\n numberOfDisplayedItems,\n isDesktopMode,\n withScroll = false\n}: Props) => {\n const [isOpen, setIsOpen] = useState<boolean>(false);\n const itemsToDisplay = isDesktopMode || isOpen ? items : slice(0, numberOfDisplayedItems, items);\n const handleOnclickShowMore = () => setIsOpen(!isOpen);\n\n return (\n <div className={styles.container}>\n <h2 className={styles.title}>{title}</h2>\n <ul className={styles.list} data-name=\"menu-links\">\n {itemsToDisplay.map((item, index) => {\n const {handleOnclick} = item;\n const Icon = item.icon ? ICONS[item.icon] : null;\n const Item = (\n <div className={styles.flexContainer}>\n <span className={item.isSelected ? styles.selectedItem : undefined}>{item.text}</span>\n {Icon ? (\n <ArrowIcon\n className={classnames(\n styles.arrowIcon,\n item.isSelected ? styles.selectedIcon : null\n )}\n />\n ) : null}\n </div>\n );\n return (\n <li onClick={handleOnclick} key={`menu-link-item-${index}`} className={styles.item}>\n <div\n className={classnames(\n styles.border,\n item.isSelected ? styles.selectedBorder : null\n )}\n />\n <div className={styles.flexContainer}>\n {Icon ? (\n <Icon\n className={classnames(\n styles.icon,\n item.isSelected ? styles.selectedIcon : null\n )}\n />\n ) : null}\n {withScroll ? (\n <a className={styles.link} href={`#menu-link-item-${index}`}>\n {Item}\n </a>\n ) : (\n Item\n )}\n </div>\n </li>\n );\n })}\n {!isDesktopMode ? (\n <li\n // eslint-disable-next-line react/jsx-no-bind\n onClick={handleOnclickShowMore}\n key={`menu-link-item-show-more`}\n className={classnames(styles.showMoreItem, styles.item)}\n >\n <div className={styles.border} />\n <span>\n {isOpen ? showMoreItem.showLessText : showMoreItem.showMoreText}\n <ArrowIcon className={isOpen ? styles.showLessIcon : styles.showMoreIcon} />\n </span>\n </li>\n ) : null}\n </ul>\n </div>\n );\n};\n\nMenuLinks.propTypes = propTypes;\n\nexport default MenuLinks;\n"],"mappings":"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"}
@@ -0,0 +1,166 @@
1
+ @value colors: "../../variables/colors.css";
2
+ @value breakpoints: "../../variables/breakpoints.css";
3
+ @value mobile from breakpoints;
4
+ @value tablet from breakpoints;
5
+ @value cm_primary_blue from colors;
6
+ @value cm_grey_500 from colors;
7
+ @value cm_grey_700 from colors;
8
+ @value cm_grey_800 from colors;
9
+ @value white from colors;
10
+
11
+
12
+ .container {
13
+ display: flex;
14
+ flex-direction: column;
15
+ align-items: flex-start;
16
+ padding: 24px 24px 8px 0px;
17
+ gap: 24px;
18
+ background: #FFFFFF;
19
+ border-radius: 8px;
20
+ flex: none;
21
+ order: 0;
22
+ flex-grow: 0;
23
+ }
24
+
25
+ .link {
26
+ text-decoration: none;
27
+ color: cm_grey_700;
28
+ }
29
+
30
+ .title {
31
+ padding: 0px 0px 0px 24px;
32
+ margin: 0;
33
+ font-family: 'Gilroy';
34
+ font-style: normal;
35
+ font-weight: 600;
36
+ font-size: 16px;
37
+ line-height: 22px;
38
+ order: 0;
39
+ flex-grow: 0;
40
+ z-index: 0;
41
+ color: cm_grey_500;
42
+ }
43
+
44
+ .list {
45
+ list-style: none;
46
+ cursor: pointer;
47
+ margin: 0;
48
+ padding: 0;
49
+ width: 100%;
50
+ }
51
+
52
+ .item {
53
+ display: flex;
54
+ flex-direction: row;
55
+ gap: 28px;
56
+ margin-bottom: 16px;
57
+ width: 100%;
58
+ }
59
+
60
+ .flexContainer span {
61
+ font-family: Gilroy;
62
+ font-size: 14px;
63
+ font-weight: 700;
64
+ line-height: 20px;
65
+ letter-spacing: 0px;
66
+ text-align: left;
67
+ }
68
+
69
+ .flexContainer {
70
+ display: flex;
71
+ justify-content: space-between;
72
+ align-items: center;
73
+ width: 100%;
74
+ }
75
+ .border {
76
+ width: 4px;
77
+ font-weight: inherit;
78
+ background-color: white;
79
+ flex-shrink: 0;
80
+ min-width: 4px;
81
+ flex-basis: 4px;
82
+ }
83
+
84
+ .icon {
85
+ width: 20px;
86
+ height: 20px;
87
+ color: #000;
88
+ margin-right: 12px;
89
+ }
90
+
91
+ .arrowIcon{
92
+ width: 12px;
93
+ min-width: 12px;
94
+ height: 12px;
95
+ margin-left: 10px;
96
+ transform: rotateZ(270deg);
97
+ }
98
+
99
+ .selectedBorder {
100
+ background-color: cm_primary_blue;
101
+ }
102
+
103
+ .showMoreItem {
104
+ display: none;
105
+ }
106
+
107
+ .selectedItem {
108
+ color: cm_primary_blue;
109
+ font-weight: 600;
110
+ }
111
+
112
+ .selectedIcon {
113
+ color: cm_primary_blue;
114
+ }
115
+ .item:hover{
116
+ text-decoration: underline;
117
+ }
118
+
119
+ .selectedItem:hover {
120
+ text-decoration-color: cm_primary_blue!important;
121
+ color: cm_primary_blue;
122
+ }
123
+ .showMoreIcon {
124
+ width: 12px;
125
+ height: 8px;
126
+ margin-left: 8px;
127
+ }
128
+
129
+ .showLessIcon {
130
+ width: 12px;
131
+ height: 8px;
132
+ margin-left: 8px;
133
+ transform: rotateZ(180deg);
134
+ }
135
+
136
+ @media tablet {
137
+ .showMoreItem {
138
+ font-family: 'Gilroy';
139
+ font-style: normal;
140
+ font-weight: 700;
141
+ font-size: 14px;
142
+ line-height: 20px;
143
+ color: cm_grey_700;
144
+ margin: 0;
145
+ display: block;
146
+ display: flex;
147
+ flex-direction: row;
148
+ margin-bottom: 16px;
149
+ }
150
+ }
151
+
152
+ @media mobile {
153
+ .showMoreItem {
154
+ font-family: 'Gilroy';
155
+ font-style: normal;
156
+ font-weight: 700;
157
+ font-size: 14px;
158
+ line-height: 20px;
159
+ color: cm_grey_700;
160
+ margin: 0;
161
+ display: block;
162
+ display: flex;
163
+ flex-direction: row;
164
+ margin-bottom: 16px;
165
+ }
166
+ }
@@ -0,0 +1,37 @@
1
+ import PropTypes from 'prop-types';
2
+ export declare const propTypes: {
3
+ title: PropTypes.Requireable<string>;
4
+ numberOfDisplayedItems: PropTypes.Requireable<number>;
5
+ isDesktopMode: PropTypes.Requireable<boolean>;
6
+ withScroll: PropTypes.Requireable<boolean>;
7
+ showMoreItem: PropTypes.Requireable<PropTypes.InferProps<{
8
+ showMoreText: PropTypes.Requireable<string>;
9
+ showLessText: PropTypes.Requireable<string>;
10
+ isSelected: PropTypes.Requireable<boolean>;
11
+ }>>;
12
+ items: PropTypes.Requireable<(PropTypes.InferProps<{
13
+ text: PropTypes.Requireable<string>;
14
+ isSelected: PropTypes.Requireable<boolean>;
15
+ handleOnclick: PropTypes.Requireable<(...args: any[]) => any>;
16
+ }> | null | undefined)[]>;
17
+ };
18
+ export declare type Item = {
19
+ text: string;
20
+ isSelected?: boolean;
21
+ handleOnclick: () => void;
22
+ icon?: IconsType;
23
+ };
24
+ export declare type ShowMoreItem = {
25
+ showMoreText: string;
26
+ showLessText: string;
27
+ };
28
+ export declare type IconsType = 'mobilePhone' | 'chatBubbleCircleQuestionMark' | 'networkAlert' | 'binoculaire' | 'contentBook';
29
+ export declare type Props = {
30
+ title: string;
31
+ isDesktopMode: boolean;
32
+ withScroll?: boolean;
33
+ showMoreItem: ShowMoreItem;
34
+ numberOfDisplayedItems: number;
35
+ items: Item[];
36
+ };
37
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/molecule/menu-links/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAEnC,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;CAiBrB,CAAC;AAEF,oBAAY,IAAI,GAAG;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,IAAI,CAAC,EAAE,SAAS,CAAC;CAClB,CAAC;AAEF,oBAAY,YAAY,GAAG;IACzB,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,oBAAY,SAAS,GACjB,aAAa,GACb,8BAA8B,GAC9B,cAAc,GACd,aAAa,GACb,aAAa,CAAC;AAElB,oBAAY,KAAK,GAAG;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,aAAa,EAAE,OAAO,CAAC;IACvB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,YAAY,EAAE,YAAY,CAAC;IAC3B,sBAAsB,EAAE,MAAM,CAAC;IAC/B,KAAK,EAAE,IAAI,EAAE,CAAC;CACf,CAAC"}
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+
3
+ exports.__esModule = true;
4
+ exports.propTypes = void 0;
5
+
6
+ var _propTypes = _interopRequireDefault(require("prop-types"));
7
+
8
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
9
+
10
+ const propTypes = {
11
+ title: _propTypes.default.string,
12
+ numberOfDisplayedItems: _propTypes.default.number,
13
+ isDesktopMode: _propTypes.default.bool,
14
+ withScroll: _propTypes.default.bool,
15
+ showMoreItem: _propTypes.default.shape({
16
+ showMoreText: _propTypes.default.string,
17
+ showLessText: _propTypes.default.string,
18
+ isSelected: _propTypes.default.bool
19
+ }),
20
+ items: _propTypes.default.arrayOf(_propTypes.default.shape({
21
+ text: _propTypes.default.string,
22
+ isSelected: _propTypes.default.bool,
23
+ handleOnclick: _propTypes.default.func
24
+ }))
25
+ };
26
+ exports.propTypes = propTypes;
27
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","names":["propTypes","title","PropTypes","string","numberOfDisplayedItems","number","isDesktopMode","bool","withScroll","showMoreItem","shape","showMoreText","showLessText","isSelected","items","arrayOf","text","handleOnclick","func"],"sources":["../../../src/molecule/menu-links/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\n\nexport const propTypes = {\n title: PropTypes.string,\n numberOfDisplayedItems: PropTypes.number,\n isDesktopMode: PropTypes.bool,\n withScroll: PropTypes.bool,\n showMoreItem: PropTypes.shape({\n showMoreText: PropTypes.string,\n showLessText: PropTypes.string,\n isSelected: PropTypes.bool\n }),\n items: PropTypes.arrayOf(\n PropTypes.shape({\n text: PropTypes.string,\n isSelected: PropTypes.bool,\n handleOnclick: PropTypes.func\n })\n )\n};\n\nexport type Item = {\n text: string;\n isSelected?: boolean;\n handleOnclick: () => void;\n icon?: IconsType;\n};\n\nexport type ShowMoreItem = {\n showMoreText: string;\n showLessText: string;\n};\n\nexport type IconsType =\n | 'mobilePhone'\n | 'chatBubbleCircleQuestionMark'\n | 'networkAlert'\n | 'binoculaire'\n | 'contentBook';\n\nexport type Props = {\n title: string;\n isDesktopMode: boolean;\n withScroll?: boolean;\n showMoreItem: ShowMoreItem;\n numberOfDisplayedItems: number;\n items: Item[];\n};\n"],"mappings":";;;;;AAAA;;;;AAEO,MAAMA,SAAS,GAAG;EACvBC,KAAK,EAAEC,kBAAA,CAAUC,MADM;EAEvBC,sBAAsB,EAAEF,kBAAA,CAAUG,MAFX;EAGvBC,aAAa,EAAEJ,kBAAA,CAAUK,IAHF;EAIvBC,UAAU,EAAEN,kBAAA,CAAUK,IAJC;EAKvBE,YAAY,EAAEP,kBAAA,CAAUQ,KAAV,CAAgB;IAC5BC,YAAY,EAAET,kBAAA,CAAUC,MADI;IAE5BS,YAAY,EAAEV,kBAAA,CAAUC,MAFI;IAG5BU,UAAU,EAAEX,kBAAA,CAAUK;EAHM,CAAhB,CALS;EAUvBO,KAAK,EAAEZ,kBAAA,CAAUa,OAAV,CACLb,kBAAA,CAAUQ,KAAV,CAAgB;IACdM,IAAI,EAAEd,kBAAA,CAAUC,MADF;IAEdU,UAAU,EAAEX,kBAAA,CAAUK,IAFR;IAGdU,aAAa,EAAEf,kBAAA,CAAUgB;EAHX,CAAhB,CADK;AAVgB,CAAlB"}