@coorpacademy/components 11.33.14 → 11.33.16
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.
- package/es/atom/title/index.d.ts.map +1 -1
- package/es/atom/title/index.js +4 -2
- package/es/atom/title/index.js.map +1 -1
- package/es/atom/title/style.css +6 -0
- package/es/atom/title/types.d.ts +1 -1
- package/es/atom/title/types.d.ts.map +1 -1
- package/es/atom/title/types.js.map +1 -1
- package/es/molecule/icon-preview/index.d.ts +12 -9
- package/es/molecule/icon-preview/index.d.ts.map +1 -1
- package/es/molecule/icon-preview/index.js +8 -13
- package/es/molecule/icon-preview/index.js.map +1 -1
- package/es/molecule/icon-preview/style.css +0 -1
- package/es/molecule/icon-preview/types.d.ts +18 -0
- package/es/molecule/icon-preview/types.d.ts.map +1 -0
- package/es/molecule/icon-preview/types.js +11 -0
- package/es/molecule/icon-preview/types.js.map +1 -0
- package/es/organism/header-with-actions/index.d.ts.map +1 -1
- package/es/organism/header-with-actions/index.js +9 -1
- package/es/organism/header-with-actions/index.js.map +1 -1
- package/es/organism/icon-editor/index.d.ts +73 -23
- package/es/organism/icon-editor/index.d.ts.map +1 -1
- package/es/organism/icon-editor/index.js +22 -35
- package/es/organism/icon-editor/index.js.map +1 -1
- package/es/organism/icon-editor/style.css +5 -5
- package/es/organism/icon-editor/types.d.ts +77 -0
- package/es/organism/icon-editor/types.d.ts.map +1 -0
- package/es/organism/icon-editor/types.js +11 -0
- package/es/organism/icon-editor/types.js.map +1 -0
- package/es/organism/list-item/style.css +3 -2
- package/es/organism/skill-edition/index.d.ts +1661 -0
- package/es/organism/skill-edition/index.d.ts.map +1 -0
- package/es/organism/skill-edition/index.js +26 -0
- package/es/organism/skill-edition/index.js.map +1 -0
- package/es/organism/skill-edition/style.css +23 -0
- package/es/organism/skill-edition/types.d.ts +1674 -0
- package/es/organism/skill-edition/types.d.ts.map +1 -0
- package/es/organism/skill-edition/types.js +18 -0
- package/es/organism/skill-edition/types.js.map +1 -0
- package/es/organism/title-and-input/index.d.ts +64 -0
- package/es/organism/title-and-input/index.d.ts.map +1 -1
- package/es/organism/title-and-input/index.js +3 -0
- package/es/organism/title-and-input/index.js.map +1 -1
- package/es/organism/title-and-input/types.d.ts +68 -3
- package/es/organism/title-and-input/types.d.ts.map +1 -1
- package/es/organism/title-and-input/types.js +3 -2
- package/es/organism/title-and-input/types.js.map +1 -1
- package/es/template/back-office/brand-update/index.d.ts +1747 -2
- package/es/template/back-office/brand-update/index.d.ts.map +1 -1
- package/es/template/back-office/brand-update/index.js +14 -3
- package/es/template/back-office/brand-update/index.js.map +1 -1
- package/lib/atom/title/index.d.ts.map +1 -1
- package/lib/atom/title/index.js +4 -2
- package/lib/atom/title/index.js.map +1 -1
- package/lib/atom/title/style.css +6 -0
- package/lib/atom/title/types.d.ts +1 -1
- package/lib/atom/title/types.d.ts.map +1 -1
- package/lib/atom/title/types.js.map +1 -1
- package/lib/molecule/icon-preview/index.d.ts +12 -9
- package/lib/molecule/icon-preview/index.d.ts.map +1 -1
- package/lib/molecule/icon-preview/index.js +8 -13
- package/lib/molecule/icon-preview/index.js.map +1 -1
- package/lib/molecule/icon-preview/style.css +0 -1
- package/lib/molecule/icon-preview/types.d.ts +18 -0
- package/lib/molecule/icon-preview/types.d.ts.map +1 -0
- package/lib/molecule/icon-preview/types.js +16 -0
- package/lib/molecule/icon-preview/types.js.map +1 -0
- package/lib/organism/header-with-actions/index.d.ts.map +1 -1
- package/lib/organism/header-with-actions/index.js +9 -1
- package/lib/organism/header-with-actions/index.js.map +1 -1
- package/lib/organism/icon-editor/index.d.ts +73 -23
- package/lib/organism/icon-editor/index.d.ts.map +1 -1
- package/lib/organism/icon-editor/index.js +24 -35
- package/lib/organism/icon-editor/index.js.map +1 -1
- package/lib/organism/icon-editor/style.css +5 -5
- package/lib/organism/icon-editor/types.d.ts +77 -0
- package/lib/organism/icon-editor/types.d.ts.map +1 -0
- package/lib/organism/icon-editor/types.js +16 -0
- package/lib/organism/icon-editor/types.js.map +1 -0
- package/lib/organism/list-item/style.css +3 -2
- package/lib/organism/skill-edition/index.d.ts +1661 -0
- package/lib/organism/skill-edition/index.d.ts.map +1 -0
- package/lib/organism/skill-edition/index.js +31 -0
- package/lib/organism/skill-edition/index.js.map +1 -0
- package/lib/organism/skill-edition/style.css +23 -0
- package/lib/organism/skill-edition/types.d.ts +1674 -0
- package/lib/organism/skill-edition/types.d.ts.map +1 -0
- package/lib/organism/skill-edition/types.js +23 -0
- package/lib/organism/skill-edition/types.js.map +1 -0
- package/lib/organism/title-and-input/index.d.ts +64 -0
- package/lib/organism/title-and-input/index.d.ts.map +1 -1
- package/lib/organism/title-and-input/index.js +3 -0
- package/lib/organism/title-and-input/index.js.map +1 -1
- package/lib/organism/title-and-input/types.d.ts +68 -3
- package/lib/organism/title-and-input/types.d.ts.map +1 -1
- package/lib/organism/title-and-input/types.js +3 -2
- package/lib/organism/title-and-input/types.js.map +1 -1
- package/lib/template/back-office/brand-update/index.d.ts +1747 -2
- package/lib/template/back-office/brand-update/index.d.ts.map +1 -1
- package/lib/template/back-office/brand-update/index.js +14 -3
- package/lib/template/back-office/brand-update/index.js.map +1 -1
- package/locales/bs/global.json +6 -0
- package/locales/cs/global.json +6 -0
- package/locales/de/global.json +6 -0
- package/locales/en/global.json +6 -0
- package/locales/es/global.json +6 -0
- package/locales/et/global.json +6 -0
- package/locales/fi/global.json +6 -0
- package/locales/fr/global.json +11 -5
- package/locales/hr/global.json +6 -0
- package/locales/hu/global.json +6 -0
- package/locales/hy/global.json +6 -0
- package/locales/it/global.json +6 -0
- package/locales/ja/global.json +6 -0
- package/locales/ko/global.json +6 -0
- package/locales/nl/global.json +6 -0
- package/locales/pl/global.json +6 -0
- package/locales/pt/global.json +6 -0
- package/locales/ro/global.json +6 -0
- package/locales/ru/global.json +6 -0
- package/locales/sk/global.json +6 -0
- package/locales/sl/global.json +6 -0
- package/locales/sv/global.json +6 -0
- package/locales/tl/global.json +6 -0
- package/locales/tr/global.json +6 -0
- package/locales/uk/global.json +6 -0
- package/locales/vi/global.json +6 -0
- package/locales/zh/global.json +6 -0
- package/locales/zh_TW/global.json +6 -0
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/title/index.js"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/title/index.js"],"names":[],"mappings":";AAsDA,gDAkCC"}
|
package/es/atom/title/index.js
CHANGED
|
@@ -20,9 +20,11 @@ const getTitleStyle = (type, size) => {
|
|
|
20
20
|
return style.xlStrongTitle;
|
|
21
21
|
case 'medium':
|
|
22
22
|
return style.mediumTitleFormGroup;
|
|
23
|
+
case 'medium-light-color':
|
|
24
|
+
return style.mediumAndLightColorTitleFormGroup;
|
|
23
25
|
case 'small':
|
|
24
26
|
return style.smallTitleFormGroup;
|
|
25
|
-
case '
|
|
27
|
+
case 'small-and-light':
|
|
26
28
|
return style.smallAndLightTitleFormGroup;
|
|
27
29
|
}
|
|
28
30
|
}
|
|
@@ -84,7 +86,7 @@ Title.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
84
86
|
subtitle: PropTypes.string,
|
|
85
87
|
type: PropTypes.oneOf(['page', 'form-group']),
|
|
86
88
|
'data-name': PropTypes.string,
|
|
87
|
-
titleSize: PropTypes.oneOf(['xl-strong', 'standard', 'standard-light-weight', 'medium', 'small', '
|
|
89
|
+
titleSize: PropTypes.oneOf(['xl-strong', 'standard', 'standard-light-weight', 'medium', 'medium-light-color', 'small', 'small-and-light']),
|
|
88
90
|
subtitleSize: PropTypes.oneOf(['standard', 'standard-without-margin', 'medium', 'small', 'small-without-margin', 'extra-small']),
|
|
89
91
|
icon: PropTypes.shape(Icon.propTypes),
|
|
90
92
|
tag: PropTypes.shape(Tag.propTypes),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","PropTypes","Icon","Tag","ButtonLink","style","getTitleStyle","type","size","titlePage","titleFormGroup","titleFormGroupLightWeight","xlStrongTitle","mediumTitleFormGroup","smallTitleFormGroup","smallAndLightTitleFormGroup","getSubtitleStyle","subtitlePage","subtitleFormGroup","subtitleFormGroupWithoutMargin","mediumSubtitleFormGroup","smallSubtitleFormGroup","smallSubtitleFormGroupWithoutMargin","extraSmallSubtitleFormGroup","Title","props","title","subtitle","dataName","titleSize","subtitleSize","icon","tag","button","required","titleStyle","subtitleStyle","subtitleSection","createElement","className","container","_extends","titleContainer","_isEmpty","propTypes","process","env","NODE_ENV","string","oneOf","shape","bool"],"sources":["../../../src/atom/title/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {isEmpty} from 'lodash/fp';\nimport Icon from '../icon';\nimport Tag from '../tag';\nimport ButtonLink from '../button-link';\nimport style from './style.css';\n\nconst getTitleStyle = (type, size) => {\n switch (type) {\n case 'page':\n return style.titlePage;\n case 'form-group':\n switch (size) {\n case 'standard':\n return style.titleFormGroup;\n case 'standard-light-weight':\n return style.titleFormGroupLightWeight;\n case 'xl-strong':\n return style.xlStrongTitle;\n case 'medium':\n return style.mediumTitleFormGroup;\n case 'small':\n return style.smallTitleFormGroup;\n case '
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","PropTypes","Icon","Tag","ButtonLink","style","getTitleStyle","type","size","titlePage","titleFormGroup","titleFormGroupLightWeight","xlStrongTitle","mediumTitleFormGroup","mediumAndLightColorTitleFormGroup","smallTitleFormGroup","smallAndLightTitleFormGroup","getSubtitleStyle","subtitlePage","subtitleFormGroup","subtitleFormGroupWithoutMargin","mediumSubtitleFormGroup","smallSubtitleFormGroup","smallSubtitleFormGroupWithoutMargin","extraSmallSubtitleFormGroup","Title","props","title","subtitle","dataName","titleSize","subtitleSize","icon","tag","button","required","titleStyle","subtitleStyle","subtitleSection","createElement","className","container","_extends","titleContainer","_isEmpty","propTypes","process","env","NODE_ENV","string","oneOf","shape","bool"],"sources":["../../../src/atom/title/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {isEmpty} from 'lodash/fp';\nimport Icon from '../icon';\nimport Tag from '../tag';\nimport ButtonLink from '../button-link';\nimport style from './style.css';\n\nconst getTitleStyle = (type, size) => {\n switch (type) {\n case 'page':\n return style.titlePage;\n case 'form-group':\n switch (size) {\n case 'standard':\n return style.titleFormGroup;\n case 'standard-light-weight':\n return style.titleFormGroupLightWeight;\n case 'xl-strong':\n return style.xlStrongTitle;\n case 'medium':\n return style.mediumTitleFormGroup;\n case 'medium-light-color':\n return style.mediumAndLightColorTitleFormGroup;\n case 'small':\n return style.smallTitleFormGroup;\n case 'small-and-light':\n return style.smallAndLightTitleFormGroup;\n }\n }\n};\n\nconst getSubtitleStyle = (type, size) => {\n switch (type) {\n case 'page':\n return style.subtitlePage;\n case 'form-group':\n switch (size) {\n case 'standard':\n return style.subtitleFormGroup;\n case 'standard-without-margin':\n return style.subtitleFormGroupWithoutMargin;\n case 'medium':\n return style.mediumSubtitleFormGroup;\n case 'small':\n return style.smallSubtitleFormGroup;\n case 'small-without-margin':\n return style.smallSubtitleFormGroupWithoutMargin;\n case 'extra-small':\n return style.extraSmallSubtitleFormGroup;\n }\n }\n};\n\nconst Title = props => {\n const {\n title,\n subtitle,\n type,\n 'data-name': dataName,\n titleSize = 'standard',\n subtitleSize = 'standard',\n icon,\n tag,\n button,\n required\n } = props;\n const titleStyle = getTitleStyle(type, titleSize);\n const subtitleStyle = getSubtitleStyle(type, subtitleSize);\n\n const subtitleSection = subtitle ? <div className={subtitleStyle}>{subtitle}</div> : null;\n\n return (\n <div className={style.container}>\n {icon ? <Icon {...icon} className={style.icon} /> : null}\n <div className={style.titleContainer}>\n <div>\n <div className={titleStyle} data-name={dataName}>\n {title}\n {required ? <span className={style.required}>*</span> : null}\n {tag ? <Tag {...tag} /> : null}\n </div>\n {subtitleSection}\n </div>\n {!isEmpty(button) ? <ButtonLink {...button} /> : null}\n </div>\n </div>\n );\n};\n\nTitle.propTypes = {\n title: PropTypes.string,\n subtitle: PropTypes.string,\n type: PropTypes.oneOf(['page', 'form-group']),\n 'data-name': PropTypes.string,\n titleSize: PropTypes.oneOf([\n 'xl-strong',\n 'standard',\n 'standard-light-weight',\n 'medium',\n 'medium-light-color',\n 'small',\n 'small-and-light'\n ]),\n subtitleSize: PropTypes.oneOf([\n 'standard',\n 'standard-without-margin',\n 'medium',\n 'small',\n 'small-without-margin',\n 'extra-small'\n ]),\n icon: PropTypes.shape(Icon.propTypes),\n tag: PropTypes.shape(Tag.propTypes),\n button: PropTypes.shape(ButtonLink.propTypes),\n required: PropTypes.bool\n};\nexport default Title;\n"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,SAAS,MAAM,YAAY;AAElC,OAAOC,IAAI,MAAM,SAAS;AAC1B,OAAOC,GAAG,MAAM,QAAQ;AACxB,OAAOC,UAAU,MAAM,gBAAgB;AACvC,OAAOC,KAAK,MAAM,aAAa;AAE/B,MAAMC,aAAa,GAAGA,CAACC,IAAI,EAAEC,IAAI,KAAK;EACpC,QAAQD,IAAI;IACV,KAAK,MAAM;MACT,OAAOF,KAAK,CAACI,SAAS;IACxB,KAAK,YAAY;MACf,QAAQD,IAAI;QACV,KAAK,UAAU;UACb,OAAOH,KAAK,CAACK,cAAc;QAC7B,KAAK,uBAAuB;UAC1B,OAAOL,KAAK,CAACM,yBAAyB;QACxC,KAAK,WAAW;UACd,OAAON,KAAK,CAACO,aAAa;QAC5B,KAAK,QAAQ;UACX,OAAOP,KAAK,CAACQ,oBAAoB;QACnC,KAAK,oBAAoB;UACvB,OAAOR,KAAK,CAACS,iCAAiC;QAChD,KAAK,OAAO;UACV,OAAOT,KAAK,CAACU,mBAAmB;QAClC,KAAK,iBAAiB;UACpB,OAAOV,KAAK,CAACW,2BAA2B;MAC5C;EACJ;AACF,CAAC;AAED,MAAMC,gBAAgB,GAAGA,CAACV,IAAI,EAAEC,IAAI,KAAK;EACvC,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AACkD,KAAK,CAAC/C,UAAU,CAACyC,SAAS,CAAC;EAC7CV,QAAQ,EAAElC,SAAS,CAACmD;AACtB,CAAC;AACD,eAAe3B,KAAK","ignoreList":[]}
|
package/es/atom/title/style.css
CHANGED
package/es/atom/title/types.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export declare type TitleProps = {
|
|
|
3
3
|
subtitle: string;
|
|
4
4
|
type: 'page' | 'form-group';
|
|
5
5
|
'data-name'?: string;
|
|
6
|
-
titleSize: 'xl-strong' | 'standard' | 'standard-light-weight' | 'medium' | 'small' | '
|
|
6
|
+
titleSize: 'xl-strong' | 'standard' | 'standard-light-weight' | 'medium' | 'medium-light-color' | 'small' | 'small-and-light';
|
|
7
7
|
subtitleSize: 'standard' | 'medium' | 'small-without-margin' | 'small' | 'extra-small';
|
|
8
8
|
required: boolean;
|
|
9
9
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/title/types.ts"],"names":[],"mappings":"AAAA,oBAAY,UAAU,GAAG;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,GAAG,YAAY,CAAC;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,EACL,WAAW,GACX,UAAU,GACV,uBAAuB,GACvB,QAAQ,GACR,OAAO,GACP,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/title/types.ts"],"names":[],"mappings":"AAAA,oBAAY,UAAU,GAAG;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,GAAG,YAAY,CAAC;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,EACL,WAAW,GACX,UAAU,GACV,uBAAuB,GACvB,QAAQ,GACR,oBAAoB,GACpB,OAAO,GACP,iBAAiB,CAAC;IACtB,YAAY,EAAE,UAAU,GAAG,QAAQ,GAAG,sBAAsB,GAAG,OAAO,GAAG,aAAa,CAAC;IACvF,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","names":[],"sources":["../../../src/atom/title/types.ts"],"sourcesContent":["export type TitleProps = {\n title: string;\n subtitle: string;\n type: 'page' | 'form-group';\n 'data-name'?: string;\n titleSize:\n | 'xl-strong'\n | 'standard'\n | 'standard-light-weight'\n | 'medium'\n | 'small'\n | '
|
|
1
|
+
{"version":3,"file":"types.js","names":[],"sources":["../../../src/atom/title/types.ts"],"sourcesContent":["export type TitleProps = {\n title: string;\n subtitle: string;\n type: 'page' | 'form-group';\n 'data-name'?: string;\n titleSize:\n | 'xl-strong'\n | 'standard'\n | 'standard-light-weight'\n | 'medium'\n | 'medium-light-color'\n | 'small'\n | 'small-and-light';\n subtitleSize: 'standard' | 'medium' | 'small-without-margin' | 'small' | 'extra-small';\n required: boolean;\n};\n"],"mappings":"","ignoreList":[]}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { IconPreviewProps } from './types';
|
|
3
|
+
declare const IconPreview: {
|
|
4
|
+
(props: IconPreviewProps): JSX.Element;
|
|
5
|
+
propTypes: {
|
|
6
|
+
title: import("prop-types").Requireable<string>;
|
|
7
|
+
icon: import("prop-types").Validator<NonNullable<import("prop-types").InferProps<{
|
|
8
|
+
name: import("prop-types").Validator<string>;
|
|
9
|
+
color: import("prop-types").Requireable<string>;
|
|
10
|
+
}>>>;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
1
13
|
export default IconPreview;
|
|
2
|
-
declare function IconPreview(props: any): JSX.Element;
|
|
3
|
-
declare namespace IconPreview {
|
|
4
|
-
namespace propTypes {
|
|
5
|
-
const iconName: PropTypes.Validator<string>;
|
|
6
|
-
const iconColor: PropTypes.Requireable<string>;
|
|
7
|
-
const title: PropTypes.Requireable<string>;
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
import PropTypes from "prop-types";
|
|
11
14
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/icon-preview/index.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/molecule/icon-preview/index.tsx"],"names":[],"mappings":";AAGA,OAAkB,EAAC,gBAAgB,EAAC,MAAM,SAAS,CAAC;AAGpD,QAAA,MAAM,WAAW;YAAW,gBAAgB;;;;;;;;CAyB3C,CAAC;AAIF,eAAe,WAAW,CAAC"}
|
|
@@ -1,39 +1,34 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
2
|
import FaIcon from '../../atom/icon';
|
|
4
3
|
import { createGradientBackground } from '../../util/get-background-gradient-color';
|
|
4
|
+
import propTypes from './types';
|
|
5
5
|
import style from './style.css';
|
|
6
6
|
const IconPreview = props => {
|
|
7
7
|
const {
|
|
8
|
-
|
|
9
|
-
iconColor,
|
|
8
|
+
icon,
|
|
10
9
|
title
|
|
11
10
|
} = props;
|
|
12
11
|
return /*#__PURE__*/React.createElement("div", {
|
|
13
12
|
className: style.iconPreviewWrapper,
|
|
14
13
|
style: {
|
|
15
|
-
background: createGradientBackground(
|
|
14
|
+
background: createGradientBackground(icon.color, '93%', '100%')
|
|
16
15
|
}
|
|
17
16
|
}, /*#__PURE__*/React.createElement("div", {
|
|
18
17
|
className: style.iconPreview
|
|
19
18
|
}, /*#__PURE__*/React.createElement("div", {
|
|
20
19
|
className: style.iconWrapper
|
|
21
20
|
}, /*#__PURE__*/React.createElement(FaIcon, {
|
|
22
|
-
iconName:
|
|
23
|
-
iconColor:
|
|
24
|
-
gradientBackground: true,
|
|
21
|
+
iconName: icon.name,
|
|
22
|
+
iconColor: icon.color,
|
|
25
23
|
size: {
|
|
26
24
|
faSize: 36,
|
|
27
25
|
wrapperSize: 80
|
|
28
|
-
}
|
|
26
|
+
},
|
|
27
|
+
gradientBackground: true
|
|
29
28
|
})), /*#__PURE__*/React.createElement("div", {
|
|
30
29
|
className: style.titleWrapper
|
|
31
30
|
}, title)));
|
|
32
31
|
};
|
|
33
|
-
IconPreview.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
34
|
-
iconName: PropTypes.string.isRequired,
|
|
35
|
-
iconColor: PropTypes.string,
|
|
36
|
-
title: PropTypes.string
|
|
37
|
-
} : {};
|
|
32
|
+
IconPreview.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {};
|
|
38
33
|
export default IconPreview;
|
|
39
34
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","FaIcon","createGradientBackground","propTypes","style","IconPreview","props","icon","title","createElement","className","iconPreviewWrapper","background","color","iconPreview","iconWrapper","iconName","name","iconColor","size","faSize","wrapperSize","gradientBackground","titleWrapper","process","env","NODE_ENV"],"sources":["../../../src/molecule/icon-preview/index.tsx"],"sourcesContent":["import React from 'react';\nimport FaIcon from '../../atom/icon';\nimport {createGradientBackground} from '../../util/get-background-gradient-color';\nimport propTypes, {IconPreviewProps} from './types';\nimport style from './style.css';\n\nconst IconPreview = (props: IconPreviewProps) => {\n const {icon, title} = props;\n return (\n <div\n className={style.iconPreviewWrapper}\n style={{background: createGradientBackground(icon.color, '93%', '100%')}}\n >\n <div className={style.iconPreview}>\n <div className={style.iconWrapper}>\n <FaIcon\n {...{\n iconName: icon.name,\n iconColor: icon.color,\n size: {\n faSize: 36,\n wrapperSize: 80\n },\n gradientBackground: true\n }}\n />\n </div>\n <div className={style.titleWrapper}>{title}</div>\n </div>\n </div>\n );\n};\n\nIconPreview.propTypes = propTypes;\n\nexport default IconPreview;\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,MAAM,MAAM,iBAAiB;AACpC,SAAQC,wBAAwB,QAAO,0CAA0C;AACjF,OAAOC,SAAS,MAA0B,SAAS;AACnD,OAAOC,KAAK,MAAM,aAAa;AAE/B,MAAMC,WAAW,GAAIC,KAAuB,IAAK;EAC/C,MAAM;IAACC,IAAI;IAAEC;EAAK,CAAC,GAAGF,KAAK;EAC3B,oBACEN,KAAA,CAAAS,aAAA;IACEC,SAAS,EAAEN,KAAK,CAACO,kBAAmB;IACpCP,KAAK,EAAE;MAACQ,UAAU,EAAEV,wBAAwB,CAACK,IAAI,CAACM,KAAK,EAAE,KAAK,EAAE,MAAM;IAAC;EAAE,gBAEzEb,KAAA,CAAAS,aAAA;IAAKC,SAAS,EAAEN,KAAK,CAACU;EAAY,gBAChCd,KAAA,CAAAS,aAAA;IAAKC,SAAS,EAAEN,KAAK,CAACW;EAAY,gBAChCf,KAAA,CAAAS,aAAA,CAACR,MAAM;IAEHe,QAAQ,EAAET,IAAI,CAACU,IAAI;IACnBC,SAAS,EAAEX,IAAI,CAACM,KAAK;IACrBM,IAAI,EAAE;MACJC,MAAM,EAAE,EAAE;MACVC,WAAW,EAAE;IACf,CAAC;IACDC,kBAAkB,EAAE;EAAI,CAE3B,CACE,CAAC,eACNtB,KAAA,CAAAS,aAAA;IAAKC,SAAS,EAAEN,KAAK,CAACmB;EAAa,GAAEf,KAAW,CAC7C,CACF,CAAC;AAEV,CAAC;AAEDH,WAAW,CAACF,SAAS,GAAAqB,OAAA,CAAAC,GAAA,CAAAC,QAAA,oBAAGvB,SAAS;AAEjC,eAAeE,WAAW","ignoreList":[]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import PropTypes from 'prop-types';
|
|
2
|
+
declare const IconPreviewPropTypes: {
|
|
3
|
+
title: PropTypes.Requireable<string>;
|
|
4
|
+
icon: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
|
|
5
|
+
name: PropTypes.Validator<string>;
|
|
6
|
+
color: PropTypes.Requireable<string>;
|
|
7
|
+
}>>>;
|
|
8
|
+
};
|
|
9
|
+
export default IconPreviewPropTypes;
|
|
10
|
+
declare type IconProps = {
|
|
11
|
+
name: string;
|
|
12
|
+
color?: string;
|
|
13
|
+
};
|
|
14
|
+
export declare type IconPreviewProps = {
|
|
15
|
+
title?: string;
|
|
16
|
+
icon: IconProps;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/molecule/icon-preview/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAOnC,QAAA,MAAM,oBAAoB;;;;;;CAGzB,CAAC;AAEF,eAAe,oBAAoB,CAAC;AAEpC,aAAK,SAAS,GAAG;IACf,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,oBAAY,gBAAgB,GAAG;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,SAAS,CAAC;CACjB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import PropTypes from 'prop-types';
|
|
2
|
+
const IconPropTypes = {
|
|
3
|
+
name: PropTypes.string.isRequired,
|
|
4
|
+
color: PropTypes.string
|
|
5
|
+
};
|
|
6
|
+
const IconPreviewPropTypes = {
|
|
7
|
+
title: PropTypes.string,
|
|
8
|
+
icon: PropTypes.shape(IconPropTypes).isRequired
|
|
9
|
+
};
|
|
10
|
+
export default IconPreviewPropTypes;
|
|
11
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","names":["PropTypes","IconPropTypes","name","string","isRequired","color","IconPreviewPropTypes","title","icon","shape"],"sources":["../../../src/molecule/icon-preview/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\n\nconst IconPropTypes = {\n name: PropTypes.string.isRequired,\n color: PropTypes.string\n};\n\nconst IconPreviewPropTypes = {\n title: PropTypes.string,\n icon: PropTypes.shape(IconPropTypes).isRequired\n};\n\nexport default IconPreviewPropTypes;\n\ntype IconProps = {\n name: string;\n color?: string;\n};\n\nexport type IconPreviewProps = {\n title?: string;\n icon: IconProps;\n};\n"],"mappings":"AAAA,OAAOA,SAAS,MAAM,YAAY;AAElC,MAAMC,aAAa,GAAG;EACpBC,IAAI,EAAEF,SAAS,CAACG,MAAM,CAACC,UAAU;EACjCC,KAAK,EAAEL,SAAS,CAACG;AACnB,CAAC;AAED,MAAMG,oBAAoB,GAAG;EAC3BC,KAAK,EAAEP,SAAS,CAACG,MAAM;EACvBK,IAAI,EAAER,SAAS,CAACS,KAAK,CAACR,aAAa,CAAC,CAACG;AACvC,CAAC;AAED,eAAeE,oBAAoB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/header-with-actions/index.tsx"],"names":[],"mappings":";AAQA,OAAmC,EAAC,sBAAsB,EAAC,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/header-with-actions/index.tsx"],"names":[],"mappings":";AAQA,OAAmC,EAAC,sBAAsB,EAAC,MAAM,SAAS,CAAC;AAO3E,QAAA,MAAM,iBAAiB;YAAW,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgCvD,CAAC;AAIF,eAAe,iBAAiB,CAAC"}
|
|
@@ -9,6 +9,10 @@ import BulletPointMenuButton from '../../molecule/bullet-point-menu-button';
|
|
|
9
9
|
import headerWithActionsPropTypes from './types';
|
|
10
10
|
import style from './style.css';
|
|
11
11
|
const getDataName = suffix => `header-with-actions-${suffix}`;
|
|
12
|
+
// @ts-expect-error (need to get the index)
|
|
13
|
+
const uncappedMap = map.convert({
|
|
14
|
+
cap: false
|
|
15
|
+
});
|
|
12
16
|
const HeaderWithActions = props => {
|
|
13
17
|
const {
|
|
14
18
|
closeButton,
|
|
@@ -41,7 +45,11 @@ const HeaderWithActions = props => {
|
|
|
41
45
|
"data-name": getDataName('buttons-wrapper')
|
|
42
46
|
}, bulletPointMenuButton && !isEmpty(bulletPointMenuButton.buttons) ? /*#__PURE__*/React.createElement(BulletPointMenuButton, _extends({}, bulletPointMenuButton, {
|
|
43
47
|
buttonAriaLabel: "More actions"
|
|
44
|
-
})) : null,
|
|
48
|
+
})) : null, uncappedMap((action, key) => {
|
|
49
|
+
return /*#__PURE__*/React.createElement(ButtonLink, _extends({}, action, {
|
|
50
|
+
key: key
|
|
51
|
+
}));
|
|
52
|
+
}, actionButtons)));
|
|
45
53
|
};
|
|
46
54
|
HeaderWithActions.propTypes = process.env.NODE_ENV !== "production" ? headerWithActionsPropTypes : {};
|
|
47
55
|
export default HeaderWithActions;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","isEmpty","map","ButtonLink","ButtonLinkIcon","Tag","BulletPointMenuButton","headerWithActionsPropTypes","style","getDataName","suffix","HeaderWithActions","props","closeButton","title","tag","saveStatus","bulletPointMenuButton","actionButtons","createElement","className","headerWrapper","titleAndButtonWrapper","_extends","button","titleWrapper","statusWrapper","display","label","buttonsWrapper","buttons","buttonAriaLabel","action","propTypes","process","env","NODE_ENV"],"sources":["../../../src/organism/header-with-actions/index.tsx"],"sourcesContent":["import React from 'react';\nimport isEmpty from 'lodash/fp/isEmpty';\nimport map from 'lodash/fp/map';\nimport ButtonLink from '../../atom/button-link';\nimport ButtonLinkIcon from '../../atom/button-link-icon';\nimport Tag from '../../atom/tag';\nimport {ButtonLinkProps} from '../../atom/button-link/types';\nimport BulletPointMenuButton from '../../molecule/bullet-point-menu-button';\nimport headerWithActionsPropTypes, {HeaderWithActionsProps} from './types';\nimport style from './style.css';\n\nconst getDataName = (suffix: string) => `header-with-actions-${suffix}`;\n\nconst HeaderWithActions = (props: HeaderWithActionsProps) => {\n const {closeButton, title, tag, saveStatus, bulletPointMenuButton, actionButtons} = props;\n\n return (\n <div className={style.headerWrapper} data-name={getDataName('wrapper')}>\n <div\n className={style.titleAndButtonWrapper}\n data-name={getDataName('title-and-button-wrapper')}\n >\n <ButtonLinkIcon {...closeButton} className={style.button} />\n <div className={style.titleWrapper}>\n <div className={style.statusWrapper}>\n <Tag {...tag} />\n {saveStatus.display && saveStatus.label ? (\n <p className={style.saveStatus}>{saveStatus.label}</p>\n ) : null}\n </div>\n <h3 className={style.title} aria-label={title} data-name={getDataName('title')}>\n {title}\n </h3>\n </div>\n </div>\n <div className={style.buttonsWrapper} data-name={getDataName('buttons-wrapper')}>\n {bulletPointMenuButton && !isEmpty(bulletPointMenuButton.buttons) ? (\n <BulletPointMenuButton {...bulletPointMenuButton} buttonAriaLabel=\"More actions\" />\n ) : null}\n {
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","isEmpty","map","ButtonLink","ButtonLinkIcon","Tag","BulletPointMenuButton","headerWithActionsPropTypes","style","getDataName","suffix","uncappedMap","convert","cap","HeaderWithActions","props","closeButton","title","tag","saveStatus","bulletPointMenuButton","actionButtons","createElement","className","headerWrapper","titleAndButtonWrapper","_extends","button","titleWrapper","statusWrapper","display","label","buttonsWrapper","buttons","buttonAriaLabel","action","key","propTypes","process","env","NODE_ENV"],"sources":["../../../src/organism/header-with-actions/index.tsx"],"sourcesContent":["import React from 'react';\nimport isEmpty from 'lodash/fp/isEmpty';\nimport map from 'lodash/fp/map';\nimport ButtonLink from '../../atom/button-link';\nimport ButtonLinkIcon from '../../atom/button-link-icon';\nimport Tag from '../../atom/tag';\nimport {ButtonLinkProps} from '../../atom/button-link/types';\nimport BulletPointMenuButton from '../../molecule/bullet-point-menu-button';\nimport headerWithActionsPropTypes, {HeaderWithActionsProps} from './types';\nimport style from './style.css';\n\nconst getDataName = (suffix: string) => `header-with-actions-${suffix}`;\n// @ts-expect-error (need to get the index)\nconst uncappedMap = map.convert({cap: false});\n\nconst HeaderWithActions = (props: HeaderWithActionsProps) => {\n const {closeButton, title, tag, saveStatus, bulletPointMenuButton, actionButtons} = props;\n\n return (\n <div className={style.headerWrapper} data-name={getDataName('wrapper')}>\n <div\n className={style.titleAndButtonWrapper}\n data-name={getDataName('title-and-button-wrapper')}\n >\n <ButtonLinkIcon {...closeButton} className={style.button} />\n <div className={style.titleWrapper}>\n <div className={style.statusWrapper}>\n <Tag {...tag} />\n {saveStatus.display && saveStatus.label ? (\n <p className={style.saveStatus}>{saveStatus.label}</p>\n ) : null}\n </div>\n <h3 className={style.title} aria-label={title} data-name={getDataName('title')}>\n {title}\n </h3>\n </div>\n </div>\n <div className={style.buttonsWrapper} data-name={getDataName('buttons-wrapper')}>\n {bulletPointMenuButton && !isEmpty(bulletPointMenuButton.buttons) ? (\n <BulletPointMenuButton {...bulletPointMenuButton} buttonAriaLabel=\"More actions\" />\n ) : null}\n {uncappedMap((action: ButtonLinkProps, key: string) => {\n return <ButtonLink {...action} key={key} />;\n }, actionButtons)}\n </div>\n </div>\n );\n};\n\nHeaderWithActions.propTypes = headerWithActionsPropTypes;\n\nexport default HeaderWithActions;\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,OAAO,MAAM,mBAAmB;AACvC,OAAOC,GAAG,MAAM,eAAe;AAC/B,OAAOC,UAAU,MAAM,wBAAwB;AAC/C,OAAOC,cAAc,MAAM,6BAA6B;AACxD,OAAOC,GAAG,MAAM,gBAAgB;AAEhC,OAAOC,qBAAqB,MAAM,yCAAyC;AAC3E,OAAOC,0BAA0B,MAAgC,SAAS;AAC1E,OAAOC,KAAK,MAAM,aAAa;AAE/B,MAAMC,WAAW,GAAIC,MAAc,IAAK,uBAAuBA,MAAM,EAAE;AACvE;AACA,MAAMC,WAAW,GAAGT,GAAG,CAACU,OAAO,CAAC;EAACC,GAAG,EAAE;AAAK,CAAC,CAAC;AAE7C,MAAMC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,EAAAoB,QAAA,KAAKN,qBAAqB;IAAEc,eAAe,EAAC;EAAc,EAAE,CAAC,GACjF,IAAI,EACPvB,WAAW,CAAC,CAACwB,MAAuB,EAAEC,GAAW,KAAK;IACrD,oBAAOpC,KAAA,CAAAsB,aAAA,CAACnB,UAAU,EAAAuB,QAAA,KAAKS,MAAM;MAAEC,GAAG,EAAEA;IAAI,EAAE,CAAC;EAC7C,CAAC,EAAEf,aAAa,CACb,CACF,CAAC;AAEV,CAAC;AAEDP,iBAAiB,CAACuB,SAAS,GAAAC,OAAA,CAAAC,GAAA,CAAAC,QAAA,oBAAGjC,0BAA0B;AAExD,eAAeO,iBAAiB","ignoreList":[]}
|
|
@@ -1,26 +1,76 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { WebContextValues } from '../../atom/provider/web-context';
|
|
3
|
+
import { IconEditorProps } from './types';
|
|
4
|
+
declare const IconEditor: {
|
|
5
|
+
(props: IconEditorProps, legacyContext: WebContextValues): JSX.Element;
|
|
6
|
+
contextTypes: {
|
|
7
|
+
translate: import("prop-types").Requireable<(...args: any[]) => any>;
|
|
8
|
+
};
|
|
9
|
+
propTypes: {
|
|
10
|
+
iconPreview: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
11
|
+
title: import("prop-types").Requireable<string>;
|
|
12
|
+
icon: import("prop-types").Validator<NonNullable<import("prop-types").InferProps<{
|
|
13
|
+
name: import("prop-types").Validator<string>;
|
|
14
|
+
color: import("prop-types").Requireable<string>;
|
|
15
|
+
}>>>;
|
|
16
|
+
}>>;
|
|
17
|
+
inputText: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
18
|
+
autoFocus: import("prop-types").Requireable<boolean>;
|
|
19
|
+
title: import("prop-types").Requireable<string>;
|
|
20
|
+
placeholder: import("prop-types").Requireable<string>;
|
|
21
|
+
defaultValue: import("prop-types").Requireable<string>;
|
|
22
|
+
theme: import("prop-types").Requireable<string>;
|
|
23
|
+
disabled: import("prop-types").Requireable<boolean>;
|
|
24
|
+
value: import("prop-types").Requireable<string>;
|
|
25
|
+
hint: import("prop-types").Requireable<string>;
|
|
26
|
+
error: import("prop-types").Requireable<string>;
|
|
27
|
+
onChange: import("prop-types").Requireable<(...args: any[]) => any>;
|
|
28
|
+
description: import("prop-types").Requireable<string>;
|
|
29
|
+
modified: import("prop-types").Requireable<boolean>;
|
|
30
|
+
type: import("prop-types").Requireable<string>;
|
|
31
|
+
valid: import("prop-types").Requireable<boolean>;
|
|
32
|
+
'aria-label': import("prop-types").Requireable<string>;
|
|
33
|
+
'data-name': import("prop-types").Requireable<string>;
|
|
34
|
+
inputColor: import("prop-types").Requireable<boolean>;
|
|
35
|
+
}>>;
|
|
36
|
+
buttonLink: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
37
|
+
type: import("prop-types").Requireable<string>;
|
|
38
|
+
usage: import("prop-types").Requireable<string>;
|
|
39
|
+
label: import("prop-types").Requireable<string>;
|
|
40
|
+
content: import("prop-types").Requireable<import("prop-types").ReactNodeLike>;
|
|
41
|
+
'aria-label': import("prop-types").Requireable<string>;
|
|
42
|
+
tooltipText: import("prop-types").Requireable<string>;
|
|
43
|
+
tooltipPlacement: import("prop-types").Requireable<string>;
|
|
44
|
+
'data-name': import("prop-types").Requireable<string>;
|
|
45
|
+
'data-testid': import("prop-types").Requireable<string>;
|
|
46
|
+
icon: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
47
|
+
position: import("prop-types").Requireable<string>;
|
|
48
|
+
type: import("prop-types").Requireable<string>;
|
|
49
|
+
faIcon: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
50
|
+
name: import("prop-types").Validator<string>;
|
|
51
|
+
color: import("prop-types").Requireable<string>;
|
|
52
|
+
backgroundColor: import("prop-types").Requireable<string>;
|
|
53
|
+
size: import("prop-types").Requireable<number>;
|
|
54
|
+
customStyle: import("prop-types").Requireable<{
|
|
55
|
+
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
56
|
+
}>;
|
|
57
|
+
}>>;
|
|
20
58
|
}>>;
|
|
21
|
-
onClick:
|
|
59
|
+
onClick: import("prop-types").Requireable<(...args: any[]) => any>;
|
|
60
|
+
link: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
61
|
+
href: import("prop-types").Requireable<string>;
|
|
62
|
+
download: import("prop-types").Requireable<boolean>;
|
|
63
|
+
target: import("prop-types").Requireable<string>;
|
|
64
|
+
}>>;
|
|
65
|
+
hoverBackgroundColor: import("prop-types").Requireable<string>;
|
|
66
|
+
hoverColor: import("prop-types").Requireable<string>;
|
|
67
|
+
disabled: import("prop-types").Requireable<boolean>;
|
|
68
|
+
className: import("prop-types").Requireable<string>;
|
|
69
|
+
customStyle: import("prop-types").Requireable<{
|
|
70
|
+
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
71
|
+
}>;
|
|
22
72
|
}>>;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
export default IconEditor;
|
|
26
76
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/icon-editor/index.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/icon-editor/index.tsx"],"names":[],"mappings":";AAMA,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,iCAAiC,CAAC;AAGtE,OAAkB,EAAC,eAAe,EAAC,MAAM,SAAS,CAAC;AAEnD,QAAA,MAAM,UAAU;YAAW,eAAe,iBAAiB,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8B1E,CAAC;AAQF,eAAe,UAAU,CAAC"}
|
|
@@ -1,62 +1,49 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
2
|
import IconPreview from '../../molecule/icon-preview';
|
|
4
3
|
import InputText from '../../atom/input-text';
|
|
5
4
|
import ButtonLink from '../../atom/button-link';
|
|
6
|
-
import Provider from '../../atom/provider';
|
|
5
|
+
import Provider, { GetTranslateFromContext } from '../../atom/provider';
|
|
7
6
|
import { validateColor } from '../../util/validate-color';
|
|
7
|
+
import { COLORS } from '../../variables/colors';
|
|
8
8
|
import style from './style.css';
|
|
9
|
-
|
|
9
|
+
import propTypes from './types';
|
|
10
|
+
const IconEditor = (props, legacyContext) => {
|
|
11
|
+
const translate = GetTranslateFromContext(legacyContext);
|
|
10
12
|
const {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
buttonLink,
|
|
15
|
-
handleChange
|
|
13
|
+
iconPreview,
|
|
14
|
+
inputText,
|
|
15
|
+
buttonLink
|
|
16
16
|
} = props;
|
|
17
17
|
const {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
title,
|
|
19
|
+
icon
|
|
20
|
+
} = iconPreview;
|
|
21
|
+
const isValidColor = validateColor(icon.color);
|
|
21
22
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(IconPreview, {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
23
|
+
icon: {
|
|
24
|
+
...icon,
|
|
25
|
+
color: isValidColor ? icon.color : COLORS.white
|
|
26
|
+
},
|
|
27
|
+
title: title
|
|
25
28
|
}), /*#__PURE__*/React.createElement("div", {
|
|
26
29
|
className: style.inputButtonContainer
|
|
27
30
|
}, /*#__PURE__*/React.createElement(InputText, {
|
|
28
31
|
type: "text",
|
|
29
32
|
title: translate('icon_editor_color'),
|
|
30
|
-
placeholder:
|
|
33
|
+
placeholder: COLORS.white,
|
|
31
34
|
theme: "coorpmanager",
|
|
32
35
|
description: translate('icon_editor_color'),
|
|
33
|
-
value:
|
|
34
|
-
error:
|
|
36
|
+
value: icon.color,
|
|
37
|
+
error: icon.color && !isValidColor ? translate('invalid_color') : undefined,
|
|
35
38
|
disabled: false,
|
|
36
39
|
valid: false,
|
|
37
|
-
onChange: handleChange,
|
|
40
|
+
onChange: inputText.handleChange,
|
|
38
41
|
inputColor: true
|
|
39
42
|
}), /*#__PURE__*/React.createElement(ButtonLink, buttonLink)));
|
|
40
43
|
};
|
|
41
44
|
IconEditor.contextTypes = {
|
|
42
45
|
translate: Provider.childContextTypes.translate
|
|
43
46
|
};
|
|
44
|
-
IconEditor.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
45
|
-
iconName: PropTypes.string.isRequired,
|
|
46
|
-
iconColor: PropTypes.string,
|
|
47
|
-
title: PropTypes.string,
|
|
48
|
-
handleChange: PropTypes.func.isRequired,
|
|
49
|
-
buttonLink: PropTypes.shape({
|
|
50
|
-
type: PropTypes.string,
|
|
51
|
-
label: PropTypes.string,
|
|
52
|
-
ariaLabel: PropTypes.string,
|
|
53
|
-
dataName: PropTypes.string,
|
|
54
|
-
icon: PropTypes.shape({
|
|
55
|
-
position: PropTypes.string,
|
|
56
|
-
type: PropTypes.string
|
|
57
|
-
}),
|
|
58
|
-
onClick: PropTypes.func
|
|
59
|
-
})
|
|
60
|
-
} : {};
|
|
47
|
+
IconEditor.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {};
|
|
61
48
|
export default IconEditor;
|
|
62
49
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","IconPreview","InputText","ButtonLink","Provider","GetTranslateFromContext","validateColor","COLORS","style","propTypes","IconEditor","props","legacyContext","translate","iconPreview","inputText","buttonLink","title","icon","isValidColor","color","createElement","Fragment","white","className","inputButtonContainer","type","placeholder","theme","description","value","error","undefined","disabled","valid","onChange","handleChange","inputColor","contextTypes","childContextTypes","process","env","NODE_ENV"],"sources":["../../../src/organism/icon-editor/index.tsx"],"sourcesContent":["import React from 'react';\nimport IconPreview from '../../molecule/icon-preview';\nimport InputText from '../../atom/input-text';\nimport ButtonLink from '../../atom/button-link';\nimport Provider, {GetTranslateFromContext} from '../../atom/provider';\nimport {validateColor} from '../../util/validate-color';\nimport type {WebContextValues} from '../../atom/provider/web-context';\nimport {COLORS} from '../../variables/colors';\nimport style from './style.css';\nimport propTypes, {IconEditorProps} from './types';\n\nconst IconEditor = (props: IconEditorProps, legacyContext: WebContextValues) => {\n const translate = GetTranslateFromContext(legacyContext);\n const {iconPreview, inputText, buttonLink} = props;\n const {title, icon} = iconPreview;\n\n const isValidColor = validateColor(icon.color);\n return (\n <>\n <IconPreview\n icon={{...icon, color: isValidColor ? icon.color : COLORS.white}}\n title={title}\n />\n <div className={style.inputButtonContainer}>\n <InputText\n type=\"text\"\n title={translate('icon_editor_color')}\n placeholder={COLORS.white}\n theme=\"coorpmanager\"\n description={translate('icon_editor_color')}\n value={icon.color}\n error={icon.color && !isValidColor ? translate('invalid_color') : undefined}\n disabled={false}\n valid={false}\n onChange={inputText.handleChange}\n inputColor\n />\n <ButtonLink {...buttonLink} />\n </div>\n </>\n );\n};\n\nIconEditor.contextTypes = {\n translate: Provider.childContextTypes.translate\n};\n\nIconEditor.propTypes = propTypes;\n\nexport default IconEditor;\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,WAAW,MAAM,6BAA6B;AACrD,OAAOC,SAAS,MAAM,uBAAuB;AAC7C,OAAOC,UAAU,MAAM,wBAAwB;AAC/C,OAAOC,QAAQ,IAAGC,uBAAuB,QAAO,qBAAqB;AACrE,SAAQC,aAAa,QAAO,2BAA2B;AAEvD,SAAQC,MAAM,Q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