@synerise/ds-banner 1.1.11 → 1.1.13

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/CHANGELOG.md CHANGED
@@ -3,7 +3,7 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
- ## [1.1.11](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.10...@synerise/ds-banner@1.1.11) (2025-06-24)
6
+ ## [1.1.13](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.12...@synerise/ds-banner@1.1.13) (2025-07-01)
7
7
 
8
8
  **Note:** Version bump only for package @synerise/ds-banner
9
9
 
@@ -11,7 +11,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
11
11
 
12
12
 
13
13
 
14
- ## [1.1.10](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.9...@synerise/ds-banner@1.1.10) (2025-06-05)
14
+ ## [1.1.12](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.11...@synerise/ds-banner@1.1.12) (2025-06-26)
15
15
 
16
16
  **Note:** Version bump only for package @synerise/ds-banner
17
17
 
@@ -19,7 +19,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
19
19
 
20
20
 
21
21
 
22
- ## [1.1.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.8...@synerise/ds-banner@1.1.9) (2025-06-03)
22
+ ## [1.1.11](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.10...@synerise/ds-banner@1.1.11) (2025-06-24)
23
23
 
24
24
  **Note:** Version bump only for package @synerise/ds-banner
25
25
 
@@ -27,199 +27,112 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
27
27
 
28
28
 
29
29
 
30
- ## [1.1.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.7...@synerise/ds-banner@1.1.8) (2025-05-26)
30
+ ## [1.1.10](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.9...@synerise/ds-banner@1.1.10) (2025-06-05)
31
31
 
32
32
  **Note:** Version bump only for package @synerise/ds-banner
33
33
 
34
+ ## [1.1.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.8...@synerise/ds-banner@1.1.9) (2025-06-03)
34
35
 
36
+ **Note:** Version bump only for package @synerise/ds-banner
35
37
 
38
+ ## [1.1.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.7...@synerise/ds-banner@1.1.8) (2025-05-26)
36
39
 
40
+ **Note:** Version bump only for package @synerise/ds-banner
37
41
 
38
42
  ## [1.1.7](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.6...@synerise/ds-banner@1.1.7) (2025-05-19)
39
43
 
40
44
  **Note:** Version bump only for package @synerise/ds-banner
41
45
 
42
-
43
-
44
-
45
-
46
46
  ## [1.1.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.5...@synerise/ds-banner@1.1.6) (2025-05-07)
47
47
 
48
48
  **Note:** Version bump only for package @synerise/ds-banner
49
49
 
50
-
51
-
52
-
53
-
54
50
  ## [1.1.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.4...@synerise/ds-banner@1.1.5) (2025-04-24)
55
51
 
56
52
  **Note:** Version bump only for package @synerise/ds-banner
57
53
 
58
-
59
-
60
-
61
-
62
54
  ## [1.1.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.3...@synerise/ds-banner@1.1.4) (2025-04-16)
63
55
 
64
56
  **Note:** Version bump only for package @synerise/ds-banner
65
57
 
66
-
67
-
68
-
69
-
70
58
  ## [1.1.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.2...@synerise/ds-banner@1.1.3) (2025-04-02)
71
59
 
72
60
  **Note:** Version bump only for package @synerise/ds-banner
73
61
 
74
-
75
-
76
-
77
-
78
62
  ## [1.1.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.1...@synerise/ds-banner@1.1.2) (2025-03-31)
79
63
 
80
64
  **Note:** Version bump only for package @synerise/ds-banner
81
65
 
82
-
83
-
84
-
85
-
86
66
  ## [1.1.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.1.0...@synerise/ds-banner@1.1.1) (2025-03-26)
87
67
 
88
68
  **Note:** Version bump only for package @synerise/ds-banner
89
69
 
90
-
91
-
92
-
93
-
94
70
  # [1.1.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@1.0.0...@synerise/ds-banner@1.1.0) (2025-03-18)
95
71
 
96
-
97
72
  ### Features
98
73
 
99
- * **button:** add support for tag in button ([32b6956](https://github.com/Synerise/synerise-design/commit/32b6956d5e1f46df03abb4de8fbaf0a7d487043e))
100
-
101
-
102
-
103
-
74
+ - **button:** add support for tag in button ([32b6956](https://github.com/Synerise/synerise-design/commit/32b6956d5e1f46df03abb4de8fbaf0a7d487043e))
104
75
 
105
76
  ## [0.2.9](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.8...@synerise/ds-banner@0.2.9) (2025-03-10)
106
77
 
107
78
  **Note:** Version bump only for package @synerise/ds-banner
108
79
 
109
-
110
-
111
-
112
-
113
80
  ## [0.2.8](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.7...@synerise/ds-banner@0.2.8) (2025-03-04)
114
81
 
115
82
  **Note:** Version bump only for package @synerise/ds-banner
116
83
 
117
-
118
-
119
-
120
-
121
84
  ## [0.2.7](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.6...@synerise/ds-banner@0.2.7) (2025-02-27)
122
85
 
123
86
  **Note:** Version bump only for package @synerise/ds-banner
124
87
 
125
-
126
-
127
-
128
-
129
88
  ## [0.2.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.5...@synerise/ds-banner@0.2.6) (2025-02-20)
130
89
 
131
90
  **Note:** Version bump only for package @synerise/ds-banner
132
91
 
133
-
134
-
135
-
136
-
137
92
  ## [0.2.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.4...@synerise/ds-banner@0.2.5) (2025-02-18)
138
93
 
139
94
  **Note:** Version bump only for package @synerise/ds-banner
140
95
 
141
-
142
-
143
-
144
-
145
96
  ## [0.2.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.3...@synerise/ds-banner@0.2.4) (2025-02-17)
146
97
 
147
98
  **Note:** Version bump only for package @synerise/ds-banner
148
99
 
149
-
150
-
151
-
152
-
153
100
  ## [0.2.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.2...@synerise/ds-banner@0.2.3) (2025-02-14)
154
101
 
155
102
  **Note:** Version bump only for package @synerise/ds-banner
156
103
 
157
-
158
-
159
-
160
-
161
104
  ## [0.2.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.1...@synerise/ds-banner@0.2.2) (2025-02-14)
162
105
 
163
106
  **Note:** Version bump only for package @synerise/ds-banner
164
107
 
165
-
166
-
167
-
168
-
169
108
  ## [0.2.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.2.0...@synerise/ds-banner@0.2.1) (2025-02-07)
170
109
 
171
110
  **Note:** Version bump only for package @synerise/ds-banner
172
111
 
173
-
174
-
175
-
176
-
177
112
  # [0.2.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.1.4...@synerise/ds-banner@0.2.0) (2025-01-29)
178
113
 
179
-
180
114
  ### Features
181
115
 
182
- * antd@4.24 react@18 ([d97a667](https://github.com/Synerise/synerise-design/commit/d97a667b1f33aed3177e1851de3b6f60be2d46a6))
183
-
184
-
185
-
186
-
116
+ - antd@4.24 react@18 ([d97a667](https://github.com/Synerise/synerise-design/commit/d97a667b1f33aed3177e1851de3b6f60be2d46a6))
187
117
 
188
118
  ## [0.1.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.1.3...@synerise/ds-banner@0.1.4) (2025-01-21)
189
119
 
190
120
  **Note:** Version bump only for package @synerise/ds-banner
191
121
 
192
-
193
-
194
-
195
-
196
122
  ## [0.1.3](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.1.2...@synerise/ds-banner@0.1.3) (2025-01-15)
197
123
 
198
124
  **Note:** Version bump only for package @synerise/ds-banner
199
125
 
200
-
201
-
202
-
203
-
204
126
  ## [0.1.2](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.1.1...@synerise/ds-banner@0.1.2) (2024-12-16)
205
127
 
206
128
  **Note:** Version bump only for package @synerise/ds-banner
207
129
 
208
-
209
-
210
-
211
-
212
130
  ## [0.1.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-banner@0.1.0...@synerise/ds-banner@0.1.1) (2024-12-13)
213
131
 
214
132
  **Note:** Version bump only for package @synerise/ds-banner
215
133
 
216
-
217
-
218
-
219
-
220
134
  # 0.1.0 (2024-12-04)
221
135
 
222
-
223
136
  ### Features
224
137
 
225
- * **banner:** new component ([881a411](https://github.com/Synerise/synerise-design/commit/881a41113241463b940eb9b2a6bde9ab10c143a4))
138
+ - **banner:** new component ([881a411](https://github.com/Synerise/synerise-design/commit/881a41113241463b940eb9b2a6bde9ab10c143a4))
package/dist/Banner.js CHANGED
@@ -1,15 +1,15 @@
1
1
  var _excluded = ["slides", "autoPlay", "autoPlaySpeed", "transitionEffect", "onAfterChange", "onBeforeChange", "texts", "onClose", "expandable"];
2
2
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
3
3
  function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
4
- import React, { useState, useMemo } from 'react';
4
+ import React, { useMemo, useState } from 'react';
5
5
  import { v4 as uuid } from 'uuid';
6
6
  import Button from '@synerise/ds-button';
7
7
  import Icon, { CloseM } from '@synerise/ds-icon';
8
8
  import Tooltip from '@synerise/ds-tooltip';
9
- import * as S from './Banner.styles';
10
- import { BannerSlide, BannerCounter, BannerHeader } from './components';
11
- import { useTexts, useCarousel } from './hooks';
12
9
  import { DEFAULT_SLIDE_SPEED } from './Banner.const';
10
+ import * as S from './Banner.styles';
11
+ import { BannerCounter, BannerHeader, BannerSlide } from './components';
12
+ import { useCarousel, useTexts } from './hooks';
13
13
  var Banner = function Banner(_ref) {
14
14
  var slides = _ref.slides,
15
15
  _ref$autoPlay = _ref.autoPlay,
@@ -45,7 +45,6 @@ var Banner = function Banner(_ref) {
45
45
  }, [slides]);
46
46
  var handleBeforeChange = function handleBeforeChange(from, to) {
47
47
  setCurrentIndex(to);
48
- // eslint-disable-next-line no-unused-expressions
49
48
  onBeforeChange == null || onBeforeChange(from, to);
50
49
  };
51
50
  var closeButton = onClose && /*#__PURE__*/React.createElement(S.BannerCloseWrapper, null, /*#__PURE__*/React.createElement(Tooltip, {
@@ -7,7 +7,7 @@ export declare const BannerHeaderWrapper: import("styled-components").StyledComp
7
7
  isExpanded: boolean;
8
8
  }, never>;
9
9
  export declare const BannerHeaderIcon: import("styled-components").StyledComponent<"div", any, {}, never>;
10
- export declare const BannerHeaderTitle: import("styled-components").StyledComponent<({ size, className, children, ellipsis }: {
10
+ export declare const BannerHeaderTitle: import("styled-components").StyledComponent<({ size, className, children, ellipsis, }: {
11
11
  size?: import("@synerise/ds-typography").TextSize | undefined;
12
12
  ellipsis?: import("@synerise/ds-typography/dist/Ellipsis").EllipsisProps | undefined;
13
13
  children?: import("react").ReactNode;
@@ -1,5 +1,5 @@
1
- import styled, { css } from 'styled-components';
2
1
  import { Carousel } from 'antd';
2
+ import styled, { css } from 'styled-components';
3
3
  import Tag from '@synerise/ds-tag';
4
4
  import { Text, Title } from '@synerise/ds-typography';
5
5
  export var BannerWrapper = styled.div.withConfig({
@@ -1,6 +1,6 @@
1
1
  import type { ReactNode } from 'react';
2
- import type { WithHTMLAttributes } from '@synerise/ds-utils';
3
2
  import type { TagProps } from '@synerise/ds-tag';
3
+ import type { WithHTMLAttributes } from '@synerise/ds-utils';
4
4
  type Texts = 'expand' | 'collapse' | 'closeTooltip';
5
5
  export type BannerTexts = {
6
6
  [k in Texts]: ReactNode;
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
2
  import type { BannerCounterProps } from '../../Banner.types';
3
- export declare const BannerCounter: ({ slides, currentIndex, onDotClick, onPrevClick, onNextClick }: BannerCounterProps) => React.JSX.Element;
3
+ export declare const BannerCounter: ({ slides, currentIndex, onDotClick, onPrevClick, onNextClick, }: BannerCounterProps) => React.JSX.Element;
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
2
  import type { BannerHeaderProps } from '../../Banner.types';
3
- export declare const BannerHeader: ({ closeButton, icon, title, isExpanded, texts, onToggle }: BannerHeaderProps) => React.JSX.Element;
3
+ export declare const BannerHeader: ({ closeButton, icon, title, isExpanded, texts, onToggle, }: BannerHeaderProps) => React.JSX.Element;
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
2
  import type { BannerSlideProps } from '../../Banner.types';
3
- export declare const BannerSlide: ({ mainContent, leftSideContent, rightSideContent }: BannerSlideProps) => React.JSX.Element;
3
+ export declare const BannerSlide: ({ mainContent, leftSideContent, rightSideContent, }: BannerSlideProps) => React.JSX.Element;
@@ -1,15 +1,17 @@
1
1
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
2
2
  import React, { useMemo } from 'react';
3
3
  import * as S from '../../Banner.styles';
4
- import { BannerSlideMediaContent, BannerSlideTextContent } from '../index';
5
4
  import { isMediaContent } from '../../utils/isMediaContent';
5
+ import { BannerSlideMediaContent, BannerSlideTextContent } from '../index';
6
6
  export var BannerSlide = function BannerSlide(_ref) {
7
7
  var mainContent = _ref.mainContent,
8
8
  leftSideContent = _ref.leftSideContent,
9
9
  rightSideContent = _ref.rightSideContent;
10
10
  var hasMainContent = Boolean(mainContent);
11
11
  var leftSideComponent = useMemo(function () {
12
- if (!leftSideContent) return /*#__PURE__*/React.createElement(React.Fragment, null);
12
+ if (!leftSideContent) {
13
+ return /*#__PURE__*/React.createElement(React.Fragment, null);
14
+ }
13
15
  return isMediaContent(leftSideContent) ? /*#__PURE__*/React.createElement(BannerSlideMediaContent, _extends({
14
16
  position: "left",
15
17
  hasMainContent: hasMainContent
@@ -19,7 +21,9 @@ export var BannerSlide = function BannerSlide(_ref) {
19
21
  }, leftSideContent));
20
22
  }, [leftSideContent, hasMainContent]);
21
23
  var rightSideComponent = useMemo(function () {
22
- if (!rightSideContent) return /*#__PURE__*/React.createElement(React.Fragment, null);
24
+ if (!rightSideContent) {
25
+ return /*#__PURE__*/React.createElement(React.Fragment, null);
26
+ }
23
27
  return isMediaContent(rightSideContent) ? /*#__PURE__*/React.createElement(BannerSlideMediaContent, _extends({
24
28
  position: "right",
25
29
  hasMainContent: hasMainContent
@@ -29,7 +33,9 @@ export var BannerSlide = function BannerSlide(_ref) {
29
33
  }, rightSideContent));
30
34
  }, [rightSideContent, hasMainContent]);
31
35
  var mainComponent = useMemo(function () {
32
- if (!mainContent) return /*#__PURE__*/React.createElement(React.Fragment, null);
36
+ if (!mainContent) {
37
+ return /*#__PURE__*/React.createElement(React.Fragment, null);
38
+ }
33
39
  return isMediaContent(mainContent) ? /*#__PURE__*/React.createElement(BannerSlideMediaContent, _extends({
34
40
  position: "main"
35
41
  }, mainContent)) : /*#__PURE__*/React.createElement(BannerSlideTextContent, _extends({
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
- import type { BannerSlideTextContentProps, BannerSlideContentProps } from '../../Banner.types';
2
+ import type { BannerSlideContentProps, BannerSlideTextContentProps } from '../../Banner.types';
3
3
  export declare const BannerSlideTextContent: ({ title, titlePrefix, titleStatus, description, position, buttons, hasMainContent, }: BannerSlideTextContentProps & BannerSlideContentProps) => React.JSX.Element;
@@ -1,8 +1,8 @@
1
1
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
2
2
  import React from 'react';
3
3
  import { TagShape } from '@synerise/ds-tag';
4
- import * as S from '../../Banner.styles';
5
4
  import { DEFAULT_STATUS_COLOR, DEFAULT_STATUS_TEXT_COLOR } from '../../Banner.const';
5
+ import * as S from '../../Banner.styles';
6
6
  export var BannerSlideTextContent = function BannerSlideTextContent(_ref) {
7
7
  var title = _ref.title,
8
8
  titlePrefix = _ref.titlePrefix,
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import { CarouselRef } from 'antd/lib/carousel';
2
+ import { type CarouselRef } from 'antd/lib/carousel';
3
3
  export declare const useCarousel: () => {
4
4
  bannerRef: import("react").RefObject<CarouselRef>;
5
5
  handleDotClick: (index: number) => void;
@@ -1,2 +1,2 @@
1
- import { BannerTexts } from '../Banner.types';
1
+ import { type BannerTexts } from '../Banner.types';
2
2
  export declare const useTexts: (texts?: Partial<BannerTexts>) => BannerTexts;
@@ -1,2 +1,2 @@
1
- import { BannerSlideTextContentProps, BannerSlideMediaContentProps } from '../Banner.types';
1
+ import { type BannerSlideMediaContentProps, type BannerSlideTextContentProps } from '../Banner.types';
2
2
  export declare const isMediaContent: (props: BannerSlideTextContentProps | BannerSlideMediaContentProps) => props is BannerSlideMediaContentProps;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synerise/ds-banner",
3
- "version": "1.1.11",
3
+ "version": "1.1.13",
4
4
  "description": "Banner UI Component for the Synerise Design System",
5
5
  "license": "ISC",
6
6
  "repository": "Synerise/synerise-design",
@@ -34,12 +34,12 @@
34
34
  ],
35
35
  "types": "dist/index.d.ts",
36
36
  "dependencies": {
37
- "@synerise/ds-button": "^1.4.0",
38
- "@synerise/ds-icon": "^1.5.3",
39
- "@synerise/ds-tag": "^1.1.10",
40
- "@synerise/ds-tooltip": "^1.1.10",
41
- "@synerise/ds-typography": "^1.0.11",
42
- "@synerise/ds-utils": "^1.3.0",
37
+ "@synerise/ds-button": "^1.4.2",
38
+ "@synerise/ds-icon": "^1.5.4",
39
+ "@synerise/ds-tag": "^1.1.12",
40
+ "@synerise/ds-tooltip": "^1.1.12",
41
+ "@synerise/ds-typography": "^1.0.13",
42
+ "@synerise/ds-utils": "^1.3.1",
43
43
  "uuid": "^8.3.2"
44
44
  },
45
45
  "peerDependencies": {
@@ -49,5 +49,5 @@
49
49
  "react-intl": ">= 3.12.0 <= 6.8",
50
50
  "styled-components": "^5.3.3"
51
51
  },
52
- "gitHead": "f2713cd35cfe22f63a159f05144585834897a132"
52
+ "gitHead": "4512641033ba3581a3df208143c547fcfed45895"
53
53
  }