@coorpacademy/components 11.34.4-alpha.3 → 11.34.4
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/organism/icon-editor/index.d.ts.map +1 -1
- package/es/organism/icon-editor/index.js +6 -13
- package/es/organism/icon-editor/index.js.map +1 -1
- package/es/organism/skill-edition/index.d.ts +1383 -1065
- package/es/organism/skill-edition/index.d.ts.map +1 -1
- package/es/organism/skill-edition/index.js +5 -115
- package/es/organism/skill-edition/index.js.map +1 -1
- package/es/organism/skill-edition/types.d.ts +371 -87
- package/es/organism/skill-edition/types.d.ts.map +1 -1
- package/es/organism/skill-edition/types.js +4 -39
- package/es/organism/skill-edition/types.js.map +1 -1
- package/es/template/back-office/brand-update/index.d.ts +366 -47
- package/lib/organism/icon-editor/index.d.ts.map +1 -1
- package/lib/organism/icon-editor/index.js +6 -13
- package/lib/organism/icon-editor/index.js.map +1 -1
- package/lib/organism/skill-edition/index.d.ts +1383 -1065
- package/lib/organism/skill-edition/index.d.ts.map +1 -1
- package/lib/organism/skill-edition/index.js +5 -115
- package/lib/organism/skill-edition/index.js.map +1 -1
- package/lib/organism/skill-edition/types.d.ts +371 -87
- package/lib/organism/skill-edition/types.d.ts.map +1 -1
- package/lib/organism/skill-edition/types.js +4 -39
- package/lib/organism/skill-edition/types.js.map +1 -1
- package/lib/template/back-office/brand-update/index.d.ts +366 -47
- package/locales/de/global.json +2 -2
- package/package.json +2 -2
- package/locales/.mtslconfig.json +0 -1
|
@@ -1 +1 @@
|
|
|
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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
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"}
|
|
@@ -18,18 +18,11 @@ const IconEditor = (props, legacyContext) => {
|
|
|
18
18
|
title,
|
|
19
19
|
icon
|
|
20
20
|
} = iconPreview;
|
|
21
|
-
const
|
|
22
|
-
value,
|
|
23
|
-
description,
|
|
24
|
-
handleChange
|
|
25
|
-
} = inputText;
|
|
26
|
-
const isValidColor = validateColor(inputText.value);
|
|
27
|
-
const previewColor = isValidColor ? value : COLORS.white;
|
|
28
|
-
const inputError = value && (!isValidColor ? translate('invalid_color') : undefined);
|
|
21
|
+
const isValidColor = validateColor(icon.color);
|
|
29
22
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(IconPreview, {
|
|
30
23
|
icon: {
|
|
31
24
|
...icon,
|
|
32
|
-
color:
|
|
25
|
+
color: isValidColor ? icon.color : COLORS.white
|
|
33
26
|
},
|
|
34
27
|
title: title
|
|
35
28
|
}), /*#__PURE__*/React.createElement("div", {
|
|
@@ -39,12 +32,12 @@ const IconEditor = (props, legacyContext) => {
|
|
|
39
32
|
title: translate('icon_editor_color'),
|
|
40
33
|
placeholder: COLORS.white,
|
|
41
34
|
theme: "coorpmanager",
|
|
42
|
-
description:
|
|
43
|
-
value:
|
|
44
|
-
error:
|
|
35
|
+
description: translate('icon_editor_color'),
|
|
36
|
+
value: icon.color,
|
|
37
|
+
error: icon.color && !isValidColor ? translate('invalid_color') : undefined,
|
|
45
38
|
disabled: false,
|
|
46
39
|
valid: false,
|
|
47
|
-
onChange: handleChange,
|
|
40
|
+
onChange: inputText.handleChange,
|
|
48
41
|
inputColor: true
|
|
49
42
|
}), /*#__PURE__*/React.createElement(ButtonLink, buttonLink)));
|
|
50
43
|
};
|
|
@@ -1 +1 @@
|
|
|
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","
|
|
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,QAAO,wBAAwB;AAC7C,OAAOC,KAAK,MAAM,aAAa;AAC/B,OAAOC,SAAS,MAAyB,SAAS;AAElD,MAAMC,UAAU,GAAGA,CAACC,KAAsB,EAAEC,aAA+B,KAAK;EAC9E,MAAMC,SAAS,GAAGR,uBAAuB,CAACO,aAAa,CAAC;EACxD,MAAM;IAACE,WAAW;IAAEC,SAAS;IAAEC;EAAU,CAAC,GAAGL,KAAK;EAClD,MAAM;IAACM,KAAK;IAAEC;EAAI,CAAC,GAAGJ,WAAW;EAEjC,MAAMK,YAAY,GAAGb,aAAa,CAACY,IAAI,CAACE,KAAK,CAAC;EAC9C,oBACEpB,KAAA,CAAAqB,aAAA,CAAArB,KAAA,CAAAsB,QAAA,qBACEtB,KAAA,CAAAqB,aAAA,CAACpB,WAAW;IACViB,IAAI,EAAE;MAAC,GAAGA,IAAI;MAAEE,KAAK,EAAED,YAAY,GAAGD,IAAI,CAACE,KAAK,GAAGb,MAAM,CAACgB;IAAK,CAAE;IACjEN,KAAK,EAAEA;EAAM,CACd,CAAC,eACFjB,KAAA,CAAAqB,aAAA;IAAKG,SAAS,EAAEhB,KAAK,CAACiB;EAAqB,gBACzCz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