pds-dev-kit-web-test 0.2.1 → 0.2.3

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 (194) hide show
  1. package/README.md +12 -1
  2. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Image/Image.d.ts +8 -0
  3. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Image/Image.js +46 -0
  4. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Image/index.d.ts +2 -0
  5. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Image/index.js +8 -0
  6. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/RichText/RichText.d.ts +2 -3
  7. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/RichText/RichText.js +3 -3
  8. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/RichText/index.d.ts +2 -2
  9. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Text/Text.d.ts +13 -0
  10. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Text/Text.js +63 -0
  11. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Text/index.d.ts +2 -0
  12. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Text/index.js +8 -0
  13. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/TwitterTimeline/TwitterTimeline.d.ts +3 -11
  14. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/TwitterTimeline/TwitterTimeline.js +18 -18
  15. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/TwitterTimeline/TwitterTimelineRerender.d.ts +14 -0
  16. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/TwitterTimeline/TwitterTimelineRerender.js +41 -0
  17. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Wrapper/Wrapper.d.ts +35 -0
  18. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Wrapper/Wrapper.js +141 -0
  19. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Wrapper/constants.d.ts +2 -0
  20. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Wrapper/constants.js +33 -0
  21. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Wrapper/index.d.ts +1 -0
  22. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/Wrapper/index.js +8 -0
  23. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/index.d.ts +3 -2
  24. package/dist/src/sub/DynamicLayout/components/ComponentBlocks/index.js +3 -1
  25. package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/EditModeSectionMatcher.js +3 -3
  26. package/dist/src/sub/DynamicLayout/components/Section/Section.d.ts +6 -3
  27. package/dist/src/sub/DynamicLayout/components/Section/Section.js +40 -8
  28. package/dist/src/sub/DynamicLayout/components/Section/components/CustomSectionBackgroundMedia.d.ts +9 -0
  29. package/dist/src/sub/DynamicLayout/components/Section/components/CustomSectionBackgroundMedia.js +68 -0
  30. package/dist/src/sub/DynamicLayout/components/SectionMatcher/SectionMatcher.js +4 -4
  31. package/dist/src/sub/DynamicLayout/components/index.d.ts +0 -1
  32. package/dist/src/sub/DynamicLayout/components/index.js +1 -6
  33. package/dist/src/sub/DynamicLayout/mock_customSection.d.ts +2 -0
  34. package/dist/src/sub/DynamicLayout/mock_customSection.js +838 -0
  35. package/dist/src/sub/DynamicLayout/mock_samplePage.js +5 -210
  36. package/dist/src/sub/DynamicLayout/nakedMocks.json +783 -0
  37. package/dist/src/sub/DynamicLayout/sectionActionTypes.d.ts +17 -4
  38. package/dist/src/sub/DynamicLayout/sections/CustomSection/CustomSection.d.ts +2 -9
  39. package/dist/src/sub/DynamicLayout/sections/CustomSection/CustomSection.js +85 -51
  40. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlock.d.ts +7 -0
  41. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlock.js +55 -0
  42. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlockMatcher.d.ts +3 -0
  43. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlockMatcher.js +70 -0
  44. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/Button.d.ts +5 -0
  45. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/Button.js +73 -0
  46. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/btnTypes.d.ts +68 -0
  47. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/btnTypes.js +2 -0
  48. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Divider.d.ts +5 -0
  49. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Divider.js +66 -0
  50. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Image.d.ts +16 -0
  51. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Image.js +102 -0
  52. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/RichText/RichText.d.ts +5 -0
  53. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/RichText/RichText.js +62 -0
  54. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/RichText/index.d.ts +1 -0
  55. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/RichText/index.js +8 -0
  56. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/RichText/types.d.ts +44 -0
  57. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/RichText/types.js +2 -0
  58. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Text.d.ts +32 -0
  59. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Text.js +58 -0
  60. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Twitter.d.ts +10 -0
  61. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Twitter.js +41 -0
  62. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/Youtube.d.ts +5 -0
  63. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/Youtube.js +69 -0
  64. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/index.d.ts +1 -0
  65. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/index.js +8 -0
  66. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/parseYoutubeContentProp.d.ts +7 -0
  67. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/parseYoutubeContentProp.js +33 -0
  68. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/types.d.ts +48 -0
  69. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Youtube/types.js +2 -0
  70. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_CB_Box.d.ts +2 -0
  71. package/dist/src/sub/DynamicLayout/sections/CustomSection/{BlockMatcher/blocks/Button.js → components/ComponentBlock/componentBlocks/components/S_CB_Box.js} +6 -11
  72. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_HiddenCover.d.ts +1 -0
  73. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_HiddenCover.js +13 -0
  74. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/hooks/useCLINK.d.ts +8 -0
  75. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/hooks/useCLINK.js +24 -0
  76. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/types.d.ts +20 -0
  77. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/types.js +2 -0
  78. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/utils/CLINKhandler.d.ts +0 -0
  79. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/utils/CLINKhandler.js +18 -0
  80. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/index.d.ts +1 -0
  81. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/index.js +8 -0
  82. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/index.d.ts +1 -0
  83. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/index.js +5 -0
  84. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/index.d.ts +1 -0
  85. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/index.js +5 -0
  86. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useIntersectionObserver.d.ts +6 -0
  87. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useIntersectionObserver.js +26 -0
  88. package/dist/src/sub/DynamicLayout/sections/CustomSection/index.d.ts +0 -1
  89. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/colorUtil.d.ts +31 -0
  90. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/colorUtil.js +66 -0
  91. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/index.d.ts +2 -0
  92. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/index.js +10 -0
  93. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/replaceUndefinedValues.d.ts +2 -0
  94. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/replaceUndefinedValues.js +46 -0
  95. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/textUtil.d.ts +18 -0
  96. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/textUtil.js +79 -0
  97. package/dist/src/sub/DynamicLayout/sections/CustomSection/types.d.ts +50 -81
  98. package/dist/src/sub/DynamicLayout/sections/CustomSection/types.js +11 -12
  99. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/contentPropParsers/index.d.ts +3 -0
  100. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/contentPropParsers/index.js +16 -0
  101. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/contentPropParsers/parseContentVisibility.d.ts +12 -0
  102. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/contentPropParsers/parseContentVisibility.js +18 -0
  103. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/contentPropParsers/types.d.ts +5 -0
  104. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/contentPropParsers/types.js +7 -0
  105. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/constants.d.ts +4 -0
  106. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/constants.js +46 -0
  107. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/index.d.ts +3 -0
  108. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/index.js +16 -0
  109. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/parseEffectPropEntAnim.d.ts +19 -0
  110. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/parseEffectPropEntAnim.js +51 -0
  111. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/types.d.ts +5 -0
  112. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/effectPropParsers/types.js +7 -0
  113. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/index.d.ts +6 -0
  114. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/index.js +18 -0
  115. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/index.d.ts +3 -0
  116. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/index.js +19 -0
  117. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/parseLayoutPropArrange.d.ts +24 -0
  118. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/parseLayoutPropArrange.js +80 -0
  119. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/parseLayoutPropPadding.d.ts +21 -0
  120. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/parseLayoutPropPadding.js +32 -0
  121. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/types.d.ts +7 -0
  122. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/layoutPropParsers/types.js +8 -0
  123. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parseJsonProperties.d.ts +3 -0
  124. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parseJsonProperties.js +61 -0
  125. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parsePlacement.d.ts +20 -0
  126. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parsePlacement.js +46 -0
  127. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parseProperties.d.ts +5 -0
  128. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parseProperties.js +54 -0
  129. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/index.d.ts +3 -0
  130. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/index.js +41 -0
  131. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBgColor.d.ts +43 -0
  132. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBgColor.js +58 -0
  133. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBgImage.d.ts +19 -0
  134. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBgImage.js +118 -0
  135. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBgOverlay.d.ts +43 -0
  136. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBgOverlay.js +64 -0
  137. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBorder.d.ts +38 -0
  138. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropBorder.js +73 -0
  139. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropDivider.d.ts +26 -0
  140. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropDivider.js +65 -0
  141. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropImage.d.ts +19 -0
  142. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropImage.js +118 -0
  143. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropOpacity.d.ts +15 -0
  144. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropOpacity.js +41 -0
  145. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropShadow.d.ts +39 -0
  146. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropShadow.js +46 -0
  147. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropTextSpec.d.ts +39 -0
  148. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropTextSpec.js +80 -0
  149. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/types.d.ts +22 -0
  150. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/types.js +16 -0
  151. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/types.d.ts +134 -0
  152. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/types.js +2 -0
  153. package/dist/src/sub/DynamicLayout/sections/index.d.ts +1 -0
  154. package/dist/src/sub/DynamicLayout/sections/index.js +3 -1
  155. package/dist/src/sub/DynamicLayout/types.d.ts +70 -4
  156. package/package.json +2 -3
  157. package/release-note.md +2 -2
  158. package/dist/src/sub/DynamicLayout/components/Box.d.ts +0 -13
  159. package/dist/src/sub/DynamicLayout/components/Box.js +0 -73
  160. package/dist/src/sub/DynamicLayout/custonSectionSampleData.d.ts +0 -218
  161. package/dist/src/sub/DynamicLayout/custonSectionSampleData.js +0 -198
  162. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/BlockMatcher.d.ts +0 -11
  163. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/BlockMatcher.js +0 -71
  164. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Accordion.d.ts +0 -12
  165. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Accordion.js +0 -46
  166. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionBody.d.ts +0 -8
  167. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionBody.js +0 -74
  168. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionCore.d.ts +0 -13
  169. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionCore.js +0 -25
  170. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionHeader.d.ts +0 -7
  171. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionHeader.js +0 -49
  172. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionItem.d.ts +0 -7
  173. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/AccordionItem.js +0 -19
  174. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/index.d.ts +0 -4
  175. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/AccordionCore/index.js +0 -14
  176. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Button.d.ts +0 -8
  177. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Divider.d.ts +0 -7
  178. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Divider.js +0 -29
  179. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Image.d.ts +0 -7
  180. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Image.js +0 -18
  181. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Instagram.d.ts +0 -7
  182. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Instagram.js +0 -19
  183. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/RichText.d.ts +0 -7
  184. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/RichText.js +0 -9
  185. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Text.d.ts +0 -7
  186. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Text.js +0 -29
  187. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Twitter.d.ts +0 -7
  188. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Twitter.js +0 -30
  189. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Youtube.d.ts +0 -9
  190. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/Youtube.js +0 -38
  191. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/index.d.ts +0 -9
  192. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/blocks/index.js +0 -24
  193. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/index.d.ts +0 -1
  194. package/dist/src/sub/DynamicLayout/sections/CustomSection/BlockMatcher/index.js +0 -8
@@ -0,0 +1,43 @@
1
+ import type { Device, ENUM_STRING, NUMBER_INTEGER, OverlayStyleAndOverlayHoverStyle, STRING_8DIGIT_HEX, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ export declare type NAMED_CB_STYLE_BGOVERLAY_PROPS = {
4
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_BGOVERLAY;
5
+ specs: CB_STYLE_PROP_BGOVERLAY_SPECS;
6
+ };
7
+ export default function parseStylePropBgOverlay(namedProps: NAMED_CB_STYLE_BGOVERLAY_PROPS, device: Device): StyleAndHoverStyle & Partial<OverlayStyleAndOverlayHoverStyle>;
8
+ export declare type CB_STYLE_PROP_BGOVERLAY_SPECS_BASE = {
9
+ CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE: NUMBER_INTEGER;
10
+ CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR: STRING_8DIGIT_HEX;
11
+ CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR: STRING_8DIGIT_HEX;
12
+ CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC: NUMBER_INTEGER;
13
+ CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT: ENUM_STRING;
14
+ CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR: STRING_8DIGIT_HEX;
15
+ CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC: NUMBER_INTEGER;
16
+ CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE: ENUM_STRING;
17
+ };
18
+ export declare type CB_STYLE_PROP_BGOVERLAY_SPECS = CB_STYLE_PROP_BGOVERLAY_SPECS_BASE & {
19
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE:HOVER': NUMBER_INTEGER;
20
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE:MOBILE': NUMBER_INTEGER | undefined;
21
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE:MOBILE:HOVER': NUMBER_INTEGER | undefined;
22
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR:HOVER': STRING_8DIGIT_HEX;
23
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR:MOBILE': STRING_8DIGIT_HEX | undefined;
24
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | undefined;
25
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR:HOVER': STRING_8DIGIT_HEX;
26
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR:MOBILE': STRING_8DIGIT_HEX | undefined;
27
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | undefined;
28
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC:HOVER': NUMBER_INTEGER;
29
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC:MOBILE': NUMBER_INTEGER | undefined;
30
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC:MOBILE:HOVER': NUMBER_INTEGER | undefined;
31
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT:HOVER': ENUM_STRING;
32
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT:MOBILE': ENUM_STRING | undefined;
33
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT:MOBILE:HOVER': ENUM_STRING | undefined;
34
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR:HOVER': STRING_8DIGIT_HEX;
35
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR:MOBILE': STRING_8DIGIT_HEX | undefined;
36
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | undefined;
37
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC:HOVER': NUMBER_INTEGER;
38
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC:MOBILE': NUMBER_INTEGER | undefined;
39
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC:MOBILE:HOVER': NUMBER_INTEGER | undefined;
40
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE:HOVER': ENUM_STRING;
41
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE:MOBILE': ENUM_STRING | undefined;
42
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE:MOBILE:HOVER': ENUM_STRING | undefined;
43
+ };
@@ -0,0 +1,64 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ var AVAILABLE_SPECS = [
15
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE',
16
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR',
17
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR',
18
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC',
19
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT',
20
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR',
21
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC',
22
+ 'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE'
23
+ ];
24
+ function parseStylePropBgOverlay(namedProps, device) {
25
+ var specs = namedProps.specs;
26
+ var bgColorCssProperties = AVAILABLE_SPECS.reduce(function (acc, cur) {
27
+ var _a, _b;
28
+ var baseKey = device === 'DESKTOP' ? cur : cur + ":MOBILE";
29
+ var value = specs[baseKey];
30
+ var hoverValue = specs[baseKey + ":HOVER"];
31
+ return {
32
+ style: __assign({}, acc.style),
33
+ hoverStyle: __assign({}, acc.hoverStyle),
34
+ overlayStyle: __assign(__assign({}, acc.overlayStyle), (_a = {}, _a[baseKey] = value, _a)),
35
+ overlayHoverStyle: __assign(__assign({}, acc.overlayHoverStyle), (_b = {}, _b[baseKey] = hoverValue, _b))
36
+ };
37
+ }, {
38
+ style: {},
39
+ hoverStyle: {},
40
+ overlayStyle: {},
41
+ overlayHoverStyle: {}
42
+ });
43
+ return {
44
+ style: {},
45
+ hoverStyle: {},
46
+ overlayStyle: { background: valueGenerator(bgColorCssProperties.overlayStyle) },
47
+ overlayHoverStyle: { background: valueGenerator(bgColorCssProperties.overlayHoverStyle) }
48
+ };
49
+ }
50
+ exports.default = parseStylePropBgOverlay;
51
+ function valueGenerator(valueSet) {
52
+ var CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE, CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR, CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR, CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC, CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT, CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR, CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC, CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE = valueSet.CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE;
53
+ if (CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE === 'GRADIENT') {
54
+ var isLinear = CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT === 'LINEAR';
55
+ var gradientType = isLinear ? 'linear-gradient' : 'radial-gradient';
56
+ var gradientDegree = isLinear ? CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE + "deg," : '';
57
+ var gradientStartColor = CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR;
58
+ var gradientStartPosition = CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC;
59
+ var gradientEndColor = CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR;
60
+ var gradientEndPosition = CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC;
61
+ return gradientType + "(" + gradientDegree + " " + gradientStartColor + " " + gradientStartPosition + "%, " + gradientEndColor + " " + gradientEndPosition + "%)";
62
+ }
63
+ return "" + CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR;
64
+ }
@@ -0,0 +1,38 @@
1
+ import type { Device, ENUM_STRING, NUMBER_INTEGER, STRING_8DIGIT_HEX, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ export declare type NAMED_CB_STYLE_BORDER_PROPS = {
4
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_BORDER;
5
+ specs: CB_STYLE_PROP_BORDER_SPECS;
6
+ };
7
+ export default function parseStylePropBorder(namedProps: NAMED_CB_STYLE_BORDER_PROPS, device: Device): StyleAndHoverStyle;
8
+ declare type CB_STYLE_PROP_BORDER_SPEC_RADIUS_OBJ = {
9
+ tl: number;
10
+ tr: number;
11
+ bl: number;
12
+ br: number;
13
+ };
14
+ export declare type CB_STYLE_PROP_BORDER_SPECS_BASE = {
15
+ CB_STYLE_PROP_BORDER_SPEC_STYLE: ENUM_STRING;
16
+ CB_STYLE_PROP_BORDER_SPEC_WIDTH: NUMBER_INTEGER;
17
+ CB_STYLE_PROP_BORDER_SPEC_COLOR: STRING_8DIGIT_HEX;
18
+ CB_STYLE_PROP_BORDER_SPEC_RADIUS: CB_STYLE_PROP_BORDER_SPEC_RADIUS_OBJ;
19
+ CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX: boolean;
20
+ };
21
+ export declare type CB_STYLE_PROP_BORDER_SPECS = CB_STYLE_PROP_BORDER_SPECS_BASE & {
22
+ 'CB_STYLE_PROP_BORDER_SPEC_STYLE:HOVER': ENUM_STRING;
23
+ 'CB_STYLE_PROP_BORDER_SPEC_STYLE:MOBILE': ENUM_STRING | undefined;
24
+ 'CB_STYLE_PROP_BORDER_SPEC_STYLE:MOBILE:HOVER': ENUM_STRING | undefined;
25
+ 'CB_STYLE_PROP_BORDER_SPEC_WIDTH:HOVER': NUMBER_INTEGER;
26
+ 'CB_STYLE_PROP_BORDER_SPEC_WIDTH:MOBILE': NUMBER_INTEGER | undefined;
27
+ 'CB_STYLE_PROP_BORDER_SPEC_WIDTH:MOBILE:HOVER': NUMBER_INTEGER | undefined;
28
+ 'CB_STYLE_PROP_BORDER_SPEC_COLOR:HOVER': STRING_8DIGIT_HEX;
29
+ 'CB_STYLE_PROP_BORDER_SPEC_COLOR:MOBILE': STRING_8DIGIT_HEX | undefined;
30
+ 'CB_STYLE_PROP_BORDER_SPEC_COLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | undefined;
31
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUS:HOVER': CB_STYLE_PROP_BORDER_SPEC_RADIUS_OBJ;
32
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUS:MOBILE': CB_STYLE_PROP_BORDER_SPEC_RADIUS_OBJ | undefined;
33
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUS:MOBILE:HOVER': CB_STYLE_PROP_BORDER_SPEC_RADIUS_OBJ | undefined;
34
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX:HOVER': boolean;
35
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX:MOBILE': boolean | undefined;
36
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX:MOBILE:HOVER': boolean | undefined;
37
+ };
38
+ export {};
@@ -0,0 +1,73 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ var AVAILABLE_SPECS = [
15
+ 'CB_STYLE_PROP_BORDER_SPEC_STYLE',
16
+ 'CB_STYLE_PROP_BORDER_SPEC_WIDTH',
17
+ 'CB_STYLE_PROP_BORDER_SPEC_COLOR',
18
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUS',
19
+ 'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX'
20
+ ];
21
+ function parseStylePropBorder(namedProps, device) {
22
+ var specs = namedProps.specs;
23
+ return AVAILABLE_SPECS.reduce(function (acc, cur) {
24
+ var _a, _b;
25
+ var baseKey = device === 'DESKTOP' ? cur : cur + ":MOBILE";
26
+ var cssPropertyKey = getParsedKey(baseKey);
27
+ var value = specs[baseKey];
28
+ var hoverValue = specs[baseKey + ":HOVER"];
29
+ var isRadius = cssPropertyKey === 'borderRadius';
30
+ if (isRadius) {
31
+ var _c = value, tl = _c.tl, tr = _c.tr, bl = _c.bl, br = _c.br;
32
+ var _d = hoverValue, hoverTl = _d.tl, hoverTr = _d.tr, hoverBl = _d.bl, hoverBr = _d.br;
33
+ return {
34
+ style: __assign(__assign({}, acc.style), { borderTopLeftRadius: tl, borderTopRightRadius: tr, borderBottomLeftRadius: bl, borderBottomRightRadius: br }),
35
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), { borderTopLeftRadius: hoverTl, borderTopRightRadius: hoverTr, borderBottomLeftRadius: hoverBl, borderBottomRightRadius: hoverBr })
36
+ };
37
+ }
38
+ return {
39
+ style: __assign(__assign({}, acc.style), (_a = {}, _a[cssPropertyKey] = value, _a)),
40
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), (_b = {}, _b[cssPropertyKey] = hoverValue, _b))
41
+ };
42
+ }, {
43
+ style: {},
44
+ hoverStyle: {}
45
+ });
46
+ }
47
+ exports.default = parseStylePropBorder;
48
+ function getParsedKey(key) {
49
+ switch (key) {
50
+ case 'CB_STYLE_PROP_BORDER_SPEC_STYLE':
51
+ case 'CB_STYLE_PROP_BORDER_SPEC_STYLE:HOVER':
52
+ case 'CB_STYLE_PROP_BORDER_SPEC_STYLE:MOBILE':
53
+ case 'CB_STYLE_PROP_BORDER_SPEC_STYLE:MOBILE:HOVER':
54
+ return 'borderStyle';
55
+ case 'CB_STYLE_PROP_BORDER_SPEC_WIDTH':
56
+ case 'CB_STYLE_PROP_BORDER_SPEC_WIDTH:HOVER':
57
+ case 'CB_STYLE_PROP_BORDER_SPEC_WIDTH:MOBILE':
58
+ case 'CB_STYLE_PROP_BORDER_SPEC_WIDTH:MOBILE:HOVER':
59
+ return 'borderWidth';
60
+ case 'CB_STYLE_PROP_BORDER_SPEC_COLOR':
61
+ case 'CB_STYLE_PROP_BORDER_SPEC_COLOR:HOVER':
62
+ case 'CB_STYLE_PROP_BORDER_SPEC_COLOR:MOBILE':
63
+ case 'CB_STYLE_PROP_BORDER_SPEC_COLOR:MOBILE:HOVER':
64
+ return 'borderColor';
65
+ case 'CB_STYLE_PROP_BORDER_SPEC_RADIUS':
66
+ case 'CB_STYLE_PROP_BORDER_SPEC_RADIUS:HOVER':
67
+ case 'CB_STYLE_PROP_BORDER_SPEC_RADIUS:MOBILE':
68
+ case 'CB_STYLE_PROP_BORDER_SPEC_RADIUS:MOBILE:HOVER':
69
+ return 'borderRadius';
70
+ default:
71
+ return '';
72
+ }
73
+ }
@@ -0,0 +1,26 @@
1
+ import type { Device, ENUM_STRING, NUMBER_INTEGER, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ declare type SpecKeys = keyof CB_STYLE_PROP_DIVIDER_SPECS;
4
+ export declare type NAMED_CB_STYLE_DIVIDER_PROPS = {
5
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_DIVIDER;
6
+ specs: CB_STYLE_PROP_DIVIDER_SPECS;
7
+ };
8
+ export declare type ValueSetType = Partial<Record<SpecKeys, string | number | undefined>>;
9
+ export default function parseStylePropDivider(namedProps: NAMED_CB_STYLE_DIVIDER_PROPS, device: Device): StyleAndHoverStyle;
10
+ export declare type CB_STYLE_PROP_DIVIDER_SPECS_BASE = {
11
+ CB_STYLE_PROP_DIVIDER_SPEC_STYLE: ENUM_STRING;
12
+ CB_STYLE_PROP_DIVIDER_SPEC_WIDTH: NUMBER_INTEGER;
13
+ CB_STYLE_PROP_DIVIDER_SPEC_COLOR: ENUM_STRING;
14
+ };
15
+ export declare type CB_STYLE_PROP_DIVIDER_SPECS = CB_STYLE_PROP_DIVIDER_SPECS_BASE & {
16
+ 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE:HOVER': ENUM_STRING;
17
+ 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE:MOBILE': ENUM_STRING | undefined;
18
+ 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE:MOBILE:HOVER': ENUM_STRING | undefined;
19
+ 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH:HOVER': NUMBER_INTEGER;
20
+ 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH:MOBILE': NUMBER_INTEGER | undefined;
21
+ 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH:MOBILE:HOVER': NUMBER_INTEGER | undefined;
22
+ 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR:HOVER': ENUM_STRING;
23
+ 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR:MOBILE': ENUM_STRING | undefined;
24
+ 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR:MOBILE:HOVER': ENUM_STRING | undefined;
25
+ };
26
+ export {};
@@ -0,0 +1,65 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ var AVAILABLE_SPECS = [
15
+ 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE',
16
+ 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH',
17
+ 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR'
18
+ ];
19
+ function parseStylePropDivider(namedProps, device) {
20
+ var specs = namedProps.specs;
21
+ return AVAILABLE_SPECS.reduce(function (acc, cur) {
22
+ var _a, _b, _c, _d;
23
+ var baseKey = device === 'DESKTOP' ? cur : cur + ":MOBILE";
24
+ var cssPropertyKey = getDividerCSSPropKey(baseKey);
25
+ var value = specs[baseKey];
26
+ var hoverValue = specs[baseKey + ":HOVER"];
27
+ if (cssPropertyKey === 'border-bottom-style') {
28
+ var widthValue = value === 'NONE' ? 'solid' : value;
29
+ var widthHoverValue = hoverValue === 'NONE' ? 'solid' : hoverValue;
30
+ return {
31
+ style: __assign(__assign({}, acc.style), (_a = {}, _a[cssPropertyKey] = widthValue, _a)),
32
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), (_b = {}, _b[cssPropertyKey] = widthHoverValue, _b))
33
+ };
34
+ }
35
+ return {
36
+ style: __assign(__assign({}, acc.style), (_c = {}, _c[cssPropertyKey] = value, _c)),
37
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), (_d = {}, _d[cssPropertyKey] = hoverValue, _d))
38
+ };
39
+ }, {
40
+ style: {},
41
+ hoverStyle: {}
42
+ });
43
+ }
44
+ exports.default = parseStylePropDivider;
45
+ function getDividerCSSPropKey(key) {
46
+ switch (key) {
47
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE':
48
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE:HOVER':
49
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE:MOBILE':
50
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_STYLE:MOBILE:HOVER':
51
+ return 'border-bottom-style';
52
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH':
53
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH:HOVER':
54
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH:MOBILE':
55
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_WIDTH:MOBILE:HOVER':
56
+ return 'border-bottom-width';
57
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR':
58
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR:HOVER':
59
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR:MOBILE':
60
+ case 'CB_STYLE_PROP_DIVIDER_SPEC_COLOR:MOBILE:HOVER':
61
+ return 'border-bottom-color';
62
+ default:
63
+ return '';
64
+ }
65
+ }
@@ -0,0 +1,19 @@
1
+ import type { Device, ENUM_STRING, STRING_PLAIN, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ export declare type NAMED_CB_STYLE_IMAGE_PROPS = {
4
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_IMAGE;
5
+ specs: CB_STYLE_PROP_IMAGE_SPECS;
6
+ };
7
+ export default function parseStylePropImage(namedProps: NAMED_CB_STYLE_IMAGE_PROPS, device: Device): StyleAndHoverStyle;
8
+ export declare type CB_STYLE_PROP_IMAGE_SPECS_BASE = {
9
+ CB_STYLE_PROP_IMAGE_SPEC_FIT: STRING_PLAIN;
10
+ CB_STYLE_PROP_IMAGE_SPEC_POSITION: ENUM_STRING;
11
+ };
12
+ export declare type CB_STYLE_PROP_IMAGE_SPECS = CB_STYLE_PROP_IMAGE_SPECS_BASE & {
13
+ 'CB_STYLE_PROP_IMAGE_SPEC_FIT:HOVER': STRING_PLAIN;
14
+ 'CB_STYLE_PROP_IMAGE_SPEC_FIT:MOBILE': STRING_PLAIN | undefined;
15
+ 'CB_STYLE_PROP_IMAGE_SPEC_FIT:MOBILE:HOVER': STRING_PLAIN | undefined;
16
+ 'CB_STYLE_PROP_IMAGE_SPEC_POSITION:HOVER': ENUM_STRING;
17
+ 'CB_STYLE_PROP_IMAGE_SPEC_POSITION:MOBILE': ENUM_STRING | undefined;
18
+ 'CB_STYLE_PROP_IMAGE_SPEC_POSITION:MOBILE:HOVER': ENUM_STRING | undefined;
19
+ };
@@ -0,0 +1,118 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ var AVAILABLE_SPECS = [
15
+ 'CB_STYLE_PROP_IMAGE_SPEC_FIT',
16
+ 'CB_STYLE_PROP_IMAGE_SPEC_POSITION'
17
+ ];
18
+ function parseStylePropImage(namedProps, device) {
19
+ var specs = namedProps.specs;
20
+ return AVAILABLE_SPECS.reduce(function (acc, cur) {
21
+ var _a, _b;
22
+ var baseKey = device === 'DESKTOP' ? cur : cur + ":MOBILE";
23
+ var cssPropertyKey = getParsedKey(baseKey);
24
+ var value = specs[baseKey];
25
+ var hoverValue = specs[baseKey + ":HOVER"];
26
+ var isPosition = cssPropertyKey === 'position';
27
+ if (isPosition) {
28
+ var positionCss = getCssProperties(value);
29
+ var hoverPositionCss = getCssProperties(hoverValue);
30
+ return {
31
+ style: __assign(__assign({}, acc.style), positionCss),
32
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), hoverPositionCss)
33
+ };
34
+ }
35
+ return {
36
+ style: __assign(__assign({}, acc.style), (_a = {}, _a[cssPropertyKey] = value === null || value === void 0 ? void 0 : value.toLowerCase(), _a)),
37
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), (_b = {}, _b[cssPropertyKey] = hoverValue === null || hoverValue === void 0 ? void 0 : hoverValue.toLowerCase(), _b))
38
+ };
39
+ }, {
40
+ style: {},
41
+ hoverStyle: {}
42
+ });
43
+ }
44
+ exports.default = parseStylePropImage;
45
+ function getParsedKey(key) {
46
+ switch (key) {
47
+ case 'CB_STYLE_PROP_IMAGE_SPEC_FIT':
48
+ case 'CB_STYLE_PROP_IMAGE_SPEC_FIT:HOVER':
49
+ case 'CB_STYLE_PROP_IMAGE_SPEC_FIT:MOBILE':
50
+ case 'CB_STYLE_PROP_IMAGE_SPEC_FIT:MOBILE:HOVER':
51
+ return 'objectFit';
52
+ case 'CB_STYLE_PROP_IMAGE_SPEC_POSITION':
53
+ case 'CB_STYLE_PROP_IMAGE_SPEC_POSITION:HOVER':
54
+ case 'CB_STYLE_PROP_IMAGE_SPEC_POSITION:MOBILE':
55
+ case 'CB_STYLE_PROP_IMAGE_SPEC_POSITION:MOBILE:HOVER':
56
+ return 'position';
57
+ }
58
+ }
59
+ function getCssProperties(value) {
60
+ switch (value) {
61
+ case 'LT':
62
+ return {
63
+ display: 'flex',
64
+ alignItems: 'flex-start',
65
+ justifyContent: 'flex-start'
66
+ };
67
+ case 'CT':
68
+ return {
69
+ display: 'flex',
70
+ alignItems: 'flex-start',
71
+ justifyContent: 'center'
72
+ };
73
+ case 'RT':
74
+ return {
75
+ display: 'flex',
76
+ alignItems: 'flex-start',
77
+ justifyContent: 'flex-end'
78
+ };
79
+ case 'LC':
80
+ return {
81
+ display: 'flex',
82
+ alignItems: 'center',
83
+ justifyContent: 'flex-start'
84
+ };
85
+ case 'CC':
86
+ return {
87
+ display: 'flex',
88
+ alignItems: 'center',
89
+ justifyContent: 'center'
90
+ };
91
+ case 'RC':
92
+ return {
93
+ display: 'flex',
94
+ alignItems: 'center',
95
+ justifyContent: 'flex-end'
96
+ };
97
+ case 'LB':
98
+ return {
99
+ display: 'flex',
100
+ alignItems: 'flex-end',
101
+ justifyContent: 'flex-start'
102
+ };
103
+ case 'CB':
104
+ return {
105
+ display: 'flex',
106
+ alignItems: 'center',
107
+ justifyContent: 'flex-end'
108
+ };
109
+ case 'RB':
110
+ return {
111
+ display: 'flex',
112
+ alignItems: 'flex-end',
113
+ justifyContent: 'flex-end'
114
+ };
115
+ default:
116
+ return {};
117
+ }
118
+ }
@@ -0,0 +1,15 @@
1
+ import type { Device, NUMBER_INTEGER, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ export declare type NAMED_CB_STYLE_OPACITY_PROPS = {
4
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_OPACITY;
5
+ specs: CB_STYLE_PROP_TEXT_OPACITY_SPECS;
6
+ };
7
+ export default function parseStylePropOpacity(namedProps: NAMED_CB_STYLE_OPACITY_PROPS, device: Device): StyleAndHoverStyle;
8
+ export declare type CB_STYLE_PROP_TEXT_OPACITY_BASE = {
9
+ CB_STYLE_PROP_OPACITY_SPEC_OPACITY: NUMBER_INTEGER;
10
+ };
11
+ export declare type CB_STYLE_PROP_TEXT_OPACITY_SPECS = CB_STYLE_PROP_TEXT_OPACITY_BASE & {
12
+ 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:HOVER': NUMBER_INTEGER;
13
+ 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:MOBILE': NUMBER_INTEGER | undefined;
14
+ 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:MOBILE:HOVER': NUMBER_INTEGER | undefined;
15
+ };
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ function parseStylePropOpacity(namedProps, device) {
15
+ var specs = namedProps.specs;
16
+ return AVAILABLE_SPECS.reduce(function (acc, cur) {
17
+ var _a, _b;
18
+ var baseKey = device === 'DESKTOP' ? cur : cur + ":MOBILE";
19
+ var cssPropertyKey = getParsedKey(baseKey);
20
+ var value = specs[baseKey];
21
+ var hoverValue = specs[baseKey + ":HOVER"];
22
+ return {
23
+ style: __assign(__assign({}, acc.style), (_a = {}, _a[cssPropertyKey] = value, _a)),
24
+ hoverStyle: __assign(__assign({}, acc.hoverStyle), (_b = {}, _b[cssPropertyKey] = hoverValue, _b))
25
+ };
26
+ }, {
27
+ style: {},
28
+ hoverStyle: {}
29
+ });
30
+ }
31
+ exports.default = parseStylePropOpacity;
32
+ var AVAILABLE_SPECS = ['CB_STYLE_PROP_OPACITY_SPEC_OPACITY'];
33
+ function getParsedKey(key) {
34
+ switch (key) {
35
+ case 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY':
36
+ case 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:HOVER':
37
+ case 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:MOBILE':
38
+ case 'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:MOBILE:HOVER':
39
+ return 'opacity';
40
+ }
41
+ }
@@ -0,0 +1,39 @@
1
+ import type { Device, ENUM_STRING, NUMBER_INTEGER, STRING_8DIGIT_HEX, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ export declare type NAMED_CB_STYLE_SHADOW_PROPS = {
4
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_SHADOW;
5
+ specs: CB_STYLE_PROP_SHADOW_SPECS;
6
+ };
7
+ export default function parseStylePropShadow(namedProps: NAMED_CB_STYLE_SHADOW_PROPS, device: Device): StyleAndHoverStyle;
8
+ export declare type CB_STYLE_PROP_SHADOW_SPECS_BASE = {
9
+ CB_STYLE_PROP_SHADOW_SPEC_TYPE: ENUM_STRING;
10
+ CB_STYLE_PROP_SHADOW_SPEC_COLOR: STRING_8DIGIT_HEX;
11
+ CB_STYLE_PROP_SHADOW_SPEC_X: NUMBER_INTEGER;
12
+ CB_STYLE_PROP_SHADOW_SPEC_Y: NUMBER_INTEGER;
13
+ CB_STYLE_PROP_SHADOW_SPEC_BLUR: NUMBER_INTEGER;
14
+ CB_STYLE_PROP_SHADOW_SPEC_SPREAD: NUMBER_INTEGER;
15
+ CB_STYLE_PROP_SHADOW_SPEC_OPACITY: NUMBER_INTEGER;
16
+ };
17
+ export declare type CB_STYLE_PROP_SHADOW_SPECS = CB_STYLE_PROP_SHADOW_SPECS_BASE & {
18
+ 'CB_STYLE_PROP_SHADOW_SPEC_TYPE:HOVER': ENUM_STRING;
19
+ 'CB_STYLE_PROP_SHADOW_SPEC_TYPE:MOBILE': ENUM_STRING | undefined;
20
+ 'CB_STYLE_PROP_SHADOW_SPEC_TYPE:MOBILE:HOVER': ENUM_STRING | undefined;
21
+ 'CB_STYLE_PROP_SHADOW_SPEC_COLOR:HOVER': STRING_8DIGIT_HEX;
22
+ 'CB_STYLE_PROP_SHADOW_SPEC_COLOR:MOBILE': STRING_8DIGIT_HEX | undefined;
23
+ 'CB_STYLE_PROP_SHADOW_SPEC_COLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | undefined;
24
+ 'CB_STYLE_PROP_SHADOW_SPEC_X:HOVER': NUMBER_INTEGER;
25
+ 'CB_STYLE_PROP_SHADOW_SPEC_X:MOBILE': NUMBER_INTEGER | undefined;
26
+ 'CB_STYLE_PROP_SHADOW_SPEC_X:MOBILE:HOVER': NUMBER_INTEGER | undefined;
27
+ 'CB_STYLE_PROP_SHADOW_SPEC_Y:HOVER': NUMBER_INTEGER;
28
+ 'CB_STYLE_PROP_SHADOW_SPEC_Y:MOBILE': NUMBER_INTEGER | undefined;
29
+ 'CB_STYLE_PROP_SHADOW_SPEC_Y:MOBILE:HOVER': NUMBER_INTEGER | undefined;
30
+ 'CB_STYLE_PROP_SHADOW_SPEC_BLUR:HOVER': NUMBER_INTEGER;
31
+ 'CB_STYLE_PROP_SHADOW_SPEC_BLUR:MOBILE': NUMBER_INTEGER | undefined;
32
+ 'CB_STYLE_PROP_SHADOW_SPEC_BLUR:MOBILE:HOVER': NUMBER_INTEGER | undefined;
33
+ 'CB_STYLE_PROP_SHADOW_SPEC_SPREAD:HOVER': NUMBER_INTEGER;
34
+ 'CB_STYLE_PROP_SHADOW_SPEC_SPREAD:MOBILE': NUMBER_INTEGER | undefined;
35
+ 'CB_STYLE_PROP_SHADOW_SPEC_SPREAD:MOBILE:HOVER': NUMBER_INTEGER | undefined;
36
+ 'CB_STYLE_PROP_SHADOW_SPEC_OPACITY:HOVER': NUMBER_INTEGER;
37
+ 'CB_STYLE_PROP_SHADOW_SPEC_OPACITY:MOBILE': NUMBER_INTEGER | undefined;
38
+ 'CB_STYLE_PROP_SHADOW_SPEC_OPACITY:MOBILE:HOVER': NUMBER_INTEGER | undefined;
39
+ };
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ var AVAILABLE_SPECS = [
15
+ 'CB_STYLE_PROP_SHADOW_SPEC_TYPE',
16
+ 'CB_STYLE_PROP_SHADOW_SPEC_COLOR',
17
+ 'CB_STYLE_PROP_SHADOW_SPEC_X',
18
+ 'CB_STYLE_PROP_SHADOW_SPEC_Y',
19
+ 'CB_STYLE_PROP_SHADOW_SPEC_BLUR',
20
+ 'CB_STYLE_PROP_SHADOW_SPEC_SPREAD',
21
+ 'CB_STYLE_PROP_SHADOW_SPEC_OPACITY'
22
+ ];
23
+ function parseStylePropShadow(namedProps, device) {
24
+ var specs = namedProps.specs;
25
+ var valueSet = AVAILABLE_SPECS.reduce(function (acc, cur) {
26
+ var _a, _b;
27
+ var baseKey = device === 'DESKTOP' ? cur : cur + ":MOBILE";
28
+ var value = specs[baseKey];
29
+ var hoverValue = specs[baseKey + ":HOVER"];
30
+ return {
31
+ normal: __assign(__assign({}, acc.normal), (_a = {}, _a[baseKey] = value, _a)),
32
+ hover: __assign(__assign({}, acc.hover), (_b = {}, _b[baseKey] = hoverValue, _b))
33
+ };
34
+ }, {
35
+ normal: {},
36
+ hover: {}
37
+ });
38
+ return {
39
+ style: { boxShadow: valueGenerator(valueSet.normal) },
40
+ hoverStyle: { boxShadow: valueGenerator(valueSet.hover) }
41
+ };
42
+ }
43
+ exports.default = parseStylePropShadow;
44
+ function valueGenerator(valueSet) {
45
+ return (valueSet.CB_STYLE_PROP_SHADOW_SPEC_TYPE === 'inset' ? 'inset' : '') + " " + valueSet.CB_STYLE_PROP_SHADOW_SPEC_Y + "px " + valueSet.CB_STYLE_PROP_SHADOW_SPEC_X + "px " + valueSet.CB_STYLE_PROP_SHADOW_SPEC_BLUR + "px " + valueSet.CB_STYLE_PROP_SHADOW_SPEC_SPREAD + "px " + valueSet.CB_STYLE_PROP_SHADOW_SPEC_COLOR;
46
+ }
@@ -0,0 +1,39 @@
1
+ import type { Device, ENUM_STRING, NUMBER_INTEGER, STRING_8DIGIT_HEX, StyleAndHoverStyle } from '../types';
2
+ import type { CB_STYLE_PROP_KEYS } from './types';
3
+ export declare type NAMED_CB_STYLE_TEXT_PROPS = {
4
+ name: CB_STYLE_PROP_KEYS.CB_STYLE_PROP_TEXT;
5
+ specs: CB_STYLE_PROP_TEXT_SPECS;
6
+ };
7
+ export default function parseStylePropTextSpec(namedProps: NAMED_CB_STYLE_TEXT_PROPS, device: Device): StyleAndHoverStyle;
8
+ export declare type CB_STYLE_PROP_TEXT_SPECS_BASE = {
9
+ CB_STYLE_PROP_TEXT_SPEC_FONT: ENUM_STRING;
10
+ CB_STYLE_PROP_TEXT_SPEC_WEIGHT: NUMBER_INTEGER;
11
+ CB_STYLE_PROP_TEXT_SPEC_SIZE: NUMBER_INTEGER;
12
+ CB_STYLE_PROP_TEXT_SPEC_FITTOSIZE: boolean;
13
+ CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT: NUMBER_INTEGER;
14
+ CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING: NUMBER_INTEGER;
15
+ CB_STYLE_PROP_TEXT_SPEC_COLOR: STRING_8DIGIT_HEX;
16
+ };
17
+ export declare type CB_STYLE_PROP_TEXT_SPECS = CB_STYLE_PROP_TEXT_SPECS_BASE & {
18
+ 'CB_STYLE_PROP_TEXT_SPEC_FONT:HOVER': ENUM_STRING;
19
+ 'CB_STYLE_PROP_TEXT_SPEC_FONT:MOBILE': ENUM_STRING | undefined;
20
+ 'CB_STYLE_PROP_TEXT_SPEC_FONT:MOBILE:HOVER': ENUM_STRING | undefined;
21
+ 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT:HOVER': NUMBER_INTEGER;
22
+ 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT:MOBILE': NUMBER_INTEGER | undefined;
23
+ 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT:MOBILE:HOVER': NUMBER_INTEGER | undefined;
24
+ 'CB_STYLE_PROP_TEXT_SPEC_SIZE:HOVER': NUMBER_INTEGER;
25
+ 'CB_STYLE_PROP_TEXT_SPEC_SIZE:MOBILE': NUMBER_INTEGER | undefined;
26
+ 'CB_STYLE_PROP_TEXT_SPEC_SIZE:MOBILE:HOVER': NUMBER_INTEGER | undefined;
27
+ 'CB_STYLE_PROP_TEXT_SPEC_FITTOSIZE:HOVER': boolean;
28
+ 'CB_STYLE_PROP_TEXT_SPEC_FITTOSIZE:MOBILE': boolean | undefined;
29
+ 'CB_STYLE_PROP_TEXT_SPEC_FITTOSIZE:MOBILE:HOVER': boolean | undefined;
30
+ 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT:HOVER': NUMBER_INTEGER;
31
+ 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT:MOBILE': NUMBER_INTEGER | undefined;
32
+ 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT:MOBILE:HOVER': NUMBER_INTEGER | undefined;
33
+ 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING:HOVER': NUMBER_INTEGER;
34
+ 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING:MOBILE': NUMBER_INTEGER | undefined;
35
+ 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING:MOBILE:HOVER': NUMBER_INTEGER | undefined;
36
+ 'CB_STYLE_PROP_TEXT_SPEC_COLOR:HOVER': STRING_8DIGIT_HEX;
37
+ 'CB_STYLE_PROP_TEXT_SPEC_COLOR:MOBILE': STRING_8DIGIT_HEX | undefined;
38
+ 'CB_STYLE_PROP_TEXT_SPEC_COLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | undefined;
39
+ };