@coorpacademy/components 11.35.2-forcedeploy.13 → 11.35.2
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/button-link/index.js +1 -1
- package/es/atom/button-link/index.js.map +1 -1
- package/es/atom/button-link/style.css +2 -2
- package/es/atom/icon/index.d.ts +17 -35
- package/es/atom/icon/index.d.ts.map +1 -1
- package/es/atom/icon/index.js +15 -32
- package/es/atom/icon/index.js.map +1 -1
- package/es/atom/radio-with-title/index.d.ts +3 -13
- package/es/atom/radio-with-title/index.d.ts.map +1 -1
- package/es/atom/radio-with-title/types.d.ts +2 -13
- package/es/atom/radio-with-title/types.d.ts.map +1 -1
- package/es/atom/status-item/index.native.js +1 -1
- package/es/atom/status-item/index.native.js.map +1 -1
- package/es/atom/tag/index.d.ts +1 -12
- package/es/atom/tag/style.css +0 -1
- package/es/atom/title/index.d.ts +2 -13
- package/es/molecule/banner/style.css +0 -1
- package/es/molecule/base-modal/style.css +1 -0
- package/es/molecule/bulk-progress-bar/index.js +2 -2
- package/es/molecule/bulk-progress-bar/index.js.map +1 -1
- package/es/molecule/certification-card/index.js +1 -1
- package/es/molecule/certification-card/index.js.map +1 -1
- package/es/molecule/cm-popin/types.d.ts +7 -28
- package/es/molecule/cm-popin/types.d.ts.map +1 -1
- package/es/molecule/cm-popin/types.js +1 -1
- package/es/molecule/cm-popin/types.js.map +1 -1
- package/es/molecule/dashboard/cards-list/index.d.ts.map +1 -1
- package/es/molecule/dashboard/cards-list/index.js +0 -2
- package/es/molecule/dashboard/cards-list/index.js.map +1 -1
- package/es/molecule/learner-skill-card/index.js +8 -10
- package/es/molecule/learner-skill-card/index.js.map +1 -1
- package/es/molecule/learner-skill-card/style.css +0 -1
- package/es/molecule/learning-priority-modal/style.css +2 -3
- package/es/molecule/progress-wrapper/index.js +1 -1
- package/es/molecule/progress-wrapper/index.js.map +1 -1
- package/es/molecule/skills-chart-side-information-item/index.d.ts +1 -1
- package/es/molecule/skills-chart-side-information-panel/index.d.ts +1 -1
- package/es/molecule/title-and-checkbox-wrapper/index.d.ts +2 -13
- package/es/molecule/title-radio-wrapper/index.d.ts +3 -13
- package/es/molecule/title-radio-wrapper/index.d.ts.map +1 -1
- package/es/molecule/title-radio-wrapper/types.d.ts +2 -13
- package/es/molecule/title-radio-wrapper/types.d.ts.map +1 -1
- package/es/molecule/translation-modal/index.d.ts +1 -0
- package/es/molecule/translation-modal/index.d.ts.map +1 -1
- package/es/molecule/translation-modal/index.js +7 -24
- package/es/molecule/translation-modal/index.js.map +1 -1
- package/es/organism/cards-grid/index.d.ts +10 -48
- package/es/organism/cards-grid/index.d.ts.map +1 -1
- package/es/organism/cards-grid/index.js +2 -3
- package/es/organism/cards-grid/index.js.map +1 -1
- package/es/organism/content-skill-modal/index.d.ts +3 -13
- package/es/organism/content-skill-modal/index.d.ts.map +1 -1
- package/es/organism/content-skill-modal/types.d.ts +2 -12
- package/es/organism/content-skill-modal/types.d.ts.map +1 -1
- package/es/organism/list-item/index.js +5 -5
- package/es/organism/list-item/index.js.map +1 -1
- package/es/organism/list-item/style.css +17 -23
- package/es/organism/list-items/index.d.ts +2 -13
- package/es/organism/list-items/style.css +0 -1
- package/es/organism/rewards-form/index.d.ts +2 -13
- package/es/organism/select-opponents/index.d.ts +3 -13
- package/es/organism/select-opponents/index.d.ts.map +1 -1
- package/es/organism/select-opponents/types.d.ts +2 -13
- package/es/organism/select-opponents/types.d.ts.map +1 -1
- package/es/organism/sidebar/index.d.ts +2 -2
- package/es/organism/skill-edition/index.d.ts +52 -1261
- package/es/organism/skill-edition/index.d.ts.map +1 -1
- package/es/organism/skill-edition/index.js +224 -3
- package/es/organism/skill-edition/index.js.map +1 -1
- package/es/organism/skill-edition/types.d.ts +117 -1268
- package/es/organism/skill-edition/types.d.ts.map +1 -1
- package/es/organism/skill-edition/types.js +59 -7
- package/es/organism/skill-edition/types.js.map +1 -1
- package/es/organism/title-and-input/index.d.ts +5 -25
- package/es/organism/title-and-input/index.d.ts.map +1 -1
- package/es/organism/title-and-input/types.d.ts +4 -24
- package/es/organism/title-and-input/types.d.ts.map +1 -1
- package/es/organism/wizard-contents/index.d.ts +2 -13
- package/es/template/app-player/loading/index.d.ts +6 -27
- package/es/template/app-player/player/index.d.ts +12 -53
- package/es/template/app-player/player/slides/index.d.ts +6 -27
- package/es/template/app-player/player/slides/index.d.ts.map +1 -1
- package/es/template/app-player/popin-correction/index.d.ts +6 -26
- package/es/template/app-player/popin-correction/index.d.ts.map +1 -1
- package/es/template/app-player/popin-end/index.d.ts +6 -27
- package/es/template/app-review/index.d.ts +7 -27
- package/es/template/app-review/index.d.ts.map +1 -1
- package/es/template/app-review/player/prop-types.d.ts +6 -27
- package/es/template/app-review/player/prop-types.d.ts.map +1 -1
- package/es/template/app-review/prop-types.d.ts +6 -27
- package/es/template/app-review/prop-types.d.ts.map +1 -1
- package/es/template/back-office/brand-update/index.d.ts +1113 -1713
- package/es/template/back-office/brand-update/index.d.ts.map +1 -1
- package/es/template/back-office/brand-update/index.js +12 -0
- package/es/template/back-office/brand-update/index.js.map +1 -1
- package/es/template/back-office/brand-update/utils.d.ts +1 -1
- package/es/template/common/dashboard/index.d.ts +12 -53
- package/es/template/common/search-page/index.d.ts +6 -27
- package/es/template/external-course/index.d.ts +6 -27
- package/es/template/skill-detail/all-courses.css +2 -3
- package/es/template/skill-detail/all-courses.d.ts +17 -52
- package/es/template/skill-detail/all-courses.d.ts.map +1 -1
- package/es/template/skill-detail/all-courses.js +11 -12
- package/es/template/skill-detail/all-courses.js.map +1 -1
- package/es/template/skill-detail/continue-learning.css +2 -7
- package/es/template/skill-detail/continue-learning.d.ts +12 -25
- package/es/template/skill-detail/continue-learning.d.ts.map +1 -1
- package/es/template/skill-detail/continue-learning.js.map +1 -1
- package/es/template/skill-detail/index.d.ts +71 -81
- package/es/template/skill-detail/index.d.ts.map +1 -1
- package/es/template/skill-detail/index.js +55 -87
- package/es/template/skill-detail/index.js.map +1 -1
- package/es/template/skill-detail/style.css +39 -97
- package/es/variables/colors.css +0 -2
- package/es/variables/colors.d.ts +2 -3
- package/es/variables/colors.d.ts.map +1 -1
- package/es/variables/colors.js +3 -4
- package/es/variables/colors.js.map +1 -1
- package/es/variables/theme.native.js +1 -1
- package/es/variables/theme.native.js.map +1 -1
- package/lib/atom/button-link/index.js +1 -1
- package/lib/atom/button-link/index.js.map +1 -1
- package/lib/atom/button-link/style.css +2 -2
- package/lib/atom/icon/index.d.ts +17 -35
- package/lib/atom/icon/index.d.ts.map +1 -1
- package/lib/atom/icon/index.js +18 -34
- package/lib/atom/icon/index.js.map +1 -1
- package/lib/atom/radio-with-title/index.d.ts +3 -13
- package/lib/atom/radio-with-title/index.d.ts.map +1 -1
- package/lib/atom/radio-with-title/types.d.ts +2 -13
- package/lib/atom/radio-with-title/types.d.ts.map +1 -1
- package/lib/atom/status-item/index.native.js +1 -1
- package/lib/atom/status-item/index.native.js.map +1 -1
- package/lib/atom/tag/index.d.ts +1 -12
- package/lib/atom/tag/style.css +0 -1
- package/lib/atom/title/index.d.ts +2 -13
- package/lib/molecule/banner/style.css +0 -1
- package/lib/molecule/base-modal/style.css +1 -0
- package/lib/molecule/bulk-progress-bar/index.js +2 -2
- package/lib/molecule/bulk-progress-bar/index.js.map +1 -1
- package/lib/molecule/certification-card/index.js +1 -1
- package/lib/molecule/certification-card/index.js.map +1 -1
- package/lib/molecule/cm-popin/types.d.ts +7 -28
- package/lib/molecule/cm-popin/types.d.ts.map +1 -1
- package/lib/molecule/cm-popin/types.js +1 -1
- package/lib/molecule/cm-popin/types.js.map +1 -1
- package/lib/molecule/dashboard/cards-list/index.d.ts.map +1 -1
- package/lib/molecule/dashboard/cards-list/index.js +0 -2
- package/lib/molecule/dashboard/cards-list/index.js.map +1 -1
- package/lib/molecule/learner-skill-card/index.js +8 -10
- package/lib/molecule/learner-skill-card/index.js.map +1 -1
- package/lib/molecule/learner-skill-card/style.css +0 -1
- package/lib/molecule/learning-priority-modal/style.css +2 -3
- package/lib/molecule/progress-wrapper/index.js +1 -1
- package/lib/molecule/progress-wrapper/index.js.map +1 -1
- package/lib/molecule/skills-chart-side-information-item/index.d.ts +1 -1
- package/lib/molecule/skills-chart-side-information-panel/index.d.ts +1 -1
- package/lib/molecule/title-and-checkbox-wrapper/index.d.ts +2 -13
- package/lib/molecule/title-radio-wrapper/index.d.ts +3 -13
- package/lib/molecule/title-radio-wrapper/index.d.ts.map +1 -1
- package/lib/molecule/title-radio-wrapper/types.d.ts +2 -13
- package/lib/molecule/title-radio-wrapper/types.d.ts.map +1 -1
- package/lib/molecule/translation-modal/index.d.ts +1 -0
- package/lib/molecule/translation-modal/index.d.ts.map +1 -1
- package/lib/molecule/translation-modal/index.js +6 -23
- package/lib/molecule/translation-modal/index.js.map +1 -1
- package/lib/organism/cards-grid/index.d.ts +10 -48
- package/lib/organism/cards-grid/index.d.ts.map +1 -1
- package/lib/organism/cards-grid/index.js +2 -3
- package/lib/organism/cards-grid/index.js.map +1 -1
- package/lib/organism/content-skill-modal/index.d.ts +3 -13
- package/lib/organism/content-skill-modal/index.d.ts.map +1 -1
- package/lib/organism/content-skill-modal/types.d.ts +2 -12
- package/lib/organism/content-skill-modal/types.d.ts.map +1 -1
- package/lib/organism/list-item/index.js +5 -5
- package/lib/organism/list-item/index.js.map +1 -1
- package/lib/organism/list-item/style.css +17 -23
- package/lib/organism/list-items/index.d.ts +2 -13
- package/lib/organism/list-items/style.css +0 -1
- package/lib/organism/rewards-form/index.d.ts +2 -13
- package/lib/organism/select-opponents/index.d.ts +3 -13
- package/lib/organism/select-opponents/index.d.ts.map +1 -1
- package/lib/organism/select-opponents/types.d.ts +2 -13
- package/lib/organism/select-opponents/types.d.ts.map +1 -1
- package/lib/organism/sidebar/index.d.ts +2 -2
- package/lib/organism/skill-edition/index.d.ts +52 -1261
- package/lib/organism/skill-edition/index.d.ts.map +1 -1
- package/lib/organism/skill-edition/index.js +224 -3
- package/lib/organism/skill-edition/index.js.map +1 -1
- package/lib/organism/skill-edition/types.d.ts +117 -1268
- package/lib/organism/skill-edition/types.d.ts.map +1 -1
- package/lib/organism/skill-edition/types.js +59 -7
- package/lib/organism/skill-edition/types.js.map +1 -1
- package/lib/organism/title-and-input/index.d.ts +5 -25
- package/lib/organism/title-and-input/index.d.ts.map +1 -1
- package/lib/organism/title-and-input/types.d.ts +4 -24
- package/lib/organism/title-and-input/types.d.ts.map +1 -1
- package/lib/organism/wizard-contents/index.d.ts +2 -13
- package/lib/template/app-player/loading/index.d.ts +6 -27
- package/lib/template/app-player/player/index.d.ts +12 -53
- package/lib/template/app-player/player/slides/index.d.ts +6 -27
- package/lib/template/app-player/player/slides/index.d.ts.map +1 -1
- package/lib/template/app-player/popin-correction/index.d.ts +6 -26
- package/lib/template/app-player/popin-correction/index.d.ts.map +1 -1
- package/lib/template/app-player/popin-end/index.d.ts +6 -27
- package/lib/template/app-review/index.d.ts +7 -27
- package/lib/template/app-review/index.d.ts.map +1 -1
- package/lib/template/app-review/player/prop-types.d.ts +6 -27
- package/lib/template/app-review/player/prop-types.d.ts.map +1 -1
- package/lib/template/app-review/prop-types.d.ts +6 -27
- package/lib/template/app-review/prop-types.d.ts.map +1 -1
- package/lib/template/back-office/brand-update/index.d.ts +1113 -1713
- package/lib/template/back-office/brand-update/index.d.ts.map +1 -1
- package/lib/template/back-office/brand-update/index.js +12 -0
- package/lib/template/back-office/brand-update/index.js.map +1 -1
- package/lib/template/back-office/brand-update/utils.d.ts +1 -1
- package/lib/template/common/dashboard/index.d.ts +12 -53
- package/lib/template/common/search-page/index.d.ts +6 -27
- package/lib/template/external-course/index.d.ts +6 -27
- package/lib/template/skill-detail/all-courses.css +2 -3
- package/lib/template/skill-detail/all-courses.d.ts +17 -52
- package/lib/template/skill-detail/all-courses.d.ts.map +1 -1
- package/lib/template/skill-detail/all-courses.js +11 -11
- package/lib/template/skill-detail/all-courses.js.map +1 -1
- package/lib/template/skill-detail/continue-learning.css +2 -7
- package/lib/template/skill-detail/continue-learning.d.ts +12 -25
- package/lib/template/skill-detail/continue-learning.d.ts.map +1 -1
- package/lib/template/skill-detail/continue-learning.js.map +1 -1
- package/lib/template/skill-detail/index.d.ts +71 -81
- package/lib/template/skill-detail/index.d.ts.map +1 -1
- package/lib/template/skill-detail/index.js +55 -87
- package/lib/template/skill-detail/index.js.map +1 -1
- package/lib/template/skill-detail/style.css +39 -97
- package/lib/variables/colors.css +0 -2
- package/lib/variables/colors.d.ts +2 -3
- package/lib/variables/colors.d.ts.map +1 -1
- package/lib/variables/colors.js +3 -4
- package/lib/variables/colors.js.map +1 -1
- package/lib/variables/theme.native.js +1 -1
- package/lib/variables/theme.native.js.map +1 -1
- package/locales/bs/global.json +1 -0
- package/locales/de/global.json +1 -0
- package/locales/es/global.json +1 -0
- package/locales/et/global.json +1 -0
- package/locales/fi/global.json +1 -0
- package/locales/fr/global.json +1 -0
- package/locales/hu/global.json +1 -0
- package/locales/hy/global.json +1 -0
- package/locales/ja/global.json +1 -0
- package/locales/nl/global.json +1 -0
- package/locales/pl/global.json +1 -0
- package/locales/pt/global.json +1 -0
- package/locales/ro/global.json +1 -0
- package/locales/sk/global.json +1 -0
- package/locales/sl/global.json +1 -0
- package/locales/sv/global.json +1 -0
- package/locales/tl/global.json +1 -0
- package/locales/tr/global.json +1 -0
- package/locales/uk/global.json +1 -0
- package/locales/vi/global.json +1 -0
- package/locales/zh/global.json +1 -0
- package/locales/zh_TW/global.json +1 -0
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.native.js","names":["COLORS","HTML_ANCHOR_TEXT_COLOR","cm_primary_blue","defaultTheme","colors","border","gray","extra","lighter","light","lightMedium","medium","dark","extraDark","text","primary","secondary","cta","negative","positive","
|
|
1
|
+
{"version":3,"file":"theme.native.js","names":["COLORS","HTML_ANCHOR_TEXT_COLOR","cm_primary_blue","defaultTheme","colors","border","gray","extra","lighter","light","lightMedium","medium","dark","extraDark","text","primary","secondary","cta","negative","positive","white","black","battle","notification","salmon","podcast","background","cm_grey_800","spacing","micro","tiny","small","base","large","xlarge","radius","common","card","regular","search","button","thumbnail","fontWeight","semiBold","bold","extraBold","fontSize","extraSmall","xxlarge","xxxlarge","letterSpacing","header"],"sources":["../../src/variables/theme.native.ts"],"sourcesContent":["import {TextStyle} from 'react-native';\nimport {COLORS} from './colors';\n\nexport type SpaceType = 'micro' | 'tiny' | 'small' | 'base' | 'medium' | 'large' | 'xlarge';\n\nexport const HTML_ANCHOR_TEXT_COLOR = '#002BDB';\n\nconst {cm_primary_blue} = COLORS;\n\nexport type Colors = {\n border: string;\n gray: {\n extra: string;\n light: string;\n lighter: string;\n lightMedium: string;\n medium: string;\n dark: string;\n extraDark: string;\n };\n podcast: {\n background: string;\n primary: string;\n };\n text: {\n primary: string;\n secondary: string;\n };\n cta: string;\n negative: string;\n positive: string;\n white: string;\n black: string;\n battle: string;\n notification: string;\n salmon: string;\n};\n\nexport type Theme = {\n colors: Colors;\n spacing: {\n micro: number;\n tiny: number;\n small: number;\n base: number;\n medium: number;\n large: number;\n xlarge: number;\n };\n radius: {\n button: number;\n common: number;\n card: number;\n medium: number;\n regular: number;\n search: number;\n thumbnail: number;\n };\n fontWeight: {\n regular: TextStyle['fontWeight'];\n semiBold: TextStyle['fontWeight'];\n bold: TextStyle['fontWeight'];\n extraBold: TextStyle['fontWeight'];\n };\n fontSize: {\n extraSmall: TextStyle['fontSize'];\n small: TextStyle['fontSize'];\n medium: TextStyle['fontSize'];\n regular: TextStyle['fontSize'];\n large: TextStyle['fontSize'];\n xlarge: TextStyle['fontSize'];\n xxlarge: TextStyle['fontSize'];\n xxxlarge: TextStyle['fontSize'];\n };\n letterSpacing: {\n header: number;\n };\n};\n\nconst defaultTheme: Theme = {\n colors: {\n border: 'rgba(0, 0, 0, 0.1)',\n gray: {\n extra: '#FAFAFA',\n lighter: '#F4F4F5',\n light: '#ededed',\n lightMedium: '#CFD8DC',\n medium: '#90A4AE',\n dark: '#546E7A',\n extraDark: '#323232'\n },\n text: {\n primary: '#06265B',\n secondary: '#FFFFFF'\n },\n cta: cm_primary_blue,\n negative: COLORS.negative,\n positive: COLORS.positive,\n white: '#FFFFFF',\n black: '#14171A',\n battle: '#FFDE03',\n notification: '#FF7043',\n salmon: '#FDE2E5',\n podcast: {\n background: COLORS.cm_grey_800,\n primary: '#FF541F'\n }\n },\n spacing: {\n micro: 4,\n tiny: 8,\n small: 16,\n base: 24,\n medium: 32,\n large: 48,\n xlarge: 64\n },\n radius: {\n common: 3,\n card: 5,\n regular: 8,\n medium: 12,\n search: 24,\n button: 32,\n thumbnail: 1000\n },\n fontWeight: {\n regular: '400',\n semiBold: '500',\n bold: '700',\n extraBold: '900'\n },\n fontSize: {\n extraSmall: 10,\n small: 12,\n medium: 13,\n regular: 15,\n large: 17,\n xlarge: 22,\n xxlarge: 28,\n xxxlarge: 40\n },\n letterSpacing: {\n header: 5\n }\n};\n\nexport default defaultTheme;\n"],"mappings":"AACA,SAAQA,MAAM,QAAO,UAAU;AAI/B,OAAO,MAAMC,sBAAsB,GAAG,SAAS;AAE/C,MAAM;EAACC;AAAe,CAAC,GAAGF,MAAM;AAwEhC,MAAMG,YAAmB,GAAG;EAC1BC,MAAM,EAAE;IACNC,MAAM,EAAE,oBAAoB;IAC5BC,IAAI,EAAE;MACJC,KAAK,EAAE,SAAS;MAChBC,OAAO,EAAE,SAAS;MAClBC,KAAK,EAAE,SAAS;MAChBC,WAAW,EAAE,SAAS;MACtBC,MAAM,EAAE,SAAS;MACjBC,IAAI,EAAE,SAAS;MACfC,SAAS,EAAE;IACb,CAAC;IACDC,IAAI,EAAE;MACJC,OAAO,EAAE,SAAS;MAClBC,SAAS,EAAE;IACb,CAAC;IACDC,GAAG,EAAEf,eAAe;IACpBgB,QAAQ,EAAElB,MAAM,CAACkB,QAAQ;IACzBC,QAAQ,EAAEnB,MAAM,CAACmB,QAAQ;IACzBC,KAAK,EAAE,SAAS;IAChBC,KAAK,EAAE,SAAS;IAChBC,MAAM,EAAE,SAAS;IACjBC,YAAY,EAAE,SAAS;IACvBC,MAAM,EAAE,SAAS;IACjBC,OAAO,EAAE;MACPC,UAAU,EAAE1B,MAAM,CAAC2B,WAAW;MAC9BZ,OAAO,EAAE;IACX;EACF,CAAC;EACDa,OAAO,EAAE;IACPC,KAAK,EAAE,CAAC;IACRC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,EAAE;IACTC,IAAI,EAAE,EAAE;IACRrB,MAAM,EAAE,EAAE;IACVsB,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV,CAAC;EACDC,MAAM,EAAE;IACNC,MAAM,EAAE,CAAC;IACTC,IAAI,EAAE,CAAC;IACPC,OAAO,EAAE,CAAC;IACV3B,MAAM,EAAE,EAAE;IACV4B,MAAM,EAAE,EAAE;IACVC,MAAM,EAAE,EAAE;IACVC,SAAS,EAAE;EACb,CAAC;EACDC,UAAU,EAAE;IACVJ,OAAO,EAAE,KAAK;IACdK,QAAQ,EAAE,KAAK;IACfC,IAAI,EAAE,KAAK;IACXC,SAAS,EAAE;EACb,CAAC;EACDC,QAAQ,EAAE;IACRC,UAAU,EAAE,EAAE;IACdhB,KAAK,EAAE,EAAE;IACTpB,MAAM,EAAE,EAAE;IACV2B,OAAO,EAAE,EAAE;IACXL,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE,EAAE;IACVc,OAAO,EAAE,EAAE;IACXC,QAAQ,EAAE;EACZ,CAAC;EACDC,aAAa,EAAE;IACbC,MAAM,EAAE;EACV;AACF,CAAC;AAED,eAAehD,YAAY","ignoreList":[]}
|
|
@@ -36,7 +36,7 @@ const getButtonContent = (icon, content, hovered, hoverBackgroundColor, hoverCol
|
|
|
36
36
|
iconName: faIcon.name,
|
|
37
37
|
iconColor: hovered && hoverColor ? hoverColor : faIcon.color ?? _icon.DEFAULT_ICON_COLOR,
|
|
38
38
|
// eslint-disable-next-line no-nested-ternary
|
|
39
|
-
backgroundColor: !faIcon?.backgroundColor ?
|
|
39
|
+
backgroundColor: !faIcon?.backgroundColor ? 'transparent' : hovered && hoverBackgroundColor ? hoverBackgroundColor : faIcon.backgroundColor,
|
|
40
40
|
size: {
|
|
41
41
|
faSize: faIcon.size,
|
|
42
42
|
wrapperSize: faIcon.size
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["_react","_interopRequireWildcard","require","_classnames","_interopRequireDefault","_link","_icon","_buttonIcons","_tooltip","_types","_style","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","_extends","assign","bind","arguments","length","apply","getButtonContent","icon","content","hovered","hoverBackgroundColor","hoverColor","type","faIcon","position","Icon","ICONS","createElement","className","style","buttonContent","label","iconComponent","iconName","name","iconColor","color","DEFAULT_ICON_COLOR","backgroundColor","size","faSize","wrapperSize","customStyle","theme","ButtonLink","props","usage","disabled","dataName","dataTestId","ariaLabel","tooltipText","tooltipPlacement","link","onClick","_noop2","onKeyDown","useTitle","styleButton","classnames","button","iconButton","primary","secondary","tertiary","text","dangerous","setHovered","useState","handleOnClick","useCallback","event","handleOnKeyDown","handleMouseOver","handleMouseLeave","TooltipContent","tooltipContentWrapper","renderToolTip","closeToolTipInformationTextAriaLabel","fontSize","anchorId","toolTipIsVisible","placement","_customStyle","useMemo","title","onMouseEnter","onMouseLeave","onMouseOver","tabIndex","propTypes","process","env","NODE_ENV","_default","exports"],"sources":["../../../src/atom/button-link/index.tsx"],"sourcesContent":["import React, {useCallback, useState, useMemo} from 'react';\nimport {noop} from 'lodash/fp';\nimport classnames from 'classnames';\nimport Link from '../link';\nimport FaIcon, {DEFAULT_ICON_COLOR, IconProps} from '../icon';\nimport {ICONS} from '../../util/button-icons';\nimport ToolTip from '../tooltip';\nimport propTypes, {ButtonLinkProps, IconType} from './types';\nimport style from './style.css';\n\nconst getButtonContent = (\n icon?: IconType,\n content?: string | React.ReactNode,\n hovered?: boolean,\n hoverBackgroundColor?: string,\n hoverColor?: string\n) => {\n const {type, faIcon, position} = icon || {type: '', position: ''};\n const Icon = type && ICONS[type];\n\n if (!Icon && !faIcon) {\n return (\n <div className={style.buttonContent}>\n <span className={style.label}>{content}</span>\n </div>\n );\n }\n\n const iconComponent = faIcon ? (\n <FaIcon\n {...({\n iconName: faIcon.name,\n iconColor: hovered && hoverColor ? hoverColor : faIcon.color ?? DEFAULT_ICON_COLOR,\n // eslint-disable-next-line no-nested-ternary\n backgroundColor: !faIcon?.backgroundColor\n ? null\n : hovered && hoverBackgroundColor\n ? hoverBackgroundColor\n : faIcon.backgroundColor,\n size: {\n faSize: faIcon.size,\n wrapperSize: faIcon.size\n },\n customStyle: faIcon.customStyle\n } as IconProps)}\n />\n ) : (\n <Icon className={style.icon} theme=\"coorpmanager\" />\n );\n\n return (\n <div className={style.buttonContent}>\n {position === 'left' ? iconComponent : null}\n {content ? <span className={style.label}>{content}</span> : null}\n {position === 'right' ? iconComponent : null}\n </div>\n );\n};\n\nconst ButtonLink = (props: ButtonLinkProps) => {\n const {\n type,\n usage = 'button',\n label,\n content,\n hoverBackgroundColor,\n hoverColor,\n disabled = false,\n icon,\n 'data-name': dataName,\n 'data-testid': dataTestId = 'button-link',\n 'aria-label': ariaLabel,\n tooltipText,\n tooltipPlacement = 'left',\n link,\n onClick = noop,\n onKeyDown = noop,\n className,\n customStyle,\n useTitle = true\n } = props;\n const styleButton = classnames(\n className,\n style.button,\n !label && style.iconButton,\n type === 'primary' && style.primary,\n type === 'secondary' && style.secondary,\n type === 'tertiary' && style.tertiary,\n type === 'text' && style.text,\n type === 'dangerous' && style.dangerous,\n link && style.link,\n disabled && style.disabled\n );\n\n const [hovered, setHovered] = useState(false);\n\n const handleOnClick = useCallback(event => onClick(event), [onClick]);\n\n const handleOnKeyDown = useCallback(event => onKeyDown(event), [onKeyDown]);\n\n const handleMouseOver = useCallback(() => {\n setHovered(true);\n }, [setHovered]);\n\n const handleMouseLeave = useCallback(() => setHovered(false), [setHovered]);\n\n const TooltipContent = useCallback(\n () => <span className={style.tooltipContentWrapper}>{tooltipText || ariaLabel}</span>,\n [tooltipText, ariaLabel]\n );\n\n const renderToolTip = () => {\n const closeToolTipInformationTextAriaLabel = tooltipText || ariaLabel;\n if (!closeToolTipInformationTextAriaLabel) return null;\n return (\n <ToolTip\n fontSize={12}\n anchorId=\"button-icon\"\n toolTipIsVisible={hovered}\n placement={tooltipPlacement}\n TooltipContent={TooltipContent}\n closeToolTipInformationTextAriaLabel={closeToolTipInformationTextAriaLabel}\n />\n );\n };\n\n const _customStyle = useMemo(() => {\n return {\n ...customStyle,\n ...((hoverBackgroundColor || hoverColor) && hovered\n ? {\n backgroundColor: hoverBackgroundColor,\n color: hoverColor\n }\n : null)\n };\n }, [hoverBackgroundColor, hoverColor, hovered, customStyle]);\n\n if (link) {\n return (\n <Link\n {...link}\n {...(useTitle && {\n title: ariaLabel || label\n })}\n style={customStyle}\n className={styleButton}\n data-name={dataName}\n data-testid={dataTestId}\n aria-label={ariaLabel || label}\n hoverColor={hoverColor}\n hoverBackgroundColor={hoverBackgroundColor}\n onMouseEnter={handleMouseOver}\n onMouseLeave={handleMouseLeave}\n >\n {getButtonContent(icon, content ?? label, hovered, hoverBackgroundColor, hoverColor)}\n {renderToolTip()}\n </Link>\n );\n }\n\n return (\n <button\n {...(useTitle && {\n title: ariaLabel || label\n })}\n {...(ariaLabel && !label\n ? {\n 'data-for': 'button-icon',\n 'data-tip': hovered\n }\n : {})}\n // eslint-disable-next-line react/button-has-type\n type={usage}\n aria-label={ariaLabel || label}\n data-name={dataName}\n data-testid={dataTestId}\n style={_customStyle}\n className={styleButton}\n onClick={handleOnClick}\n onKeyDown={handleOnKeyDown}\n onMouseOver={handleMouseOver}\n onMouseLeave={handleMouseLeave}\n tabIndex={0}\n disabled={disabled}\n >\n {getButtonContent(icon, content ?? label, hovered, hoverBackgroundColor, hoverColor)}\n {renderToolTip()}\n </button>\n );\n};\n\nButtonLink.propTypes = propTypes;\n\nexport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I,QAAA,GAAAC,OAAA,CAAAnG,OAAA,GAElBgD,UAAU","ignoreList":[]}
|
|
1
|
+
{"version":3,"file":"index.js","names":["_react","_interopRequireWildcard","require","_classnames","_interopRequireDefault","_link","_icon","_buttonIcons","_tooltip","_types","_style","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","_extends","assign","bind","arguments","length","apply","getButtonContent","icon","content","hovered","hoverBackgroundColor","hoverColor","type","faIcon","position","Icon","ICONS","createElement","className","style","buttonContent","label","iconComponent","iconName","name","iconColor","color","DEFAULT_ICON_COLOR","backgroundColor","size","faSize","wrapperSize","customStyle","theme","ButtonLink","props","usage","disabled","dataName","dataTestId","ariaLabel","tooltipText","tooltipPlacement","link","onClick","_noop2","onKeyDown","useTitle","styleButton","classnames","button","iconButton","primary","secondary","tertiary","text","dangerous","setHovered","useState","handleOnClick","useCallback","event","handleOnKeyDown","handleMouseOver","handleMouseLeave","TooltipContent","tooltipContentWrapper","renderToolTip","closeToolTipInformationTextAriaLabel","fontSize","anchorId","toolTipIsVisible","placement","_customStyle","useMemo","title","onMouseEnter","onMouseLeave","onMouseOver","tabIndex","propTypes","process","env","NODE_ENV","_default","exports"],"sources":["../../../src/atom/button-link/index.tsx"],"sourcesContent":["import React, {useCallback, useState, useMemo} from 'react';\nimport {noop} from 'lodash/fp';\nimport classnames from 'classnames';\nimport Link from '../link';\nimport FaIcon, {DEFAULT_ICON_COLOR} from '../icon';\nimport {ICONS} from '../../util/button-icons';\nimport ToolTip from '../tooltip';\nimport propTypes, {ButtonLinkProps, IconType} from './types';\nimport style from './style.css';\n\nconst getButtonContent = (\n icon?: IconType,\n content?: string | React.ReactNode,\n hovered?: boolean,\n hoverBackgroundColor?: string,\n hoverColor?: string\n) => {\n const {type, faIcon, position} = icon || {type: '', position: ''};\n const Icon = type && ICONS[type];\n\n if (!Icon && !faIcon) {\n return (\n <div className={style.buttonContent}>\n <span className={style.label}>{content}</span>\n </div>\n );\n }\n\n const iconComponent = faIcon ? (\n <FaIcon\n {...{\n iconName: faIcon.name,\n iconColor: hovered && hoverColor ? hoverColor : faIcon.color ?? DEFAULT_ICON_COLOR,\n // eslint-disable-next-line no-nested-ternary\n backgroundColor: !faIcon?.backgroundColor\n ? 'transparent'\n : hovered && hoverBackgroundColor\n ? hoverBackgroundColor\n : faIcon.backgroundColor,\n size: {\n faSize: faIcon.size,\n wrapperSize: faIcon.size\n },\n customStyle: faIcon.customStyle\n }}\n />\n ) : (\n <Icon className={style.icon} theme=\"coorpmanager\" />\n );\n\n return (\n <div className={style.buttonContent}>\n {position === 'left' ? iconComponent : null}\n {content ? <span className={style.label}>{content}</span> : null}\n {position === 'right' ? iconComponent : null}\n </div>\n );\n};\n\nconst ButtonLink = (props: ButtonLinkProps) => {\n const {\n type,\n usage = 'button',\n label,\n content,\n hoverBackgroundColor,\n hoverColor,\n disabled = false,\n icon,\n 'data-name': dataName,\n 'data-testid': dataTestId = 'button-link',\n 'aria-label': ariaLabel,\n tooltipText,\n tooltipPlacement = 'left',\n link,\n onClick = noop,\n onKeyDown = noop,\n className,\n customStyle,\n useTitle = true\n } = props;\n const styleButton = classnames(\n className,\n style.button,\n !label && style.iconButton,\n type === 'primary' && style.primary,\n type === 'secondary' && style.secondary,\n type === 'tertiary' && style.tertiary,\n type === 'text' && style.text,\n type === 'dangerous' && style.dangerous,\n link && style.link,\n disabled && style.disabled\n );\n\n const [hovered, setHovered] = useState(false);\n\n const handleOnClick = useCallback(event => onClick(event), [onClick]);\n\n const handleOnKeyDown = useCallback(event => onKeyDown(event), [onKeyDown]);\n\n const handleMouseOver = useCallback(() => {\n setHovered(true);\n }, [setHovered]);\n\n const handleMouseLeave = useCallback(() => setHovered(false), [setHovered]);\n\n const TooltipContent = useCallback(\n () => <span className={style.tooltipContentWrapper}>{tooltipText || ariaLabel}</span>,\n [tooltipText, ariaLabel]\n );\n\n const renderToolTip = () => {\n const closeToolTipInformationTextAriaLabel = tooltipText || ariaLabel;\n if (!closeToolTipInformationTextAriaLabel) return null;\n return (\n <ToolTip\n fontSize={12}\n anchorId=\"button-icon\"\n toolTipIsVisible={hovered}\n placement={tooltipPlacement}\n TooltipContent={TooltipContent}\n closeToolTipInformationTextAriaLabel={closeToolTipInformationTextAriaLabel}\n />\n );\n };\n\n const _customStyle = useMemo(() => {\n return {\n ...customStyle,\n ...((hoverBackgroundColor || hoverColor) && hovered\n ? {\n backgroundColor: hoverBackgroundColor,\n color: hoverColor\n }\n : null)\n };\n }, [hoverBackgroundColor, hoverColor, hovered, customStyle]);\n\n if (link) {\n return (\n <Link\n {...link}\n {...(useTitle && {\n title: ariaLabel || label\n })}\n style={customStyle}\n className={styleButton}\n data-name={dataName}\n data-testid={dataTestId}\n aria-label={ariaLabel || label}\n hoverColor={hoverColor}\n hoverBackgroundColor={hoverBackgroundColor}\n onMouseEnter={handleMouseOver}\n onMouseLeave={handleMouseLeave}\n >\n {getButtonContent(icon, content ?? label, hovered, hoverBackgroundColor, hoverColor)}\n {renderToolTip()}\n </Link>\n );\n }\n\n return (\n <button\n {...(useTitle && {\n title: ariaLabel || label\n })}\n {...(ariaLabel && !label\n ? {\n 'data-for': 'button-icon',\n 'data-tip': hovered\n }\n : {})}\n // eslint-disable-next-line react/button-has-type\n type={usage}\n aria-label={ariaLabel || label}\n data-name={dataName}\n data-testid={dataTestId}\n style={_customStyle}\n className={styleButton}\n onClick={handleOnClick}\n onKeyDown={handleOnKeyDown}\n onMouseOver={handleMouseOver}\n onMouseLeave={handleMouseLeave}\n tabIndex={0}\n disabled={disabled}\n >\n {getButtonContent(icon, content ?? label, hovered, hoverBackgroundColor, hoverColor)}\n {renderToolTip()}\n </button>\n );\n};\n\nButtonLink.propTypes = propTypes;\n\nexport default ButtonLink;\n"],"mappings":";;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AAEA,IAAAC,WAAA,GAAAC,sBAAA,CAAAF,OAAA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|
cursor: pointer;
|
|
24
24
|
border: none;
|
|
25
|
-
padding:
|
|
25
|
+
padding: 0px 16px;
|
|
26
26
|
/* prevents text selection when dragging
|
|
27
27
|
the mouse over the button */
|
|
28
28
|
user-select: none;
|
|
@@ -39,7 +39,6 @@
|
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
.buttonContent {
|
|
42
|
-
gap: 8px;
|
|
43
42
|
display: flex;
|
|
44
43
|
justify-content: center;
|
|
45
44
|
align-items: center;
|
|
@@ -56,6 +55,7 @@
|
|
|
56
55
|
}
|
|
57
56
|
|
|
58
57
|
.label {
|
|
58
|
+
margin: 0 8px 0 8px;
|
|
59
59
|
text-wrap: nowrap;
|
|
60
60
|
display: block;
|
|
61
61
|
}
|
package/lib/atom/icon/index.d.ts
CHANGED
|
@@ -1,40 +1,22 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
iconName: string;
|
|
14
|
-
iconColor?: string;
|
|
15
|
-
backgroundColor?: string;
|
|
16
|
-
gradientBackground?: boolean;
|
|
17
|
-
borderRadius?: string;
|
|
18
|
-
preset?: string;
|
|
19
|
-
size?: IconSize;
|
|
20
|
-
customStyle?: CSSProperties;
|
|
21
|
-
}
|
|
22
|
-
export declare function getForegroundColor(backgroundColor: string): string;
|
|
23
|
-
declare const Icon: React.FC<IconProps>;
|
|
24
|
-
export declare const propTypes: {
|
|
25
|
-
iconName: PropTypes.Validator<string>;
|
|
26
|
-
iconColor: PropTypes.Requireable<string>;
|
|
27
|
-
backgroundColor: PropTypes.Requireable<string>;
|
|
28
|
-
gradientBackground: PropTypes.Requireable<boolean>;
|
|
29
|
-
borderRadius: PropTypes.Requireable<string>;
|
|
30
|
-
preset: PropTypes.Requireable<string>;
|
|
31
|
-
size: PropTypes.Requireable<PropTypes.InferProps<{
|
|
32
|
-
faSize: PropTypes.Validator<number>;
|
|
33
|
-
wrapperSize: PropTypes.Validator<number>;
|
|
1
|
+
export const DEFAULT_ICON_COLOR: "hsl(0, 0%, 32%)";
|
|
2
|
+
export function getForegroundColor(backgroundColor: any): any;
|
|
3
|
+
export namespace iconPropTypes {
|
|
4
|
+
const iconName: PropTypes.Validator<string>;
|
|
5
|
+
const iconColor: PropTypes.Requireable<string>;
|
|
6
|
+
const backgroundColor: PropTypes.Requireable<string>;
|
|
7
|
+
const gradientBackground: PropTypes.Requireable<boolean>;
|
|
8
|
+
const borderRadius: PropTypes.Requireable<string>;
|
|
9
|
+
const preset: PropTypes.Requireable<string>;
|
|
10
|
+
const size: PropTypes.Requireable<PropTypes.InferProps<{
|
|
11
|
+
faSize: PropTypes.Requireable<number>;
|
|
12
|
+
wrapperSize: PropTypes.Requireable<number>;
|
|
34
13
|
}>>;
|
|
35
|
-
customStyle: PropTypes.Requireable<{
|
|
14
|
+
const customStyle: PropTypes.Requireable<{
|
|
36
15
|
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
37
16
|
}>;
|
|
38
|
-
}
|
|
17
|
+
}
|
|
39
18
|
export default Icon;
|
|
19
|
+
import PropTypes from "prop-types";
|
|
20
|
+
declare const Icon: React.NamedExoticComponent<object>;
|
|
21
|
+
import React from "react";
|
|
40
22
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/icon/index.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/icon/index.js"],"names":[],"mappings":"AAkBA,mDAAoD;AAiB7C,8DAC8D;;;;;;;;;;;;;;;;;;AAGrE,uDAsCG"}
|
package/lib/atom/icon/index.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
exports.__esModule = true;
|
|
4
|
-
exports.
|
|
5
|
-
exports.getForegroundColor = getForegroundColor;
|
|
6
|
-
exports.propTypes = void 0;
|
|
4
|
+
exports.iconPropTypes = exports.getForegroundColor = exports.default = exports.DEFAULT_ICON_COLOR = void 0;
|
|
7
5
|
var _react = _interopRequireDefault(require("react"));
|
|
8
|
-
var _propTypes =
|
|
6
|
+
var _propTypes = _interopRequireWildcard(require("prop-types"));
|
|
9
7
|
var _reactFontawesome = require("@fortawesome/react-fontawesome");
|
|
10
8
|
var _proSolidSvgIcons = require("@fortawesome/pro-solid-svg-icons");
|
|
11
9
|
var _fontawesomeSvgCore = require("@fortawesome/fontawesome-svg-core");
|
|
@@ -15,16 +13,15 @@ var _getOr = _interopRequireDefault(require("lodash/fp/getOr"));
|
|
|
15
13
|
var _cssColorFunction = require("css-color-function");
|
|
16
14
|
var _getBackgroundGradientColor = require("../../util/get-background-gradient-color");
|
|
17
15
|
var _style = _interopRequireDefault(require("./style.css"));
|
|
16
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
17
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
18
18
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
19
19
|
_fontawesomeSvgCore.library.add(_proSolidSvgIcons.fas);
|
|
20
|
-
const DEFAULT_PRESET =
|
|
21
|
-
const ICON_LUMINOSITY =
|
|
22
|
-
const DEFAULT_WRAPPER_SIZE =
|
|
23
|
-
const ICON_PADDING =
|
|
20
|
+
const DEFAULT_PRESET = 'm';
|
|
21
|
+
const ICON_LUMINOSITY = 32;
|
|
22
|
+
const DEFAULT_WRAPPER_SIZE = 40;
|
|
23
|
+
const ICON_PADDING = 8;
|
|
24
24
|
const DEFAULT_ICON_COLOR = exports.DEFAULT_ICON_COLOR = 'hsl(0, 0%, 32%)';
|
|
25
|
-
function getForegroundColor(backgroundColor) {
|
|
26
|
-
return (0, _cssColorFunction.convert)(`color(${backgroundColor} lightness(${ICON_LUMINOSITY}%))`);
|
|
27
|
-
}
|
|
28
25
|
const SIZE_CONFIGS = {
|
|
29
26
|
s: {
|
|
30
27
|
faSize: 12,
|
|
@@ -39,7 +36,10 @@ const SIZE_CONFIGS = {
|
|
|
39
36
|
wrapperSize: 48
|
|
40
37
|
}
|
|
41
38
|
};
|
|
42
|
-
const
|
|
39
|
+
const getForegroundColor = backgroundColor => (0, _cssColorFunction.convert)(`color(${backgroundColor} lightness(${ICON_LUMINOSITY}%))`);
|
|
40
|
+
// set lightness to 32%
|
|
41
|
+
exports.getForegroundColor = getForegroundColor;
|
|
42
|
+
const Icon = /*#__PURE__*/_react.default.memo(function Icon({
|
|
43
43
|
iconName,
|
|
44
44
|
iconColor,
|
|
45
45
|
backgroundColor,
|
|
@@ -48,18 +48,9 @@ const Icon = ({
|
|
|
48
48
|
preset = DEFAULT_PRESET,
|
|
49
49
|
size,
|
|
50
50
|
customStyle
|
|
51
|
-
})
|
|
51
|
+
}) {
|
|
52
52
|
const effectiveIconColor = iconColor || (backgroundColor ? getForegroundColor(backgroundColor) : DEFAULT_ICON_COLOR);
|
|
53
53
|
const effectiveSize = size ? (0, _merge.default)(SIZE_CONFIGS[DEFAULT_PRESET], size) : (0, _getOr.default)(SIZE_CONFIGS[DEFAULT_PRESET], (0, _toLower.default)(preset), SIZE_CONFIGS);
|
|
54
|
-
const hasBackground = backgroundColor || gradientBackground;
|
|
55
|
-
if (!hasBackground) {
|
|
56
|
-
return /*#__PURE__*/_react.default.createElement(_reactFontawesome.FontAwesomeIcon, {
|
|
57
|
-
icon: `fa-${iconName}`,
|
|
58
|
-
color: effectiveIconColor,
|
|
59
|
-
fontSize: effectiveSize.faSize,
|
|
60
|
-
style: customStyle
|
|
61
|
-
});
|
|
62
|
-
}
|
|
63
54
|
const wrapperSize = effectiveSize.wrapperSize - ICON_PADDING * 2;
|
|
64
55
|
const iconWrapperStyle = {
|
|
65
56
|
background: gradientBackground ? (0, _getBackgroundGradientColor.createGradientBackground)(effectiveIconColor, '81%', '91%') : backgroundColor,
|
|
@@ -79,8 +70,8 @@ const Icon = ({
|
|
|
79
70
|
color: effectiveIconColor,
|
|
80
71
|
fontSize: effectiveSize.faSize
|
|
81
72
|
}));
|
|
82
|
-
};
|
|
83
|
-
const
|
|
73
|
+
});
|
|
74
|
+
const iconPropTypes = exports.iconPropTypes = {
|
|
84
75
|
iconName: _propTypes.default.string.isRequired,
|
|
85
76
|
iconColor: _propTypes.default.string,
|
|
86
77
|
backgroundColor: _propTypes.default.string,
|
|
@@ -88,18 +79,11 @@ const propTypes = exports.propTypes = {
|
|
|
88
79
|
borderRadius: _propTypes.default.string,
|
|
89
80
|
preset: _propTypes.default.oneOf(['s', 'm', 'xl']),
|
|
90
81
|
size: _propTypes.default.shape({
|
|
91
|
-
faSize: _propTypes.
|
|
92
|
-
wrapperSize: _propTypes.default.number
|
|
82
|
+
faSize: _propTypes.number,
|
|
83
|
+
wrapperSize: _propTypes.default.number
|
|
93
84
|
}),
|
|
94
85
|
customStyle: _propTypes.default.objectOf(_propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]))
|
|
95
86
|
};
|
|
96
|
-
|
|
97
|
-
// const MemoizedIcon = React.memo(Icon) as React.MemoExoticComponent<React.FC<IconProps>> & {
|
|
98
|
-
// propTypes?: React.WeakValidationMap<IconProps>;
|
|
99
|
-
// defaultProps?: Partial<IconProps>;
|
|
100
|
-
// };
|
|
101
|
-
|
|
102
|
-
Icon.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {};
|
|
103
|
-
// MemoizedIcon.propTypes = Icon.propTypes;
|
|
87
|
+
Icon.propTypes = process.env.NODE_ENV !== "production" ? iconPropTypes : {};
|
|
104
88
|
var _default = exports.default = Icon;
|
|
105
89
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["_react","_interopRequireDefault","require","_propTypes","_reactFontawesome","_proSolidSvgIcons","_fontawesomeSvgCore","_toLower","_merge","_getOr","_cssColorFunction","_getBackgroundGradientColor","_style","e","__esModule","default","
|
|
1
|
+
{"version":3,"file":"index.js","names":["_react","_interopRequireDefault","require","_propTypes","_interopRequireWildcard","_reactFontawesome","_proSolidSvgIcons","_fontawesomeSvgCore","_toLower","_merge","_getOr","_cssColorFunction","_getBackgroundGradientColor","_style","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","library","add","fas","DEFAULT_PRESET","ICON_LUMINOSITY","DEFAULT_WRAPPER_SIZE","ICON_PADDING","DEFAULT_ICON_COLOR","exports","SIZE_CONFIGS","s","faSize","wrapperSize","m","xl","getForegroundColor","backgroundColor","convert","Icon","React","memo","iconName","iconColor","gradientBackground","borderRadius","preset","size","customStyle","effectiveIconColor","effectiveSize","merge","getOr","toLower","iconWrapperStyle","background","createGradientBackground","width","height","padding","createElement","className","style","iconWrapper","FontAwesomeIcon","icon","color","fontSize","iconPropTypes","PropTypes","string","isRequired","bool","oneOf","shape","number","objectOf","oneOfType","propTypes","process","env","NODE_ENV","_default"],"sources":["../../../src/atom/icon/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes, {number} from 'prop-types';\nimport {FontAwesomeIcon} from '@fortawesome/react-fontawesome';\nimport {fas} from '@fortawesome/pro-solid-svg-icons';\nimport {library} from '@fortawesome/fontawesome-svg-core';\nimport toLower from 'lodash/fp/toLower';\nimport merge from 'lodash/fp/merge';\nimport getOr from 'lodash/fp/getOr';\nimport {convert} from 'css-color-function';\nimport {createGradientBackground} from '../../util/get-background-gradient-color';\nimport style from './style.css';\n\nlibrary.add(fas);\n\nconst DEFAULT_PRESET = 'm';\nconst ICON_LUMINOSITY = 32;\nconst DEFAULT_WRAPPER_SIZE = 40;\nconst ICON_PADDING = 8;\nexport const DEFAULT_ICON_COLOR = 'hsl(0, 0%, 32%)';\n\nconst SIZE_CONFIGS = {\n s: {\n faSize: 12,\n wrapperSize: 32\n },\n m: {\n faSize: 16,\n wrapperSize: DEFAULT_WRAPPER_SIZE\n },\n xl: {\n faSize: 20,\n wrapperSize: 48\n }\n};\n\nexport const getForegroundColor = backgroundColor =>\n convert(`color(${backgroundColor} lightness(${ICON_LUMINOSITY}%))`);\n// set lightness to 32%\n\nconst Icon = React.memo(function Icon({\n iconName,\n iconColor,\n backgroundColor,\n gradientBackground,\n borderRadius,\n preset = DEFAULT_PRESET,\n size,\n customStyle\n}) {\n const effectiveIconColor =\n iconColor || (backgroundColor ? getForegroundColor(backgroundColor) : DEFAULT_ICON_COLOR);\n\n const effectiveSize = size\n ? merge(SIZE_CONFIGS[DEFAULT_PRESET], size)\n : getOr(SIZE_CONFIGS[DEFAULT_PRESET], toLower(preset), SIZE_CONFIGS);\n\n const wrapperSize = effectiveSize.wrapperSize - ICON_PADDING * 2;\n\n const iconWrapperStyle = {\n background: gradientBackground\n ? createGradientBackground(effectiveIconColor, '81%', '91%')\n : backgroundColor,\n borderRadius,\n width: wrapperSize,\n height: wrapperSize,\n padding: ICON_PADDING\n };\n\n return (\n <div className={style.iconWrapper} style={{...iconWrapperStyle, ...customStyle}}>\n <FontAwesomeIcon\n icon={`fa-${iconName}`}\n color={effectiveIconColor}\n fontSize={effectiveSize.faSize}\n />\n </div>\n );\n});\n\nexport const iconPropTypes = {\n iconName: PropTypes.string.isRequired,\n iconColor: PropTypes.string,\n backgroundColor: PropTypes.string,\n gradientBackground: PropTypes.bool,\n borderRadius: PropTypes.string,\n preset: PropTypes.oneOf(['s', 'm', 'xl']),\n size: PropTypes.shape({\n faSize: number,\n wrapperSize: PropTypes.number\n }),\n customStyle: PropTypes.objectOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number]))\n};\n\nIcon.propTypes = iconPropTypes;\n\nexport default Icon;\n"],"mappings":";;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,UAAA,GAAAC,uBAAA,CAAAF,OAAA;AACA,IAAAG,iBAAA,GAAAH,OAAA;AACA,IAAAI,iBAAA,GAAAJ,OAAA;AACA,IAAAK,mBAAA,GAAAL,OAAA;AACA,IAAAM,QAAA,GAAAP,sBAAA,CAAAC,OAAA;AACA,IAAAO,MAAA,GAAAR,sBAAA,CAAAC,OAAA;AACA,IAAAQ,MAAA,GAAAT,sBAAA,CAAAC,OAAA;AACA,IAAAS,iBAAA,GAAAT,OAAA;AACA,IAAAU,2BAAA,GAAAV,OAAA;AACA,IAAAW,MAAA,GAAAZ,sBAAA,CAAAC,OAAA;AAAgC,SAAAY,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAX,wBAAAW,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,WAAAK,OAAA,EAAAL,CAAA,QAAAG,CAAA,GAAAJ,wBAAA,CAAAG,CAAA,OAAAC,CAAA,IAAAA,CAAA,CAAAG,GAAA,CAAAN,CAAA,UAAAG,CAAA,CAAAI,GAAA,CAAAP,CAAA,OAAAQ,CAAA,KAAAC,SAAA,UAAAC,CAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MA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K,MAAMoC,aAAa,GAAAvC,OAAA,CAAAuC,aAAA,GAAG;EAC3B1B,QAAQ,EAAE2B,kBAAS,CAACC,MAAM,CAACC,UAAU;EACrC5B,SAAS,EAAE0B,kBAAS,CAACC,MAAM;EAC3BjC,eAAe,EAAEgC,kBAAS,CAACC,MAAM;EACjC1B,kBAAkB,EAAEyB,kBAAS,CAACG,IAAI;EAClC3B,YAAY,EAAEwB,kBAAS,CAACC,MAAM;EAC9BxB,MAAM,EAAEuB,kBAAS,CAACI,KAAK,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;EACzC1B,IAAI,EAAEsB,kBAAS,CAACK,KAAK,CAAC;IACpB1C,MAAM,EAAE2C,iBAAM;IACd1C,WAAW,EAAEoC,kBAAS,CAACM;EACzB,CAAC,CAAC;EACF3B,WAAW,EAAEqB,kBAAS,CAACO,QAAQ,CAACP,kBAAS,CAACQ,SAAS,CAAC,CAACR,kBAAS,CAACC,MAAM,EAAED,kBAAS,CAACM,MAAM,CAAC,CAAC;AAC3F,CAAC;AAEDpC,IAAI,CAACuC,SAAS,GAAAC,OAAA,CAAAC,GAAA,CAAAC,QAAA,oBAAGb,aAAa;AAAC,IAAAc,QAAA,GAAArD,OAAA,CAAAtB,OAAA,GAEhBgC,IAAI","ignoreList":[]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { RadioWithTitleProps } from './types';
|
|
3
3
|
declare const RadioWithTitle: {
|
|
4
4
|
(props: RadioWithTitleProps): JSX.Element;
|
|
@@ -10,7 +10,7 @@ declare const RadioWithTitle: {
|
|
|
10
10
|
'data-name': import("prop-types").Requireable<string>;
|
|
11
11
|
titleSize: import("prop-types").Requireable<string>;
|
|
12
12
|
subtitleSize: import("prop-types").Requireable<string>;
|
|
13
|
-
icon: import("prop-types").Requireable<import("prop-types").InferProps<
|
|
13
|
+
icon: import("prop-types").Requireable<import("prop-types").InferProps<any>>;
|
|
14
14
|
tag: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
15
15
|
label: import("prop-types").Requireable<string>;
|
|
16
16
|
type: import("prop-types").Requireable<string>;
|
|
@@ -18,17 +18,7 @@ declare const RadioWithTitle: {
|
|
|
18
18
|
customStyle: import("prop-types").Requireable<{
|
|
19
19
|
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
20
20
|
}>;
|
|
21
|
-
icon: import("prop-types").Requireable<import("prop-types").InferProps<
|
|
22
|
-
position: import("prop-types").Requireable<string>;
|
|
23
|
-
iconName?: React.Validator<string> | undefined;
|
|
24
|
-
iconColor?: React.Validator<string | null | undefined> | undefined;
|
|
25
|
-
backgroundColor?: React.Validator<string | null | undefined> | undefined;
|
|
26
|
-
gradientBackground?: React.Validator<boolean | null | undefined> | undefined;
|
|
27
|
-
borderRadius?: React.Validator<string | null | undefined> | undefined;
|
|
28
|
-
preset?: React.Validator<string | null | undefined> | undefined;
|
|
29
|
-
size?: React.Validator<import("../icon").IconSize | null | undefined> | undefined;
|
|
30
|
-
customStyle?: React.Validator<React.CSSProperties | null | undefined> | undefined;
|
|
31
|
-
}>>;
|
|
21
|
+
icon: import("prop-types").Requireable<import("prop-types").InferProps<any>>;
|
|
32
22
|
}>>;
|
|
33
23
|
button: import("prop-types").Requireable<import("prop-types").InferProps<{
|
|
34
24
|
type: import("prop-types").Requireable<string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/radio-with-title/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/radio-with-title/index.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAY,mBAAmB,EAAC,MAAM,SAAS,CAAC;AAEvD,QAAA,MAAM,cAAc;YAAW,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwBjD,CAAC;AAIF,eAAe,cAAc,CAAC"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import PropTypes from 'prop-types';
|
|
3
2
|
export declare const propTypes: {
|
|
4
3
|
title: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
|
|
@@ -8,7 +7,7 @@ export declare const propTypes: {
|
|
|
8
7
|
'data-name': PropTypes.Requireable<string>;
|
|
9
8
|
titleSize: PropTypes.Requireable<string>;
|
|
10
9
|
subtitleSize: PropTypes.Requireable<string>;
|
|
11
|
-
icon: PropTypes.Requireable<PropTypes.InferProps<
|
|
10
|
+
icon: PropTypes.Requireable<PropTypes.InferProps<any>>;
|
|
12
11
|
tag: PropTypes.Requireable<PropTypes.InferProps<{
|
|
13
12
|
label: PropTypes.Requireable<string>;
|
|
14
13
|
type: PropTypes.Requireable<string>;
|
|
@@ -16,17 +15,7 @@ export declare const propTypes: {
|
|
|
16
15
|
customStyle: PropTypes.Requireable<{
|
|
17
16
|
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
18
17
|
}>;
|
|
19
|
-
icon: PropTypes.Requireable<PropTypes.InferProps<
|
|
20
|
-
position: PropTypes.Requireable<string>;
|
|
21
|
-
iconName?: import("react").Validator<string> | undefined;
|
|
22
|
-
iconColor?: import("react").Validator<string | null | undefined> | undefined;
|
|
23
|
-
backgroundColor?: import("react").Validator<string | null | undefined> | undefined;
|
|
24
|
-
gradientBackground?: import("react").Validator<boolean | null | undefined> | undefined;
|
|
25
|
-
borderRadius?: import("react").Validator<string | null | undefined> | undefined;
|
|
26
|
-
preset?: import("react").Validator<string | null | undefined> | undefined;
|
|
27
|
-
size?: import("react").Validator<import("../icon").IconSize | null | undefined> | undefined;
|
|
28
|
-
customStyle?: import("react").Validator<import("react").CSSProperties | null | undefined> | undefined;
|
|
29
|
-
}>>;
|
|
18
|
+
icon: PropTypes.Requireable<PropTypes.InferProps<any>>;
|
|
30
19
|
}>>;
|
|
31
20
|
button: PropTypes.Requireable<PropTypes.InferProps<{
|
|
32
21
|
type: PropTypes.Requireable<string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/radio-with-title/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/radio-with-title/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAGnC,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAOrB,CAAC;AAEF,oBAAY,mBAAmB,GAAG;IAChC,KAAK,EAAE;QACL,KAAK,EAAE,MAAM,CAAC;QACd,QAAQ,EAAE,MAAM,CAAC;QACjB,IAAI,EAAE,MAAM,CAAC;QACb,WAAW,EAAE,MAAM,CAAC;QACpB,YAAY,EAAE,MAAM,CAAC;KACtB,CAAC;IACF,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IACnC,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC"}
|
|
@@ -12,7 +12,7 @@ const createStyle = (icon, current) => {
|
|
|
12
12
|
let backgroundColor;
|
|
13
13
|
switch (icon) {
|
|
14
14
|
case 'right':
|
|
15
|
-
backgroundColor = _colors.COLORS.
|
|
15
|
+
backgroundColor = _colors.COLORS.positive;
|
|
16
16
|
break;
|
|
17
17
|
case 'wrong':
|
|
18
18
|
backgroundColor = _colors.COLORS.negative;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["_react","_interopRequireWildcard","require","_reactNative","_novaIcons","_colors","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","createStyle","icon","current","backgroundColor","COLORS","
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["_react","_interopRequireWildcard","require","_reactNative","_novaIcons","_colors","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","createStyle","icon","current","backgroundColor","COLORS","positive","negative","gray","StyleSheet","create","step","width","height","opacity","marginHorizontal","alignItems","justifyContent","borderRadius","stepText","fontWeight","fontSize","Step","value","style","setStyle","useState","useEffect","_style","child","createElement","NovaCompositionCoorpacademyCheck","color","NovaSolidStatusClose","Text","View","_default","exports"],"sources":["../../../src/atom/status-item/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, TextStyle, View, ViewStyle} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport {COLORS} from '../../variables/colors';\nimport {StatusItemProps} from './types';\n\ntype StyleSheetType = {\n step: ViewStyle;\n stepText: TextStyle;\n icon: ViewStyle;\n};\n\nconst createStyle = (icon: StatusItemProps['icon'], current?: boolean): StyleSheetType => {\n let backgroundColor;\n\n switch (icon) {\n case 'right':\n backgroundColor = COLORS.positive;\n break;\n case 'wrong':\n backgroundColor = COLORS.negative;\n break;\n case 'no-answer':\n default:\n backgroundColor = COLORS.gray;\n }\n\n return StyleSheet.create({\n step: {\n width: current ? 40 : 32,\n height: current ? 40 : 32,\n opacity: current ? 1 : 0.5,\n marginHorizontal: 8,\n backgroundColor,\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: 50\n },\n stepText: {\n fontWeight: '600',\n fontSize: current ? 16 : 12\n },\n icon: {\n width: current ? 14 : 12,\n height: current ? 14 : 12\n }\n });\n};\n\nconst Step = ({value, icon, current}: StatusItemProps) => {\n const [style, setStyle] = useState<StyleSheetType | null>(null);\n\n useEffect(() => {\n const _style = createStyle(icon, current);\n setStyle(_style);\n }, [current, icon]);\n\n if (!style) {\n return null;\n }\n\n let child;\n\n switch (icon) {\n case 'right':\n child = <RightIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'wrong':\n child = <WrongIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'no-answer':\n default:\n child = <Text style={style.stepText}>{value}</Text>;\n }\n\n return <View style={style.step}>{child}</View>;\n};\n\nexport default Step;\n"],"mappings":";;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AAIA,IAAAG,OAAA,GAAAH,OAAA;AAA8C,SAAAI,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAN,wBAAAM,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,WAAAK,OAAA,EAAAL,CAAA,QAAAG,CAAA,GAAAJ,wBAAA,CAAAG,CAAA,OAAAC,CAAA,IAAAA,CAAA,CAAAG,GAAA,CAAAN,CAAA,UAAAG,CAAA,CAAAI,GAAA,CAAAP,CAAA,OAAAQ,CAAA,KAAAC,SAAA,UAAAC,CAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,CAAA,IAAAd,CAAA,oBAAAc,CAAA,OAAAC,cAAA,CAAAC,IAAA,CAAAhB,CAAA,EAAAc,CAAA,SAAAG,CAAA,GAAAP,CAAA,GAAAC,MAAA,CAAAE,wBAAA,CAAAb,CAAA,EAAAc,CAAA,UAAAG,CA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ropTypes.Requireable<{
|
|
15
15
|
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
16
16
|
}>;
|
|
17
|
-
const icon: PropTypes.Requireable<PropTypes.InferProps<
|
|
18
|
-
position: PropTypes.Requireable<string>;
|
|
19
|
-
iconName?: React.Validator<string> | undefined;
|
|
20
|
-
iconColor?: React.Validator<string | null | undefined> | undefined;
|
|
21
|
-
backgroundColor?: React.Validator<string | null | undefined> | undefined;
|
|
22
|
-
gradientBackground?: React.Validator<boolean | null | undefined> | undefined;
|
|
23
|
-
borderRadius?: React.Validator<string | null | undefined> | undefined;
|
|
24
|
-
preset?: React.Validator<string | null | undefined> | undefined;
|
|
25
|
-
size?: React.Validator<import("../icon").IconSize | null | undefined> | undefined;
|
|
26
|
-
customStyle?: React.Validator<React.CSSProperties | null | undefined> | undefined;
|
|
27
|
-
}>>;
|
|
17
|
+
const icon: PropTypes.Requireable<PropTypes.InferProps<any>>;
|
|
28
18
|
}
|
|
29
19
|
}
|
|
30
20
|
import PropTypes from "prop-types";
|
|
31
|
-
import React from "react";
|
|
32
21
|
//# sourceMappingURL=index.d.ts.map
|
package/lib/atom/tag/style.css
CHANGED
|
@@ -8,7 +8,7 @@ declare namespace Title {
|
|
|
8
8
|
'data-name': PropTypes.Requireable<string>;
|
|
9
9
|
titleSize: PropTypes.Requireable<string>;
|
|
10
10
|
subtitleSize: PropTypes.Requireable<string>;
|
|
11
|
-
icon: PropTypes.Requireable<PropTypes.InferProps<
|
|
11
|
+
icon: PropTypes.Requireable<PropTypes.InferProps<any>>;
|
|
12
12
|
tag: PropTypes.Requireable<PropTypes.InferProps<{
|
|
13
13
|
label: PropTypes.Requireable<string>;
|
|
14
14
|
type: PropTypes.Requireable<string>;
|
|
@@ -16,17 +16,7 @@ declare namespace Title {
|
|
|
16
16
|
customStyle: PropTypes.Requireable<{
|
|
17
17
|
[x: string]: NonNullable<string | number | null | undefined> | null | undefined;
|
|
18
18
|
}>;
|
|
19
|
-
icon: PropTypes.Requireable<PropTypes.InferProps<
|
|
20
|
-
position: PropTypes.Requireable<string>;
|
|
21
|
-
iconName?: React.Validator<string> | undefined;
|
|
22
|
-
iconColor?: React.Validator<string | null | undefined> | undefined;
|
|
23
|
-
backgroundColor?: React.Validator<string | null | undefined> | undefined;
|
|
24
|
-
gradientBackground?: React.Validator<boolean | null | undefined> | undefined;
|
|
25
|
-
borderRadius?: React.Validator<string | null | undefined> | undefined;
|
|
26
|
-
preset?: React.Validator<string | null | undefined> | undefined;
|
|
27
|
-
size?: React.Validator<import("../icon").IconSize | null | undefined> | undefined;
|
|
28
|
-
customStyle?: React.Validator<React.CSSProperties | null | undefined> | undefined;
|
|
29
|
-
}>>;
|
|
19
|
+
icon: PropTypes.Requireable<PropTypes.InferProps<any>>;
|
|
30
20
|
}>>;
|
|
31
21
|
button: PropTypes.Requireable<PropTypes.InferProps<{
|
|
32
22
|
type: PropTypes.Requireable<string>;
|
|
@@ -69,5 +59,4 @@ declare namespace Title {
|
|
|
69
59
|
};
|
|
70
60
|
}
|
|
71
61
|
import PropTypes from "prop-types";
|
|
72
|
-
import React from "react";
|
|
73
62
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -12,7 +12,7 @@ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e
|
|
|
12
12
|
const {
|
|
13
13
|
negative: cm_negative_100,
|
|
14
14
|
cm_primary_blue,
|
|
15
|
-
|
|
15
|
+
positive: cm_positive_100
|
|
16
16
|
} = _colors.COLORS;
|
|
17
17
|
const STATUS = {
|
|
18
18
|
inProgress: 'inProgress',
|
|
@@ -36,7 +36,7 @@ const resolveProgressBarColor = status => {
|
|
|
36
36
|
case STATUS.inProgress:
|
|
37
37
|
return cm_primary_blue;
|
|
38
38
|
default:
|
|
39
|
-
return
|
|
39
|
+
return cm_positive_100;
|
|
40
40
|
}
|
|
41
41
|
};
|
|
42
42
|
const BulkProgressBar = props => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["_react","_interopRequireDefault","require","_progressBar","_statusItem","_colors","_style","_types","e","__esModule","default","negative","cm_negative_100","cm_primary_blue","
|
|
1
|
+
{"version":3,"file":"index.js","names":["_react","_interopRequireDefault","require","_progressBar","_statusItem","_colors","_style","_types","e","__esModule","default","negative","cm_negative_100","cm_primary_blue","positive","cm_positive_100","COLORS","STATUS","inProgress","fail","renderStatusIcon","status","progress","createElement","role","className","style","progressText","statusItemWrapper","icon","resolveProgressBarColor","BulkProgressBar","props","dataName","container","progressBar","value","max","steps","backgroundColor","borderRadius","displayInfo","propTypes","process","env","NODE_ENV","_default","exports"],"sources":["../../../src/molecule/bulk-progress-bar/index.tsx"],"sourcesContent":["import React from 'react';\nimport ProgressBar from '../progress-bar';\nimport StatusItem from '../../atom/status-item';\nimport {COLORS} from '../../variables/colors';\nimport style from './style.css';\nimport {Props, propTypes, Status} from './types';\n\nconst {negative: cm_negative_100, cm_primary_blue, positive: cm_positive_100} = COLORS;\n\nconst STATUS = {\n inProgress: 'inProgress',\n fail: 'fail'\n};\n\nconst renderStatusIcon = (status: Status, progress: number) => {\n if (status === STATUS.inProgress)\n return <div role=\"status\" className={style.progressText}>{`${progress} %`}</div>;\n return (\n <div className={style.statusItemWrapper}>\n <StatusItem icon={status === STATUS.fail ? 'invalid' : 'valid'} />\n </div>\n );\n};\n\nconst resolveProgressBarColor = (status: Status) => {\n switch (status) {\n case STATUS.fail:\n return cm_negative_100;\n case STATUS.inProgress:\n return cm_primary_blue;\n default:\n return cm_positive_100;\n }\n};\n\nconst BulkProgressBar = (props: Props) => {\n const {'data-name': dataName, status, progress} = props;\n\n return (\n <div className={style.container} data-name={dataName}>\n <ProgressBar\n className={style.progressBar}\n value={progress}\n max={100}\n steps={0}\n style={{backgroundColor: resolveProgressBarColor(status), borderRadius: '10px'}}\n displayInfo={false}\n />\n {renderStatusIcon(status, progress)}\n </div>\n );\n};\n\nBulkProgressBar.propTypes = propTypes;\n\nexport default BulkProgressBar;\n"],"mappings":";;;;AAAA,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