@gravity-ui/page-constructor 4.31.1-alpha.0 → 4.33.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 (116) hide show
  1. package/build/cjs/blocks/Header/Header.js +6 -2
  2. package/build/cjs/blocks/Tabs/Tabs.js +8 -1
  3. package/build/cjs/blocks/index.d.ts +0 -1
  4. package/build/cjs/blocks/index.js +1 -3
  5. package/build/cjs/components/BackLink/BackLink.d.ts +3 -2
  6. package/build/cjs/components/BackLink/BackLink.js +2 -2
  7. package/build/cjs/components/Button/Button.d.ts +0 -1
  8. package/build/cjs/components/DefaultVideo/DefaultVideo.css +5 -0
  9. package/build/cjs/components/DefaultVideo/DefaultVideo.d.ts +11 -0
  10. package/build/cjs/components/DefaultVideo/DefaultVideo.js +60 -0
  11. package/build/cjs/components/FileLink/FileLink.js +2 -2
  12. package/build/cjs/components/FullscreenImage/FullscreenImage.d.ts +2 -1
  13. package/build/cjs/components/FullscreenImage/FullscreenImage.js +2 -2
  14. package/build/cjs/components/Image/Image.js +2 -2
  15. package/build/cjs/components/Link/Link.js +4 -4
  16. package/build/cjs/components/Media/Video/Video.css +0 -5
  17. package/build/cjs/components/Media/Video/Video.js +3 -7
  18. package/build/cjs/components/Title/Title.d.ts +2 -1
  19. package/build/cjs/components/Title/Title.js +2 -2
  20. package/build/cjs/components/Title/TitleItem.css +3 -3
  21. package/build/cjs/components/YandexForm/YandexForm.d.ts +17 -2
  22. package/build/cjs/components/YandexForm/YandexForm.js +4 -6
  23. package/build/cjs/constructor-items.d.ts +0 -1
  24. package/build/cjs/constructor-items.js +0 -1
  25. package/build/cjs/models/constructor-items/blocks.d.ts +6 -31
  26. package/build/cjs/models/constructor-items/blocks.js +1 -13
  27. package/build/cjs/models/constructor-items/common.d.ts +6 -19
  28. package/build/cjs/models/guards.d.ts +1 -3
  29. package/build/cjs/models/guards.js +1 -9
  30. package/build/cjs/models/navigation.d.ts +1 -0
  31. package/build/cjs/navigation/components/Logo/Logo.css +1 -0
  32. package/build/cjs/navigation/components/Logo/Logo.js +10 -5
  33. package/build/cjs/schema/constants.js +1 -2
  34. package/build/cjs/schema/validators/blocks.d.ts +0 -1
  35. package/build/cjs/schema/validators/blocks.js +0 -1
  36. package/build/cjs/sub-blocks/BasicCard/BasicCard.js +5 -2
  37. package/build/cjs/sub-blocks/Content/Content.js +12 -5
  38. package/build/cjs/sub-blocks/HubspotForm/HubspotForm.css +10 -10
  39. package/build/cjs/sub-blocks/LayoutItem/utils.d.ts +1 -0
  40. package/build/cjs/sub-blocks/Quote/Quote.css +0 -2
  41. package/build/esm/blocks/Header/Header.js +6 -2
  42. package/build/esm/blocks/Tabs/Tabs.js +8 -1
  43. package/build/esm/blocks/index.d.ts +0 -1
  44. package/build/esm/blocks/index.js +0 -1
  45. package/build/esm/components/BackLink/BackLink.d.ts +3 -2
  46. package/build/esm/components/BackLink/BackLink.js +2 -2
  47. package/build/esm/components/Button/Button.d.ts +0 -1
  48. package/build/esm/components/DefaultVideo/DefaultVideo.css +5 -0
  49. package/build/esm/components/DefaultVideo/DefaultVideo.d.ts +12 -0
  50. package/build/esm/components/DefaultVideo/DefaultVideo.js +57 -0
  51. package/build/esm/components/FileLink/FileLink.js +2 -2
  52. package/build/esm/components/FullscreenImage/FullscreenImage.d.ts +2 -1
  53. package/build/esm/components/FullscreenImage/FullscreenImage.js +2 -2
  54. package/build/esm/components/Image/Image.js +3 -2
  55. package/build/esm/components/Link/Link.js +4 -4
  56. package/build/esm/components/Media/Video/Video.css +0 -5
  57. package/build/esm/components/Media/Video/Video.js +3 -7
  58. package/build/esm/components/Title/Title.d.ts +2 -1
  59. package/build/esm/components/Title/Title.js +2 -2
  60. package/build/esm/components/Title/TitleItem.css +3 -3
  61. package/build/esm/components/YandexForm/YandexForm.d.ts +17 -2
  62. package/build/esm/components/YandexForm/YandexForm.js +3 -5
  63. package/build/esm/constructor-items.d.ts +0 -1
  64. package/build/esm/constructor-items.js +1 -2
  65. package/build/esm/models/constructor-items/blocks.d.ts +6 -31
  66. package/build/esm/models/constructor-items/blocks.js +0 -12
  67. package/build/esm/models/constructor-items/common.d.ts +6 -19
  68. package/build/esm/models/guards.d.ts +1 -3
  69. package/build/esm/models/guards.js +1 -7
  70. package/build/esm/models/navigation.d.ts +1 -0
  71. package/build/esm/navigation/components/Logo/Logo.css +1 -0
  72. package/build/esm/navigation/components/Logo/Logo.js +11 -6
  73. package/build/esm/schema/constants.js +2 -3
  74. package/build/esm/schema/validators/blocks.d.ts +0 -1
  75. package/build/esm/schema/validators/blocks.js +0 -1
  76. package/build/esm/sub-blocks/BasicCard/BasicCard.js +5 -2
  77. package/build/esm/sub-blocks/Content/Content.js +12 -5
  78. package/build/esm/sub-blocks/HubspotForm/HubspotForm.css +10 -10
  79. package/build/esm/sub-blocks/LayoutItem/utils.d.ts +1 -0
  80. package/build/esm/sub-blocks/Quote/Quote.css +0 -2
  81. package/package.json +1 -1
  82. package/server/models/constructor-items/blocks.d.ts +6 -31
  83. package/server/models/constructor-items/blocks.js +1 -13
  84. package/server/models/constructor-items/common.d.ts +6 -19
  85. package/server/models/guards.d.ts +1 -3
  86. package/server/models/guards.js +1 -9
  87. package/server/models/navigation.d.ts +1 -0
  88. package/widget/index.js +1 -1
  89. package/build/cjs/blocks/Form/Form.css +0 -136
  90. package/build/cjs/blocks/Form/Form.d.ts +0 -4
  91. package/build/cjs/blocks/Form/Form.js +0 -61
  92. package/build/cjs/blocks/Form/HubspotInlineForm.d.ts +0 -7
  93. package/build/cjs/blocks/Form/HubspotInlineForm.js +0 -14
  94. package/build/cjs/blocks/Form/InnerForm/InnerForm.d.ts +0 -9
  95. package/build/cjs/blocks/Form/InnerForm/InnerForm.js +0 -28
  96. package/build/cjs/blocks/Form/schema.d.ts +0 -202
  97. package/build/cjs/blocks/Form/schema.js +0 -44
  98. package/build/cjs/components/YandexForm/schema.d.ts +0 -16
  99. package/build/cjs/components/YandexForm/schema.js +0 -13
  100. package/build/cjs/editor/data/templates/form-block.json +0 -20
  101. package/build/cjs/sub-blocks/HubspotForm/schema.d.ts +0 -22
  102. package/build/cjs/sub-blocks/HubspotForm/schema.js +0 -17
  103. package/build/esm/blocks/Form/Form.css +0 -136
  104. package/build/esm/blocks/Form/Form.d.ts +0 -5
  105. package/build/esm/blocks/Form/Form.js +0 -59
  106. package/build/esm/blocks/Form/HubspotInlineForm.d.ts +0 -7
  107. package/build/esm/blocks/Form/HubspotInlineForm.js +0 -12
  108. package/build/esm/blocks/Form/InnerForm/InnerForm.d.ts +0 -9
  109. package/build/esm/blocks/Form/InnerForm/InnerForm.js +0 -26
  110. package/build/esm/blocks/Form/schema.d.ts +0 -202
  111. package/build/esm/blocks/Form/schema.js +0 -40
  112. package/build/esm/components/YandexForm/schema.d.ts +0 -16
  113. package/build/esm/components/YandexForm/schema.js +0 -10
  114. package/build/esm/editor/data/templates/form-block.json +0 -20
  115. package/build/esm/sub-blocks/HubspotForm/schema.d.ts +0 -22
  116. package/build/esm/sub-blocks/HubspotForm/schema.js +0 -14
@@ -1,7 +1,7 @@
1
- import React, { CSSProperties, ReactNode } from 'react';
1
+ import React, { CSSProperties, HTMLProps, ReactNode } from 'react';
2
2
  import { ButtonView, ButtonProps as UikitButtonProps } from '@gravity-ui/uikit';
3
3
  import { ThemeSupporting } from '../../utils';
4
- import { AnalyticsEventsBase, ClassNameProps, PixelEvent, PixelEventType, QAProps } from '../common';
4
+ import { AnalyticsEventsBase, ClassNameProps, PixelEventType, QAProps } from '../common';
5
5
  export declare enum AuthorType {
6
6
  Column = "column",
7
7
  Line = "line"
@@ -95,7 +95,7 @@ interface LoopProps {
95
95
  start: number;
96
96
  end?: number;
97
97
  }
98
- export interface ImageInfoProps {
98
+ export interface ImageInfoProps extends Pick<HTMLProps<HTMLImageElement>, 'aria-describedby'> {
99
99
  alt?: string;
100
100
  disableCompress?: boolean;
101
101
  }
@@ -138,6 +138,7 @@ export interface LinkProps extends AnalyticsEventsBase, Stylable, Tabbable {
138
138
  target?: string;
139
139
  metrikaGoals?: MetrikaGoal;
140
140
  pixelEvents?: ButtonPixel;
141
+ extraProps?: HTMLProps<HTMLAnchorElement>;
141
142
  }
142
143
  export interface FileLinkProps extends ClassNameProps, Tabbable {
143
144
  href: string;
@@ -147,11 +148,13 @@ export interface FileLinkProps extends ClassNameProps, Tabbable {
147
148
  theme?: ContentTheme;
148
149
  urlTitle?: string;
149
150
  onClick?: () => void;
151
+ extraProps?: HTMLProps<HTMLAnchorElement>;
150
152
  }
151
153
  export type ButtonTheme = ButtonView | 'github' | 'app-store' | 'google-play' | 'scale' | 'monochrome';
152
154
  export interface ButtonProps extends AnalyticsEventsBase, Pick<UikitButtonProps, 'size' | 'width' | 'extraProps'> {
153
155
  text: string;
154
156
  url: string;
157
+ urlTitle?: string;
155
158
  primary?: boolean;
156
159
  theme?: ButtonTheme;
157
160
  img?: ButtonImageProps | string;
@@ -337,20 +340,4 @@ export interface TitleProps {
337
340
  title?: TitleItemProps | string;
338
341
  subtitle?: string;
339
342
  }
340
- export interface YandexFormProps extends AnalyticsEventsBase {
341
- id: number | string;
342
- containerId?: string;
343
- theme?: string;
344
- className?: string;
345
- headerHeight?: number;
346
- customFormOrigin?: string;
347
- customFormSection?: string;
348
- params?: {
349
- [key: string]: string;
350
- };
351
- onSubmit?: () => void;
352
- onLoad?: () => void;
353
- metrikaGoals?: string | string[];
354
- pixelEvents?: string | string[] | PixelEvent | PixelEvent[];
355
- }
356
343
  export {};
@@ -1,6 +1,4 @@
1
- import { Block, ConstructorItem, FormBlockData, FormBlockHubspotData, FormBlockYandexData } from './';
1
+ import { Block, ConstructorItem } from './';
2
2
  import { MetrikaGoal, NewMetrikaGoal } from './index';
3
3
  export declare function isBlock(block: ConstructorItem): block is Block;
4
4
  export declare function isNewMetrikaFormat(metrika: MetrikaGoal): metrika is NewMetrikaGoal[];
5
- export declare function isYandexDataForm(data: FormBlockData): data is FormBlockYandexData;
6
- export declare function isHubspotDataForm(data: FormBlockData): data is FormBlockHubspotData;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isHubspotDataForm = exports.isYandexDataForm = exports.isNewMetrikaFormat = exports.isBlock = void 0;
3
+ exports.isNewMetrikaFormat = exports.isBlock = void 0;
4
4
  const _1 = require("./");
5
5
  function isBlock(block) {
6
6
  return block.type in _1.BlockTypes;
@@ -10,11 +10,3 @@ function isNewMetrikaFormat(metrika) {
10
10
  return Boolean(Array.isArray(metrika) && metrika.length && typeof metrika[0] === 'object');
11
11
  }
12
12
  exports.isNewMetrikaFormat = isNewMetrikaFormat;
13
- function isYandexDataForm(data) {
14
- return Boolean(data.yandex);
15
- }
16
- exports.isYandexDataForm = isYandexDataForm;
17
- function isHubspotDataForm(data) {
18
- return Boolean(data.hubspot);
19
- }
20
- exports.isHubspotDataForm = isHubspotDataForm;
@@ -62,6 +62,7 @@ export interface NavigationLogoData {
62
62
  icon: ImageProps;
63
63
  text?: string;
64
64
  url?: string;
65
+ urlTitle?: string;
65
66
  }
66
67
  export type ThemedNavigationLogoData = NavigationLogoData & ThemeSupporting<NavigationLogoData>;
67
68
  export interface HeaderData {
@@ -7,6 +7,7 @@ unpredictable css rules order in build */
7
7
  .pc-logo {
8
8
  display: flex;
9
9
  align-items: center;
10
+ text-decoration: none;
10
11
  }
11
12
  .pc-logo__icon {
12
13
  display: flex;
@@ -1,21 +1,26 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const react_1 = tslib_1.__importDefault(require("react"));
4
+ const react_1 = tslib_1.__importStar(require("react"));
5
5
  const components_1 = require("../../../components");
6
6
  const utils_1 = require("../../../components/Media/Image/utils");
7
7
  const RouterLink_1 = tslib_1.__importDefault(require("../../../components/RouterLink/RouterLink"));
8
+ const locationContext_1 = require("../../../context/locationContext");
8
9
  const theme_1 = require("../../../context/theme");
9
10
  const utils_2 = require("../../../utils");
10
11
  const b = (0, utils_2.block)('logo');
11
12
  const Logo = (props) => {
13
+ const { hostname, Link } = (0, react_1.useContext)(locationContext_1.LocationContext);
12
14
  const theme = (0, theme_1.useTheme)();
13
15
  const themedLogoProps = (0, utils_2.getThemedValue)(props, theme) || props;
14
16
  const imageData = (0, utils_1.getMediaImage)(themedLogoProps.icon || props.icon);
15
17
  const textData = themedLogoProps.text || props.text;
16
- return (react_1.default.createElement(RouterLink_1.default, { href: themedLogoProps.url || props.url || '/', passHref: true },
17
- react_1.default.createElement("div", { className: b(null, props.className) },
18
- imageData && react_1.default.createElement(components_1.Image, Object.assign({ className: b('icon') }, imageData)),
19
- react_1.default.createElement("span", { className: b('text') }, textData))));
18
+ const url = themedLogoProps.url || props.url || '/';
19
+ const urlTitle = themedLogoProps.urlTitle || props.urlTitle || textData;
20
+ const linkExtraProps = (0, utils_2.getLinkProps)(url, hostname);
21
+ const content = (react_1.default.createElement(react_1.Fragment, null,
22
+ imageData && react_1.default.createElement(components_1.Image, Object.assign({ className: b('icon') }, imageData)),
23
+ react_1.default.createElement("span", { className: b('text') }, textData)));
24
+ return (react_1.default.createElement(RouterLink_1.default, { href: url, passHref: true }, Link ? (react_1.default.createElement("span", { className: b(null, props.className) }, content)) : (react_1.default.createElement("a", Object.assign({ className: b(null, props.className), href: url, title: urlTitle }, linkExtraProps), content))));
20
25
  };
21
26
  exports.default = Logo;
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.constructorCardSchemaNames = exports.constructorBlockSchemaNames = exports.cardSchemas = exports.blockSchemas = void 0;
4
4
  const blocks_1 = require("./validators/blocks");
5
5
  const sub_blocks_1 = require("./validators/sub-blocks");
6
- exports.blockSchemas = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, sub_blocks_1.Divider), blocks_1.ExtendedFeaturesBlock), blocks_1.PromoFeaturesBlock), blocks_1.SliderBlock), blocks_1.QuestionsBlock), blocks_1.HeaderBlock), blocks_1.BannerBlock), blocks_1.CompaniesBlock), blocks_1.MediaBlock), blocks_1.MapBlock), blocks_1.InfoBlock), blocks_1.TableBlock), blocks_1.TabsBlock), blocks_1.HeaderSliderBlock), blocks_1.IconsBlock), blocks_1.CardLayoutBlock), blocks_1.ContentLayoutBlock), blocks_1.ShareBlock), blocks_1.FilterBlock), blocks_1.FormBlock);
6
+ exports.blockSchemas = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, sub_blocks_1.Divider), blocks_1.ExtendedFeaturesBlock), blocks_1.PromoFeaturesBlock), blocks_1.SliderBlock), blocks_1.QuestionsBlock), blocks_1.HeaderBlock), blocks_1.BannerBlock), blocks_1.CompaniesBlock), blocks_1.MediaBlock), blocks_1.MapBlock), blocks_1.InfoBlock), blocks_1.TableBlock), blocks_1.TabsBlock), blocks_1.HeaderSliderBlock), blocks_1.IconsBlock), blocks_1.CardLayoutBlock), blocks_1.ContentLayoutBlock), blocks_1.ShareBlock), blocks_1.FilterBlock);
7
7
  exports.cardSchemas = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, sub_blocks_1.MediaCardBlock), blocks_1.BannerCard), sub_blocks_1.PriceDetailedBlock), sub_blocks_1.BackgroundCard), sub_blocks_1.Quote), sub_blocks_1.BasicCard);
8
8
  exports.constructorBlockSchemaNames = [
9
9
  'divider',
@@ -30,7 +30,6 @@ exports.constructorBlockSchemaNames = [
30
30
  'content-layout-block',
31
31
  'share-block',
32
32
  'filter-block',
33
- 'form-block',
34
33
  ];
35
34
  exports.constructorCardSchemaNames = [
36
35
  'media-card',
@@ -16,4 +16,3 @@ export * from '../../blocks/CardLayout/schema';
16
16
  export * from '../../blocks/ContentLayout/schema';
17
17
  export * from '../../blocks/Share/schema';
18
18
  export * from '../../blocks/FilterBlock/schema';
19
- export * from '../../blocks/Form/schema';
@@ -19,4 +19,3 @@ tslib_1.__exportStar(require("../../blocks/CardLayout/schema"), exports);
19
19
  tslib_1.__exportStar(require("../../blocks/ContentLayout/schema"), exports);
20
20
  tslib_1.__exportStar(require("../../blocks/Share/schema"), exports);
21
21
  tslib_1.__exportStar(require("../../blocks/FilterBlock/schema"), exports);
22
- tslib_1.__exportStar(require("../../blocks/Form/schema"), exports);
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const react_1 = tslib_1.__importDefault(require("react"));
5
+ const uikit_1 = require("@gravity-ui/uikit");
5
6
  const __1 = require("../");
6
7
  const CardBase_1 = tslib_1.__importDefault(require("../../components/CardBase/CardBase"));
7
8
  const Image_1 = tslib_1.__importDefault(require("../../components/Image/Image"));
@@ -12,10 +13,12 @@ const b = (0, utils_2.block)('basic-card');
12
13
  const BasicCard = (props) => {
13
14
  const { title, text, icon, additionalInfo, links, buttons, iconPosition = sub_blocks_1.IconPosition.Top } = props, cardParams = tslib_1.__rest(props, ["title", "text", "icon", "additionalInfo", "links", "buttons", "iconPosition"]);
14
15
  const iconProps = icon && (0, utils_1.getMediaImage)(icon);
15
- return (react_1.default.createElement(CardBase_1.default, Object.assign({ className: b() }, cardParams),
16
+ const titleId = (0, uikit_1.useUniqId)();
17
+ const descriptionId = (0, uikit_1.useUniqId)();
18
+ return (react_1.default.createElement(CardBase_1.default, Object.assign({ className: b() }, cardParams, { extraProps: { 'aria-describedby': descriptionId, 'aria-labelledby': titleId } }),
16
19
  react_1.default.createElement(CardBase_1.default.Content, null,
17
20
  react_1.default.createElement("div", { className: b('content', { ['icon-position']: iconPosition }) },
18
21
  iconProps && (react_1.default.createElement(Image_1.default, Object.assign({}, iconProps, { className: b('icon', { ['icon-position']: iconPosition }) }))),
19
- react_1.default.createElement(__1.Content, { title: title, text: text, additionalInfo: additionalInfo, links: links, buttons: buttons, colSizes: { all: 12, md: 12 }, size: "s", className: b({ ['content-layout']: iconPosition }) })))));
22
+ react_1.default.createElement(__1.Content, { title: title, titleId: titleId, text: text, textId: descriptionId, additionalInfo: additionalInfo, links: links, buttons: buttons, colSizes: { all: 12, md: 12 }, size: "s", className: b({ ['content-layout']: iconPosition }) })))));
20
23
  };
21
24
  exports.default = BasicCard;
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const react_1 = tslib_1.__importDefault(require("react"));
5
+ const uikit_1 = require("@gravity-ui/uikit");
5
6
  const components_1 = require("../../components");
6
7
  const Link_1 = tslib_1.__importDefault(require("../../components/Link/Link"));
7
8
  const grid_1 = require("../../grid");
@@ -37,16 +38,18 @@ function getButtonSize(size) {
37
38
  }
38
39
  }
39
40
  const Content = (props) => {
40
- const { title, text, additionalInfo, size = 'l', links, buttons, colSizes = { all: 12, sm: 8 }, centered, theme, className, list, qa, } = props;
41
+ const { title, titleId: titleIdFromProps, text, textId, additionalInfo, size = 'l', links, buttons, colSizes = { all: 12, sm: 8 }, centered, theme, className, list, qa, } = props;
41
42
  const qaAttributes = (0, blocks_1.getQaAttrubutes)(qa, ['links', 'link', 'buttons', 'button', 'list']);
42
43
  const titleProps = !title || typeof title === 'string'
43
44
  ? { text: title, textSize: getTextSize(size) }
44
45
  : title;
45
46
  const hasTitle = Boolean(title);
47
+ const defaultTitleId = (0, uikit_1.useUniqId)();
48
+ const titleId = titleIdFromProps || defaultTitleId;
46
49
  return (react_1.default.createElement(grid_1.Col, { className: b({ size, centered, theme }, className), reset: true, sizes: colSizes, qa: qaAttributes.container },
47
- title && react_1.default.createElement(components_1.Title, { className: b('title'), title: titleProps, colSizes: { all: 12 } }),
50
+ title && (react_1.default.createElement(components_1.Title, { className: b('title'), title: titleProps, colSizes: { all: 12 }, id: titleId })),
48
51
  text && (react_1.default.createElement("div", { className: b('text', { ['without-title']: !hasTitle }) },
49
- react_1.default.createElement(components_1.YFMWrapper, { content: text, modifiers: { constructor: true, [`constructor-size-${size}`]: true } }))),
52
+ react_1.default.createElement(components_1.YFMWrapper, { content: text, modifiers: { constructor: true, [`constructor-size-${size}`]: true }, id: textId }))),
50
53
  (list === null || list === void 0 ? void 0 : list.length) ? react_1.default.createElement(ContentList_1.default, { list: list, size: size, qa: qaAttributes.list }) : null,
51
54
  additionalInfo && (react_1.default.createElement("div", { className: b('notice') },
52
55
  react_1.default.createElement(components_1.YFMWrapper, { content: additionalInfo, modifiers: {
@@ -54,7 +57,11 @@ const Content = (props) => {
54
57
  'constructor-notice': true,
55
58
  [`constructor-size-${size}`]: true,
56
59
  } }))),
57
- links && (react_1.default.createElement("div", { className: b('links'), "data-qa": qaAttributes.links }, links.map((link) => (react_1.default.createElement(Link_1.default, Object.assign({ className: b('link') }, link, { textSize: getLinkSize(size), key: link.url, qa: qaAttributes.link })))))),
58
- buttons && (react_1.default.createElement("div", { className: b('buttons'), "data-qa": qaAttributes.buttons }, buttons.map((item) => (react_1.default.createElement(components_1.Button, Object.assign({ className: b('button') }, item, { key: item.url, size: getButtonSize(size), qa: qaAttributes.button }))))))));
60
+ links && (react_1.default.createElement("div", { className: b('links'), "data-qa": qaAttributes.links }, links.map((link) => (react_1.default.createElement(Link_1.default, Object.assign({ className: b('link') }, link, { textSize: getLinkSize(size), key: link.url, qa: qaAttributes.link, extraProps: {
61
+ 'aria-describedby': link.urlTitle ? undefined : titleId,
62
+ } })))))),
63
+ buttons && (react_1.default.createElement("div", { className: b('buttons'), "data-qa": qaAttributes.buttons }, buttons.map((item) => (react_1.default.createElement(components_1.Button, Object.assign({ className: b('button') }, item, { key: item.url, size: getButtonSize(size), qa: qaAttributes.button, extraProps: {
64
+ 'aria-describedby': item.urlTitle ? undefined : titleId,
65
+ } }))))))));
59
66
  };
60
67
  exports.default = Content;
@@ -239,16 +239,6 @@ unpredictable css rules order in build */
239
239
  font-weight: var(--g-text-body-font-weight);
240
240
  margin: 20px 0;
241
241
  }
242
- .pc-hubspot-form .hs-richtext a:focus {
243
- box-shadow: 0 0 0 2px var(--g-color-line-focus);
244
- }
245
- .pc-hubspot-form .hs-richtext a:focus:not(:focus-visible) {
246
- box-shadow: none;
247
- }
248
- .pc-hubspot-form .hs-richtext a:focus {
249
- outline: 0;
250
- border-radius: var(--g-focus-border-radius);
251
- }
252
242
  .pc-hubspot-form .hs_error_rollup {
253
243
  padding-left: 10px;
254
244
  font-size: var(--g-text-body-1-font-size);
@@ -390,6 +380,16 @@ unpredictable css rules order in build */
390
380
  .pc-hubspot-form_mobile .hs-button.primary {
391
381
  width: 80%;
392
382
  }
383
+ .pc-hubspot-form a:focus {
384
+ box-shadow: 0 0 0 2px var(--g-color-line-focus);
385
+ }
386
+ .pc-hubspot-form a:focus:not(:focus-visible) {
387
+ box-shadow: none;
388
+ }
389
+ .pc-hubspot-form a:focus {
390
+ outline: 0;
391
+ border-radius: var(--g-focus-border-radius);
392
+ }
393
393
  .pc-hubspot-form_theme_dark {
394
394
  --g-color-line-focus: var(--pc-color-line-focus-dark);
395
395
  }
@@ -10,6 +10,7 @@ export declare const getLayoutItemLinks: (links: LayoutItemProps['content']['lin
10
10
  target?: string | undefined;
11
11
  metrikaGoals?: import("../../models").MetrikaGoal | undefined;
12
12
  pixelEvents?: import("../../models").ButtonPixel | undefined;
13
+ extraProps?: import("react").HTMLProps<HTMLAnchorElement> | undefined;
13
14
  analyticsEvents?: {
14
15
  name: string;
15
16
  type?: string | undefined;
@@ -62,7 +62,6 @@ unpredictable css rules order in build */
62
62
  }
63
63
  .pc-quote__content_quote-type_chevron::before {
64
64
  position: absolute;
65
- top: -1px;
66
65
  left: -10px;
67
66
  content: "«";
68
67
  }
@@ -71,7 +70,6 @@ unpredictable css rules order in build */
71
70
  }
72
71
  .pc-quote__content_quote-type_english-double::before {
73
72
  position: absolute;
74
- top: -1px;
75
73
  left: -8px;
76
74
  content: "“";
77
75
  }
@@ -1,4 +1,5 @@
1
1
  import React, { useContext } from 'react';
2
+ import { useUniqId } from '@gravity-ui/uikit';
2
3
  import { Button, HTML, Media, RouterLink } from '../../components';
3
4
  import HeaderBreadcrumbs from '../../components/HeaderBreadcrumbs/HeaderBreadcrumbs';
4
5
  import { getMediaImage } from '../../components/Media/Image/utils';
@@ -32,6 +33,7 @@ export const HeaderBlock = (props) => {
32
33
  const imageThemed = image && getThemedValue(image, theme);
33
34
  const videoThemed = video && getThemedValue(video, theme);
34
35
  const fullWidth = (backgroundThemed === null || backgroundThemed === void 0 ? void 0 : backgroundThemed.fullWidth) || (backgroundThemed === null || backgroundThemed === void 0 ? void 0 : backgroundThemed.fullWidthMedia);
36
+ const titleId = useUniqId();
35
37
  return (React.createElement("header", { className: b({
36
38
  ['has-media']: hasRightSideImage,
37
39
  ['full-width']: fullWidth,
@@ -54,7 +56,7 @@ export const HeaderBlock = (props) => {
54
56
  React.createElement(Col, { sizes: titleSizes, className: b('content-inner') },
55
57
  overtitle && (React.createElement("div", { className: b('overtitle') },
56
58
  React.createElement(HTML, null, overtitle))),
57
- React.createElement("h1", { className: b('title') },
59
+ React.createElement("h1", { className: b('title'), id: titleId },
58
60
  status,
59
61
  renderTitle ? renderTitle(title) : React.createElement(HTML, null, title)),
60
62
  description && (React.createElement("div", { className: b('description') },
@@ -63,7 +65,9 @@ export const HeaderBlock = (props) => {
63
65
  constructorTheme: textTheme,
64
66
  } }))),
65
67
  buttons && (React.createElement("div", { className: b('buttons'), "data-qa": "header-buttons" }, buttons.map((button, index) => (React.createElement(RouterLink, { href: button.url, key: index },
66
- React.createElement(Button, Object.assign({ key: index, className: b('button'), size: "xl" }, button))))))),
68
+ React.createElement(Button, Object.assign({ key: index, className: b('button'), size: "xl", extraProps: {
69
+ 'aria-describedby': titleId,
70
+ } }, button))))))),
67
71
  children))),
68
72
  hasRightSideImage && (React.createElement(Media, { className: b('media', { [curImageSize]: true }), videoClassName: b('video'), imageClassName: b('image'), video: videoThemed, image: imageThemed })))))));
69
73
  };
@@ -1,4 +1,5 @@
1
1
  import React, { Fragment, useRef, useState } from 'react';
2
+ import { useUniqId } from '@gravity-ui/uikit';
2
3
  import AnimateBlock from '../../components/AnimateBlock/AnimateBlock';
3
4
  import ButtonTabs from '../../components/ButtonTabs/ButtonTabs';
4
5
  import FullscreenImage from '../../components/FullscreenImage/FullscreenImage';
@@ -23,10 +24,16 @@ export const TabsBlock = ({ items, title, description, animated, tabsColSizes, c
23
24
  const ref = useRef(null);
24
25
  const mediaWidth = (_a = ref === null || ref === void 0 ? void 0 : ref.current) === null || _a === void 0 ? void 0 : _a.offsetWidth;
25
26
  const mediaHeight = mediaWidth && getHeight(mediaWidth);
27
+ const captionId = useUniqId();
26
28
  let imageProps;
27
29
  if (activeTabData) {
28
30
  const themedImage = getThemedValue(activeTabData.image, theme);
29
31
  imageProps = themedImage && getMediaImage(themedImage);
32
+ if (activeTabData.caption && imageProps) {
33
+ Object.assign(imageProps, {
34
+ 'aria-describedby': captionId,
35
+ });
36
+ }
30
37
  }
31
38
  const showMedia = Boolean((activeTabData === null || activeTabData === void 0 ? void 0 : activeTabData.media) || imageProps);
32
39
  const showText = Boolean(activeTabData === null || activeTabData === void 0 ? void 0 : activeTabData.text);
@@ -45,7 +52,7 @@ export const TabsBlock = ({ items, title, description, animated, tabsColSizes, c
45
52
  React.createElement("div", { ref: ref }, (activeTabData === null || activeTabData === void 0 ? void 0 : activeTabData.media) && (React.createElement(Media, Object.assign({}, getThemedValue(activeTabData.media, theme), { key: activeTab, className: b('media'), playVideo: play, height: mediaHeight })))),
46
53
  imageProps && (React.createElement(Fragment, null,
47
54
  React.createElement(FullscreenImage, Object.assign({}, imageProps, { imageClassName: b('image') })))),
48
- (activeTabData === null || activeTabData === void 0 ? void 0 : activeTabData.caption) && React.createElement("p", { className: b('caption') }, activeTabData.caption)));
55
+ (activeTabData === null || activeTabData === void 0 ? void 0 : activeTabData.caption) && (React.createElement("p", { className: b('caption'), id: captionId }, activeTabData.caption))));
49
56
  const onSelectTab = (id, e) => {
50
57
  setActiveTab(id);
51
58
  e.currentTarget.scrollIntoView({ inline: 'center', behavior: 'smooth', block: 'nearest' });
@@ -16,4 +16,3 @@ export { default as CardLayoutBlock } from './CardLayout/CardLayout';
16
16
  export { default as ContentLayoutBlock } from './ContentLayout/ContentLayout';
17
17
  export { default as ShareBlock } from './Share/Share';
18
18
  export { default as FilterBlock } from './FilterBlock/FilterBlock';
19
- export { default as FormBlock } from './Form/Form';
@@ -16,4 +16,3 @@ export { default as CardLayoutBlock } from './CardLayout/CardLayout';
16
16
  export { default as ContentLayoutBlock } from './ContentLayout/ContentLayout';
17
17
  export { default as ShareBlock } from './Share/Share';
18
18
  export { default as FilterBlock } from './FilterBlock/FilterBlock';
19
- export { default as FormBlock } from './Form/Form';
@@ -1,8 +1,8 @@
1
- import { ReactNode } from 'react';
1
+ import { HTMLProps, ReactNode } from 'react';
2
2
  import { ButtonSize } from '@gravity-ui/uikit';
3
3
  import { Tabbable } from '../../models';
4
4
  export type Theme = 'default' | 'special';
5
- export interface BackLinkProps extends Tabbable {
5
+ export interface BackLinkProps<T = HTMLElement> extends Tabbable {
6
6
  url: string;
7
7
  title: ReactNode;
8
8
  theme?: Theme;
@@ -10,5 +10,6 @@ export interface BackLinkProps extends Tabbable {
10
10
  className?: string;
11
11
  shouldHandleBackAction?: boolean;
12
12
  onClick?: () => void;
13
+ extraProps?: HTMLProps<T>;
13
14
  }
14
15
  export default function BackLink(props: BackLinkProps): JSX.Element;
@@ -6,7 +6,7 @@ import { ArrowSidebar } from '../../icons';
6
6
  import { DefaultEventNames } from '../../models';
7
7
  export default function BackLink(props) {
8
8
  const { history } = useContext(LocationContext);
9
- const { url, title, theme = 'default', size = 'l', className, shouldHandleBackAction = false, onClick, tabIndex, } = props;
9
+ const { url, title, theme = 'default', size = 'l', className, shouldHandleBackAction = false, onClick, tabIndex, extraProps, } = props;
10
10
  const handleAnalytics = useAnalytics(DefaultEventNames.ShareButton, url);
11
11
  const backActionHandler = useCallback(async () => {
12
12
  handleAnalytics();
@@ -23,7 +23,7 @@ export default function BackLink(props) {
23
23
  history.push({ pathname: url });
24
24
  }
25
25
  }, [handleAnalytics, history, onClick, url]);
26
- return (React.createElement(Button, { className: className, view: theme === 'special' ? 'flat-contrast' : 'flat-secondary', size: size, href: shouldHandleBackAction ? undefined : url, onClick: shouldHandleBackAction ? backActionHandler : undefined, tabIndex: tabIndex },
26
+ return (React.createElement(Button, { className: className, view: theme === 'special' ? 'flat-contrast' : 'flat-secondary', size: size, href: shouldHandleBackAction ? undefined : url, onClick: shouldHandleBackAction ? backActionHandler : undefined, tabIndex: tabIndex, extraProps: extraProps },
27
27
  React.createElement(Icon, { data: ArrowSidebar, size: 24 }),
28
28
  React.createElement("span", null, title)));
29
29
  }
@@ -4,7 +4,6 @@ import './Button.css';
4
4
  export interface ButtonProps extends Omit<ButtonParams, 'url'>, QAProps {
5
5
  className?: string;
6
6
  url?: string;
7
- urlTitle?: string;
8
7
  onClick?: React.MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>;
9
8
  }
10
9
  declare const Button: (props: ButtonProps) => JSX.Element;
@@ -0,0 +1,5 @@
1
+ .pc-default-video {
2
+ width: 100%;
3
+ display: flex;
4
+ align-items: center;
5
+ }
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ import { MediaVideoProps } from '../../models';
3
+ import './DefaultVideo.css';
4
+ type DefaultVideoRefType = HTMLVideoElement | undefined;
5
+ interface DefaultVideoProps {
6
+ video: MediaVideoProps;
7
+ qa?: string;
8
+ customBarControlsClassName?: string;
9
+ className?: string;
10
+ }
11
+ export declare const DefaultVideo: React.ForwardRefExoticComponent<DefaultVideoProps & React.RefAttributes<DefaultVideoRefType>>;
12
+ export {};
@@ -0,0 +1,57 @@
1
+ import React, { Fragment, useCallback, useImperativeHandle, useRef, useState } from 'react';
2
+ import { CustomControlsType, MediaVideoControlsType } from '../../models';
3
+ import { block } from '../../utils';
4
+ import { getVideoTypesWithPriority } from '../Media/Video/utils';
5
+ import CustomBarControls from '../ReactPlayer/CustomBarControls';
6
+ import './DefaultVideo.css';
7
+ const b = block('default-video');
8
+ export const DefaultVideo = React.forwardRef((props, ref) => {
9
+ const { video, qa, customBarControlsClassName } = props;
10
+ const { controls, customControlsOptions, muted: initiallyMuted } = video;
11
+ const { muteButtonShown, positioning, type: customControlsType, } = customControlsOptions || {};
12
+ const [isPaused, setIsPaused] = useState(false);
13
+ const [isMuted, setIsMuted] = useState(initiallyMuted);
14
+ const videoRef = useRef(null);
15
+ // one may not use this hook and work with `ref` variable only, but
16
+ // in this case one should support both function type and object type,
17
+ // according to ForwardedRef type.
18
+ // Currently used way with extra ref and useImperativeHandle is more
19
+ // convenient and allows us to work with object typed ref only,
20
+ // avoiding typeof ref === 'function' statements
21
+ useImperativeHandle(ref, () => {
22
+ if (!(videoRef === null || videoRef === void 0 ? void 0 : videoRef.current)) {
23
+ return undefined;
24
+ }
25
+ return videoRef.current;
26
+ }, [videoRef]);
27
+ const onPlayToggle = useCallback(() => {
28
+ setIsPaused((value) => {
29
+ var _a, _b;
30
+ if (value) {
31
+ (_a = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _a === void 0 ? void 0 : _a.play();
32
+ }
33
+ else {
34
+ (_b = videoRef === null || videoRef === void 0 ? void 0 : videoRef.current) === null || _b === void 0 ? void 0 : _b.pause();
35
+ }
36
+ return !value;
37
+ });
38
+ }, [videoRef]);
39
+ const onMuteToggle = useCallback(() => {
40
+ setIsMuted((value) => !value);
41
+ }, []);
42
+ const onClick = useCallback(() => {
43
+ if (customControlsType === CustomControlsType.WithPlayPauseButton) {
44
+ onPlayToggle();
45
+ }
46
+ }, [onPlayToggle, customControlsType]);
47
+ return (React.createElement(Fragment, null,
48
+ React.createElement("video", { disablePictureInPicture: true, playsInline: true,
49
+ // @ts-ignore
50
+ // eslint-disable-next-line react/no-unknown-property
51
+ pip: "false", className: b(), ref: videoRef, preload: "metadata", muted: isMuted, "aria-label": video.ariaLabel, onClick: onClick }, getVideoTypesWithPriority(video.src).map(({ src, type }, index) => (React.createElement("source", { key: index, src: src, type: type, "data-qa": qa })))),
52
+ controls === MediaVideoControlsType.Custom && (React.createElement(CustomBarControls, { className: customBarControlsClassName, type: customControlsType, isPaused: isPaused, onPlayClick: onPlayToggle, muteButtonShown: muteButtonShown, shown: true, positioning: positioning, mute: {
53
+ isMuted: Boolean(isMuted),
54
+ changeMute: onMuteToggle,
55
+ } }))));
56
+ });
57
+ DefaultVideo.displayName = 'DefaultVideo';
@@ -37,13 +37,13 @@ const LabelSizeMap = {
37
37
  };
38
38
  const FileLink = (props) => {
39
39
  const { hostname } = useContext(LocationContext);
40
- const { href, text, type = 'vertical', textSize = 'm', className, theme = 'default', onClick, tabIndex, urlTitle, } = props;
40
+ const { href, text, type = 'vertical', textSize = 'm', className, theme = 'default', onClick, tabIndex, urlTitle, extraProps, } = props;
41
41
  const fileExt = getFileExt(href);
42
42
  const labelTheme = (FileExtensionThemes[fileExt] || 'unknown');
43
43
  const labelSize = LabelSizeMap[textSize];
44
44
  return (React.createElement("div", { className: b({ ext: fileExt, type, size: textSize, theme }, className) },
45
45
  React.createElement(Label, { className: b('file-label'), size: labelSize, theme: labelTheme }, fileExt),
46
46
  React.createElement("div", { className: b('link') },
47
- React.createElement("a", Object.assign({ href: href, onClick: onClick, tabIndex: tabIndex, title: urlTitle }, getLinkProps(href, hostname)), text))));
47
+ React.createElement("a", Object.assign({ href: href, onClick: onClick, tabIndex: tabIndex, title: urlTitle }, getLinkProps(href, hostname), extraProps), text))));
48
48
  };
49
49
  export default FileLink;
@@ -1,10 +1,11 @@
1
- import { CSSProperties } from 'react';
1
+ import { CSSProperties, HTMLProps } from 'react';
2
2
  import { ImageProps } from '../Image/Image';
3
3
  import './FullscreenImage.css';
4
4
  export interface FullscreenImageProps extends ImageProps {
5
5
  imageClassName?: string;
6
6
  modalImageClass?: string;
7
7
  imageStyle?: CSSProperties;
8
+ extraProps?: HTMLProps<HTMLDivElement>;
8
9
  }
9
10
  declare const FullscreenImage: (props: FullscreenImageProps) => JSX.Element;
10
11
  export default FullscreenImage;
@@ -9,11 +9,11 @@ const b = block('fullscreen-image');
9
9
  const FULL_SCREEN_ICON_SIZE = 18;
10
10
  const CLOSE_ICON_SIZE = 30;
11
11
  const FullscreenImage = (props) => {
12
- const { imageClassName, modalImageClass, imageStyle, alt = i18n('img-alt') } = props;
12
+ const { imageClassName, modalImageClass, imageStyle, alt = i18n('img-alt'), extraProps } = props;
13
13
  const [isOpened, setIsOpened] = useState(false);
14
14
  const openModal = () => setIsOpened(true);
15
15
  const closeModal = () => setIsOpened(false);
16
- return (React.createElement("div", { className: b() },
16
+ return (React.createElement("div", Object.assign({ className: b() }, extraProps),
17
17
  React.createElement("div", { className: b('image-wrapper') },
18
18
  React.createElement(Image, Object.assign({}, props, { alt: alt, className: b('image', imageClassName), onClick: openModal, style: imageStyle })),
19
19
  React.createElement("button", { className: b('icon-wrapper'), onClick: openModal },
@@ -1,3 +1,4 @@
1
+ import { __rest } from "tslib";
1
2
  import React, { Fragment, useContext, useState } from 'react';
2
3
  import { BREAKPOINTS } from '../../constants';
3
4
  import { ProjectSettingsContext } from '../../context/projectSettingsContext';
@@ -12,7 +13,7 @@ const DeviceSpecificFragment = ({ disableWebp, src, breakpoint, qa, }) => (React
12
13
  React.createElement("source", { srcSet: src, media: `(max-width: ${breakpoint}px)`, "data-qa": qa })));
13
14
  const Image = (props) => {
14
15
  const projectSettings = useContext(ProjectSettingsContext);
15
- const { src: imageSrc, alt, disableCompress, tablet, desktop, mobile, style, className, onClick, containerClassName, qa, } = props;
16
+ const { src: imageSrc, alt, disableCompress, tablet, desktop, mobile, style, className, onClick, containerClassName, qa } = props, rest = __rest(props, ["src", "alt", "disableCompress", "tablet", "desktop", "mobile", "style", "className", "onClick", "containerClassName", "qa"]);
16
17
  const [imgLoadingError, setImgLoadingError] = useState(false);
17
18
  const src = imageSrc || desktop;
18
19
  if (!src) {
@@ -27,6 +28,6 @@ const Image = (props) => {
27
28
  mobile && (React.createElement(DeviceSpecificFragment, { src: mobile, disableWebp: disableWebp, breakpoint: BREAKPOINTS.sm, qa: qaAttributes.mobileSource })),
28
29
  tablet && (React.createElement(DeviceSpecificFragment, { src: tablet, disableWebp: disableWebp, breakpoint: BREAKPOINTS.md, qa: qaAttributes.tabletSource })),
29
30
  src && !disableWebp && (React.createElement("source", { srcSet: checkWebP(src), type: "image/webp", "data-qa": qaAttributes.desktopSourceCompressed })),
30
- React.createElement(ImageBase, { className: className, alt: alt, src: src, style: style, onClick: onClick, onError: () => setImgLoadingError(true) })));
31
+ React.createElement(ImageBase, Object.assign({ className: className, alt: alt, src: src, style: style, onClick: onClick, onError: () => setImgLoadingError(true) }, rest))));
31
32
  };
32
33
  export default Image;
@@ -26,7 +26,7 @@ function getArrowSize(size) {
26
26
  }
27
27
  }
28
28
  const LinkBlock = (props) => {
29
- const { text, url, arrow, metrikaGoals, pixelEvents, analyticsEvents, theme = 'file-link', colorTheme = 'light', textSize = 'm', className, target, children, tabIndex, qa, urlTitle, } = props;
29
+ const { text, url, arrow, metrikaGoals, pixelEvents, analyticsEvents, theme = 'file-link', colorTheme = 'light', textSize = 'm', className, target, children, tabIndex, qa, urlTitle, extraProps, } = props;
30
30
  const qaAttributes = getQaAttrubutes(qa, ['normal']);
31
31
  const handleMetrika = useMetrika();
32
32
  const handleAnalytics = useAnalytics(DefaultEventNames.Link, url);
@@ -41,14 +41,14 @@ const LinkBlock = (props) => {
41
41
  const getLinkByType = () => {
42
42
  switch (theme) {
43
43
  case 'back':
44
- return (React.createElement(BackLink, { title: children || text, url: href, onClick: onClick, tabIndex: tabIndex }));
44
+ return (React.createElement(BackLink, { title: children || text, url: href, onClick: onClick, tabIndex: tabIndex, extraProps: extraProps }));
45
45
  case 'file-link':
46
46
  case 'underline':
47
- return (React.createElement(FileLink, { text: children || text, href: href, type: "horizontal", textSize: textSize, onClick: onClick, tabIndex: tabIndex }));
47
+ return (React.createElement(FileLink, { text: children || text, href: href, type: "horizontal", textSize: textSize, onClick: onClick, tabIndex: tabIndex, extraProps: extraProps }));
48
48
  case 'normal': {
49
49
  const linkProps = getLinkProps(url, hostname, target);
50
50
  const content = children || text;
51
- return (React.createElement("a", Object.assign({ className: b('link', { theme: colorTheme, 'has-arrow': arrow }), href: href, onClick: onClick, tabIndex: tabIndex, title: urlTitle }, linkProps, { "data-qa": qaAttributes.normal }), arrow ? (React.createElement(Fragment, null,
51
+ return (React.createElement("a", Object.assign({ className: b('link', { theme: colorTheme, 'has-arrow': arrow }), href: href, onClick: onClick, tabIndex: tabIndex, title: urlTitle }, linkProps, { "data-qa": qaAttributes.normal }, extraProps), arrow ? (React.createElement(Fragment, null,
52
52
  React.createElement("span", { className: b('content') }, content),
53
53
  WORD_JOINER_SYM,
54
54
  React.createElement(Icon, { className: b('arrow'), data: Chevron, size: getArrowSize(textSize) }))) : (content)));
@@ -4,11 +4,6 @@ unpredictable css rules order in build */
4
4
  position: relative;
5
5
  overflow: hidden;
6
6
  }
7
- .pc-media-component-video__item {
8
- width: 100%;
9
- display: flex;
10
- align-items: center;
11
- }
12
7
  .pc-media-component-video__react-player {
13
8
  display: flex;
14
9
  position: relative;