pds-dev-kit-web-test 2.7.159 → 2.7.161

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.
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.MOCK_SECTIONS = void 0;
4
4
  var mock_contentsCarousel_1 = require("./mock_contentsCarousel");
5
5
  require("./mock_contentsList");
6
- require("./mock_slideBanner");
6
+ var mock_slideBanner_1 = require("./mock_slideBanner");
7
7
  exports.MOCK_SECTIONS = [
8
8
  {
9
9
  administrativeTitle: 'Daily Pages',
@@ -11,8 +11,8 @@ exports.MOCK_SECTIONS = [
11
11
  componentBlocks: [
12
12
  // MOCK_VIDEO_CB,
13
13
  // MOCK_VIDEO_CB_2,
14
- mock_contentsCarousel_1.SAMPLE_CONTENTSCAROUSEL_CB
15
- // SAMPLE_SLIDEBANNER_CB,
14
+ mock_contentsCarousel_1.SAMPLE_CONTENTSCAROUSEL_CB,
15
+ mock_slideBanner_1.SAMPLE_SLIDEBANNER_CB
16
16
  // SAMPLE_LIST_CB
17
17
  // ...MOCK_COMPONENT_BLOCKS
18
18
  ],
@@ -120,9 +120,9 @@ function SlideBanner(props) {
120
120
  var _a;
121
121
  switch (component.type) {
122
122
  case 'PREV':
123
- return ((0, jsx_runtime_1.jsx)(CustomNavigationPrevBtn_1.CustomNavigationPrevBtn, { isDisabled: loop ? false : isBeginning, styles: isHovered ? customNavigationHoverStyle : customNavigationNormalStyle, onClick: onClickPrevBtn }));
123
+ return ((0, jsx_runtime_1.jsx)(CustomNavigationPrevBtn_1.CustomNavigationPrevBtn, { isDisabled: loop ? false : isBeginning, styles: customNavigationNormalStyle, hoverStyles: customNavigationHoverStyle, onClick: onClickPrevBtn }));
124
124
  case 'NEXT':
125
- return ((0, jsx_runtime_1.jsx)(CustomNavigationNextBtn_1.CustomNavigationNextBtn, { isDisabled: loop ? false : isEnd, styles: isHovered ? customNavigationHoverStyle : customNavigationNormalStyle, onClick: onClickNextBtn }));
125
+ return ((0, jsx_runtime_1.jsx)(CustomNavigationNextBtn_1.CustomNavigationNextBtn, { isDisabled: loop ? false : isEnd, styles: customNavigationNormalStyle, hoverStyles: customNavigationHoverStyle, onClick: onClickNextBtn }));
126
126
  case 'PAGINATION':
127
127
  return ((0, jsx_runtime_1.jsx)(CustomPagination_1.CustomPagination, { styles: isHovered ? customPaginationHoverStyle : customPaginationNormalStyle, current: currentSlide, isPrevBtnDisabled: loop ? false : isBeginning, isNextBtnDisabled: loop ? false : isEnd, total: ((_a = swiperRef.current) === null || _a === void 0 ? void 0 : _a.swiper.slides.length) || 0, onBulletClick: onClickBullet, onPrevBtnClick: onClickPrevBtn, onNextBtnClick: onClickNextBtn }));
128
128
  case 'PROGRESSBAR':
@@ -3,9 +3,10 @@ import type { CustomNavigationProps } from '../types';
3
3
  export interface CustomNavigationNextBtnProps {
4
4
  isDisabled: boolean;
5
5
  styles: CustomNavigationProps;
6
+ hoverStyles?: CustomNavigationProps;
6
7
  onClick?: () => void;
7
8
  }
8
- export declare const CustomNavigationNextBtn: ({ isDisabled, styles, onClick }: CustomNavigationNextBtnProps) => JSX.Element;
9
+ export declare const CustomNavigationNextBtn: ({ isDisabled, styles, hoverStyles, onClick }: CustomNavigationNextBtnProps) => JSX.Element;
9
10
  export interface FlexBoxProps {
10
11
  direction?: 'row' | 'column';
11
12
  justifyContent?: string;
@@ -40,11 +40,13 @@ var __importStar = (this && this.__importStar) || function (mod) {
40
40
  Object.defineProperty(exports, "__esModule", { value: true });
41
41
  exports.CustomNavigationNextBtn = void 0;
42
42
  var jsx_runtime_1 = require("react/jsx-runtime");
43
+ var react_1 = require("react");
43
44
  var IconButton_1 = require("../../../../../../../../DynamicLayout/components/pdsOriginal/desktop/IconButton");
44
45
  var styled_components_1 = __importStar(require("styled-components"));
45
46
  var navigationConfigs_1 = require("./navigationConfigs");
46
47
  var CustomNavigationNextBtn = function (_a) {
47
- var isDisabled = _a.isDisabled, styles = _a.styles, onClick = _a.onClick;
48
+ var isDisabled = _a.isDisabled, styles = _a.styles, hoverStyles = _a.hoverStyles, onClick = _a.onClick;
49
+ var _b = (0, react_1.useState)(false), isHovered = _b[0], setIsHovered = _b[1];
48
50
  var nextButton = styles.nextBtnType === 'NONE'
49
51
  ? undefined
50
52
  : navigationConfigs_1.nextButtonMappedIcons[styles.nextBtnType || 'DESIGN1'];
@@ -58,7 +60,11 @@ var CustomNavigationNextBtn = function (_a) {
58
60
  buttonSize = 'xxlarge';
59
61
  iconSize = 48;
60
62
  }
61
- return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: nextButton && ((0, jsx_runtime_1.jsx)(S_NextButton, __assign({ className: "cb-slidebanner-next-button", disabled: isDisabled, "$size": styles.nextBtnSize }, { children: (0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { fillType: "fill", baseSize: buttonSize, iconSize: iconSize, shapeType: nextButton.shapeType, borderColorKey: nextButton.borderColorKey, overrideBaseColorHex: styles.nextBtnPrimaryColor, iconName: nextButton.iconName, iconFillType: "line", iconColorKey: nextButton.iconColorKey || 'ui_cpnt_icon_sys_black', overrideIconColorHex: styles.nextBtnSecondaryColor, shadow: nextButton.shadow, onClick: onClick }) }))) }));
63
+ return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: nextButton && ((0, jsx_runtime_1.jsx)(S_NextButton, __assign({ className: "cb-slidebanner-next-button", disabled: isDisabled, "$size": styles.nextBtnSize, onMouseEnter: function () { return setIsHovered(true); }, onMouseLeave: function () { return setIsHovered(false); } }, { children: (0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { fillType: "fill", baseSize: buttonSize, iconSize: iconSize, shapeType: nextButton.shapeType, borderColorKey: nextButton.borderColorKey, overrideBaseColorHex: isHovered ? hoverStyles === null || hoverStyles === void 0 ? void 0 : hoverStyles.nextBtnPrimaryColor : styles.nextBtnPrimaryColor,
64
+ // overrideBaseColorHexHover={hoverStyles?.nextBtnPrimaryColor}
65
+ iconName: nextButton.iconName, iconFillType: "line", iconColorKey: nextButton.iconColorKey || 'ui_cpnt_icon_sys_black', overrideIconColorHex: isHovered ? hoverStyles === null || hoverStyles === void 0 ? void 0 : hoverStyles.nextBtnSecondaryColor : styles.nextBtnSecondaryColor,
66
+ // overrideIconColorHexHover={hoverStyles?.nextBtnSecondaryColor}
67
+ shadow: nextButton.shadow, useDefaultActiveStyle: false, useDefaultHoverStyle: false, onClick: onClick }) }))) }));
62
68
  };
63
69
  exports.CustomNavigationNextBtn = CustomNavigationNextBtn;
64
70
  var S_NextButton = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n cursor: pointer;\n\n ", ";\n"], ["\n cursor: pointer;\n\n ", ";\n"])), function (_a) {
@@ -3,9 +3,10 @@ import type { CustomNavigationProps } from '../types';
3
3
  export interface CustomNavigationPrevBtnProps {
4
4
  isDisabled: boolean;
5
5
  styles: CustomNavigationProps;
6
+ hoverStyles?: CustomNavigationProps;
6
7
  onClick?: () => void;
7
8
  }
8
- export declare const CustomNavigationPrevBtn: ({ isDisabled, styles, onClick }: CustomNavigationPrevBtnProps) => JSX.Element;
9
+ export declare const CustomNavigationPrevBtn: ({ isDisabled, styles, hoverStyles, onClick }: CustomNavigationPrevBtnProps) => JSX.Element;
9
10
  export interface FlexBoxProps {
10
11
  direction?: 'row' | 'column';
11
12
  justifyContent?: string;
@@ -44,7 +44,7 @@ var IconButton_1 = require("../../../../../../../../DynamicLayout/components/pds
44
44
  var styled_components_1 = __importStar(require("styled-components"));
45
45
  var navigationConfigs_1 = require("./navigationConfigs");
46
46
  var CustomNavigationPrevBtn = function (_a) {
47
- var isDisabled = _a.isDisabled, styles = _a.styles, onClick = _a.onClick;
47
+ var isDisabled = _a.isDisabled, styles = _a.styles, hoverStyles = _a.hoverStyles, onClick = _a.onClick;
48
48
  var prevButton = styles.prevBtnType === 'NONE'
49
49
  ? undefined
50
50
  : navigationConfigs_1.prevButtonMappedIcons[styles.prevBtnType || 'DESIGN1'];
@@ -58,7 +58,7 @@ var CustomNavigationPrevBtn = function (_a) {
58
58
  buttonSize = 'xxlarge';
59
59
  iconSize = 48;
60
60
  }
61
- return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: prevButton && ((0, jsx_runtime_1.jsx)(S_PrevButton, __assign({ className: "cb-slidebanner-prev-button", disabled: isDisabled, "$size": styles.prevBtnSize }, { children: (0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { fillType: "fill", baseSize: buttonSize, iconSize: iconSize, shapeType: prevButton.shapeType, borderColorKey: prevButton.borderColorKey, overrideBaseColorHex: styles.prevBtnPrimaryColor, iconName: prevButton.iconName, iconFillType: "line", iconColorKey: prevButton.iconColorKey || 'ui_cpnt_icon_sys_black', overrideIconColorHex: styles.prevBtnSecondaryColor, shadow: prevButton.shadow, onClick: onClick }) }))) }));
61
+ return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: prevButton && ((0, jsx_runtime_1.jsx)(S_PrevButton, __assign({ className: "cb-slidebanner-prev-button", disabled: isDisabled }, { children: (0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { fillType: "fill", baseSize: buttonSize, iconSize: iconSize, shapeType: prevButton.shapeType, borderColorKey: prevButton.borderColorKey, overrideBaseColorHex: styles.prevBtnPrimaryColor, overrideIconColorHexHover: hoverStyles === null || hoverStyles === void 0 ? void 0 : hoverStyles.prevBtnPrimaryColor, iconName: prevButton.iconName, iconFillType: "line", iconColorKey: prevButton.iconColorKey || 'ui_cpnt_icon_sys_black', overrideIconColorHex: styles.prevBtnSecondaryColor, overrideBaseColorHexHover: hoverStyles === null || hoverStyles === void 0 ? void 0 : hoverStyles.prevBtnPrimaryColor, shadow: prevButton.shadow, useDefaultActiveStyle: false, useDefaultHoverStyle: false, onClick: onClick }) }))) }));
62
62
  };
63
63
  exports.CustomNavigationPrevBtn = CustomNavigationPrevBtn;
64
64
  var S_PrevButton = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n cursor: pointer;\n\n ", ";\n"], ["\n cursor: pointer;\n\n ", ";\n"])), function (_a) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pds-dev-kit-web-test",
3
- "version": "2.7.159",
3
+ "version": "2.7.161",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "main": "dist/index.js",