@coorpacademy/components 11.38.6-alpha.27 → 11.38.6-alpha.29

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 (161) hide show
  1. package/es/atom/input-search/index.d.ts +0 -2
  2. package/es/atom/input-search/index.d.ts.map +1 -1
  3. package/es/atom/input-search/index.js +13 -46
  4. package/es/atom/input-search/index.js.map +1 -1
  5. package/es/atom/input-search/style.css +0 -96
  6. package/es/molecule/card/customer.css +0 -3
  7. package/es/molecule/card/favorite.css +3 -3
  8. package/es/molecule/card/index.d.ts.map +1 -1
  9. package/es/molecule/card/index.js +27 -11
  10. package/es/molecule/card/index.js.map +1 -1
  11. package/es/molecule/card/notification.css +28 -12
  12. package/es/molecule/card/notification.d.ts.map +1 -1
  13. package/es/molecule/card/notification.js +24 -4
  14. package/es/molecule/card/notification.js.map +1 -1
  15. package/es/molecule/card/style.css +4 -53
  16. package/es/molecule/card-content/index.d.ts.map +1 -1
  17. package/es/molecule/card-content/index.js +59 -37
  18. package/es/molecule/card-content/index.js.map +1 -1
  19. package/es/molecule/card-content/style.css +27 -72
  20. package/es/molecule/cm-popin/types.d.ts +0 -2
  21. package/es/molecule/cm-popin/types.d.ts.map +1 -1
  22. package/es/molecule/external-content-button/style.css +1 -0
  23. package/es/molecule/multi-filter-panel/index.d.ts +0 -2
  24. package/es/molecule/multi-filter-panel/index.d.ts.map +1 -1
  25. package/es/molecule/multi-filter-panel/prop-types.d.ts +0 -2
  26. package/es/molecule/multi-filter-panel/prop-types.d.ts.map +1 -1
  27. package/es/molecule/search-form/index.d.ts +0 -5
  28. package/es/molecule/search-form/index.d.ts.map +1 -1
  29. package/es/molecule/search-form/index.js +16 -26
  30. package/es/molecule/search-form/index.js.map +1 -1
  31. package/es/molecule/search-form/style.css +6 -21
  32. package/es/organism/brand-table/index.d.ts +0 -2
  33. package/es/organism/content-skill-modal/index.d.ts +0 -4
  34. package/es/organism/content-skill-modal/index.d.ts.map +1 -1
  35. package/es/organism/content-skill-modal/types.d.ts +0 -4
  36. package/es/organism/content-skill-modal/types.d.ts.map +1 -1
  37. package/es/organism/filter-checkbox-and-search/index.d.ts +0 -2
  38. package/es/organism/filter-checkbox-and-search/index.d.ts.map +1 -1
  39. package/es/organism/filter-checkbox-and-search/props-types.d.ts +0 -2
  40. package/es/organism/filter-checkbox-and-search/props-types.d.ts.map +1 -1
  41. package/es/organism/list-items/index.d.ts +0 -2
  42. package/es/organism/mooc-header/index.d.ts +0 -14
  43. package/es/organism/mooc-header/index.d.ts.map +1 -1
  44. package/es/organism/mooc-header/index.js +12 -123
  45. package/es/organism/mooc-header/index.js.map +1 -1
  46. package/es/organism/mooc-header/style.css +8 -181
  47. package/es/template/app-player/loading/index.d.ts +0 -2
  48. package/es/template/app-player/player/index.d.ts +0 -4
  49. package/es/template/app-player/player/slides/index.d.ts +0 -2
  50. package/es/template/app-player/player/slides/index.d.ts.map +1 -1
  51. package/es/template/app-player/popin-correction/index.d.ts +0 -2
  52. package/es/template/app-player/popin-correction/index.d.ts.map +1 -1
  53. package/es/template/app-player/popin-end/index.d.ts +0 -2
  54. package/es/template/app-review/index.d.ts +0 -2
  55. package/es/template/app-review/index.d.ts.map +1 -1
  56. package/es/template/app-review/player/prop-types.d.ts +0 -2
  57. package/es/template/app-review/player/prop-types.d.ts.map +1 -1
  58. package/es/template/app-review/prop-types.d.ts +0 -2
  59. package/es/template/app-review/prop-types.d.ts.map +1 -1
  60. package/es/template/back-office/brand-update/index.d.ts +0 -12
  61. package/es/template/common/dashboard/index.d.ts +0 -4
  62. package/es/template/common/search-page/index.d.ts +0 -2
  63. package/es/template/external-course/index.d.ts +0 -2
  64. package/es/util/check-is-mobile.d.ts +1 -1
  65. package/es/util/check-is-mobile.d.ts.map +1 -1
  66. package/es/util/check-is-mobile.js +2 -4
  67. package/es/util/check-is-mobile.js.map +1 -1
  68. package/es/util/external-content.d.ts +38 -4
  69. package/es/util/external-content.d.ts.map +1 -1
  70. package/es/util/external-content.js +27 -4
  71. package/es/util/external-content.js.map +1 -1
  72. package/es/util/icons.d.ts +8 -0
  73. package/es/util/icons.d.ts.map +1 -0
  74. package/es/util/icons.js +8 -0
  75. package/es/util/icons.js.map +1 -0
  76. package/es/variables/colors.d.ts +5 -0
  77. package/es/variables/colors.d.ts.map +1 -1
  78. package/es/variables/colors.js +6 -1
  79. package/es/variables/colors.js.map +1 -1
  80. package/lib/atom/input-search/index.d.ts +0 -2
  81. package/lib/atom/input-search/index.d.ts.map +1 -1
  82. package/lib/atom/input-search/index.js +13 -46
  83. package/lib/atom/input-search/index.js.map +1 -1
  84. package/lib/atom/input-search/style.css +0 -96
  85. package/lib/molecule/card/customer.css +0 -3
  86. package/lib/molecule/card/favorite.css +3 -3
  87. package/lib/molecule/card/index.d.ts.map +1 -1
  88. package/lib/molecule/card/index.js +26 -10
  89. package/lib/molecule/card/index.js.map +1 -1
  90. package/lib/molecule/card/notification.css +28 -12
  91. package/lib/molecule/card/notification.d.ts.map +1 -1
  92. package/lib/molecule/card/notification.js +23 -3
  93. package/lib/molecule/card/notification.js.map +1 -1
  94. package/lib/molecule/card/style.css +4 -53
  95. package/lib/molecule/card-content/index.d.ts.map +1 -1
  96. package/lib/molecule/card-content/index.js +58 -36
  97. package/lib/molecule/card-content/index.js.map +1 -1
  98. package/lib/molecule/card-content/style.css +27 -72
  99. package/lib/molecule/cm-popin/types.d.ts +0 -2
  100. package/lib/molecule/cm-popin/types.d.ts.map +1 -1
  101. package/lib/molecule/external-content-button/style.css +1 -0
  102. package/lib/molecule/multi-filter-panel/index.d.ts +0 -2
  103. package/lib/molecule/multi-filter-panel/index.d.ts.map +1 -1
  104. package/lib/molecule/multi-filter-panel/prop-types.d.ts +0 -2
  105. package/lib/molecule/multi-filter-panel/prop-types.d.ts.map +1 -1
  106. package/lib/molecule/search-form/index.d.ts +0 -5
  107. package/lib/molecule/search-form/index.d.ts.map +1 -1
  108. package/lib/molecule/search-form/index.js +17 -27
  109. package/lib/molecule/search-form/index.js.map +1 -1
  110. package/lib/molecule/search-form/style.css +6 -21
  111. package/lib/organism/brand-table/index.d.ts +0 -2
  112. package/lib/organism/content-skill-modal/index.d.ts +0 -4
  113. package/lib/organism/content-skill-modal/index.d.ts.map +1 -1
  114. package/lib/organism/content-skill-modal/types.d.ts +0 -4
  115. package/lib/organism/content-skill-modal/types.d.ts.map +1 -1
  116. package/lib/organism/filter-checkbox-and-search/index.d.ts +0 -2
  117. package/lib/organism/filter-checkbox-and-search/index.d.ts.map +1 -1
  118. package/lib/organism/filter-checkbox-and-search/props-types.d.ts +0 -2
  119. package/lib/organism/filter-checkbox-and-search/props-types.d.ts.map +1 -1
  120. package/lib/organism/list-items/index.d.ts +0 -2
  121. package/lib/organism/mooc-header/index.d.ts +0 -14
  122. package/lib/organism/mooc-header/index.d.ts.map +1 -1
  123. package/lib/organism/mooc-header/index.js +12 -123
  124. package/lib/organism/mooc-header/index.js.map +1 -1
  125. package/lib/organism/mooc-header/style.css +8 -181
  126. package/lib/template/app-player/loading/index.d.ts +0 -2
  127. package/lib/template/app-player/player/index.d.ts +0 -4
  128. package/lib/template/app-player/player/slides/index.d.ts +0 -2
  129. package/lib/template/app-player/player/slides/index.d.ts.map +1 -1
  130. package/lib/template/app-player/popin-correction/index.d.ts +0 -2
  131. package/lib/template/app-player/popin-correction/index.d.ts.map +1 -1
  132. package/lib/template/app-player/popin-end/index.d.ts +0 -2
  133. package/lib/template/app-review/index.d.ts +0 -2
  134. package/lib/template/app-review/index.d.ts.map +1 -1
  135. package/lib/template/app-review/player/prop-types.d.ts +0 -2
  136. package/lib/template/app-review/player/prop-types.d.ts.map +1 -1
  137. package/lib/template/app-review/prop-types.d.ts +0 -2
  138. package/lib/template/app-review/prop-types.d.ts.map +1 -1
  139. package/lib/template/back-office/brand-update/index.d.ts +0 -12
  140. package/lib/template/common/dashboard/index.d.ts +0 -4
  141. package/lib/template/common/search-page/index.d.ts +0 -2
  142. package/lib/template/external-course/index.d.ts +0 -2
  143. package/lib/util/check-is-mobile.d.ts +1 -1
  144. package/lib/util/check-is-mobile.d.ts.map +1 -1
  145. package/lib/util/check-is-mobile.js +2 -4
  146. package/lib/util/check-is-mobile.js.map +1 -1
  147. package/lib/util/external-content.d.ts +38 -4
  148. package/lib/util/external-content.d.ts.map +1 -1
  149. package/lib/util/external-content.js +28 -5
  150. package/lib/util/external-content.js.map +1 -1
  151. package/lib/util/icons.d.ts +8 -0
  152. package/lib/util/icons.d.ts.map +1 -0
  153. package/lib/util/icons.js +12 -0
  154. package/lib/util/icons.js.map +1 -0
  155. package/lib/variables/colors.d.ts +5 -0
  156. package/lib/variables/colors.d.ts.map +1 -1
  157. package/lib/variables/colors.js +6 -1
  158. package/lib/variables/colors.js.map +1 -1
  159. package/locales/en/global.json +5 -0
  160. package/locales/lt/global.json +24 -24
  161. package/package.json +2 -2
@@ -1,8 +1,8 @@
1
+ import _get from "lodash/fp/get";
1
2
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
2
3
  import React, { useMemo } from 'react';
3
4
  import PropTypes from 'prop-types';
4
- import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
5
- import classnames from 'classnames';
5
+ import { NovaCompositionNavigationMore as ClearIcon } from '@coorpacademy/nova-icons';
6
6
  import Search from '../../atom/input-search';
7
7
  import style from './style.css';
8
8
  const SearchForm = (props, context) => {
@@ -14,23 +14,17 @@ const SearchForm = (props, context) => {
14
14
  search,
15
15
  onSearchFocus,
16
16
  onSearchBlur,
17
- onSearchKeyDown,
18
- inputRef,
19
17
  'search-reset-aria-label': searchResetAriaLabel,
20
- dataTestId,
21
- theme
18
+ dataTestId
22
19
  } = props;
23
20
  const handleSubmit = useMemo(() => evt => {
24
21
  evt.preventDefault();
25
22
  return onSubmit && onSubmit(evt);
26
23
  }, [onSubmit]);
27
- const handleReset = useMemo(() => evt => {
28
- evt.preventDefault();
29
- evt.stopPropagation();
30
- return onReset && onReset(evt);
31
- }, [onReset]);
32
- const isMooc = theme === 'mooc';
33
- const clearClassName = search.value ? classnames(style.wrapperClear, isMooc && style.wrapperClearMooc) : style.wrapperNoClear;
24
+ const {
25
+ skin
26
+ } = context;
27
+ const dark = _get('common.dark', skin);
34
28
  return /*#__PURE__*/React.createElement("form", {
35
29
  className: style.form,
36
30
  action: action,
@@ -41,18 +35,17 @@ const SearchForm = (props, context) => {
41
35
  }, /*#__PURE__*/React.createElement(Search, _extends({}, search, {
42
36
  onFocus: onSearchFocus,
43
37
  onBlur: onSearchBlur,
44
- onKeyDown: onSearchKeyDown,
45
- inputRef: inputRef,
46
- dataTestId: dataTestId,
47
- theme: theme
38
+ dataTestId: dataTestId
48
39
  })), /*#__PURE__*/React.createElement("div", {
49
40
  "data-name": "search-form-reset",
50
41
  "aria-label": searchResetAriaLabel,
51
- onMouseDown: handleReset,
52
- className: clearClassName
53
- }, /*#__PURE__*/React.createElement(FontAwesomeIcon, {
54
- icon: "xmark",
55
- className: style.clearIcon
42
+ onClick: onReset,
43
+ className: search.value ? style.wrapperClear : style.wrapperNoClear
44
+ }, /*#__PURE__*/React.createElement(ClearIcon, {
45
+ style: {
46
+ color: dark
47
+ },
48
+ className: style.clear
56
49
  })));
57
50
  };
58
51
  SearchForm.propTypes = process.env.NODE_ENV !== "production" ? {
@@ -62,12 +55,9 @@ SearchForm.propTypes = process.env.NODE_ENV !== "production" ? {
62
55
  onReset: PropTypes.func,
63
56
  onSearchFocus: PropTypes.func,
64
57
  onSearchBlur: PropTypes.func,
65
- onSearchKeyDown: PropTypes.func,
66
- inputRef: PropTypes.func,
67
58
  search: PropTypes.shape(Search.propTypes),
68
59
  'search-reset-aria-label': PropTypes.string,
69
- dataTestId: PropTypes.string,
70
- theme: PropTypes.string
60
+ dataTestId: PropTypes.string
71
61
  } : {};
72
62
  export default SearchForm;
73
63
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["React","useMemo","PropTypes","FontAwesomeIcon","classnames","Search","style","SearchForm","props","context","action","method","onSubmit","onReset","search","onSearchFocus","onSearchBlur","onSearchKeyDown","inputRef","searchResetAriaLabel","dataTestId","theme","handleSubmit","evt","preventDefault","handleReset","stopPropagation","isMooc","clearClassName","value","wrapperClear","wrapperClearMooc","wrapperNoClear","createElement","className","form","placeholder","_extends","onFocus","onBlur","onKeyDown","onMouseDown","icon","clearIcon","propTypes","process","env","NODE_ENV","string","func","shape"],"sources":["../../../src/molecule/search-form/index.js"],"sourcesContent":["import React, {useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport {FontAwesomeIcon} from '@fortawesome/react-fontawesome';\nimport classnames from 'classnames';\nimport Search from '../../atom/input-search';\nimport style from './style.css';\n\nconst SearchForm = (props, context) => {\n const {\n action,\n method,\n onSubmit,\n onReset,\n search,\n onSearchFocus,\n onSearchBlur,\n onSearchKeyDown,\n inputRef,\n 'search-reset-aria-label': searchResetAriaLabel,\n dataTestId,\n theme\n } = props;\n const handleSubmit = useMemo(\n () => evt => {\n evt.preventDefault();\n return onSubmit && onSubmit(evt);\n },\n [onSubmit]\n );\n\n const handleReset = useMemo(\n () => evt => {\n evt.preventDefault();\n evt.stopPropagation();\n return onReset && onReset(evt);\n },\n [onReset]\n );\n\n const isMooc = theme === 'mooc';\n\n const clearClassName = search.value\n ? classnames(style.wrapperClear, isMooc && style.wrapperClearMooc)\n : style.wrapperNoClear;\n\n return (\n <form\n className={style.form}\n action={action}\n method={method}\n onSubmit={handleSubmit}\n data-name=\"searchForm\"\n aria-label={search.placeholder}\n >\n <Search\n {...search}\n onFocus={onSearchFocus}\n onBlur={onSearchBlur}\n onKeyDown={onSearchKeyDown}\n inputRef={inputRef}\n dataTestId={dataTestId}\n theme={theme}\n />\n <div\n data-name=\"search-form-reset\"\n aria-label={searchResetAriaLabel}\n onMouseDown={handleReset}\n className={clearClassName}\n >\n <FontAwesomeIcon icon=\"xmark\" className={style.clearIcon} />\n </div>\n </form>\n );\n};\n\nSearchForm.propTypes = {\n action: PropTypes.string,\n method: PropTypes.string,\n onSubmit: PropTypes.func,\n onReset: PropTypes.func,\n onSearchFocus: PropTypes.func,\n onSearchBlur: PropTypes.func,\n onSearchKeyDown: PropTypes.func,\n inputRef: PropTypes.func,\n search: PropTypes.shape(Search.propTypes),\n 'search-reset-aria-label': PropTypes.string,\n dataTestId: PropTypes.string,\n theme: PropTypes.string\n};\n\nexport default SearchForm;\n"],"mappings":"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","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":["React","useMemo","PropTypes","NovaCompositionNavigationMore","ClearIcon","Search","style","SearchForm","props","context","action","method","onSubmit","onReset","search","onSearchFocus","onSearchBlur","searchResetAriaLabel","dataTestId","handleSubmit","evt","preventDefault","skin","dark","_get","createElement","className","form","placeholder","_extends","onFocus","onBlur","onClick","value","wrapperClear","wrapperNoClear","color","clear","propTypes","process","env","NODE_ENV","string","func","shape"],"sources":["../../../src/molecule/search-form/index.js"],"sourcesContent":["import React, {useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport {get} from 'lodash/fp';\nimport {NovaCompositionNavigationMore as ClearIcon} from '@coorpacademy/nova-icons';\nimport Search from '../../atom/input-search';\nimport style from './style.css';\n\nconst SearchForm = (props, context) => {\n const {\n action,\n method,\n onSubmit,\n onReset,\n search,\n onSearchFocus,\n onSearchBlur,\n 'search-reset-aria-label': searchResetAriaLabel,\n dataTestId\n } = props;\n const handleSubmit = useMemo(\n () => evt => {\n evt.preventDefault();\n return onSubmit && onSubmit(evt);\n },\n [onSubmit]\n );\n const {skin} = context;\n const dark = get('common.dark', skin);\n\n return (\n <form\n className={style.form}\n action={action}\n method={method}\n onSubmit={handleSubmit}\n data-name=\"searchForm\"\n aria-label={search.placeholder}\n >\n <Search {...search} onFocus={onSearchFocus} onBlur={onSearchBlur} dataTestId={dataTestId} />\n <div\n data-name=\"search-form-reset\"\n aria-label={searchResetAriaLabel}\n onClick={onReset}\n className={search.value ? style.wrapperClear : style.wrapperNoClear}\n >\n <ClearIcon style={{color: dark}} className={style.clear} />\n </div>\n </form>\n );\n};\n\nSearchForm.propTypes = {\n action: PropTypes.string,\n method: PropTypes.string,\n onSubmit: PropTypes.func,\n onReset: PropTypes.func,\n onSearchFocus: PropTypes.func,\n onSearchBlur: PropTypes.func,\n search: PropTypes.shape(Search.propTypes),\n 'search-reset-aria-label': PropTypes.string,\n dataTestId: PropTypes.string\n};\n\nexport default SearchForm;\n"],"mappings":";;AAAA,OAAOA,KAAK,IAAGC,OAAO,QAAO,OAAO;AACpC,OAAOC,SAAS,MAAM,YAAY;AAElC,SAAQC,6BAA6B,IAAIC,SAAS,QAAO,0BAA0B;AACnF,OAAOC,MAAM,MAAM,yBAAyB;AAC5C,OAAOC,KAAK,MAAM,aAAa;AAE/B,MAAMC,UAAU,GAAGA,CAACC,KAAK,EAAEC,OAAO,KAAK;EACrC,MAAM;IACJC,MAAM;IACNC,MAAM;IACNC,QAAQ;IACRC,OAAO;IACPC,MAAM;IACNC,aAAa;IACbC,YAAY;IACZ,yBAAyB,EAAEC,oBAAoB;IAC/CC;EACF,CAAC,GAAGV,KAAK;EACT,MAAMW,YAAY,GAAGlB,OAAO,CAC1B,MAAMmB,GAAG,IAAI;IACXA,GAAG,CAACC,cAAc,CAAC,CAAC;IACpB,OAAOT,QAAQ,IAAIA,QAAQ,CAACQ,GAAG,CAAC;EAClC,CAAC,EACD,CAACR,QAAQ,CACX,CAAC;EACD,MAAM;IAACU;EAAI,CAAC,GAAGb,OAAO;EACtB,MAAMc,IAAI,GAAGC,IAAA,CAAI,aAAa,EAAEF,IAAI,CAAC;EAErC,oBACEtB,KAAA,CAAAyB,aAAA;IACEC,SAAS,EAAEpB,KAAK,CAACqB,IAAK;IACtBjB,MAAM,EAAEA,MAAO;IACfC,MAAM,EAAEA,MAAO;IACfC,QAAQ,EAAEO,YAAa;IACvB,aAAU,YAAY;IACtB,cAAYL,MAAM,CAACc;EAAY,gBAE/B5B,KAAA,CAAAyB,aAAA,CAACpB,MAAM,EAAAwB,QAAA,KAAKf,MAAM;IAAEgB,OAAO,EAAEf,aAAc;IAACgB,MAAM,EAAEf,YAAa;IAACE,UAAU,EAAEA;EAAW,EAAE,CAAC,eAC5FlB,KAAA,CAAAyB,aAAA;IACE,aAAU,mBAAmB;IAC7B,cAAYR,oBAAqB;IACjCe,OAAO,EAAEnB,OAAQ;IACjBa,SAAS,EAAEZ,MAAM,CAACmB,KAAK,GAAG3B,KAAK,CAAC4B,YAAY,GAAG5B,KAAK,CAAC6B;EAAe,gBAEpEnC,KAAA,CAAAyB,aAAA,CAACrB,SAAS;IAACE,KAAK,EAAE;MAAC8B,KAAK,EAAEb;IAAI,CAAE;IAACG,SAAS,EAAEpB,KAAK,CAAC+B;EAAM,CAAE,CACvD,CACD,CAAC;AAEX,CAAC;AAED9B,UAAU,CAAC+B,SAAS,GAAAC,OAAA,CAAAC,GAAA,CAAAC,QAAA,oBAAG;EACrB/B,MAAM,EAAER,SAAS,CAACwC,MAAM;EACxB/B,MAAM,EAAET,SAAS,CAACwC,MAAM;EACxB9B,QAAQ,EAAEV,SAAS,CAACyC,IAAI;EACxB9B,OAAO,EAAEX,SAAS,CAACyC,IAAI;EACvB5B,aAAa,EAAEb,SAAS,CAACyC,IAAI;EAC7B3B,YAAY,EAAEd,SAAS,CAACyC,IAAI;EAC5B7B,MAAM,EAAEZ,SAAS,CAAC0C,KAAK,CAACvC,MAAM,CAACiC,SAAS,CAAC;EACzC,yBAAyB,EAAEpC,SAAS,CAACwC,MAAM;EAC3CxB,UAAU,EAAEhB,SAAS,CAACwC;AACxB,CAAC;AAED,eAAenC,UAAU","ignoreList":[]}
@@ -1,6 +1,3 @@
1
- @value colors: "../../variables/colors.css";
2
- @value cm_grey_500 from colors;
3
-
4
1
  .form {
5
2
  display: flex;
6
3
  justify-content: flex-start;
@@ -11,7 +8,6 @@
11
8
  margin: 0;
12
9
  width: 100%;
13
10
  height: 100%;
14
- position: relative;
15
11
  }
16
12
 
17
13
  .wrapperClear {
@@ -27,22 +23,11 @@
27
23
  display: none;
28
24
  }
29
25
 
30
- .clearIcon {
31
- color: cm_grey_500;
32
- width: 12px;
33
- height: 14px;
34
- }
35
-
36
- .wrapperClearMooc {
26
+ .clear {
27
+ transform: rotate(45deg);
28
+ width: 10px;
29
+ height: 10px;
37
30
  position: absolute;
38
- right: 16px;
39
- width: 14px;
40
- height: 14px;
41
- top: 50%;
42
- transform: translateY(-50%);
43
- cursor: pointer;
44
- display: flex;
45
- align-items: center;
46
- justify-content: center;
47
- z-index: 2002;
31
+ top: 0;
32
+ left: 0;
48
33
  }
@@ -9,8 +9,6 @@ declare namespace BrandTable {
9
9
  onClear: PropTypes.Requireable<(...args: any[]) => any>;
10
10
  onFocus: PropTypes.Requireable<(...args: any[]) => any>;
11
11
  onBlur: PropTypes.Requireable<(...args: any[]) => any>;
12
- onKeyDown: PropTypes.Requireable<(...args: any[]) => any>;
13
- inputRef: PropTypes.Requireable<(...args: any[]) => any>;
14
12
  theme: PropTypes.Requireable<string>;
15
13
  dataTestId: PropTypes.Requireable<string>;
16
14
  }>>;
@@ -493,8 +493,6 @@ declare const ContentSkillModal: {
493
493
  onClear: import("prop-types").Requireable<(...args: any[]) => any>;
494
494
  onFocus: import("prop-types").Requireable<(...args: any[]) => any>;
495
495
  onBlur: import("prop-types").Requireable<(...args: any[]) => any>;
496
- onKeyDown: import("prop-types").Requireable<(...args: any[]) => any>;
497
- inputRef: import("prop-types").Requireable<(...args: any[]) => any>;
498
496
  theme: import("prop-types").Requireable<string>;
499
497
  dataTestId: import("prop-types").Requireable<string>;
500
498
  }>>;
@@ -672,8 +670,6 @@ declare const ContentSkillModal: {
672
670
  onClear: import("prop-types").Requireable<(...args: any[]) => any>;
673
671
  onFocus: import("prop-types").Requireable<(...args: any[]) => any>;
674
672
  onBlur: import("prop-types").Requireable<(...args: any[]) => any>;
675
- onKeyDown: import("prop-types").Requireable<(...args: any[]) => any>;
676
- inputRef: import("prop-types").Requireable<(...args: any[]) => any>;
677
673
  theme: import("prop-types").Requireable<string>;
678
674
  dataTestId: import("prop-types").Requireable<string>;
679
675
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/content-skill-modal/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAOlD,OAAkB,EAAC,sBAAsB,EAAC,MAAM,SAAS,CAAC;AAE1D,QAAA,MAAM,iBAAiB;YAAW,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6DvD,CAAC;AAQF,eAAe,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/content-skill-modal/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAOlD,OAAkB,EAAC,sBAAsB,EAAC,MAAM,SAAS,CAAC;AAE1D,QAAA,MAAM,iBAAiB;YAAW,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6DvD,CAAC;AAQF,eAAe,iBAAiB,CAAC"}
@@ -490,8 +490,6 @@ declare const ContentSkillModalPropTypes: {
490
490
  onClear: PropTypes.Requireable<(...args: any[]) => any>;
491
491
  onFocus: PropTypes.Requireable<(...args: any[]) => any>;
492
492
  onBlur: PropTypes.Requireable<(...args: any[]) => any>;
493
- onKeyDown: PropTypes.Requireable<(...args: any[]) => any>;
494
- inputRef: PropTypes.Requireable<(...args: any[]) => any>;
495
493
  theme: PropTypes.Requireable<string>;
496
494
  dataTestId: PropTypes.Requireable<string>;
497
495
  }>>;
@@ -669,8 +667,6 @@ declare const ContentSkillModalPropTypes: {
669
667
  onClear: PropTypes.Requireable<(...args: any[]) => any>;
670
668
  onFocus: PropTypes.Requireable<(...args: any[]) => any>;
671
669
  onBlur: PropTypes.Requireable<(...args: any[]) => any>;
672
- onKeyDown: PropTypes.Requireable<(...args: any[]) => any>;
673
- inputRef: PropTypes.Requireable<(...args: any[]) => any>;
674
670
  theme: PropTypes.Requireable<string>;
675
671
  dataTestId: PropTypes.Requireable<string>;
676
672
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/organism/content-skill-modal/types.ts"],"names":[],"mappings":";AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,SAAS,MAAM,eAAe,CAAC;AACtC,OAAkC,EAChC,qBAAqB,EACtB,MAAM,8CAA8C,CAAC;AAStD,QAAA,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAI/B,CAAC;AAEF,eAAe,0BAA0B,CAAC;AAE1C,aAAK,UAAU,GAAG;IAChB,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,oBAAY,sBAAsB,GAAG;IACnC,WAAW,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,SAAS,CAAC,CAAC;IACpD,OAAO,EAAE,qBAAqB,CAAC;IAC/B,KAAK,EAAE,UAAU,CAAC;CACnB,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/organism/content-skill-modal/types.ts"],"names":[],"mappings":";AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,SAAS,MAAM,eAAe,CAAC;AACtC,OAAkC,EAChC,qBAAqB,EACtB,MAAM,8CAA8C,CAAC;AAStD,QAAA,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAI/B,CAAC;AAEF,eAAe,0BAA0B,CAAC;AAE1C,aAAK,UAAU,GAAG;IAChB,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,oBAAY,sBAAsB,GAAG;IACnC,WAAW,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,SAAS,CAAC,CAAC;IACpD,OAAO,EAAE,qBAAqB,CAAC;IAC/B,KAAK,EAAE,UAAU,CAAC;CACnB,CAAC"}
@@ -21,8 +21,6 @@ declare const FilterCheckboxAndSearch: {
21
21
  onClear: import("prop-types").Requireable<(...args: any[]) => any>;
22
22
  onFocus: import("prop-types").Requireable<(...args: any[]) => any>;
23
23
  onBlur: import("prop-types").Requireable<(...args: any[]) => any>;
24
- onKeyDown: import("prop-types").Requireable<(...args: any[]) => any>;
25
- inputRef: import("prop-types").Requireable<(...args: any[]) => any>;
26
24
  theme: import("prop-types").Requireable<string>;
27
25
  dataTestId: import("prop-types").Requireable<string>;
28
26
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/filter-checkbox-and-search/index.tsx"],"names":[],"mappings":";AAMA,OAAO,EAAC,gBAAgB,EAAC,MAAM,iCAAiC,CAAC;AAKjE,OAAkB,EAAC,4BAA4B,EAAC,MAAM,eAAe,CAAC;AAiBtE,QAAA,MAAM,uBAAuB;YACpB,4BAA4B,WAC1B,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+F1B,CAAC;AAQF,eAAe,uBAAuB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/filter-checkbox-and-search/index.tsx"],"names":[],"mappings":";AAMA,OAAO,EAAC,gBAAgB,EAAC,MAAM,iCAAiC,CAAC;AAKjE,OAAkB,EAAC,4BAA4B,EAAC,MAAM,eAAe,CAAC;AAiBtE,QAAA,MAAM,uBAAuB;YACpB,4BAA4B,WAC1B,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;CA+F1B,CAAC;AAQF,eAAe,uBAAuB,CAAC"}
@@ -17,8 +17,6 @@ declare const propTypes: {
17
17
  onClear: PropTypes.Requireable<(...args: any[]) => any>;
18
18
  onFocus: PropTypes.Requireable<(...args: any[]) => any>;
19
19
  onBlur: PropTypes.Requireable<(...args: any[]) => any>;
20
- onKeyDown: PropTypes.Requireable<(...args: any[]) => any>;
21
- inputRef: PropTypes.Requireable<(...args: any[]) => any>;
22
20
  theme: PropTypes.Requireable<string>;
23
21
  dataTestId: PropTypes.Requireable<string>;
24
22
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"props-types.d.ts","sourceRoot":"","sources":["../../../src/organism/filter-checkbox-and-search/props-types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAGnC,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;CAcd,CAAC;AAEF,oBAAY,8BAA8B,GAAG;IAC3C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,OAAO,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,aAAK,UAAU,GAAG;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,CAAC,EAAE,SAAS,GAAG,cAAc,CAAC;IACnC,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,oBAAY,4BAA4B,GAAG;IACzC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,aAAa,EAAE,UAAU,CAAC;IAC1B,OAAO,EAAE,8BAA8B,EAAE,CAAC;CAC3C,CAAC;AAEF,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"props-types.d.ts","sourceRoot":"","sources":["../../../src/organism/filter-checkbox-and-search/props-types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAGnC,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;CAcd,CAAC;AAEF,oBAAY,8BAA8B,GAAG;IAC3C,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,OAAO,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC;AAEF,aAAK,UAAU,GAAG;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,KAAK,CAAC,EAAE,SAAS,GAAG,cAAc,CAAC;IACnC,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,oBAAY,4BAA4B,GAAG;IACzC,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,aAAa,EAAE,UAAU,CAAC;IAC1B,OAAO,EAAE,8BAA8B,EAAE,CAAC;CAC3C,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -499,8 +499,6 @@ declare namespace ListItems {
499
499
  onClear: PropTypes.Requireable<(...args: any[]) => any>;
500
500
  onFocus: PropTypes.Requireable<(...args: any[]) => any>;
501
501
  onBlur: PropTypes.Requireable<(...args: any[]) => any>;
502
- onKeyDown: PropTypes.Requireable<(...args: any[]) => any>;
503
- inputRef: PropTypes.Requireable<(...args: any[]) => any>;
504
502
  theme: PropTypes.Requireable<string>;
505
503
  dataTestId: PropTypes.Requireable<string>;
506
504
  }>>;
@@ -17,8 +17,6 @@ declare class MoocHeader extends React.Component<any, any, any> {
17
17
  onClear: PropTypes.Requireable<(...args: any[]) => any>;
18
18
  onFocus: PropTypes.Requireable<(...args: any[]) => any>;
19
19
  onBlur: PropTypes.Requireable<(...args: any[]) => any>;
20
- onKeyDown: PropTypes.Requireable<(...args: any[]) => any>;
21
- inputRef: PropTypes.Requireable<(...args: any[]) => any>;
22
20
  theme: PropTypes.Requireable<string>;
23
21
  dataTestId: PropTypes.Requireable<string>;
24
22
  }>>;
@@ -148,14 +146,11 @@ declare class MoocHeader extends React.Component<any, any, any> {
148
146
  }>>;
149
147
  };
150
148
  constructor(props: any);
151
- isMobile: boolean;
152
149
  state: {
153
150
  isSettingsOpen: boolean;
154
151
  isMenuOpen: boolean;
155
152
  isFocus: boolean;
156
153
  isToolTipOpen: boolean;
157
- isClosing: boolean;
158
- isClosingStep2: boolean;
159
154
  };
160
155
  handleSettingsToggle(): void;
161
156
  handleMenuToggle(): void;
@@ -171,16 +166,7 @@ declare class MoocHeader extends React.Component<any, any, any> {
171
166
  handleOnMouseOver(): void;
172
167
  handleOnMouseLeave(): void;
173
168
  handleKeyPress(event: any): void;
174
- handleSearchKeyDown(event: any): void;
175
- searchBarRef: any;
176
- searchInputRef: any;
177
- setSearchBarRef(ref: any): void;
178
- setSearchInputRef(ref: any): void;
179
- handleClickOutside(event: any): void;
180
- handleTransitionEnd(event: any): void;
181
- componentDidMount(): void;
182
169
  componentDidUpdate(prevProps: any, prevState: any, prevContext: any): void;
183
- componentWillUnmount(): void;
184
170
  menuSettings: any;
185
171
  createMenuButtons: (items: any, primaryColor: any) => any;
186
172
  render(): JSX.Element | null;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/mooc-header/index.js"],"names":[],"mappings":";AAuBA;IACE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAsGE;IAEF;;;;;;;;;;;;;;;;;;;;;;;MAGE;IAEF,wBAiCC;IA/BC,kBAAuD;IACvD;;;;;;;MAOC;IA8FH,6BAIC;IAED,yBAGC;IAxBD,qCAQC;IAED,wBAGC;IAjBD,+BAEC;IA4BD,2BAgBC;IAED,0BAKC;IAED,sBAIC;IAED,qBAiBC;IAaD,yBAQC;IAED,0BAQC;IAED,0BAIC;IAED,2BAIC;IAED,iCAUC;IAED,sCAKC;IAtMC,kBAAwB;IACxB,oBAA0B;IA0B5B,gCAEC;IAED,kCAEC;IAED,qCAqBC;IAkFD,sCASC;IA3ID,0BAEC;IAED,2EASC;IAED,6BAEC;IAkCC,kBAAsB;IA6IxB,0DAaE;IAEF,6BA2iBC;CACF"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/mooc-header/index.js"],"names":[],"mappings":";AAuBA;IACE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAsGE;IAEF;;;;;;;;;;;;;;;;;;;;;;;MAGE;IAEF,wBAuBC;IArBC;;;;;MAKC;IAgDH,6BAIC;IAED,yBAGC;IAxBD,qCAQC;IAED,wBAGC;IAjBD,+BAEC;IA4BD,2BAKC;IAED,0BAKC;IAED,sBAIC;IAED,qBAIC;IAED,yBAQC;IAED,0BAQC;IAED,0BAIC;IAED,2BAIC;IAED,iCAUC;IA7GD,2EASC;IAGC,kBAAsB;IAmGxB,0DAaE;IAEF,6BAufC;CACF"}
@@ -26,14 +26,11 @@ class MoocHeader extends React.Component {
26
26
  };
27
27
  constructor(props) {
28
28
  super(props);
29
- this.isMobile = getIsMobile(navigator?.userAgent, true); // true = inclure les tablettes
30
29
  this.state = {
31
30
  isSettingsOpen: false,
32
31
  isMenuOpen: false,
33
32
  isFocus: false,
34
- isToolTipOpen: false,
35
- isClosing: false,
36
- isClosingStep2: false
33
+ isToolTipOpen: false
37
34
  };
38
35
  this.handleSettingsToggle = this.handleSettingsToggle.bind(this);
39
36
  this.handleMenuToggle = this.handleMenuToggle.bind(this);
@@ -49,16 +46,6 @@ class MoocHeader extends React.Component {
49
46
  this.handleOnMouseOver = this.handleOnMouseOver.bind(this);
50
47
  this.handleOnMouseLeave = this.handleOnMouseLeave.bind(this);
51
48
  this.handleKeyPress = this.handleKeyPress.bind(this);
52
- this.handleSearchKeyDown = this.handleSearchKeyDown.bind(this);
53
- this.searchBarRef = null;
54
- this.searchInputRef = null;
55
- this.setSearchBarRef = this.setSearchBarRef.bind(this);
56
- this.setSearchInputRef = this.setSearchInputRef.bind(this);
57
- this.handleClickOutside = this.handleClickOutside.bind(this);
58
- this.handleTransitionEnd = this.handleTransitionEnd.bind(this);
59
- }
60
- componentDidMount() {
61
- document.addEventListener('mousedown', this.handleClickOutside);
62
49
  }
63
50
  componentDidUpdate(prevProps, prevState, prevContext) {
64
51
  const {
@@ -72,33 +59,6 @@ class MoocHeader extends React.Component {
72
59
  document.removeEventListener('touchstart', this._checkOnClose);
73
60
  }
74
61
  }
75
- componentWillUnmount() {
76
- document.removeEventListener('mousedown', this.handleClickOutside);
77
- }
78
- setSearchBarRef(ref) {
79
- this.searchBarRef = ref;
80
- }
81
- setSearchInputRef(ref) {
82
- this.searchInputRef = ref;
83
- }
84
- handleClickOutside(event) {
85
- const {
86
- isFocus
87
- } = this.state;
88
- if (isFocus) {
89
- if (event.target.getAttribute('data-name') === 'mobile-overlay') {
90
- return;
91
- }
92
- const resetButton = event.target.getAttribute('data-name') === 'search-form-reset' || event.target.closest('[data-name="search-form-reset"]');
93
- if (resetButton) {
94
- return;
95
- }
96
- if (this.searchBarRef && this.searchBarRef.contains(event.target)) {
97
- return;
98
- }
99
- this.handleOnBlur();
100
- }
101
- }
102
62
  setMenuSettings(el) {
103
63
  this.menuSettings = el;
104
64
  }
@@ -134,15 +94,6 @@ class MoocHeader extends React.Component {
134
94
  const {
135
95
  onSubmitSearch
136
96
  } = this.props;
137
- const searchInput = this.searchInputRef || document.querySelector('input[name="search"]');
138
- if (searchInput) {
139
- searchInput.blur();
140
- }
141
- this.setState({
142
- isFocus: false,
143
- isClosing: false,
144
- isClosingStep2: false
145
- });
146
97
  if (onSubmitSearch) {
147
98
  onSubmitSearch();
148
99
  }
@@ -161,33 +112,9 @@ class MoocHeader extends React.Component {
161
112
  }));
162
113
  }
163
114
  handleOnBlur() {
164
- if (this.isMobile) {
165
- this.setState({
166
- isFocus: false
167
- });
168
- } else {
169
- this.setState({
170
- isClosing: true
171
- });
172
- requestAnimationFrame(() => {
173
- this.setState({
174
- isClosing: false,
175
- isClosingStep2: true
176
- });
177
- });
178
- }
179
- }
180
- handleTransitionEnd(event) {
181
- const {
182
- isClosingStep2
183
- } = this.state;
184
- if ((event.propertyName === 'max-width' || event.propertyName === 'width') && isClosingStep2) {
185
- this.setState({
186
- isFocus: false,
187
- isClosing: false,
188
- isClosingStep2: false
189
- });
190
- }
115
+ this.setState(prevState => ({
116
+ isFocus: false
117
+ }));
191
118
  }
192
119
  handleOnMenuOpen() {
193
120
  const {
@@ -232,12 +159,6 @@ class MoocHeader extends React.Component {
232
159
  }));
233
160
  }
234
161
  }
235
- handleSearchKeyDown(event) {
236
- if (event.key === 'Enter') {
237
- event.preventDefault();
238
- this.handleSubmitSearch();
239
- }
240
- }
241
162
  createMenuButtons = (items, primaryColor) => {
242
163
  return items.map(item => ({
243
164
  label: item.title,
@@ -274,15 +195,14 @@ class MoocHeader extends React.Component {
274
195
  isFocus,
275
196
  isSettingsOpen,
276
197
  isMenuOpen,
277
- isToolTipOpen,
278
- isClosing,
279
- isClosingStep2
198
+ isToolTipOpen
280
199
  } = this.state;
281
200
  const {
282
201
  translate,
283
202
  skin
284
203
  } = this.context;
285
- const isMobile = this.isMobile;
204
+ const userAgent = navigator?.userAgent;
205
+ const isMobile = getIsMobile(userAgent);
286
206
  const {
287
207
  'aria-label': logoAriaLabel,
288
208
  closeMenuAriaLabel,
@@ -607,17 +527,14 @@ class MoocHeader extends React.Component {
607
527
  if (search) {
608
528
  searchFormView = /*#__PURE__*/React.createElement("div", {
609
529
  "data-name": "Search-Bar",
610
- className: isMenuOpen && !this.isMobile ? style.hiddenSearchBar : style.searchBar
530
+ className: isMenuOpen ? style.hiddenSearchBar : style.searchBar
611
531
  }, /*#__PURE__*/React.createElement(SearchForm, {
612
532
  search: search,
613
533
  onSubmit: this.handleSubmitSearch,
614
534
  onReset: this.handleResetSearch,
615
535
  onSearchFocus: this.handleOnFocus,
616
536
  onSearchBlur: this.handleOnBlur,
617
- onSearchKeyDown: this.handleSearchKeyDown,
618
- inputRef: this.setSearchInputRef,
619
- "search-reset-aria-label": searchResetAriaLabel,
620
- theme: "mooc"
537
+ "search-reset-aria-label": searchResetAriaLabel
621
538
  }));
622
539
  }
623
540
  return /*#__PURE__*/React.createElement("header", {
@@ -627,7 +544,7 @@ class MoocHeader extends React.Component {
627
544
  "data-open": isMenuOpen,
628
545
  className: isMenuOpen ? style.open : style.header
629
546
  }, /*#__PURE__*/React.createElement("div", {
630
- className: classnames(style.logoWrapper, this.isMobile && isFocus && style.logoWrapperMobileHidden),
547
+ className: style.logoWrapper,
631
548
  "aria-label": toolTipText,
632
549
  onMouseOver: this.handleOnMouseOver,
633
550
  onMouseLeave: this.handleOnMouseLeave
@@ -692,38 +609,10 @@ class MoocHeader extends React.Component {
692
609
  style: {
693
610
  color: primaryColor
694
611
  }
695
- }))) : null)), this.isMobile ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
696
- className: isFocus ? style.mobileSearchContainerFocus : style.mobileSearchContainer,
697
- ref: this.setSearchBarRef
698
- }, searchFormView), isFocus ? /*#__PURE__*/React.createElement("div", {
699
- className: style.mobileSearchOverlay,
700
- onClick: this.handleOnBlur,
701
- "data-name": "mobile-overlay"
702
- }) : null, /*#__PURE__*/React.createElement("nav", {
703
- className: isMenuOpen ? style.menuWrapper : style.hiddenMenuWrapper,
704
- "data-name": "menu-wrapper"
705
- }, pagesView, userView || linksView, settingsView)) : /*#__PURE__*/React.createElement("div", {
706
- className: classnames({
707
- [style.rightZone]: !isFocus && !isClosing && !isClosingStep2
708
- }, {
709
- [style.rightZoneFocus]: isFocus || isClosing || isClosingStep2
710
- }, {
711
- [style.searchBarActive]: isFocus || isClosing || isClosingStep2
712
- })
713
- }, /*#__PURE__*/React.createElement("div", {
714
- className: classnames(style.floatingSearchBar, {
715
- [style['floatingSearchBar--expanded']]: isFocus && !isClosing && !isClosingStep2,
716
- [style['floatingSearchBar--closing']]: isClosing
717
- }),
718
- ref: this.setSearchBarRef,
719
- onTransitionEnd: this.handleTransitionEnd
720
- }, searchFormView), isFocus || isClosing || isClosingStep2 ? /*#__PURE__*/React.createElement("div", {
721
- className: style.searchOverlay,
722
- onClick: this.handleOnBlur
723
- }) : null, /*#__PURE__*/React.createElement("nav", {
612
+ }))) : null)), searchFormView, /*#__PURE__*/React.createElement("nav", {
724
613
  className: isMenuOpen ? style.menuWrapper : style.hiddenMenuWrapper,
725
614
  "data-name": "menu-wrapper"
726
- }, pagesView, userView || linksView, settingsView))));
615
+ }, pagesView, userView || linksView, settingsView)));
727
616
  }
728
617
  }
729
618
  MoocHeader.propTypes = process.env.NODE_ENV !== "production" ? {