@zohodesk/components 1.6.5 → 1.6.7-exp-0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/README.md +16 -1
  2. package/es/Avatar/Avatar.module.css +8 -8
  3. package/es/AvatarTeam/AvatarTeam.module.css +30 -30
  4. package/es/Button/css/Button.module.css +19 -19
  5. package/es/Buttongroup/Buttongroup.module.css +3 -5
  6. package/es/Card/Card.module.css +6 -4
  7. package/es/DateTime/DateWidget.module.css +1 -1
  8. package/es/DropBox/DropBoxElement/css/DropBoxElement.module.css +2 -2
  9. package/es/DropDown/DropDownHeading.module.css +4 -4
  10. package/es/DropDown/DropDownItem.module.css +4 -4
  11. package/es/DropDown/DropDownSearch.module.css +3 -3
  12. package/es/Label/Label.module.css +5 -5
  13. package/es/ListItem/ListItem.module.css +19 -30
  14. package/es/MultiSelect/MobileHeader/MobileHeader.module.css +1 -1
  15. package/es/Radio/Radio.module.css +8 -9
  16. package/es/Ribbon/Ribbon.module.css +16 -19
  17. package/es/RippleEffect/RippleEffect.module.css +55 -17
  18. package/es/Stencils/Stencils.module.css +30 -14
  19. package/es/Tag/Tag.module.css +17 -18
  20. package/es/TextBox/TextBox.module.css +9 -9
  21. package/es/TextBoxIcon/TextBoxIcon.module.css +1 -1
  22. package/es/Textarea/Textarea.module.css +18 -18
  23. package/es/Tooltip/Tooltip.module.css +2 -2
  24. package/es/Typography/Typography.js +18 -8
  25. package/es/Typography/__tests__/Typography.spec.js +198 -6
  26. package/es/Typography/__tests__/__snapshots__/Typography.spec.js.snap +1235 -2
  27. package/es/Typography/css/Typography.module.css +4 -0
  28. package/es/Typography/css/cssJSLogic.js +53 -21
  29. package/es/Typography/props/defaultProps.js +4 -3
  30. package/es/Typography/props/propTypes.js +68 -26
  31. package/es/Typography/utils/textHighlighter.js +2 -2
  32. package/es/common/avatarsizes.module.css +16 -16
  33. package/es/shared/InputFieldLine/InputFieldLine.module.css +2 -2
  34. package/es/v1/Switch/css/Switch_v1.module.css +28 -28
  35. package/lib/Avatar/Avatar.module.css +8 -8
  36. package/lib/AvatarTeam/AvatarTeam.module.css +30 -30
  37. package/lib/Button/css/Button.module.css +19 -19
  38. package/lib/Buttongroup/Buttongroup.module.css +3 -5
  39. package/lib/Card/Card.module.css +6 -4
  40. package/lib/DateTime/DateWidget.module.css +1 -1
  41. package/lib/DropBox/DropBoxElement/css/DropBoxElement.module.css +2 -2
  42. package/lib/DropDown/DropDownHeading.module.css +4 -4
  43. package/lib/DropDown/DropDownItem.module.css +4 -4
  44. package/lib/DropDown/DropDownSearch.module.css +3 -3
  45. package/lib/Label/Label.module.css +5 -5
  46. package/lib/ListItem/ListItem.module.css +19 -30
  47. package/lib/MultiSelect/MobileHeader/MobileHeader.module.css +1 -1
  48. package/lib/Radio/Radio.module.css +8 -9
  49. package/lib/Ribbon/Ribbon.module.css +16 -19
  50. package/lib/RippleEffect/RippleEffect.module.css +55 -17
  51. package/lib/Stencils/Stencils.module.css +30 -14
  52. package/lib/Tag/Tag.module.css +17 -18
  53. package/lib/TextBox/TextBox.module.css +9 -9
  54. package/lib/TextBoxIcon/TextBoxIcon.module.css +1 -1
  55. package/lib/Textarea/Textarea.module.css +18 -18
  56. package/lib/Tooltip/Tooltip.module.css +2 -2
  57. package/lib/Typography/Typography.js +15 -5
  58. package/lib/Typography/__tests__/Typography.spec.js +284 -92
  59. package/lib/Typography/__tests__/__snapshots__/Typography.spec.js.snap +1235 -2
  60. package/lib/Typography/css/Typography.module.css +4 -0
  61. package/lib/Typography/css/cssJSLogic.js +38 -6
  62. package/lib/Typography/props/defaultProps.js +6 -3
  63. package/lib/Typography/props/propTypes.js +67 -23
  64. package/lib/Typography/utils/textHighlighter.js +3 -3
  65. package/lib/common/avatarsizes.module.css +16 -16
  66. package/lib/shared/InputFieldLine/InputFieldLine.module.css +2 -2
  67. package/lib/v1/Switch/css/Switch_v1.module.css +28 -28
  68. package/package.json +15 -12
  69. package/_react-cli.config.js +0 -24
  70. package/assets/Appearance/dark/themes/blue/blue_CTA_DarkModifyCategory.module.css +0 -467
  71. package/assets/Appearance/dark/themes/blue/blue_CTA_DarkTheme.module.css +0 -36
  72. package/assets/Appearance/dark/themes/green/green_CTA_DarkModifyCategory.module.css +0 -467
  73. package/assets/Appearance/dark/themes/green/green_CTA_DarkTheme.module.css +0 -36
  74. package/assets/Appearance/dark/themes/orange/orange_CTA_DarkModifyCategory.module.css +0 -467
  75. package/assets/Appearance/dark/themes/orange/orange_CTA_DarkTheme.module.css +0 -36
  76. package/assets/Appearance/dark/themes/red/red_CTA_DarkModifyCategory.module.css +0 -467
  77. package/assets/Appearance/dark/themes/red/red_CTA_DarkTheme.module.css +0 -36
  78. package/assets/Appearance/dark/themes/yellow/yellow_CTA_DarkModifyCategory.module.css +0 -467
  79. package/assets/Appearance/dark/themes/yellow/yellow_CTA_DarkTheme.module.css +0 -36
  80. package/assets/Appearance/light/themes/blue/blue_CTA_LightModifyCategory.module.css +0 -467
  81. package/assets/Appearance/light/themes/blue/blue_CTA_LightTheme.module.css +0 -36
  82. package/assets/Appearance/light/themes/green/green_CTA_LightModifyCategory.module.css +0 -467
  83. package/assets/Appearance/light/themes/green/green_CTA_LightTheme.module.css +0 -36
  84. package/assets/Appearance/light/themes/orange/orange_CTA_LightModifyCategory.module.css +0 -467
  85. package/assets/Appearance/light/themes/orange/orange_CTA_LightTheme.module.css +0 -36
  86. package/assets/Appearance/light/themes/red/red_CTA_LightModifyCategory.module.css +0 -467
  87. package/assets/Appearance/light/themes/red/red_CTA_LightTheme.module.css +0 -36
  88. package/assets/Appearance/light/themes/yellow/yellow_CTA_LightModifyCategory.module.css +0 -467
  89. package/assets/Appearance/light/themes/yellow/yellow_CTA_LightTheme.module.css +0 -36
  90. package/assets/Appearance/pureDark/themes/blue/blue_CTA_PureDarkModifyCategory.module.css +0 -467
  91. package/assets/Appearance/pureDark/themes/blue/blue_CTA_PureDarkTheme.module.css +0 -36
  92. package/assets/Appearance/pureDark/themes/green/green_CTA_PureDarkModifyCategory.module.css +0 -467
  93. package/assets/Appearance/pureDark/themes/green/green_CTA_PureDarkTheme.module.css +0 -36
  94. package/assets/Appearance/pureDark/themes/orange/orange_CTA_PureDarkModifyCategory.module.css +0 -467
  95. package/assets/Appearance/pureDark/themes/orange/orange_CTA_PureDarkTheme.module.css +0 -36
  96. package/assets/Appearance/pureDark/themes/red/red_CTA_PureDarkModifyCategory.module.css +0 -467
  97. package/assets/Appearance/pureDark/themes/red/red_CTA_PureDarkTheme.module.css +0 -36
  98. package/assets/Appearance/pureDark/themes/yellow/yellow_CTA_PureDarkModifyCategory.module.css +0 -467
  99. package/assets/Appearance/pureDark/themes/yellow/yellow_CTA_PureDarkTheme.module.css +0 -36
  100. package/assets/Contrast/darkContrastLightness.module.css +0 -39
  101. package/assets/Contrast/lightContrastLightness.module.css +0 -39
  102. package/assets/Contrast/pureDarkContrastLightness.module.css +0 -39
@@ -177,6 +177,10 @@
177
177
  white-space: pre-wrap
178
178
  }
179
179
 
180
+ .whiteSpace_breakSpaces {
181
+ white-space: break-spaces;
182
+ }
183
+
180
184
 
181
185
 
182
186
  /*...............Font Size Start.........*/
@@ -7,48 +7,80 @@ export default function cssJSLogic(_ref) {
7
7
  } = _ref;
8
8
  let {
9
9
  $flag_reset,
10
+ shouldReset,
10
11
  $flag_dotted,
12
+ isDotted,
11
13
  $ui_size,
14
+ size,
12
15
  $ui_lineClamp,
16
+ lineClamp,
13
17
  $ui_lineHeight,
18
+ lineHeight,
14
19
  $ui_display,
20
+ display,
15
21
  $ui_weight,
22
+ weight,
16
23
  $ui_typeFace,
24
+ typeFace,
17
25
  $ui_textAlign,
26
+ textAlign,
18
27
  $ui_letterSpacing,
28
+ letterSpacing,
19
29
  $ui_transform,
30
+ transform,
20
31
  $ui_decoration,
32
+ decoration,
21
33
  $ui_className,
34
+ customClass,
22
35
  $ui_wordBreak,
36
+ wordBreak,
23
37
  $ui_wordWrap,
24
- $ui_whiteSpace
38
+ wordWrap,
39
+ $ui_whiteSpace,
40
+ whiteSpace
25
41
  } = props;
42
+ const finalReset = shouldReset !== undefined ? shouldReset : $flag_reset;
43
+ const finalDotted = isDotted !== undefined ? isDotted : $flag_dotted;
44
+ const finalSize = size !== undefined ? size : $ui_size;
45
+ const finalLineClamp = lineClamp !== undefined ? lineClamp : $ui_lineClamp;
46
+ const finalDisplay = display !== undefined ? display : $ui_display;
47
+ const finalWeight = weight !== undefined ? weight : $ui_weight;
48
+ const finalTypeFace = typeFace !== undefined ? typeFace : $ui_typeFace;
49
+ const finalTextAlign = textAlign !== undefined ? textAlign : $ui_textAlign;
50
+ const finalTransform = transform !== undefined ? transform : $ui_transform;
51
+ const finalDecoration = decoration !== undefined ? decoration : $ui_decoration;
52
+ const finalClassName = customClass !== undefined ? customClass : $ui_className;
53
+ const finalWordBreak = wordBreak !== undefined ? wordBreak : $ui_wordBreak;
54
+ const finalWordWrap = wordWrap !== undefined ? wordWrap : $ui_wordWrap;
55
+ const finalWhiteSpace = whiteSpace !== undefined ? whiteSpace : $ui_whiteSpace;
56
+ let finalLineHeight = lineHeight !== undefined ? lineHeight : $ui_lineHeight;
57
+ let finalLetterSpacing = letterSpacing !== undefined ? letterSpacing : $ui_letterSpacing;
26
58
 
27
- if ($ui_letterSpacing) {
28
- $ui_letterSpacing = letterspacingMapping[$ui_letterSpacing];
59
+ if (finalLetterSpacing) {
60
+ finalLetterSpacing = letterspacingMapping[finalLetterSpacing];
29
61
  }
30
62
 
31
- if ($ui_lineHeight) {
32
- $ui_lineHeight = lineheightMapping[$ui_lineHeight];
63
+ if (finalLineHeight) {
64
+ finalLineHeight = lineheightMapping[finalLineHeight];
33
65
  }
34
66
 
35
67
  let typographyClass = compileClassNames({
36
- [style.reset]: $flag_reset,
37
- [style.dotted]: $flag_dotted,
38
- [style[`size${$ui_size}`]]: !!$ui_size,
39
- [style[`lineclamp_${$ui_lineClamp}`]]: !!$ui_lineClamp,
40
- [style[`lineheight_${$ui_lineHeight}`]]: !!$ui_lineHeight,
41
- [style[`display_${$ui_display}`]]: !!$ui_display,
42
- [style[`font_${$ui_weight}`]]: !!$ui_weight,
43
- [style[`fontStyles_${$ui_typeFace}`]]: !!$ui_typeFace,
44
- [style[`textalign_${$ui_textAlign}`]]: !!$ui_textAlign,
45
- [style[`letterspacing_${$ui_letterSpacing}`]]: !!$ui_letterSpacing,
46
- [style[`transform_${$ui_transform}`]]: !!$ui_transform,
47
- [style[`decoration_${$ui_decoration}`]]: !!$ui_decoration,
48
- [$ui_className]: !!$ui_className,
49
- [style[`wordBreak_${$ui_wordBreak}`]]: !!$ui_wordBreak,
50
- [style[`wordWrap_${$ui_wordWrap}`]]: !!$ui_wordWrap,
51
- [style[`whiteSpace_${$ui_whiteSpace}`]]: !!$ui_whiteSpace
68
+ [style.reset]: finalReset,
69
+ [style.dotted]: finalDotted,
70
+ [style[`size${finalSize}`]]: !!finalSize,
71
+ [style[`lineclamp_${finalLineClamp}`]]: !!finalLineClamp,
72
+ [style[`lineheight_${finalLineHeight}`]]: !!finalLineHeight,
73
+ [style[`display_${finalDisplay}`]]: !!finalDisplay,
74
+ [style[`font_${finalWeight}`]]: !!finalWeight,
75
+ [style[`fontStyles_${finalTypeFace}`]]: !!finalTypeFace,
76
+ [style[`textalign_${finalTextAlign}`]]: !!finalTextAlign,
77
+ [style[`letterspacing_${finalLetterSpacing}`]]: !!finalLetterSpacing,
78
+ [style[`transform_${finalTransform}`]]: !!finalTransform,
79
+ [style[`decoration_${finalDecoration}`]]: !!finalDecoration,
80
+ [finalClassName]: !!finalClassName,
81
+ [style[`wordBreak_${finalWordBreak}`]]: !!finalWordBreak,
82
+ [style[`wordWrap_${finalWordWrap}`]]: !!finalWordWrap,
83
+ [style[`whiteSpace_${finalWhiteSpace}`]]: !!finalWhiteSpace
52
84
  });
53
85
  return {
54
86
  typographyClass
@@ -1,9 +1,10 @@
1
+ import { DUMMY_OBJECT } from '@zohodesk/dotkit/es/utils/constants';
1
2
  export const defaultProps = {
2
3
  $ui_className: '',
3
4
  $ui_tagName: 'div',
4
5
  $flag_reset: false,
5
6
  $flag_dotted: false,
6
- $tagAttributes_text: {},
7
- $a11yAttributes_text: {},
8
- $ui_highlightConfig: {}
7
+ $tagAttributes_text: DUMMY_OBJECT,
8
+ $a11yAttributes_text: DUMMY_OBJECT,
9
+ $ui_highlightConfig: DUMMY_OBJECT
9
10
  };
@@ -1,46 +1,88 @@
1
- import PropTypes from 'prop-types';
1
+ import PropTypes from 'prop-types'; // Define prop types once to avoid duplication
2
+
3
+ const propTypeDefinitions = {
4
+ shouldReset: PropTypes.bool,
5
+ display: PropTypes.oneOf(['block', 'inlineBlock', 'inline', 'initial']),
6
+ weight: PropTypes.oneOf(['regular', 'light', 'semibold', 'bold']),
7
+ isDotted: PropTypes.bool,
8
+ textAlign: PropTypes.oneOf(['left', 'right', 'center', 'justify']),
9
+ transform: PropTypes.oneOf(['default', 'upper', 'lower', 'capital']),
10
+ lineClamp: PropTypes.oneOf(['1', '2', '3', '4', '5']),
11
+ typeFace: PropTypes.oneOf(['normal', 'italic']),
12
+ decoration: PropTypes.oneOf(['default', 'underline', 'strike', 'overline']),
13
+ size: PropTypes.oneOf(['7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '24', '25', '26', '28', '29', '30', '32', '34', '35', '36', '40', '50', 'inherit']),
14
+ lineHeight: PropTypes.oneOf(['0', '0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2', 'normal', 'initial', 'inherit']),
15
+ letterSpacing: PropTypes.oneOf(['0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2', 'inherit']),
16
+ wordBreak: PropTypes.oneOf(['breakAll', 'keepAll', 'breakWord']),
17
+ wordWrap: PropTypes.oneOf(['normal', 'break']),
18
+ whiteSpace: PropTypes.oneOf(['normal', 'noWrap', 'pre', 'preLine', 'preWrap', 'breakSpaces']),
19
+ customClass: PropTypes.string
20
+ };
2
21
  const typoStyleProps = {
3
- $flag_reset: PropTypes.bool,
4
- $flag_dotted: PropTypes.bool,
5
- $ui_display: PropTypes.oneOf(['block', 'inlineBlock', 'inline', 'initial']),
6
- $ui_weight: PropTypes.oneOf(['regular', 'light', 'semibold', 'bold']),
7
- $ui_textAlign: PropTypes.oneOf(['left', 'right', 'center', 'justify']),
8
- $ui_transform: PropTypes.oneOf(['default', 'upper', 'lower', 'capital']),
9
- $ui_lineClamp: PropTypes.oneOf(['1', '2', '3', '4', '5']),
10
- $ui_typeFace: PropTypes.oneOf(['normal', 'italic']),
11
- $ui_decoration: PropTypes.oneOf(['default', 'underline', 'strike', 'overline']),
12
- $ui_size: PropTypes.oneOf(['7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '24', '25', '26', '28', '29', '30', '32', '34', '35', '36', '40', '50', 'inherit']),
13
- $ui_lineHeight: PropTypes.oneOf(['0', '0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2', 'normal', 'initial', 'inherit']),
14
- $ui_letterSpacing: PropTypes.oneOf(['0.1', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1', '1.1', '1.2', '1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '2', 'inherit']),
15
- $ui_wordBreak: PropTypes.oneOf(['breakAll', 'keepAll', 'breakWord']),
16
- $ui_wordWrap: PropTypes.oneOf(['normal', 'break']),
17
- $ui_whiteSpace: PropTypes.oneOf(['normal', 'noWrap', 'pre', 'preLine', 'preWrap']),
18
- $ui_className: PropTypes.string
22
+ $flag_reset: propTypeDefinitions.shouldReset,
23
+ shouldReset: propTypeDefinitions.shouldReset,
24
+ $flag_dotted: propTypeDefinitions.isDotted,
25
+ isDotted: propTypeDefinitions.isDotted,
26
+ $ui_display: propTypeDefinitions.display,
27
+ display: propTypeDefinitions.display,
28
+ $ui_weight: propTypeDefinitions.weight,
29
+ weight: propTypeDefinitions.weight,
30
+ $ui_textAlign: propTypeDefinitions.textAlign,
31
+ textAlign: propTypeDefinitions.textAlign,
32
+ $ui_transform: propTypeDefinitions.transform,
33
+ transform: propTypeDefinitions.transform,
34
+ $ui_lineClamp: propTypeDefinitions.lineClamp,
35
+ lineClamp: propTypeDefinitions.lineClamp,
36
+ $ui_typeFace: propTypeDefinitions.typeFace,
37
+ typeFace: propTypeDefinitions.typeFace,
38
+ $ui_decoration: propTypeDefinitions.decoration,
39
+ decoration: propTypeDefinitions.decoration,
40
+ $ui_size: propTypeDefinitions.size,
41
+ size: propTypeDefinitions.size,
42
+ $ui_lineHeight: propTypeDefinitions.lineHeight,
43
+ lineHeight: propTypeDefinitions.lineHeight,
44
+ $ui_letterSpacing: propTypeDefinitions.letterSpacing,
45
+ letterSpacing: propTypeDefinitions.letterSpacing,
46
+ $ui_wordBreak: propTypeDefinitions.wordBreak,
47
+ wordBreak: propTypeDefinitions.wordBreak,
48
+ $ui_wordWrap: propTypeDefinitions.wordWrap,
49
+ wordWrap: propTypeDefinitions.wordWrap,
50
+ $ui_whiteSpace: propTypeDefinitions.whiteSpace,
51
+ whiteSpace: propTypeDefinitions.whiteSpace,
52
+ $ui_className: propTypeDefinitions.customClass,
53
+ customClass: propTypeDefinitions.customClass
19
54
  };
20
55
  const highlightProps = {
21
56
  customStyle: PropTypes.object,
22
57
  shouldExcludeIndices: PropTypes.bool,
23
58
  isCaseSensitive: PropTypes.bool,
24
59
  isWholeWord: PropTypes.bool,
25
- tagName: PropTypes.string,
60
+ as: PropTypes.string,
26
61
  renderHighlight: PropTypes.oneOfType([PropTypes.func, PropTypes.node]),
27
62
  styleConfiguration: PropTypes.shape(typoStyleProps)
28
63
  };
64
+ const highlightDataItemShape = PropTypes.shape({
65
+ text: PropTypes.string,
66
+ index: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.number), PropTypes.number]),
67
+ ...highlightProps
68
+ });
69
+ const highlightConfigShape = PropTypes.shape({
70
+ data: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, highlightDataItemShape])),
71
+ ...highlightProps
72
+ });
29
73
  export const propTypes = { ...typoStyleProps,
30
74
  children: PropTypes.node,
31
75
  $ui_tagName: PropTypes.string,
76
+ as: PropTypes.string,
32
77
  $i18n_dataTitle: PropTypes.string,
78
+ dataTitle: PropTypes.string,
33
79
  testId: PropTypes.string,
34
80
  customId: PropTypes.string,
35
81
  customStyle: PropTypes.object,
36
82
  $a11yAttributes_text: PropTypes.object,
83
+ a11yAttributes: PropTypes.object,
37
84
  $tagAttributes_text: PropTypes.object,
38
- $ui_highlightConfig: PropTypes.shape({
39
- data: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.shape({
40
- text: PropTypes.string,
41
- index: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.number), PropTypes.number]),
42
- ...highlightProps
43
- })])),
44
- ...highlightProps
45
- })
85
+ tagAttributes: PropTypes.object,
86
+ $ui_highlightConfig: highlightConfigShape,
87
+ highlightConfig: highlightConfigShape
46
88
  };
@@ -11,7 +11,7 @@ export function highlightText(config) {
11
11
  shouldExcludeIndices = false,
12
12
  isCaseSensitive: enableCaseSensitiveMatch = false,
13
13
  isWholeWord: matchWholeWordOnly = false,
14
- tagName: wrapperTagName = 'span',
14
+ as: wrapperTagName = 'span',
15
15
  renderHighlight: customRenderer
16
16
  } = config;
17
17
 
@@ -55,7 +55,7 @@ export function highlightText(config) {
55
55
  shouldExcludeIndices: itemConfiguration.shouldExcludeIndices !== undefined ? itemConfiguration.shouldExcludeIndices : shouldExcludeIndices,
56
56
  isCaseSensitive: itemConfiguration.isCaseSensitive !== undefined ? itemConfiguration.isCaseSensitive : enableCaseSensitiveMatch,
57
57
  matchWholeWordOnly: itemConfiguration.isWholeWord !== undefined ? itemConfiguration.isWholeWord : matchWholeWordOnly,
58
- wrapperTagName: itemConfiguration.tagName !== undefined ? itemConfiguration.tagName : wrapperTagName,
58
+ wrapperTagName: itemConfiguration.as !== undefined ? itemConfiguration.as : wrapperTagName,
59
59
  customStyle: customStyle,
60
60
  customRenderer: itemConfiguration.renderHighlight !== undefined ? itemConfiguration.renderHighlight : customRenderer,
61
61
  highlightClasses: typographyClass,
@@ -1,8 +1,8 @@
1
1
  /*Avatar common Sizes*/
2
2
  .varClass {
3
3
  /* avatar size default variables */
4
- --avatar_width: 34px;
5
- --avatar_height: 34px;
4
+ --avatar_width: var(--zd_size34);
5
+ --avatar_height: var(--zd_size34);
6
6
  }
7
7
  .small,
8
8
  .xsmall,
@@ -16,34 +16,34 @@
16
16
  height: var(--avatar_height);
17
17
  }
18
18
  .small {
19
- --avatar_height: 22px;
20
- --avatar_width: 22px;
19
+ --avatar_height: var(--zd_size22);
20
+ --avatar_width: var(--zd_size22);
21
21
  }
22
22
  .xxsmall {
23
- --avatar_height: 18px;
24
- --avatar_width: 18px;
23
+ --avatar_height: var(--zd_size18);
24
+ --avatar_width: var(--zd_size18);
25
25
  }
26
26
  .xsmall {
27
- --avatar_height: 30px;
28
- --avatar_width: 30px;
27
+ --avatar_height: var(--zd_size30);
28
+ --avatar_width: var(--zd_size30);
29
29
  }
30
30
 
31
31
  .medium {
32
- --avatar_height: 34px;
33
- --avatar_width: 34px;
32
+ --avatar_height: var(--zd_size34);
33
+ --avatar_width: var(--zd_size34);
34
34
  }
35
35
 
36
36
  .xmedium {
37
- --avatar_height: 40px;
38
- --avatar_width: 40px;
37
+ --avatar_height: var(--zd_size40);
38
+ --avatar_width: var(--zd_size40);
39
39
  }
40
40
 
41
41
  .large {
42
- --avatar_height: 60px;
43
- --avatar_width: 60px;
42
+ --avatar_height: var(--zd_size60);
43
+ --avatar_width: var(--zd_size60);
44
44
  }
45
45
 
46
46
  .xlarge {
47
- --avatar_height: 80px;
48
- --avatar_width: 80px;
47
+ --avatar_height: var(--zd_size80);
48
+ --avatar_width: var(--zd_size80);
49
49
  }
@@ -59,12 +59,12 @@
59
59
 
60
60
  .padding_small,
61
61
  .padding_xmedium {
62
- --local_padding: 3px;
62
+ --local_padding: var(--zd_size3);
63
63
  }
64
64
 
65
65
  .padding_medium,
66
66
  .padding_large {
67
- --local_padding: 8px;
67
+ --local_padding: var(--zd_size8);
68
68
  }
69
69
 
70
70
  .xmedium {
@@ -4,47 +4,47 @@
4
4
  gap: var(--zd_size6) ;
5
5
  }
6
6
  .small {
7
- --local-switch-track-width: 22px;
8
- --local-switch-track-height: 12px;
7
+ --local-switch-track-width: var(--zd_size22);
8
+ --local-switch-track-height: var(--zd_size12);
9
9
  --local-switch-track-border-radius: 8px;
10
- --local-switch-thumb-size: 10px;
11
- --local-switch-onLabel-height: 6px;
12
- --local-switch-onLabel-left: 5px;
13
- --local-switch-offLabel-size: 7px;
14
- --local-switch-offLabel-right: 2px;
10
+ --local-switch-thumb-size: var(--zd_size10);
11
+ --local-switch-onLabel-height: var(--zd_size6);
12
+ --local-switch-onLabel-left: var(--zd_size5);
13
+ --local-switch-offLabel-size: var(--zd_size7);
14
+ --local-switch-offLabel-right: var(--zd_size2);
15
15
  --local-switch-onLabel-scaleX: 1.2;
16
16
  }
17
17
  .medium {
18
- --local-switch-track-width: 28px;
19
- --local-switch-track-height: 16px;
18
+ --local-switch-track-width: var(--zd_size28);
19
+ --local-switch-track-height: var(--zd_size16);
20
20
  --local-switch-track-border-radius: 16px;
21
- --local-switch-thumb-size: 14px;
22
- --local-switch-onLabel-height: 8px;
23
- --local-switch-onLabel-left: 6px;
24
- --local-switch-offLabel-size: 8px;
25
- --local-switch-offLabel-right: 3px;
21
+ --local-switch-thumb-size: var(--zd_size14);
22
+ --local-switch-onLabel-height: var(--zd_size8);
23
+ --local-switch-onLabel-left: var(--zd_size6);
24
+ --local-switch-offLabel-size: var(--zd_size8);
25
+ --local-switch-offLabel-right: var(--zd_size3);
26
26
  --local-switch-onLabel-scaleX: 1.4;
27
27
  }
28
28
  .large {
29
- --local-switch-track-width: 34px;
30
- --local-switch-track-height: 20px;
29
+ --local-switch-track-width: var(--zd_size34);
30
+ --local-switch-track-height: var(--zd_size20);
31
31
  --local-switch-track-border-radius: 10px;
32
- --local-switch-thumb-size: 18px;
33
- --local-switch-onLabel-height: 10px;
34
- --local-switch-onLabel-left: 7px;
35
- --local-switch-offLabel-size: 9px;
36
- --local-switch-offLabel-right: 4px;
32
+ --local-switch-thumb-size: var(--zd_size18);
33
+ --local-switch-onLabel-height: var(--zd_size10);
34
+ --local-switch-onLabel-left: var(--zd_size7);
35
+ --local-switch-offLabel-size: var(--zd_size9);
36
+ --local-switch-offLabel-right: var(--zd_size4);
37
37
  --local-switch-onLabel-scaleX: 1.6;
38
38
  }
39
39
  .xlarge {
40
- --local-switch-track-width: 40px;
41
- --local-switch-track-height: 24px;
40
+ --local-switch-track-width: var(--zd_size40);
41
+ --local-switch-track-height: var(--zd_size24);
42
42
  --local-switch-track-border-radius: 12px;
43
- --local-switch-thumb-size: 22px;
44
- --local-switch-onLabel-height: 12px;
45
- --local-switch-onLabel-left: 8px;
46
- --local-switch-offLabel-size: 10px;
47
- --local-switch-offLabel-right: 5px;
43
+ --local-switch-thumb-size: var(--zd_size22);
44
+ --local-switch-onLabel-height: var(--zd_size12);
45
+ --local-switch-onLabel-left: var(--zd_size8);
46
+ --local-switch-offLabel-size: var(--zd_size10);
47
+ --local-switch-offLabel-right: var(--zd_size5);
48
48
  --local-switch-onLabel-scaleX: 1.8;
49
49
  }
50
50
  .disabled, .readonly {
@@ -1,7 +1,7 @@
1
1
  .varClass {
2
2
  /* avatar default variables */
3
3
  --avatar_text_color: var(--zdt_avatar_default_text);
4
- --avatar_font_size: 14px;
4
+ --avatar_font_size: var(--zd_font_size14);
5
5
  --avatar_bg_color: var(--zdt_avatar_default_bg);
6
6
  --avatar_border_radius: 50%;
7
7
  --avatar_border_width: 0;
@@ -141,31 +141,31 @@
141
141
  }
142
142
 
143
143
  .xxsmall {
144
- --avatar_font_size: 8px;
144
+ --avatar_font_size: var(--zd_font_size8);
145
145
  }
146
146
 
147
147
  .small {
148
- --avatar_font_size: 9px;
148
+ --avatar_font_size: var(--zd_font_size9);
149
149
  }
150
150
 
151
151
  .xsmall {
152
- --avatar_font_size: 12px;
152
+ --avatar_font_size: var(--zd_font_size12);
153
153
  }
154
154
 
155
155
  .medium {
156
- --avatar_font_size: 14px;
156
+ --avatar_font_size: var(--zd_font_size14);
157
157
  }
158
158
 
159
159
  .xmedium {
160
- --avatar_font_size: 14px;
160
+ --avatar_font_size: var(--zd_font_size14);
161
161
  }
162
162
 
163
163
  .large {
164
- --avatar_font_size: 18px;
164
+ --avatar_font_size: var(--zd_font_size18);
165
165
  }
166
166
 
167
167
  .xlarge {
168
- --avatar_font_size: 28px;
168
+ --avatar_font_size: var(--zd_font_size28);
169
169
  }
170
170
 
171
171
  .white {
@@ -7,13 +7,13 @@
7
7
  --avatarteam_outline_style: solid;
8
8
  --avatarteam_outline_color: var(--zdt_avatarteam_innerCircle);
9
9
  --avatarteam_bg_color: var(--zdt_avatarteam_default_bg);
10
- --avatarteam_width: 5px;
11
- --avatarteam_height: 5px;
10
+ --avatarteam_width: var(--zd_size5);
11
+ --avatarteam_height: var(--zd_size5);
12
12
  --avatarteam_border_radius: 50%;
13
13
  --avatarteam_bottom_top: initial;
14
14
  --avatarteam_bottom_left: initial;
15
15
  --avatarteam_bottom_right: initial;
16
- --avatarteam_top_top: 1px;
16
+ --avatarteam_top_top: var(--zd_size1);
17
17
  }
18
18
  .container {
19
19
  position: relative;
@@ -92,18 +92,18 @@
92
92
  .smallteam,
93
93
  .xsmallteam,
94
94
  .xxsmallteam {
95
- --avatarteam_height: 3px;
96
- --avatarteam_width: 3px;
95
+ --avatarteam_height: var(--zd_size3);
96
+ --avatarteam_width: var(--zd_size3);
97
97
  }
98
98
  .mediumteam,
99
99
  .xmediumteam {
100
- --avatarteam_height: 5px;
101
- --avatarteam_width: 5px;
100
+ --avatarteam_height: var(--zd_size5);
101
+ --avatarteam_width: var(--zd_size5);
102
102
  }
103
103
  .largeteam,
104
104
  .xlargeteam {
105
- --avatarteam_height: 7px;
106
- --avatarteam_width: 7px;
105
+ --avatarteam_height: var(--zd_size7);
106
+ --avatarteam_width: var(--zd_size7);
107
107
  }
108
108
 
109
109
  .xxsmallteam {
@@ -112,78 +112,78 @@
112
112
  }
113
113
  .xxsmallteam::after,
114
114
  .xxsmallteam:before {
115
- --avatarteam_bottom_top: 13px;
115
+ --avatarteam_bottom_top: var(--zd_size13);
116
116
  }
117
117
  .xxsmallteam:after {
118
- --avatarteam_bottom_left: -8px;
118
+ --avatarteam_bottom_left: calc( var(--zd_size8) * -1 );
119
119
  }
120
120
  .xxsmallteam:before {
121
- --avatarteam_bottom_right: -8px;
121
+ --avatarteam_bottom_right: calc( var(--zd_size8) * -1 );
122
122
  }
123
123
 
124
124
 
125
125
  .smallteam::after,
126
126
  .smallteam:before {
127
- --avatarteam_bottom_top: 17px;
127
+ --avatarteam_bottom_top: var(--zd_size17);
128
128
  }
129
129
  .smallteam:after {
130
- --avatarteam_bottom_left: -8px;
130
+ --avatarteam_bottom_left: calc( var(--zd_size8) * -1 );
131
131
  }
132
132
  .smallteam:before {
133
- --avatarteam_bottom_right: -8px;
133
+ --avatarteam_bottom_right: calc( var(--zd_size8) * -1 );
134
134
  }
135
135
 
136
136
  .xsmallteam::after,
137
137
  .xsmallteam:before {
138
- --avatarteam_bottom_top: 24px;
138
+ --avatarteam_bottom_top: var(--zd_size24);
139
139
  }
140
140
  .xsmallteam:after {
141
- --avatarteam_bottom_left: -10px;
141
+ --avatarteam_bottom_left: calc( var(--zd_size10) * -1 );
142
142
  }
143
143
  .xsmallteam:before {
144
- --avatarteam_bottom_right: -10px;
144
+ --avatarteam_bottom_right: calc( var(--zd_size10) * -1 );
145
145
  }
146
146
 
147
147
  .mediumteam::after,
148
148
  .mediumteam:before {
149
- --avatarteam_bottom_top: 26px;
149
+ --avatarteam_bottom_top: var(--zd_size26);
150
150
  }
151
151
  .mediumteam:after {
152
- --avatarteam_bottom_left: -13px;
152
+ --avatarteam_bottom_left: calc( var(--zd_size13) * -1 );
153
153
  }
154
154
  .mediumteam:before {
155
- --avatarteam_bottom_right: -13px;
155
+ --avatarteam_bottom_right: calc( var(--zd_size13) * -1 );
156
156
  }
157
157
 
158
158
  .xmediumteam::after,
159
159
  .xmediumteam:before {
160
- --avatarteam_bottom_top: 30px;
160
+ --avatarteam_bottom_top: var(--zd_size30);
161
161
  }
162
162
  .xmediumteam:after {
163
- --avatarteam_bottom_left: -16px;
163
+ --avatarteam_bottom_left: calc( var(--zd_size16) * -1 );
164
164
  }
165
165
  .xmediumteam:before {
166
- --avatarteam_bottom_right: -16px;
166
+ --avatarteam_bottom_right: calc( var(--zd_size16) * -1 );
167
167
  }
168
168
 
169
169
  .largeteam::after,
170
170
  .largeteam:before {
171
- --avatarteam_bottom_top: 46px;
171
+ --avatarteam_bottom_top: var(--zd_size46);
172
172
  }
173
173
  .largeteam:after {
174
- --avatarteam_bottom_left: -24px;
174
+ --avatarteam_bottom_left: calc( var(--zd_size24) * -1 );
175
175
  }
176
176
  .largeteam:before {
177
- --avatarteam_bottom_right: -24px;
177
+ --avatarteam_bottom_right: calc( var(--zd_size24) * -1 );
178
178
  }
179
179
 
180
180
  .xlargeteam::after,
181
181
  .xlargeteam:before {
182
- --avatarteam_bottom_top: 65px;
182
+ --avatarteam_bottom_top: var(--zd_size65);
183
183
  }
184
184
  .xlargeteam:after {
185
- --avatarteam_bottom_left: -29px;
185
+ --avatarteam_bottom_left: calc( var(--zd_size29) * -1 );
186
186
  }
187
187
  .xlargeteam:before {
188
- --avatarteam_bottom_right: -29px;
188
+ --avatarteam_bottom_right: calc( var(--zd_size29) * -1 );
189
189
  }