@megafon/ui-shared 4.11.0 → 4.13.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 (50) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/dist/es/components/BenefitsPictures/BenefitsPictures.js +5 -3
  3. package/dist/es/components/BenefitsPictures/types.d.ts +2 -0
  4. package/dist/es/components/ButtonBanner/ButtonBanner.d.ts +2 -0
  5. package/dist/es/components/ButtonBanner/ButtonBanner.js +3 -0
  6. package/dist/es/components/ButtonLinkBox/ButtonLinkBox.d.ts +4 -0
  7. package/dist/es/components/ButtonLinkBox/ButtonLinkBox.js +7 -1
  8. package/dist/es/components/Card/Card.d.ts +4 -0
  9. package/dist/es/components/Card/Card.js +12 -4
  10. package/dist/es/components/Instructions/Instructions.d.ts +1 -0
  11. package/dist/es/components/Instructions/Instructions.js +5 -3
  12. package/dist/es/components/Partners/Partners.d.ts +1 -0
  13. package/dist/es/components/Partners/Partners.js +4 -1
  14. package/dist/es/components/PictureWithDescription/PictureWithDescription.d.ts +2 -0
  15. package/dist/es/components/PictureWithDescription/PictureWithDescription.js +3 -1
  16. package/dist/es/components/StoreBanner/StoreBanner.d.ts +2 -0
  17. package/dist/es/components/StoreBanner/StoreBanner.js +10 -0
  18. package/dist/es/components/StoreButton/StoreButton.d.ts +1 -1
  19. package/dist/es/components/StoreButton/StoreButton.js +8 -2
  20. package/dist/es/components/TextBox/TextBoxPicture.d.ts +2 -0
  21. package/dist/es/components/TextBox/TextBoxPicture.js +5 -3
  22. package/dist/es/components/VideoBanner/VideoBanner.d.ts +6 -0
  23. package/dist/es/components/VideoBanner/VideoBanner.js +11 -3
  24. package/dist/es/components/VideoBlock/VideoBlock.d.ts +2 -0
  25. package/dist/es/components/VideoBlock/VideoBlock.js +4 -1
  26. package/dist/lib/components/BenefitsPictures/BenefitsPictures.js +5 -3
  27. package/dist/lib/components/BenefitsPictures/types.d.ts +2 -0
  28. package/dist/lib/components/ButtonBanner/ButtonBanner.d.ts +2 -0
  29. package/dist/lib/components/ButtonBanner/ButtonBanner.js +3 -0
  30. package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.d.ts +4 -0
  31. package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.js +7 -1
  32. package/dist/lib/components/Card/Card.d.ts +4 -0
  33. package/dist/lib/components/Card/Card.js +12 -4
  34. package/dist/lib/components/Instructions/Instructions.d.ts +1 -0
  35. package/dist/lib/components/Instructions/Instructions.js +5 -3
  36. package/dist/lib/components/Partners/Partners.d.ts +1 -0
  37. package/dist/lib/components/Partners/Partners.js +4 -1
  38. package/dist/lib/components/PictureWithDescription/PictureWithDescription.d.ts +2 -0
  39. package/dist/lib/components/PictureWithDescription/PictureWithDescription.js +3 -1
  40. package/dist/lib/components/StoreBanner/StoreBanner.d.ts +2 -0
  41. package/dist/lib/components/StoreBanner/StoreBanner.js +10 -0
  42. package/dist/lib/components/StoreButton/StoreButton.d.ts +1 -1
  43. package/dist/lib/components/StoreButton/StoreButton.js +8 -2
  44. package/dist/lib/components/TextBox/TextBoxPicture.d.ts +2 -0
  45. package/dist/lib/components/TextBox/TextBoxPicture.js +5 -3
  46. package/dist/lib/components/VideoBanner/VideoBanner.d.ts +6 -0
  47. package/dist/lib/components/VideoBanner/VideoBanner.js +11 -3
  48. package/dist/lib/components/VideoBlock/VideoBlock.d.ts +2 -0
  49. package/dist/lib/components/VideoBlock/VideoBlock.js +4 -1
  50. package/package.json +4 -4
package/CHANGELOG.md CHANGED
@@ -3,6 +3,40 @@
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
+ # [4.13.0](https://github.com/MegafonWebLab/megafon-ui/compare/@megafon/ui-shared@4.12.0...@megafon/ui-shared@4.13.0) (2023-02-13)
7
+
8
+
9
+ ### Features
10
+
11
+ * **buttonbanner:** add buttonRel prop ([df2f8cd](https://github.com/MegafonWebLab/megafon-ui/commit/df2f8cd7341596114df4bd9d408fced9430d2e7e))
12
+ * **buttonlinkbox:** add buttonRel and linkRel props ([95135a1](https://github.com/MegafonWebLab/megafon-ui/commit/95135a163db6ef84dcedd56fa8a24ec2769d40b5))
13
+ * **card:** add rel prop ([e4f89a3](https://github.com/MegafonWebLab/megafon-ui/commit/e4f89a3990c29763acb7b53863a9ac8d199cc0fe))
14
+ * **partners:** add rel prop ([796d76c](https://github.com/MegafonWebLab/megafon-ui/commit/796d76c5a62e7b010c4ab5a7da19c4d1b0c72deb))
15
+ * **storebanner:** add rel prop ([3f44d31](https://github.com/MegafonWebLab/megafon-ui/commit/3f44d31c9de9844803304cd116a3be226e70d731))
16
+ * **storebutton:** add rel prop ([087b02f](https://github.com/MegafonWebLab/megafon-ui/commit/087b02fa1f3c90a1a35dd7ac0776c021adc12204))
17
+ * **videblock:** add buttonRel prop ([cfbab88](https://github.com/MegafonWebLab/megafon-ui/commit/cfbab88366be66f5a2457a76627ac70d40a76967))
18
+ * **videobanner:** add linkRel and buttonRel props ([2a7269a](https://github.com/MegafonWebLab/megafon-ui/commit/2a7269ae4c28ae6d60deefdedb9aa9474a7fb2cf))
19
+
20
+
21
+
22
+
23
+
24
+ # [4.12.0](https://github.com/MegafonWebLab/megafon-ui/compare/@megafon/ui-shared@4.11.0...@megafon/ui-shared@4.12.0) (2023-02-06)
25
+
26
+
27
+ ### Features
28
+
29
+ * **benefitpictures:** add alt prop for images ([3fd19e7](https://github.com/MegafonWebLab/megafon-ui/commit/3fd19e718068db8d418adccbb1812e4e8dd6e090))
30
+ * **card:** add alt prop for image ([a56a159](https://github.com/MegafonWebLab/megafon-ui/commit/a56a1595b1114e63aa80d9f8976bfb8d54b871db))
31
+ * **instructions:** add alt prop for images ([94d4750](https://github.com/MegafonWebLab/megafon-ui/commit/94d4750a51a4d3e848c319ed98a31b3fd241e733))
32
+ * **picturewithdescription:** add alt prop for image ([0ed9e19](https://github.com/MegafonWebLab/megafon-ui/commit/0ed9e195b00c41a2a736de741af82b3808eb1677))
33
+ * **textboxpicture:** add alt prop for image ([6df38e2](https://github.com/MegafonWebLab/megafon-ui/commit/6df38e23d9a42fbb8833c0f4968fd6f6ff4f28b7))
34
+ * **videobanner:** add alt prop for image ([3ec8c6c](https://github.com/MegafonWebLab/megafon-ui/commit/3ec8c6cda08b42fe8f36b9bee029ad0c3ad18d5f))
35
+
36
+
37
+
38
+
39
+
6
40
  # [4.11.0](https://github.com/MegafonWebLab/megafon-ui/compare/@megafon/ui-shared@4.10.0...@megafon/ui-shared@4.11.0) (2023-01-31)
7
41
 
8
42
 
@@ -157,7 +157,8 @@ var BenefitsPictures = function BenefitsPictures(_ref) {
157
157
  }, items.map(function (_ref2, index) {
158
158
  var img = _ref2.img,
159
159
  title = _ref2.title,
160
- text = _ref2.text;
160
+ text = _ref2.text,
161
+ alt = _ref2.alt;
161
162
  return /*#__PURE__*/React.createElement(GridColumn, _extends({}, align === 'left' ? getLeftConfig(items.length, index) : getCenterConfig(items.length, index, gridGap), {
162
163
  key: index
163
164
  }), /*#__PURE__*/React.createElement("div", {
@@ -167,7 +168,7 @@ var BenefitsPictures = function BenefitsPictures(_ref) {
167
168
  'h-align': align
168
169
  }),
169
170
  src: img,
170
- alt: ""
171
+ alt: alt
171
172
  }), /*#__PURE__*/React.createElement(Header, {
172
173
  className: cn('title'),
173
174
  align: align,
@@ -185,7 +186,8 @@ BenefitsPictures.propTypes = {
185
186
  items: PropTypes.arrayOf(PropTypes.shape({
186
187
  title: PropTypes.string.isRequired,
187
188
  text: PropTypes.string.isRequired,
188
- img: PropTypes.string.isRequired
189
+ img: PropTypes.string.isRequired,
190
+ alt: PropTypes.string
189
191
  }).isRequired).isRequired,
190
192
  align: PropTypes.oneOf(['left', 'center']),
191
193
  gridGap: PropTypes.oneOf(['medium', 'large']),
@@ -5,6 +5,8 @@ export interface IBenefit {
5
5
  text: string;
6
6
  /** Изображение */
7
7
  img: string;
8
+ /** Значение тега alt для изображения */
9
+ alt?: string;
8
10
  }
9
11
  declare type TGridSizeValues = '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12';
10
12
  export declare type GridConfig = {
@@ -46,6 +46,8 @@ export interface IButtonBannerProps {
46
46
  buttonTarget?: ButtonTargetType;
47
47
  /** Цвет кнопки */
48
48
  buttonColor?: ButtonColorType;
49
+ /** Rel - атрибут тега <a> */
50
+ buttonRel?: string;
49
51
  /** Масштабирование изображения */
50
52
  imageScaling?: ImageScalingType;
51
53
  /** Обработчик клика по кнопке */
@@ -43,6 +43,7 @@ var ButtonBanner = function ButtonBanner(_ref) {
43
43
  buttonTarget = _ref$buttonTarget === void 0 ? '_self' : _ref$buttonTarget,
44
44
  _ref$buttonColor = _ref.buttonColor,
45
45
  buttonColor = _ref$buttonColor === void 0 ? 'green' : _ref$buttonColor,
46
+ buttonRel = _ref.buttonRel,
46
47
  _ref$imageScaling = _ref.imageScaling,
47
48
  imageScaling = _ref$imageScaling === void 0 ? 'cover' : _ref$imageScaling,
48
49
  onButtonClick = _ref.onButtonClick;
@@ -52,6 +53,7 @@ var ButtonBanner = function ButtonBanner(_ref) {
52
53
  },
53
54
  className: cn('button', [classes.button]),
54
55
  href: buttonUrl,
56
+ rel: buttonRel,
55
57
  target: buttonTarget,
56
58
  theme: buttonColor,
57
59
  onClick: onButtonClick,
@@ -108,6 +110,7 @@ ButtonBanner.propTypes = {
108
110
  buttonDownload: PropTypes.bool,
109
111
  buttonTarget: PropTypes.oneOf(Object.values(ButtonTarget)),
110
112
  buttonColor: PropTypes.oneOf(Object.values(ButtonColor)),
113
+ buttonRel: PropTypes.string,
111
114
  onButtonClick: PropTypes.func
112
115
  };
113
116
  export default ButtonBanner;
@@ -27,12 +27,16 @@ export interface IButtonLinkBoxProps {
27
27
  buttonColor?: 'green' | 'purple';
28
28
  /** Target свойство кнопки */
29
29
  buttonTarget?: '_self' | '_blank' | '_parent' | '_top';
30
+ /** Rel - атрибут тега <a> для кнопки */
31
+ buttonRel?: string;
30
32
  /** Заголовок ссылки */
31
33
  linkTitle?: string;
32
34
  /** Добавляет атрибут download для тега <a> компонента Button */
33
35
  linkUrl?: string;
34
36
  /** Target свойство ссылки */
35
37
  linkTarget?: '_self' | '_blank' | '_parent' | '_top';
38
+ /** Rel - атрибут тега <a> для ссылки */
39
+ linkRel?: string;
36
40
  /** Добавляет атрибут download к свойству тега <a> */
37
41
  linkDownload?: boolean;
38
42
  /** Горизонтальное выравнивание */
@@ -15,9 +15,11 @@ var ButtonLinkBox = function ButtonLinkBox(_ref) {
15
15
  buttonDownload = _ref.buttonDownload,
16
16
  _ref$buttonColor = _ref.buttonColor,
17
17
  buttonColor = _ref$buttonColor === void 0 ? 'green' : _ref$buttonColor,
18
+ buttonRel = _ref.buttonRel,
18
19
  linkTitle = _ref.linkTitle,
19
20
  linkUrl = _ref.linkUrl,
20
21
  linkDownload = _ref.linkDownload,
22
+ linkRel = _ref.linkRel,
21
23
  align = _ref.align,
22
24
  className = _ref.className,
23
25
  buttonTarget = _ref.buttonTarget,
@@ -42,7 +44,8 @@ var ButtonLinkBox = function ButtonLinkBox(_ref) {
42
44
  theme: buttonColor,
43
45
  onClick: onButtonClick,
44
46
  target: buttonTarget,
45
- download: buttonDownload
47
+ download: buttonDownload,
48
+ rel: buttonRel
46
49
  }, buttonTitle)), linkTitle && /*#__PURE__*/React.createElement("div", {
47
50
  className: cn('row')
48
51
  }, /*#__PURE__*/React.createElement(TextLink, {
@@ -54,6 +57,7 @@ var ButtonLinkBox = function ButtonLinkBox(_ref) {
54
57
  download: linkDownload,
55
58
  underlineVisibility: "always",
56
59
  target: linkTarget,
60
+ rel: linkRel,
57
61
  onClick: onLinkClick
58
62
  }, linkTitle)));
59
63
  };
@@ -77,9 +81,11 @@ ButtonLinkBox.propTypes = {
77
81
  buttonUrl: PropTypes.string,
78
82
  buttonDownload: PropTypes.bool,
79
83
  buttonColor: PropTypes.oneOf(['green', 'purple']),
84
+ buttonRel: PropTypes.string,
80
85
  linkTitle: PropTypes.string,
81
86
  linkUrl: PropTypes.string,
82
87
  linkDownload: PropTypes.bool,
88
+ linkRel: PropTypes.string,
83
89
  align: PropTypes.oneOf(['center']),
84
90
  onButtonClick: PropTypes.func,
85
91
  onLinkClick: PropTypes.func
@@ -10,6 +10,7 @@ interface IButton {
10
10
  href?: string;
11
11
  target?: TargetType;
12
12
  download?: boolean;
13
+ rel?: string;
13
14
  onClick?: () => void;
14
15
  }
15
16
  interface ILink {
@@ -17,6 +18,7 @@ interface ILink {
17
18
  href?: string;
18
19
  target?: TargetType;
19
20
  download?: boolean;
21
+ rel?: string;
20
22
  }
21
23
  export declare const ObjectFit: {
22
24
  readonly FILL: "fill";
@@ -43,6 +45,8 @@ export interface ICard {
43
45
  rootRef?: Ref<HTMLDivElement>;
44
46
  /** Изображение в карточке */
45
47
  imageSrc?: string;
48
+ /** Значение тега alt для изображения */
49
+ imageAlt?: string;
46
50
  /** Иконка в карточке */
47
51
  svgSrc?: React.ReactNode;
48
52
  /** Заголовок карточки */
@@ -23,6 +23,7 @@ var Card = function Card(_ref) {
23
23
  classes = _ref$classes === void 0 ? {} : _ref$classes,
24
24
  rootRef = _ref.rootRef,
25
25
  imageSrc = _ref.imageSrc,
26
+ imageAlt = _ref.imageAlt,
26
27
  svgSrc = _ref.svgSrc,
27
28
  title = _ref.title,
28
29
  text = _ref.text,
@@ -52,7 +53,7 @@ var Card = function Card(_ref) {
52
53
  }, /*#__PURE__*/React.createElement("img", {
53
54
  className: cn('img'),
54
55
  src: imageSrc,
55
- alt: ""
56
+ alt: imageAlt
56
57
  }));
57
58
  }
58
59
 
@@ -66,7 +67,7 @@ var Card = function Card(_ref) {
66
67
  default:
67
68
  return null;
68
69
  }
69
- }, [imageSrc, svgSrc, objectFit]);
70
+ }, [imageSrc, svgSrc, objectFit, imageAlt]);
70
71
  var renderLink = React.useCallback(function () {
71
72
  if (!link) {
72
73
  return null;
@@ -75,7 +76,8 @@ var Card = function Card(_ref) {
75
76
  var linkHref = link.href,
76
77
  linkTitle = link.title,
77
78
  linkTarget = link.target,
78
- download = link.download;
79
+ download = link.download,
80
+ linkRel = link.rel;
79
81
 
80
82
  if (!linkHref || isCardLink) {
81
83
  return /*#__PURE__*/React.createElement("span", {
@@ -87,6 +89,7 @@ var Card = function Card(_ref) {
87
89
  href: linkHref,
88
90
  download: download,
89
91
  target: linkTarget,
92
+ rel: linkRel,
90
93
  dataAttrs: {
91
94
  root: dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.link
92
95
  },
@@ -102,6 +105,7 @@ var Card = function Card(_ref) {
102
105
  btnTitle = button.title,
103
106
  btnTarget = button.target,
104
107
  btnDownload = button.download,
108
+ btnRel = button.rel,
105
109
  btnOnClick = button.onClick;
106
110
  return /*#__PURE__*/React.createElement(Button, {
107
111
  dataAttrs: {
@@ -111,6 +115,7 @@ var Card = function Card(_ref) {
111
115
  href: btnHref,
112
116
  target: btnTarget,
113
117
  download: btnDownload,
118
+ rel: btnRel,
114
119
  onClick: btnOnClick
115
120
  }, btnTitle);
116
121
  }, [button, isCardLink, classes, dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.button]);
@@ -164,6 +169,7 @@ Card.propTypes = {
164
169
  current: PropTypes.elementType
165
170
  }), PropTypes.any])]),
166
171
  imageSrc: PropTypes.string,
172
+ imageAlt: PropTypes.string,
167
173
  svgSrc: PropTypes.node,
168
174
  title: PropTypes.oneOfType([PropTypes.string, PropTypes.node, PropTypes.arrayOf(PropTypes.node)]).isRequired,
169
175
  text: PropTypes.oneOfType([PropTypes.string, PropTypes.node, PropTypes.arrayOf(PropTypes.node)]),
@@ -172,13 +178,15 @@ Card.propTypes = {
172
178
  href: PropTypes.string,
173
179
  target: PropTypes.oneOf(Object.values(Target)),
174
180
  download: PropTypes.bool,
181
+ rel: PropTypes.string,
175
182
  onClick: PropTypes.func
176
183
  }),
177
184
  link: PropTypes.shape({
178
185
  title: PropTypes.string.isRequired,
179
186
  href: PropTypes.string,
180
187
  target: PropTypes.oneOf(Object.values(Target)),
181
- download: PropTypes.bool
188
+ download: PropTypes.bool,
189
+ rel: PropTypes.string
182
190
  }),
183
191
  isCenteredText: PropTypes.bool,
184
192
  isLeftHAlign: PropTypes.bool,
@@ -20,6 +20,7 @@ export declare type InstructionItemType = {
20
20
  title: string | React.ReactNode | React.ReactNode[];
21
21
  mediaUrl: string;
22
22
  isVideo: boolean;
23
+ imageAlt?: string;
23
24
  };
24
25
  export interface IInstructionsProps {
25
26
  /** Дополнительные data атрибуты к внутренним элементам */
@@ -104,12 +104,13 @@ var Instructions = function Instructions(_ref) {
104
104
  className: cn('swiper')
105
105
  }, instructionItems.map(function (_ref3, i) {
106
106
  var mediaUrl = _ref3.mediaUrl,
107
- isVideo = _ref3.isVideo;
107
+ isVideo = _ref3.isVideo,
108
+ imageAlt = _ref3.imageAlt;
108
109
  return /*#__PURE__*/React.createElement(SwiperSlide, {
109
110
  className: swiperSlideCn,
110
111
  key: i + mediaUrl
111
112
  }, isVideo ? renderVideo(mediaUrl, i) : /*#__PURE__*/React.createElement("img", _extends({
112
- alt: "",
113
+ alt: imageAlt,
113
114
  src: mediaUrl
114
115
  }, filterDataAttrs(dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.image, i + 1), {
115
116
  className: cn('swiper-img', [instructionItemImg])
@@ -246,7 +247,8 @@ Instructions.propTypes = {
246
247
  instructionItems: PropTypes.arrayOf(PropTypes.shape({
247
248
  title: PropTypes.oneOfType([PropTypes.string, PropTypes.node, PropTypes.arrayOf(PropTypes.node)]).isRequired,
248
249
  mediaUrl: PropTypes.string.isRequired,
249
- isVideo: PropTypes.bool.isRequired
250
+ isVideo: PropTypes.bool.isRequired,
251
+ imageAlt: PropTypes.string
250
252
  }).isRequired).isRequired,
251
253
  pictureAlign: PropTypes.oneOf([pictureAlignTypes.LEFT, pictureAlignTypes.RIGHT]),
252
254
  pictureMask: PropTypes.oneOf([pictureMaskTypes.ANDROID, pictureMaskTypes.NEW_IPHONE, pictureMaskTypes.WHITE_IPHONE, pictureMaskTypes.BLACK_IPHONE, pictureMaskTypes.LAPTOP, pictureMaskTypes.IPHONE_12, pictureMaskTypes.NONE]),
@@ -4,6 +4,7 @@ export declare type ItemType = {
4
4
  src: string;
5
5
  href?: string;
6
6
  alt: string;
7
+ rel?: string;
7
8
  };
8
9
  export interface IPartnersProps {
9
10
  /** Дополнительные data атрибуты к внутренним элементам */
@@ -44,9 +44,11 @@ var Partners = function Partners(_ref) {
44
44
 
45
45
  var src = item.src,
46
46
  href = item.href,
47
- alt = item.alt;
47
+ alt = item.alt,
48
+ rel = item.rel;
48
49
  return /*#__PURE__*/React.createElement(Tile, {
49
50
  href: href,
51
+ rel: rel,
50
52
  shadowLevel: "default",
51
53
  isInteractive: !!href,
52
54
  className: cn('tile'),
@@ -112,6 +114,7 @@ Partners.propTypes = {
112
114
  className: PropTypes.string,
113
115
  items: PropTypes.arrayOf(PropTypes.shape({
114
116
  href: PropTypes.string,
117
+ rel: PropTypes.string,
115
118
  src: PropTypes.string.isRequired,
116
119
  alt: PropTypes.string.isRequired
117
120
  }).isRequired).isRequired,
@@ -21,6 +21,8 @@ export interface IPictureWithDescriptionProps {
21
21
  pictureUrl: string;
22
22
  /** Расположение изображения */
23
23
  pictureAlign?: PictureAlignTypesType;
24
+ /** Значение тега alt для изображения */
25
+ pictureAlt?: string;
24
26
  /** Выравнивание текста по верхнему краю */
25
27
  isTextTopAlign?: boolean;
26
28
  }
@@ -18,6 +18,7 @@ var PictureWithDescription = function PictureWithDescription(_ref) {
18
18
  pictureUrl = _ref.pictureUrl,
19
19
  _ref$pictureAlign = _ref.pictureAlign,
20
20
  pictureAlign = _ref$pictureAlign === void 0 ? 'left' : _ref$pictureAlign,
21
+ pictureAlt = _ref.pictureAlt,
21
22
  isTextTopAlign = _ref.isTextTopAlign,
22
23
  children = _ref.children;
23
24
  return /*#__PURE__*/React.createElement("div", {
@@ -30,7 +31,7 @@ var PictureWithDescription = function PictureWithDescription(_ref) {
30
31
  }, /*#__PURE__*/React.createElement("img", {
31
32
  className: cn('img'),
32
33
  src: pictureUrl,
33
- alt: ""
34
+ alt: pictureAlt
34
35
  })), /*#__PURE__*/React.createElement("div", {
35
36
  className: cn('articles', {
36
37
  align: pictureAlign,
@@ -56,6 +57,7 @@ PictureWithDescription.propTypes = {
56
57
  title: PropTypes.oneOfType([PropTypes.string, PropTypes.node, PropTypes.arrayOf(PropTypes.node)]),
57
58
  pictureUrl: PropTypes.string.isRequired,
58
59
  pictureAlign: PropTypes.oneOf([pictureAlignTypes.LEFT, pictureAlignTypes.RIGHT]),
60
+ pictureAlt: PropTypes.string,
59
61
  isTextTopAlign: PropTypes.bool
60
62
  };
61
63
  export default PictureWithDescription;
@@ -37,6 +37,8 @@ export interface IStoreBannerProps {
37
37
  textButton?: string;
38
38
  /** Ссылка для кнопки */
39
39
  linkButton?: string;
40
+ /** Rel - атрибут тега <a> для всех кнопок баннера */
41
+ rel?: string;
40
42
  /** Ссылка на картинку с QR-кодом */
41
43
  qrCode?: string;
42
44
  /** Цветовая тема компонента */
@@ -35,6 +35,7 @@ var StoreBanner = function StoreBanner(_ref) {
35
35
  linkButton = _ref.linkButton,
36
36
  _ref$textButton = _ref.textButton,
37
37
  textButton = _ref$textButton === void 0 ? 'Установите приложение' : _ref$textButton,
38
+ rel = _ref.rel,
38
39
  qrCode = _ref.qrCode,
39
40
  imageSrc = _ref.imageSrc,
40
41
  _ref$theme = _ref.theme,
@@ -85,6 +86,7 @@ var StoreBanner = function StoreBanner(_ref) {
85
86
  },
86
87
  theme: StoreButtonTheme.APP_STORE,
87
88
  href: linkApple,
89
+ rel: rel,
88
90
  onClick: onClickApple,
89
91
  className: cn('store-link', {
90
92
  'app-store': true
@@ -95,6 +97,7 @@ var StoreBanner = function StoreBanner(_ref) {
95
97
  },
96
98
  theme: StoreButtonTheme.GOOGLE_PLAY,
97
99
  href: linkGoogle,
100
+ rel: rel,
98
101
  className: cn('store-link', {
99
102
  'google-play': true
100
103
  }, googleLinkClassName),
@@ -105,6 +108,7 @@ var StoreBanner = function StoreBanner(_ref) {
105
108
  },
106
109
  theme: StoreButtonTheme.HUAWEI_STORE,
107
110
  href: linkHuawei,
111
+ rel: rel,
108
112
  className: cn('store-link', {
109
113
  'huawei-store': true
110
114
  }, huaweiLinkClassName),
@@ -115,6 +119,7 @@ var StoreBanner = function StoreBanner(_ref) {
115
119
  },
116
120
  className: cn('button'),
117
121
  href: linkButton,
122
+ rel: rel,
118
123
  theme: theme === 'green' ? 'purple' : 'green'
119
124
  }, textButton)))), /*#__PURE__*/React.createElement(GridColumn, {
120
125
  all: "4",
@@ -139,6 +144,11 @@ StoreBanner.propTypes = {
139
144
  onClickApple: PropTypes.func,
140
145
  linkGoogle: PropTypes.string,
141
146
  onClickGoogle: PropTypes.func,
147
+ linkHuawei: PropTypes.string,
148
+ onClickHuawei: PropTypes.func,
149
+ textButton: PropTypes.string,
150
+ linkButton: PropTypes.string,
151
+ rel: PropTypes.string,
142
152
  qrCode: PropTypes.string,
143
153
  deviceMask: PropTypes.oneOf(Object.values(DeviceMask)).isRequired,
144
154
  imageSrc: PropTypes.string.isRequired,
@@ -7,7 +7,7 @@ export declare enum Theme {
7
7
  HUAWEI_STORE = "huawei-store"
8
8
  }
9
9
  declare type LinkPropTypes = React.ComponentProps<typeof Link>;
10
- export declare type Props = Required<Pick<LinkPropTypes, 'href'>> & Pick<LinkPropTypes, 'target'> & Pick<LinkPropTypes, 'onClick' | 'dataAttrs'> & {
10
+ export declare type Props = Required<Pick<LinkPropTypes, 'href'>> & Pick<LinkPropTypes, 'target' | 'rel' | 'onClick' | 'dataAttrs'> & {
11
11
  /** Тема кнопки */
12
12
  theme: Theme;
13
13
  /** Дополнительный класс */
@@ -33,13 +33,15 @@ var cn = cnCreate('mfui-store-button');
33
33
 
34
34
  var StoreButton = function StoreButton(_a) {
35
35
  var href = _a.href,
36
+ rel = _a.rel,
36
37
  onClick = _a.onClick,
37
38
  theme = _a.theme,
38
39
  className = _a.className,
39
- rest = __rest(_a, ["href", "onClick", "theme", "className"]);
40
+ rest = __rest(_a, ["href", "rel", "onClick", "theme", "className"]);
40
41
 
41
42
  return /*#__PURE__*/React.createElement(Link, _extends({}, rest, {
42
43
  href: href,
44
+ rel: rel,
43
45
  onClick: onClick,
44
46
  className: cn({
45
47
  theme: theme
@@ -49,9 +51,13 @@ var StoreButton = function StoreButton(_a) {
49
51
 
50
52
  StoreButton.propTypes = {
51
53
  href: PropTypes.string.isRequired,
54
+ rel: PropTypes.string,
52
55
  theme: PropTypes.oneOf(Object.values(Theme)).isRequired,
53
56
  onClick: PropTypes.func,
54
57
  className: PropTypes.string,
55
- target: PropTypes.oneOf(['_self', '_blank', '_parent', '_top'])
58
+ target: PropTypes.oneOf(['_self', '_blank', '_parent', '_top']),
59
+ dataAttrs: PropTypes.shape({
60
+ root: PropTypes.objectOf(PropTypes.string.isRequired)
61
+ })
56
62
  };
57
63
  export default StoreButton;
@@ -12,6 +12,8 @@ export interface ITextBoxPictureProps {
12
12
  url: string;
13
13
  /** Значение вертикальных отступов */
14
14
  margin?: PictureMarginTypesType;
15
+ /** Значение тега alt для изображения */
16
+ alt?: string;
15
17
  }
16
18
  declare const TextBoxPicture: React.FC<ITextBoxPictureProps>;
17
19
  export default TextBoxPicture;
@@ -13,7 +13,8 @@ var cn = cnCreate('mfui-text-box-picture');
13
13
  var TextBoxPicture = function TextBoxPicture(_ref) {
14
14
  var url = _ref.url,
15
15
  _ref$margin = _ref.margin,
16
- margin = _ref$margin === void 0 ? pictureMarginTypes.DEFAULT : _ref$margin;
16
+ margin = _ref$margin === void 0 ? pictureMarginTypes.DEFAULT : _ref$margin,
17
+ alt = _ref.alt;
17
18
  return /*#__PURE__*/React.createElement("div", {
18
19
  className: cn({
19
20
  margin: margin
@@ -21,12 +22,13 @@ var TextBoxPicture = function TextBoxPicture(_ref) {
21
22
  }, /*#__PURE__*/React.createElement("img", {
22
23
  className: cn('img'),
23
24
  src: url,
24
- alt: ""
25
+ alt: alt
25
26
  }));
26
27
  };
27
28
 
28
29
  TextBoxPicture.propTypes = {
29
30
  url: PropTypes.string.isRequired,
30
- margin: PropTypes.oneOf([pictureMarginTypes.DEFAULT, pictureMarginTypes.BIG_TOP, pictureMarginTypes.BIG_BOTTOM, pictureMarginTypes.BIG_VERTICAL])
31
+ margin: PropTypes.oneOf([pictureMarginTypes.DEFAULT, pictureMarginTypes.BIG_TOP, pictureMarginTypes.BIG_BOTTOM, pictureMarginTypes.BIG_VERTICAL]),
32
+ alt: PropTypes.string
31
33
  };
32
34
  export default TextBoxPicture;
@@ -34,6 +34,8 @@ export interface IContent {
34
34
  buttonTarget?: '_self' | '_blank' | '_parent' | '_top';
35
35
  /** Добавляет атрибут download для тега <a> компонента Button */
36
36
  buttonDownload?: boolean;
37
+ /** Добавляет атрибут rel для тега <a> компонента Button */
38
+ buttonRel?: string;
37
39
  /** Цвет кнопки */
38
40
  buttonColor?: ButtonColorType;
39
41
  /** Обработчик клика по кнопке */
@@ -52,6 +54,8 @@ export interface IContent {
52
54
  linkTarget?: '_self' | '_blank' | '_parent' | '_top';
53
55
  /** Добавляет атрибут download для тега <a> компонента TextLink */
54
56
  linkDownload?: boolean;
57
+ /** Добавляет атрибут rel для тега <a> компонента TextLink */
58
+ linkRel?: string;
55
59
  /** Строка со стоимостью услуги */
56
60
  cost?: string;
57
61
  }
@@ -94,6 +98,8 @@ interface IVideoBannerProps {
94
98
  imageDesktop?: string;
95
99
  /** Изображение для большого компьютерного разрешения */
96
100
  imageDesktopWide?: string;
101
+ /** Значение тега alt для изображения */
102
+ imageAlt?: string;
97
103
  /** Хлебные крошки */
98
104
  breadcrumbs?: BreadCrumbsItemsType;
99
105
  /** Включить микроразметку хлебных крошек */
@@ -60,6 +60,7 @@ var VideoBanner = function VideoBanner(_ref2) {
60
60
  imageDesktop = _ref2$imageDesktop === void 0 ? '' : _ref2$imageDesktop,
61
61
  _ref2$imageDesktopWid = _ref2.imageDesktopWide,
62
62
  imageDesktopWide = _ref2$imageDesktopWid === void 0 ? '' : _ref2$imageDesktopWid,
63
+ imageAlt = _ref2.imageAlt,
63
64
  content = _ref2.content,
64
65
  _ref2$isMuted = _ref2.isMuted,
65
66
  isMuted = _ref2$isMuted === void 0 ? true : _ref2$isMuted,
@@ -85,6 +86,7 @@ var VideoBanner = function VideoBanner(_ref2) {
85
86
  buttonDownload = _ref3.buttonDownload,
86
87
  _ref3$buttonColor = _ref3.buttonColor,
87
88
  buttonColor = _ref3$buttonColor === void 0 ? ButtonColor.GREEN : _ref3$buttonColor,
89
+ buttonRel = _ref3.buttonRel,
88
90
  onButtonClick = _ref3.onButtonClick,
89
91
  onLinkClick = _ref3.onLinkClick,
90
92
  _ref3$textColor = _ref3.textColor,
@@ -94,6 +96,7 @@ var VideoBanner = function VideoBanner(_ref2) {
94
96
  linkUrl = _ref3.linkUrl,
95
97
  linkTarget = _ref3.linkTarget,
96
98
  linkDownload = _ref3.linkDownload,
99
+ linkRel = _ref3.linkRel,
97
100
  cost = _ref3.cost;
98
101
  return /*#__PURE__*/React.createElement(Grid, {
99
102
  className: cn('grid'),
@@ -131,7 +134,8 @@ var VideoBanner = function VideoBanner(_ref2) {
131
134
  href: buttonHref,
132
135
  target: buttonTarget,
133
136
  onClick: onButtonClick,
134
- download: buttonDownload
137
+ download: buttonDownload,
138
+ rel: buttonRel
135
139
  }, buttonTitle), linkTitle && /*#__PURE__*/React.createElement(TextLink, {
136
140
  dataAttrs: {
137
141
  root: dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.link
@@ -140,7 +144,8 @@ var VideoBanner = function VideoBanner(_ref2) {
140
144
  href: linkUrl,
141
145
  download: linkDownload,
142
146
  target: linkTarget,
143
- onClick: onLinkClick
147
+ onClick: onLinkClick,
148
+ rel: linkRel
144
149
  }, linkTitle)))));
145
150
  }, [classes.button, classes.link, dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.button, dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.link]);
146
151
  var renderVideo = React.useCallback(function () {
@@ -232,7 +237,7 @@ var VideoBanner = function VideoBanner(_ref2) {
232
237
  }), /*#__PURE__*/React.createElement("img", {
233
238
  className: cn('background-image'),
234
239
  src: imageMobile,
235
- alt: ""
240
+ alt: imageAlt
236
241
  })))));
237
242
  };
238
243
 
@@ -264,6 +269,7 @@ VideoBanner.propTypes = {
264
269
  buttonHref: PropTypes.string,
265
270
  buttonDownload: PropTypes.bool,
266
271
  buttonColor: PropTypes.oneOf(Object.values(ButtonColor)),
272
+ buttonRel: PropTypes.string,
267
273
  onButtonClick: PropTypes.func,
268
274
  onLinkClick: PropTypes.func,
269
275
  textColor: PropTypes.oneOf(Object.values(TextColor)),
@@ -271,6 +277,7 @@ VideoBanner.propTypes = {
271
277
  linkTitle: PropTypes.string,
272
278
  linkUrl: PropTypes.string,
273
279
  linkDownload: PropTypes.bool,
280
+ linkRel: PropTypes.string,
274
281
  cost: PropTypes.string
275
282
  }),
276
283
  isMuted: PropTypes.bool,
@@ -278,6 +285,7 @@ VideoBanner.propTypes = {
278
285
  imageTablet: PropTypes.string.isRequired,
279
286
  imageDesktop: PropTypes.string,
280
287
  imageDesktopWide: PropTypes.string,
288
+ imageAlt: PropTypes.string,
281
289
  breadcrumbs: PropTypes.arrayOf(PropTypes.shape({
282
290
  title: PropTypes.string.isRequired,
283
291
  href: PropTypes.string
@@ -9,6 +9,8 @@ export interface IContent {
9
9
  buttonTitle?: string;
10
10
  /** Добавляет атрибут download для тега <a> компонента Button */
11
11
  buttonDownload?: boolean;
12
+ /** Добавляет атрибут rel для тега <a> компонента Button */
13
+ buttonRel?: string;
12
14
  /** Ссылка на кнопке */
13
15
  href?: string;
14
16
  /** Обработчик клика по кнопке */
@@ -98,6 +98,7 @@ var VideoBlock = function VideoBlock(_ref) {
98
98
  href = _ref2.href,
99
99
  buttonDownload = _ref2.buttonDownload,
100
100
  buttonTitle = _ref2.buttonTitle,
101
+ buttonRel = _ref2.buttonRel,
101
102
  onButtonClick = _ref2.onButtonClick;
102
103
  return /*#__PURE__*/React.createElement("div", {
103
104
  className: cn('content', {
@@ -115,7 +116,8 @@ var VideoBlock = function VideoBlock(_ref) {
115
116
  className: cn('button', [classes.button]),
116
117
  href: href,
117
118
  onClick: onButtonClick,
118
- download: buttonDownload
119
+ download: buttonDownload,
120
+ rel: buttonRel
119
121
  }, buttonTitle));
120
122
  }, [classes.button, classes.description, dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.button, contentPositionRight]);
121
123
  var renderGridColumns = React.useCallback(function () {
@@ -176,6 +178,7 @@ VideoBlock.propTypes = {
176
178
  href: PropTypes.string,
177
179
  buttonTitle: PropTypes.string,
178
180
  buttonDownload: PropTypes.bool,
181
+ buttonRel: PropTypes.string,
179
182
  onButtonClick: PropTypes.func
180
183
  }),
181
184
  videoType: PropTypes.oneOf(Object.values(VideoTypes)),