@meduza/ui-kit-2 0.8.605 → 0.8.607

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 (133) hide show
  1. package/package.json +1 -1
  2. package/src/Meta/Meta.module.css +5 -0
  3. package/src/Meta/MetaContainer.tsx +16 -13
  4. package/dist/AnnouncementInText/AnnouncementInText.types.d.ts +0 -4
  5. package/dist/AnnouncementInText/index.d.ts +0 -3
  6. package/dist/BookmarkButton/BookmarkButton.types.d.ts +0 -6
  7. package/dist/BookmarkButton/index.d.ts +0 -3
  8. package/dist/Button/Button.d.ts +0 -3
  9. package/dist/Button/Button.types.d.ts +0 -16
  10. package/dist/Button/ButtonLoader.d.ts +0 -2
  11. package/dist/Button/index.d.ts +0 -2
  12. package/dist/CardTitle/CardTitle.types.d.ts +0 -11
  13. package/dist/CardTitle/index.d.ts +0 -3
  14. package/dist/ChapterBlock/ChapterBlock.types.d.ts +0 -8
  15. package/dist/ChapterBlock/index.d.ts +0 -3
  16. package/dist/Cover/Cover.types.d.ts +0 -24
  17. package/dist/Cover/index.d.ts +0 -3
  18. package/dist/DocumentItemsCount/DocumentItemsCount.types.d.ts +0 -6
  19. package/dist/DocumentItemsCount/index.d.ts +0 -3
  20. package/dist/DonatesTeaser/DonatesTeaser.types.d.ts +0 -4
  21. package/dist/DonatesTeaser/index.d.ts +0 -3
  22. package/dist/DotsOnImage/DotsOnImage.types.d.ts +0 -46
  23. package/dist/DotsOnImage/index.d.ts +0 -3
  24. package/dist/Dropdown/Dropdown.types.d.ts +0 -5
  25. package/dist/Dropdown/index.d.ts +0 -4
  26. package/dist/EmbedBlock/EmbedBlock.d.ts +0 -3
  27. package/dist/EmbedBlock/EmbedBlock.types.d.ts +0 -12
  28. package/dist/EmbedBlock/EmbedGif.d.ts +0 -3
  29. package/dist/EmbedBlock/IframeBlock.d.ts +0 -3
  30. package/dist/EmbedBlock/index.d.ts +0 -3
  31. package/dist/Footnote/Footnote.types.d.ts +0 -5
  32. package/dist/Footnote/index.d.ts +0 -3
  33. package/dist/GroupedBlock/GroupedBlock.types.d.ts +0 -4
  34. package/dist/GroupedBlock/index.d.ts +0 -3
  35. package/dist/HalfBlock/HalfBlock.types.d.ts +0 -4
  36. package/dist/HalfBlock/index.d.ts +0 -3
  37. package/dist/Image/Image.types.d.ts +0 -35
  38. package/dist/Image/RenderPicture.d.ts +0 -4
  39. package/dist/Image/index.d.ts +0 -3
  40. package/dist/ImportantLead/ImportantLead.types.d.ts +0 -4
  41. package/dist/ImportantLead/index.d.ts +0 -3
  42. package/dist/Lazy/Lazy.types.d.ts +0 -4
  43. package/dist/Lazy/index.d.ts +0 -3
  44. package/dist/ListBlock/ListBlock.types.d.ts +0 -9
  45. package/dist/ListBlock/index.d.ts +0 -3
  46. package/dist/MaterialNote/MaterialNote.types.d.ts +0 -13
  47. package/dist/MaterialNote/index.d.ts +0 -3
  48. package/dist/MaterialTitle/MaterialTitle.types.d.ts +0 -4
  49. package/dist/MaterialTitle/index.d.ts +0 -5
  50. package/dist/MediaCaption/MediaCaption.types.d.ts +0 -5
  51. package/dist/MediaCaption/index.d.ts +0 -3
  52. package/dist/Meta/Meta.mock.d.ts +0 -12
  53. package/dist/Meta/Meta.types.d.ts +0 -20
  54. package/dist/Meta/MetaContainer.d.ts +0 -3
  55. package/dist/Meta/index.d.ts +0 -3
  56. package/dist/MetaItem/MetaItem.types.d.ts +0 -7
  57. package/dist/MetaItem/index.d.ts +0 -3
  58. package/dist/MetaItemLive/MetaItemLive.types.d.ts +0 -3
  59. package/dist/MetaItemLive/index.d.ts +0 -3
  60. package/dist/Popover/Popover.types.d.ts +0 -5
  61. package/dist/Popover/index.d.ts +0 -3
  62. package/dist/QuoteBlock/QuoteBlock.types.d.ts +0 -6
  63. package/dist/QuoteBlock/index.d.ts +0 -3
  64. package/dist/RawHtmlBlock/RawHtmlBlock.types.d.ts +0 -18
  65. package/dist/RawHtmlBlock/index.d.ts +0 -3
  66. package/dist/RelatedBlock/RelatedBlock.types.d.ts +0 -17
  67. package/dist/RelatedBlock/index.d.ts +0 -3
  68. package/dist/RelatedBook/RelatedBook.mock.d.ts +0 -65
  69. package/dist/RelatedBook/RelatedBook.types.d.ts +0 -4
  70. package/dist/RelatedBook/index.d.ts +0 -3
  71. package/dist/RelatedRichBlock/RelatedRichBlock.types.d.ts +0 -4
  72. package/dist/RelatedRichBlock/index.d.ts +0 -3
  73. package/dist/RenderBlocks/RenderBlocks.types.d.ts +0 -12
  74. package/dist/RenderBlocks/index.d.ts +0 -3
  75. package/dist/RichTitle/RichTitle.types.d.ts +0 -12
  76. package/dist/RichTitle/index.d.ts +0 -3
  77. package/dist/SensitiveBlock/SensitiveBlock.types.d.ts +0 -15
  78. package/dist/SensitiveBlock/index.d.ts +0 -3
  79. package/dist/ShopRelatedBlock/ShopRelatedBlock.types.d.ts +0 -4
  80. package/dist/ShopRelatedBlock/index.d.ts +0 -3
  81. package/dist/SimpleBlock/SimpleBlock.types.d.ts +0 -5
  82. package/dist/SimpleBlock/index.d.ts +0 -3
  83. package/dist/SimpleTitle/SimpleTitle.types.d.ts +0 -9
  84. package/dist/SimpleTitle/index.d.ts +0 -3
  85. package/dist/SourceBlock/SourceBlock.types.d.ts +0 -15
  86. package/dist/SourceBlock/index.d.ts +0 -3
  87. package/dist/Spoiler/Spoiler.types.d.ts +0 -4
  88. package/dist/Spoiler/index.d.ts +0 -3
  89. package/dist/SvgSymbol/SvgSymbol.types.d.ts +0 -8
  90. package/dist/SvgSymbol/icons.d.ts +0 -182
  91. package/dist/SvgSymbol/index.d.ts +0 -3
  92. package/dist/Switcher/Switcher.types.d.ts +0 -12
  93. package/dist/Switcher/index.d.ts +0 -3
  94. package/dist/Table/Table.types.d.ts +0 -25
  95. package/dist/Table/index.d.ts +0 -3
  96. package/dist/Tag/Tag.types.d.ts +0 -12
  97. package/dist/Tag/index.d.ts +0 -3
  98. package/dist/Timestamp/Timestamp.types.d.ts +0 -5
  99. package/dist/Timestamp/index.d.ts +0 -4
  100. package/dist/Toolbar/Toolbar.d.ts +0 -3
  101. package/dist/Toolbar/Toolbar.types.d.ts +0 -7
  102. package/dist/Toolbar/ToolbarItem.d.ts +0 -3
  103. package/dist/Toolbar/index.d.ts +0 -2
  104. package/dist/ToolbarButton/ToolbarButton.types.d.ts +0 -10
  105. package/dist/ToolbarButton/index.d.ts +0 -3
  106. package/dist/Tooltip/Tooltip.d.ts +0 -3
  107. package/dist/Tooltip/Tooltip.types.d.ts +0 -8
  108. package/dist/Tooltip/TooltipFooter.d.ts +0 -3
  109. package/dist/Tooltip/index.d.ts +0 -2
  110. package/dist/VersesBlock/VersesBlock.types.d.ts +0 -9
  111. package/dist/VersesBlock/index.d.ts +0 -3
  112. package/dist/constants.d.ts +0 -41
  113. package/dist/index.d.ts +0 -45
  114. package/dist/types.d.ts +0 -20
  115. package/dist/ui-kit-2.cjs.development.js +0 -2872
  116. package/dist/ui-kit-2.cjs.development.js.map +0 -1
  117. package/dist/ui-kit-2.cjs.production.min.js +0 -2
  118. package/dist/ui-kit-2.cjs.production.min.js.map +0 -1
  119. package/dist/ui-kit-2.esm.js +0 -2818
  120. package/dist/ui-kit-2.esm.js.map +0 -1
  121. package/dist/ui-kit-game.css +0 -7084
  122. package/dist/ui-kit.css +0 -7084
  123. package/dist/utils/BlockContext.d.ts +0 -8
  124. package/dist/utils/DangerousHtml.d.ts +0 -8
  125. package/dist/utils/capitalizeFirstLetter.d.ts +0 -1
  126. package/dist/utils/converCase.d.ts +0 -2
  127. package/dist/utils/generateGradient.d.ts +0 -2
  128. package/dist/utils/getElementPositionRelativeToViewport.d.ts +0 -2
  129. package/dist/utils/makeClassName.d.ts +0 -3
  130. package/dist/utils/makeStyleContext.d.ts +0 -3
  131. package/dist/utils/pluralize.d.ts +0 -2
  132. package/dist/utils/postMessage.d.ts +0 -2
  133. package/dist/utils/viewportSize.d.ts +0 -6
@@ -1,2872 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var React = require('react');
6
- var reactIntersectionObserver = require('react-intersection-observer');
7
- var dayjs = require('dayjs');
8
- require('dayjs/locale/ru');
9
- var relativeTime = require('dayjs/plugin/relativeTime');
10
- var reactRouterDom = require('react-router-dom');
11
-
12
- const makeClassName = list => {
13
- return list.filter(([, active]) => active).map(([className]) => className).join(' ');
14
- };
15
-
16
- const ButtonLoader = () => ( /*#__PURE__*/React.createElement("svg", {
17
- width: "30px",
18
- height: "30px",
19
- viewBox: "0 0 30 30",
20
- xmlns: "http://www.w3.org/2000/svg"
21
- }, /*#__PURE__*/React.createElement("g", null, /*#__PURE__*/React.createElement("path", {
22
- d: "M15 0C6.716 0 0 6.716 0 15c0 8.284 6.716 15 15 15 8.284 0 15-6.716 15-15 0-8.284-6.716-15-15-15zm0 2c7.18 0 13 5.82 13 13s-5.82 13-13 13S2 22.18 2 15 7.82 2 15 2z",
23
- opacity: "0.3"
24
- })), /*#__PURE__*/React.createElement("g", {
25
- fillRule: "evenodd"
26
- }, /*#__PURE__*/React.createElement("animateTransform", {
27
- attributeName: "transform",
28
- type: "rotate",
29
- from: "0 15 15",
30
- to: "360 15 15",
31
- dur: "1000ms",
32
- repeatCount: "indefinite"
33
- }), /*#__PURE__*/React.createElement("path", {
34
- d: "M15 0c8.18 0 14.83 6.547 14.997 14.686L30 15h-2c0-7.077-5.655-12.833-12.693-12.996L15 2V0z"
35
- }))));
36
-
37
- var styles$I = {"root":"Button-module_root__9OQ5b","gold":"Button-module_gold__q-XBP","isLoading":"Button-module_isLoading__Z53G4","gray":"Button-module_gray__fypDq","sand":"Button-module_sand__e5v-k","dark":"Button-module_dark__qv4NQ","light":"Button-module_light__TLYLT","black":"Button-module_black__GIsbk","red":"Button-module_red__kybni","default":"Button-module_default__utLb-","isInSpoiler":"Button-module_isInSpoiler__pGp-w","ghost":"Button-module_ghost__1s5-r","isInDropdown":"Button-module_isInDropdown__gN7TI","loader":"Button-module_loader__r0Mjs","isFancy":"Button-module_isFancy__gTRmu"};
38
-
39
- const Button = ({
40
- theme = 'gold',
41
- size = 'default',
42
- state = 'isDefault',
43
- styleContext = 'isInToolbar',
44
- appearance,
45
- disabled = false,
46
- onClick,
47
- children
48
- }) => {
49
- const handleClick = () => {
50
- if (disabled || !onClick) {
51
- return;
52
- }
53
- onClick();
54
- };
55
- return /*#__PURE__*/React.createElement("button", {
56
- "data-testid": "button",
57
- className: makeClassName([[styles$I.root, true], [styles$I[size], !!size], [styles$I[theme], !!theme], [styles$I[appearance], !!appearance], [styles$I[state], !!state && !!styles$I[state]], [styles$I[styleContext], !!styleContext]]),
58
- disabled: disabled,
59
- onClick: handleClick,
60
- type: "button"
61
- }, state === 'isLoading' ? ( /*#__PURE__*/React.createElement("span", {
62
- className: styles$I.loader
63
- }, /*#__PURE__*/React.createElement(ButtonLoader, null))) : children);
64
- };
65
-
66
- const icons = {
67
- meduzaLogo: {
68
- width: 544,
69
- height: 115,
70
- content: '<path d="M59.1008614,49.65632 L59.1008614,106.01472 L84.9480411,114.24 L84.9480411,49.65632 L101.574882,49.65632 L101.574882,106.01472 L127.270909,114.24 L144.048902,91.392 L127.422062,91.392 L127.422062,35.7952 L101.726035,26.80832 L84.9480411,46.60992 L84.9480411,35.7952 L59.2520145,26.80832 L42.4740206,46.60992 L42.4740206,35.7952 L16.7779939,26.80832 L0,49.65632 L16.6268408,49.65632 L16.6268408,106.01472 L42.4740206,114.24 L42.4740206,49.65632 L59.1008614,49.65632 L59.1008614,49.65632 Z M336.61795,91.392 L336.61795,35.0336 L310.770769,26.80832 L310.770769,105.25312 L336.466796,114.24 L353.24479,94.4384 L353.24479,105.25312 L378.940817,114.24 L395.71881,91.392 L379.091969,91.392 L379.091969,35.0336 L353.24479,26.80832 L353.24479,91.392 L336.61795,91.392 L336.61795,91.392 Z M527.373159,38.08 L502.130592,26.80832 L472.202278,41.1264 L502.130592,52.39808 L461.016949,72.352 L461.016949,104.94848 L486.86413,114.24 L502.130592,94.28608 L502.130592,105.25312 L527.977771,114.24 L544,91.23968 L527.373159,91.23968 L527.373159,38.08 L527.373159,38.08 Z M177.453737,114.24 L207.079744,102.35904 L177.453737,91.23968 L177.453737,75.24608 L216.300083,56.3584 L194.231731,26.80832 L151.606557,47.37152 L151.606557,103.12064 L177.453737,114.24 L177.453737,114.24 Z M455.424284,89.56416 L423.984441,79.968 L453.459295,42.19264 L416.577937,26.80832 L397.230341,51.48416 L428.821339,61.23264 L398.741873,98.85568 L436.076687,114.24 L455.424284,89.56416 L455.424284,89.56416 Z M486.86413,91.392 L486.86413,68.84864 L502.130592,61.53728 L502.130592,91.392 L486.86413,91.392 L486.86413,91.392 Z M177.453737,41.58336 L190.452904,59.55712 L177.453737,65.80224 L177.453737,41.58336 L177.453737,41.58336 Z M222.95082,103.12064 L248.797999,114.24 L291.27202,97.18016 L291.27202,29.7024 L222.95082,0 L222.95082,26.30784 L265.424841,43.21536 L265.424841,97.33248 L248.797999,91.23968 L248.797999,43.71584 L222.95082,51.94112 L222.95082,103.12064 L222.95082,103.12064 Z" />'
71
- },
72
- menu: {
73
- width: 24,
74
- height: 24,
75
- content: '<path d="M2 21h20M2 12h20M2 3h20" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" vector-effect="non-scaling-stroke" />'
76
- },
77
- fb: {
78
- width: 16,
79
- height: 18,
80
- content: '<path d="M15.117 1H.883A.883.883 0 0 0 0 1.883v14.234A.883.883 0 0 0 .883 17h7.663v-6.196H6.461V8.389h2.085V6.61a2.91 2.91 0 0 1 3.106-3.192c.622-.003 1.244.03 1.863.095v2.16h-1.279c-1.002 0-1.196.476-1.196 1.176v1.541h2.39l-.31 2.415h-2.08V17h4.077a.883.883 0 0 0 .883-.883V1.883A.883.883 0 0 0 15.117 1" />'
81
- },
82
- tw: {
83
- width: 20,
84
- height: 18,
85
- content: '<path d="M20 3.1c-.7.3-1.5.6-2.4.7.8-.5 1.5-1.4 1.8-2.4-.8.5-1.7.8-2.6 1-.7-.8-1.8-1.4-3-1.4-2.3 0-4.1 1.9-4.1 4.3 0 .3 0 .7.1 1-3.3-.1-6.4-1.8-8.4-4.4-.3.6-.5 1.4-.5 2.2 0 1.5.7 2.8 1.8 3.6-.7 0-1.3-.2-1.9-.5v.1c0 2.1 1.4 3.8 3.3 4.2-.3.1-.7.2-1.1.2-.3 0-.5 0-.8-.1.5 1.7 2 2.9 3.8 3-1.3 1-3.1 1.6-5 1.6-.3 0-.7 0-1-.1C1.8 17.3 4 18 6.3 18 13.8 18 18 11.5 18 5.8v-.6c.8-.5 1.5-1.2 2-2.1" fill-rule="nonzero"/>'
86
- },
87
- vk: {
88
- width: 20,
89
- height: 18,
90
- content: '<path d="M16.517 9.851s2.587-3.768 2.886-5.058c.1-.396-.1-.694-.498-.694h-2.288c-.498 0-.697.199-.896.595 0 0-1.194 2.678-2.686 4.364-.498.496-.697.694-.995.694-.2 0-.299-.198-.299-.694V4.793c0-.595-.1-.793-.597-.793H7.463c-.2 0-.398.198-.398.397 0 .595.796.694.796 2.28v3.174c0 .595 0 .893-.299.893-.796 0-2.686-2.777-3.681-5.851-.2-.595-.398-.794-.995-.794H.597C.299 4.1 0 4.298 0 4.694c0 .595.697 3.471 3.483 7.34C5.373 14.611 7.86 16 10.05 16c1.393 0 1.691-.198 1.691-.793v-1.984c0-.496.2-.694.498-.694s.895.1 2.189 1.388C15.92 15.405 16.02 16 16.915 16h2.587c.299 0 .498-.1.498-.595 0-.595-.796-1.587-1.89-2.876-.498-.595-1.195-1.29-1.493-1.686-.398-.397-.299-.595-.1-.992" fill-rule="nonzero"/>'
91
- },
92
- ok: {
93
- width: 9,
94
- height: 18,
95
- content: '<path d="M4.5 2c-2.2 0-4 1.8-4 4s1.8 4 4 4 4-1.8 4-4-1.8-4-4-4m0 5.7c-.9 0-1.6-.8-1.6-1.7 0-.9.7-1.6 1.6-1.6.9 0 1.7.7 1.7 1.7 0 .8-.8 1.6-1.7 1.6" fill-rule="nonzero"/> <path d="M6.127 12.982a9.194 9.194 0 0 0 2.307-.904c.602-.301.703-1.004.402-1.507-.301-.502-1.104-.703-1.605-.401-1.605 1.004-3.812 1.004-5.417 0-.502-.302-1.304-.201-1.605.3-.401.604-.2 1.206.401 1.608a9.194 9.194 0 0 0 2.307.904L.61 15.092c-.502.401-.502 1.104 0 1.607a1.357 1.357 0 0 0 1.705 0l2.207-2.11L6.73 16.7a1.357 1.357 0 0 0 1.705 0c.502-.402.502-1.105 0-1.608l-2.307-2.109" fill-rule="nonzero"/>'
96
- },
97
- tg: {
98
- width: 18,
99
- height: 18,
100
- content: '<path d="M9 18c-5 0-9-4-9-9s4-9 9-9 9 4 9 9-4 9-9 9zm-1.5-7.4c1.1 1 2 3.3 2 3.3.4.2.7.1.8-.4l2.1-7.4c.1-.6-.2-.8-.6-.7L4 8.3c-.6.2-.6.5-.1.7 0 .1 2.4.6 3.6 1.6z" fill-rule="nonzero"/>'
101
- },
102
- meduzaSymbol: {
103
- width: 24,
104
- height: 18,
105
- content: '<path d="M10.026233,17.0968697 L13.9737671,18.3530831 L13.9737671,10.9855851 L13.9737671,8.48948164 L16.5131165,8.48948164 L16.5131165,17.0968697 L20.4375656,18.3530831 L23,14.8636014 L20.4606507,14.8636014 L20.4606507,6.37252945 L16.5362015,5 L13.9737671,8.02421743 L13.9737671,6.37252945 L10.049318,5 L7.48688354,8.02421743 L7.48688354,6.37252945 L3.56243443,5 L1,8.48948164 L3.53934943,8.48948164 L3.53934943,17.0968697 L7.48688354,18.3530831 L7.48688354,8.48948164 L10.026233,8.48948164 L10.026233,17.0968697 Z" />'
106
- },
107
- backward: {
108
- width: 25,
109
- height: 27,
110
- content: '<path d="M13 0v2.01c6.672.263 12 5.754 12 12.49C25 21.404 19.404 27 12.5 27S0 21.404 0 14.5c0-3.493 1.441-6.758 3.936-9.105a.75.75 0 111.028 1.092A10.965 10.965 0 001.5 14.5c0 6.075 4.925 11 11 11s11-4.925 11-11c0-5.907-4.656-10.727-10.499-10.989L13 6 8 3l5-3zm3.295 11.33v1.25h-3.16v1.63c.32-.32.86-.56 1.47-.56 1.13 0 2.14.81 2.14 2.16 0 1.42-1.06 2.31-2.67 2.31-1.16 0-2-.38-2.57-1l.79-.99c.45.47 1.07.73 1.77.73.79 0 1.24-.45 1.24-.99 0-.59-.44-.99-1.2-.99-.55 0-1 .16-1.4.54l-.99-.26v-3.83h4.58zm-5.94 0V18h-1.42v-4.84l-1.11 1.13-.81-.85 2.1-2.11h1.24z" fill-rule="nonzero"/>'
111
- },
112
- forward: {
113
- width: 25,
114
- height: 27,
115
- content: '<path d="M12 0l5 3-5 3V3.511C6.157 3.773 1.5 8.592 1.5 14.5c0 6.075 4.925 11 11 11s11-4.925 11-11c0-3.075-1.267-5.946-3.464-8.013a.75.75 0 011.028-1.092A12.465 12.465 0 0125 14.5C25 21.404 19.404 27 12.5 27S0 21.404 0 14.5C0 7.764 5.328 2.272 12 2.01V0zm4.295 11.33v1.25h-3.16v1.63c.32-.32.86-.56 1.47-.56 1.13 0 2.14.81 2.14 2.16 0 1.42-1.06 2.31-2.67 2.31-1.16 0-2-.38-2.57-1l.79-.99c.45.47 1.07.73 1.77.73.79 0 1.24-.45 1.24-.99 0-.59-.44-.99-1.2-.99-.55 0-1 .16-1.4.54l-.99-.26v-3.83h4.58zm-5.94 0V18h-1.42v-4.84l-1.11 1.13-.81-.85 2.1-2.11h1.24z" fill-rule="nonzero"/>'
116
- },
117
- download: {
118
- width: 25,
119
- height: 27,
120
- content: '<path d="M12.5 2C19.404 2 25 7.596 25 14.5S19.404 27 12.5 27 0 21.404 0 14.5 5.596 2 12.5 2zm0 1.5c-6.075 0-11 4.925-11 11s4.925 11 11 11 11-4.925 11-11-4.925-11-11-11zm6 15.75a.75.75 0 01.102 1.493l-.102.007h-12a.75.75 0 01-.102-1.493l.102-.007h12zm-6-12a.75.75 0 01.743.648L13.25 8v7.598l1.834-1.222a.75.75 0 11.832 1.248l-3 2a.75.75 0 01-.832 0l-3-2a.75.75 0 11.832-1.248l1.834 1.223V8a.75.75 0 01.648-.743l.102-.007z" fill-rule="nonzero" fill="currentColor" />'
121
- },
122
- episodeDownload: {
123
- width: 30,
124
- height: 30,
125
- content: '<g opacity="0.4"><circle cx="15" cy="15" r="10.5" stroke="white" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/><path d="M15 19.5L15 10.5M15 19.5L18.5 17.2257M15 19.5L11.5 17.2257" stroke="white" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/></g>'
126
- },
127
- play: {
128
- width: 62,
129
- height: 62,
130
- content: '<path d="M24.35 41.772a.5.5 0 0 1-.739-.439V20.667a.5.5 0 0 1 .74-.44l18.944 10.334a.5.5 0 0 1 0 .878L24.351 41.772z" fill-rule="nonzero"/>'
131
- },
132
- pause: {
133
- width: 22,
134
- height: 22,
135
- content: '<path d="M12.832 4h2.8c.276 0 .5.224.5.5v12.394c0 .277-.224.5-.5.5h-2.8c-.276 0-.5-.223-.5-.5V4.5c0-.276.224-.5.5-.5zM6.5 4h2.8c.277 0 .5.224.5.5v12.394c0 .277-.223.5-.5.5H6.5c-.276 0-.5-.223-.5-.5V4.5c0-.276.224-.5.5-.5z" />'
136
- },
137
- speedHalf: {
138
- width: 27,
139
- height: 11,
140
- content: `<g xmlns="http://www.w3.org/2000/svg" opacity="0.25">
141
- <path d="M24.0086 6.10773L22.3566 7.75973C22.2586 7.85773 22.1186 7.92773 21.9646 7.92773C21.6566 7.92773 21.4186 7.67573 21.4186 7.38173C21.4186 7.22773 21.4886 7.08773 21.5726 6.98973L23.2246 5.32373L21.5726 3.67173C21.4886 3.57373 21.4186 3.43373 21.4186 3.27973C21.4186 2.97173 21.6566 2.71973 21.9646 2.71973C22.1186 2.71973 22.2726 2.78973 22.3706 2.88773L24.0086 4.55373L25.6606 2.88773C25.7586 2.78973 25.9126 2.73373 26.0526 2.73373C26.3606 2.73373 26.6126 2.97173 26.6126 3.27973C26.6126 3.43373 26.5426 3.57373 26.4446 3.67173L24.7926 5.32373L26.4446 6.98973C26.5426 7.08773 26.6126 7.22773 26.6126 7.38173C26.6126 7.67573 26.3606 7.91373 26.0526 7.91373C25.9126 7.91373 25.7726 7.85773 25.6746 7.75973L24.0086 6.10773Z" fill="black"/>
142
- <path d="M13.307 9.31411C13.083 9.17411 12.915 8.88011 12.915 8.58611C12.915 8.09611 13.307 7.70411 13.797 7.70411C13.965 7.70411 14.133 7.74611 14.273 7.84411C14.847 8.25011 15.505 8.43211 16.233 8.43211C17.339 8.43211 17.969 7.80211 17.969 7.03211C17.969 6.17811 17.353 5.60411 16.289 5.60411C15.673 5.60411 15.155 5.75811 14.665 6.13611C14.483 6.27611 14.259 6.34611 14.007 6.34611C13.419 6.34611 12.943 5.87011 12.943 5.28211V1.71211C12.943 1.04011 13.307 0.662109 13.993 0.662109H18.599C19.061 0.662109 19.467 1.04011 19.467 1.53011C19.467 1.99211 19.061 2.37011 18.599 2.37011H14.889V4.70811C15.379 4.27411 16.135 3.92411 16.989 3.92411C18.571 3.92411 19.985 5.05811 19.985 6.94811C19.985 8.92211 18.501 10.1681 16.247 10.1681C15.029 10.1681 14.077 9.86011 13.307 9.31411Z" fill="black"/>
143
- <path d="M9.03894 9.01974C9.03894 8.40374 9.55694 7.88574 10.1729 7.88574C10.7889 7.88574 11.3069 8.40374 11.3069 9.01974C11.3069 9.63574 10.7889 10.1537 10.1729 10.1537C9.55694 10.1537 9.03894 9.63574 9.03894 9.01974Z" fill="black"/>
144
- <path d="M0.476074 5.33748C0.476074 2.92948 1.66607 0.521484 4.34007 0.521484C7.00007 0.521484 8.20407 2.92948 8.20407 5.33748C8.20407 7.74548 7.00007 10.1675 4.34007 10.1675C1.66607 10.1675 0.476074 7.74548 0.476074 5.33748ZM6.17407 5.33748C6.17407 3.61548 5.67007 2.28549 4.34007 2.28549C2.99607 2.28549 2.49207 3.61548 2.49207 5.33748C2.49207 7.05948 2.99607 8.40349 4.34007 8.40349C5.67007 8.40349 6.17407 7.05948 6.17407 5.33748Z" fill="black"/>
145
- </g>`
146
- },
147
- speedThreeQuarters: {
148
- width: 34,
149
- height: 11,
150
- content: `<g xmlns="http://www.w3.org/2000/svg" opacity="0.25">
151
- <path d="M30.6531 6.10773L29.0011 7.75973C28.9031 7.85773 28.7631 7.92773 28.6091 7.92773C28.3011 7.92773 28.0631 7.67573 28.0631 7.38173C28.0631 7.22773 28.1331 7.08773 28.2171 6.98973L29.8691 5.32373L28.2171 3.67173C28.1331 3.57373 28.0631 3.43373 28.0631 3.27973C28.0631 2.97173 28.3011 2.71973 28.6091 2.71973C28.7631 2.71973 28.9171 2.78973 29.0151 2.88773L30.6531 4.55373L32.3051 2.88773C32.4031 2.78973 32.5571 2.73373 32.6971 2.73373C33.0051 2.73373 33.2571 2.97173 33.2571 3.27973C33.2571 3.43373 33.1871 3.57373 33.0891 3.67173L31.4371 5.32373L33.0891 6.98973C33.1871 7.08773 33.2571 7.22773 33.2571 7.38173C33.2571 7.67573 33.0051 7.91373 32.6971 7.91373C32.5571 7.91373 32.4171 7.85773 32.3191 7.75973L30.6531 6.10773Z" fill="black"/>
152
- <path d="M19.9516 9.31411C19.7276 9.17411 19.5596 8.88011 19.5596 8.58611C19.5596 8.09611 19.9516 7.70411 20.4416 7.70411C20.6096 7.70411 20.7776 7.74611 20.9176 7.84411C21.4916 8.25011 22.1496 8.43211 22.8776 8.43211C23.9836 8.43211 24.6136 7.80211 24.6136 7.03211C24.6136 6.17811 23.9976 5.60411 22.9336 5.60411C22.3176 5.60411 21.7996 5.75811 21.3096 6.13611C21.1276 6.27611 20.9036 6.34611 20.6516 6.34611C20.0636 6.34611 19.5876 5.87011 19.5876 5.28211V1.71211C19.5876 1.04011 19.9516 0.662109 20.6376 0.662109H25.2436C25.7056 0.662109 26.1116 1.04011 26.1116 1.53011C26.1116 1.99211 25.7056 2.37011 25.2436 2.37011H21.5336V4.70811C22.0236 4.27411 22.7796 3.92411 23.6336 3.92411C25.2156 3.92411 26.6296 5.05811 26.6296 6.94811C26.6296 8.92211 25.1456 10.1681 22.8916 10.1681C21.6736 10.1681 20.7216 9.86011 19.9516 9.31411Z" fill="black"/>
153
- <path d="M14.1437 10.0981C13.5977 10.0981 13.1497 9.65011 13.1497 9.10411C13.1497 8.96411 13.1917 8.83811 13.2337 8.69811L16.0197 2.41211H12.0997C11.6237 2.41211 11.2177 2.02011 11.2177 1.54411C11.2177 1.05411 11.6237 0.662109 12.0997 0.662109H17.4757C17.9937 0.662109 18.4277 1.08211 18.4277 1.61411C18.4277 1.75411 18.3997 1.88011 18.3437 1.99211L15.0677 9.49611C14.9277 9.86011 14.5637 10.0981 14.1437 10.0981Z" fill="black"/>
154
- <path d="M9.03894 9.01974C9.03894 8.40374 9.55694 7.88574 10.1729 7.88574C10.7889 7.88574 11.3069 8.40374 11.3069 9.01974C11.3069 9.63574 10.7889 10.1537 10.1729 10.1537C9.55694 10.1537 9.03894 9.63574 9.03894 9.01974Z" fill="black"/>
155
- <path d="M0.476074 5.33748C0.476074 2.92948 1.66607 0.521484 4.34007 0.521484C7.00007 0.521484 8.20407 2.92948 8.20407 5.33748C8.20407 7.74548 7.00007 10.1675 4.34007 10.1675C1.66607 10.1675 0.476074 7.74548 0.476074 5.33748ZM6.17407 5.33748C6.17407 3.61548 5.67007 2.28549 4.34007 2.28549C2.99607 2.28549 2.49207 3.61548 2.49207 5.33748C2.49207 7.05948 2.99607 8.40349 4.34007 8.40349C5.67007 8.40349 6.17407 7.05948 6.17407 5.33748Z" fill="black"/>
156
- </g>`
157
- },
158
- speedOne: {
159
- width: 25,
160
- height: 10,
161
- content: `<g xmlns="http://www.w3.org/2000/svg" opacity="0.25">
162
- <path d="M21.9901 5.60773L20.3381 7.25973C20.2401 7.35773 20.1001 7.42773 19.9461 7.42773C19.6381 7.42773 19.4001 7.17573 19.4001 6.88173C19.4001 6.72773 19.4701 6.58773 19.5541 6.48973L21.2061 4.82373L19.5541 3.17173C19.4701 3.07373 19.4001 2.93373 19.4001 2.77973C19.4001 2.47173 19.6381 2.21973 19.9461 2.21973C20.1001 2.21973 20.2541 2.28973 20.3521 2.38773L21.9901 4.05373L23.6421 2.38773C23.7401 2.28973 23.8941 2.23373 24.0341 2.23373C24.3421 2.23373 24.5941 2.47173 24.5941 2.77973C24.5941 2.93373 24.5241 3.07373 24.4261 3.17173L22.7741 4.82373L24.4261 6.48973C24.5241 6.58773 24.5941 6.72773 24.5941 6.88173C24.5941 7.17573 24.3421 7.41373 24.0341 7.41373C23.8941 7.41373 23.7541 7.35773 23.6561 7.25973L21.9901 5.60773Z" fill="black"/>
163
- <path d="M10.2565 4.83748C10.2565 2.42948 11.4465 0.0214844 14.1205 0.0214844C16.7805 0.0214844 17.9845 2.42948 17.9845 4.83748C17.9845 7.24548 16.7805 9.66749 14.1205 9.66749C11.4465 9.66749 10.2565 7.24548 10.2565 4.83748ZM15.9545 4.83748C15.9545 3.11548 15.4505 1.78549 14.1205 1.78549C12.7765 1.78549 12.2725 3.11548 12.2725 4.83748C12.2725 6.55948 12.7765 7.90349 14.1205 7.90349C15.4505 7.90349 15.9545 6.55948 15.9545 4.83748Z" fill="black"/>
164
- <path d="M6.85645 8.51974C6.85645 7.90374 7.37445 7.38574 7.99045 7.38574C8.60645 7.38574 9.12444 7.90374 9.12444 8.51974C9.12444 9.13574 8.60645 9.65374 7.99045 9.65374C7.37445 9.65374 6.85645 9.13574 6.85645 8.51974Z" fill="black"/>
165
- <path d="M4.27766 9.59748C3.71766 9.59748 3.28366 9.13548 3.28366 8.60348V2.72348L2.26166 3.77348C2.10766 3.92748 1.89766 4.02548 1.67366 4.02548C1.21166 4.02548 0.847656 3.64748 0.847656 3.19948C0.847656 2.96148 0.945656 2.76548 1.08566 2.61148L3.29766 0.399477C3.50766 0.189477 3.80166 0.0634766 4.12366 0.0634766C4.75366 0.0634766 5.27166 0.581477 5.27166 1.21148V8.60348C5.27166 9.13548 4.82366 9.59748 4.27766 9.59748Z" fill="black"/>
166
- </g>`
167
- },
168
- speedOneQuarter: {
169
- width: 33,
170
- height: 11,
171
- content: `<g xmlns="http://www.w3.org/2000/svg" opacity="0.25">
172
- <path d="M29.6005 6.10773L27.9485 7.75973C27.8505 7.85773 27.7105 7.92773 27.5565 7.92773C27.2485 7.92773 27.0105 7.67573 27.0105 7.38173C27.0105 7.22773 27.0805 7.08773 27.1645 6.98973L28.8165 5.32373L27.1645 3.67173C27.0805 3.57373 27.0105 3.43373 27.0105 3.27973C27.0105 2.97173 27.2485 2.71973 27.5565 2.71973C27.7105 2.71973 27.8645 2.78973 27.9625 2.88773L29.6005 4.55373L31.2525 2.88773C31.3505 2.78973 31.5045 2.73373 31.6445 2.73373C31.9525 2.73373 32.2045 2.97173 32.2045 3.27973C32.2045 3.43373 32.1345 3.57373 32.0365 3.67173L30.3845 5.32373L32.0365 6.98973C32.1345 7.08773 32.2045 7.22773 32.2045 7.38173C32.2045 7.67573 31.9525 7.91373 31.6445 7.91373C31.5045 7.91373 31.3645 7.85773 31.2665 7.75973L29.6005 6.10773Z" fill="black"/>
173
- <path d="M18.899 9.31411C18.675 9.17411 18.507 8.88011 18.507 8.58611C18.507 8.09611 18.899 7.70411 19.389 7.70411C19.557 7.70411 19.725 7.74611 19.865 7.84411C20.439 8.25011 21.097 8.43211 21.825 8.43211C22.931 8.43211 23.561 7.80211 23.561 7.03211C23.561 6.17811 22.945 5.60411 21.881 5.60411C21.265 5.60411 20.747 5.75811 20.257 6.13611C20.075 6.27611 19.851 6.34611 19.599 6.34611C19.011 6.34611 18.535 5.87011 18.535 5.28211V1.71211C18.535 1.04011 18.899 0.662109 19.585 0.662109H24.191C24.653 0.662109 25.059 1.04011 25.059 1.53011C25.059 1.99211 24.653 2.37011 24.191 2.37011H20.481V4.70811C20.971 4.27411 21.727 3.92411 22.581 3.92411C24.163 3.92411 25.577 5.05811 25.577 6.94811C25.577 8.92211 24.093 10.1681 21.839 10.1681C20.621 10.1681 19.669 9.86011 18.899 9.31411Z" fill="black"/>
174
- <path d="M10.7532 9.99949C10.1932 9.99949 9.71716 9.53749 9.71716 8.96348C9.71716 8.62748 9.89916 8.31948 10.1512 8.13748C13.7072 5.54748 14.7572 4.62348 14.7572 3.50348C14.7572 2.69148 14.0152 2.28549 13.2312 2.28549C12.4612 2.28549 11.8172 2.52348 11.2572 2.91548C11.1172 3.01348 10.9492 3.06948 10.7672 3.06948C10.2772 3.06948 9.88516 2.67748 9.88516 2.18748C9.88516 1.89348 10.0392 1.62748 10.2492 1.47348C11.1172 0.815485 12.1812 0.521484 13.2032 0.521484C15.1912 0.521484 16.7732 1.64148 16.7732 3.50348C16.7732 5.09948 15.4572 6.48549 12.9512 8.24949H16.0592C16.5352 8.24949 16.9412 8.64149 16.9412 9.11749C16.9412 9.60748 16.5352 9.99949 16.0592 9.99949H10.7532Z" fill="black"/>
175
- <path d="M6.37305 9.01974C6.37305 8.40374 6.89105 7.88574 7.50705 7.88574C8.12305 7.88574 8.64105 8.40374 8.64105 9.01974C8.64105 9.63574 8.12305 10.1537 7.50705 10.1537C6.89105 10.1537 6.37305 9.63574 6.37305 9.01974Z" fill="black"/>
176
- <path d="M3.79426 10.0975C3.23426 10.0975 2.80026 9.63548 2.80026 9.10348V3.22348L1.77826 4.27348C1.62426 4.42748 1.41426 4.52548 1.19026 4.52548C0.728258 4.52548 0.364258 4.14748 0.364258 3.69948C0.364258 3.46148 0.462258 3.26548 0.602258 3.11148L2.81426 0.899477C3.02426 0.689477 3.31826 0.563477 3.64026 0.563477C4.27026 0.563477 4.78826 1.08148 4.78826 1.71148V9.10348C4.78826 9.63548 4.34026 10.0975 3.79426 10.0975Z" fill="black"/>
177
- </g>`
178
- },
179
- speedOneHalf: {
180
- width: 24,
181
- height: 11,
182
- content: `<g xmlns="http://www.w3.org/2000/svg" opacity="0.25">
183
- <path d="M21.3427 6.1087L19.6907 7.7607C19.5927 7.8587 19.4527 7.9287 19.2987 7.9287C18.9907 7.9287 18.7527 7.6767 18.7527 7.3827C18.7527 7.2287 18.8227 7.0887 18.9067 6.9907L20.5587 5.3247L18.9067 3.6727C18.8227 3.5747 18.7527 3.4347 18.7527 3.2807C18.7527 2.9727 18.9907 2.7207 19.2987 2.7207C19.4527 2.7207 19.6067 2.7907 19.7047 2.8887L21.3427 4.5547L22.9947 2.8887C23.0927 2.7907 23.2467 2.7347 23.3867 2.7347C23.6947 2.7347 23.9467 2.9727 23.9467 3.2807C23.9467 3.4347 23.8767 3.5747 23.7787 3.6727L22.1267 5.3247L23.7787 6.9907C23.8767 7.0887 23.9467 7.2287 23.9467 7.3827C23.9467 7.6767 23.6947 7.9147 23.3867 7.9147C23.2467 7.9147 23.1067 7.8587 23.0087 7.7607L21.3427 6.1087Z" fill="black"/>
184
- <path d="M10.6411 9.31411C10.4171 9.17411 10.2491 8.88011 10.2491 8.58611C10.2491 8.09611 10.6411 7.70411 11.1311 7.70411C11.2991 7.70411 11.4671 7.74611 11.6071 7.84411C12.1811 8.25011 12.8391 8.43211 13.5671 8.43211C14.6731 8.43211 15.3031 7.80211 15.3031 7.03211C15.3031 6.17811 14.6871 5.60411 13.6231 5.60411C13.0071 5.60411 12.4891 5.75811 11.9991 6.13611C11.8171 6.27611 11.5931 6.34611 11.3411 6.34611C10.7531 6.34611 10.2771 5.87011 10.2771 5.28211V1.71211C10.2771 1.04011 10.6411 0.662109 11.3271 0.662109H15.9331C16.3951 0.662109 16.8011 1.04011 16.8011 1.53011C16.8011 1.99211 16.3951 2.37011 15.9331 2.37011H12.2231V4.70811C12.7131 4.27411 13.4691 3.92411 14.3231 3.92411C15.9051 3.92411 17.3191 5.05811 17.3191 6.94811C17.3191 8.92211 15.8351 10.1681 13.5811 10.1681C12.3631 10.1681 11.4111 9.86011 10.6411 9.31411Z" fill="black"/>
185
- <path d="M6.37305 9.02072C6.37305 8.40472 6.89105 7.88672 7.50705 7.88672C8.12305 7.88672 8.64105 8.40472 8.64105 9.02072C8.64105 9.63672 8.12305 10.1547 7.50705 10.1547C6.89105 10.1547 6.37305 9.63672 6.37305 9.02072Z" fill="black"/>
186
- <path d="M3.79426 10.0985C3.23426 10.0985 2.80026 9.63645 2.80026 9.10445V3.22445L1.77826 4.27445C1.62426 4.42845 1.41426 4.52645 1.19026 4.52645C0.728258 4.52645 0.364258 4.14845 0.364258 3.70045C0.364258 3.46245 0.462258 3.26645 0.602258 3.11245L2.81426 0.900453C3.02426 0.690453 3.31826 0.564453 3.64026 0.564453C4.27026 0.564453 4.78826 1.08245 4.78826 1.71245V9.10445C4.78826 9.63645 4.34026 10.0985 3.79426 10.0985Z" fill="black"/>
187
- </g>`
188
- },
189
- speedTwo: {
190
- width: 27,
191
- height: 11,
192
- content: `<g xmlns="http://www.w3.org/2000/svg" opacity="0.25">
193
- <path d="M24.0494 6.10773L22.3974 7.75973C22.2994 7.85773 22.1594 7.92773 22.0054 7.92773C21.6974 7.92773 21.4594 7.67573 21.4594 7.38173C21.4594 7.22773 21.5294 7.08773 21.6134 6.98973L23.2654 5.32373L21.6134 3.67173C21.5294 3.57373 21.4594 3.43373 21.4594 3.27973C21.4594 2.97173 21.6974 2.71973 22.0054 2.71973C22.1594 2.71973 22.3134 2.78973 22.4114 2.88773L24.0494 4.55373L25.7014 2.88773C25.7994 2.78973 25.9534 2.73373 26.0934 2.73373C26.4014 2.73373 26.6534 2.97173 26.6534 3.27973C26.6534 3.43373 26.5834 3.57373 26.4854 3.67173L24.8334 5.32373L26.4854 6.98973C26.5834 7.08773 26.6534 7.22773 26.6534 7.38173C26.6534 7.67573 26.4014 7.91373 26.0934 7.91373C25.9534 7.91373 25.8134 7.85773 25.7154 7.75973L24.0494 6.10773Z" fill="black"/>
194
- <path d="M12.3157 5.33748C12.3157 2.92948 13.5057 0.521484 16.1797 0.521484C18.8397 0.521484 20.0437 2.92948 20.0437 5.33748C20.0437 7.74548 18.8397 10.1675 16.1797 10.1675C13.5057 10.1675 12.3157 7.74548 12.3157 5.33748ZM18.0137 5.33748C18.0137 3.61548 17.5097 2.28549 16.1797 2.28549C14.8357 2.28549 14.3317 3.61548 14.3317 5.33748C14.3317 7.05948 14.8357 8.40349 16.1797 8.40349C17.5097 8.40349 18.0137 7.05948 18.0137 5.33748Z" fill="black"/>
195
- <path d="M8.91565 9.01974C8.91565 8.40374 9.43365 7.88574 10.0496 7.88574C10.6656 7.88574 11.1836 8.40374 11.1836 9.01974C11.1836 9.63574 10.6656 10.1537 10.0496 10.1537C9.43365 10.1537 8.91565 9.63574 8.91565 9.01974Z" fill="black"/>
196
- <path d="M1.45592 9.99949C0.895922 9.99949 0.419922 9.53749 0.419922 8.96348C0.419922 8.62748 0.601922 8.31948 0.853922 8.13748C4.40992 5.54748 5.45992 4.62348 5.45992 3.50348C5.45992 2.69148 4.71792 2.28549 3.93392 2.28549C3.16392 2.28549 2.51992 2.52348 1.95992 2.91548C1.81992 3.01348 1.65192 3.06948 1.46992 3.06948C0.979922 3.06948 0.587922 2.67748 0.587922 2.18748C0.587922 1.89348 0.741922 1.62748 0.951922 1.47348C1.81992 0.815485 2.88392 0.521484 3.90592 0.521484C5.89392 0.521484 7.47592 1.64148 7.47592 3.50348C7.47592 5.09948 6.15992 6.48549 3.65392 8.24949H6.76192C7.23792 8.24949 7.64392 8.64149 7.64392 9.11749C7.64392 9.60748 7.23792 9.99949 6.76192 9.99949H1.45592Z" fill="black"/>
197
- </g>`
198
- },
199
- podcastBookmark: {
200
- width: 25,
201
- height: 27,
202
- content: '<path d="M12.5 27C19.404 27 25 21.404 25 14.5S19.404 2 12.5 2 0 7.596 0 14.5 5.596 27 12.5 27zm0-1.5c-6.075 0-11-4.925-11-11s4.925-11 11-11 11 4.925 11 11-4.925 11-11 11z" /> <path d="M17.071 8.25H8a.75.75 0 00-.75.75v11.545l.007.104a.75.75 0 001.228.468l4.05-3.437 4.051 3.437a.75.75 0 001.235-.572V9a.75.75 0 00-.75-.75zm-.75 1.499v9.176l-3.3-2.8-.098-.07a.75.75 0 00-.873.07l-3.3 2.799V9.749h7.571z" data-stroke="true" /> <path d="M17.071 8.25H8a.75.75 0 00-.75.75v11.545l.007.104a.75.75 0 001.228.468l4.05-3.437 4.051 3.437a.75.75 0 001.235-.572V9a.75.75 0 00-.75-.75z" data-fill="true" />'
203
- },
204
- reaction: {
205
- width: 16,
206
- height: 16,
207
- content: '<path data-theme="light" fill="#D09959" d="M1 2h14v12H1z"/> <path d="M0 1.778C0 .8.8 0 1.778 0h12.444C15.2 0 16 .8 16 1.778v12.444C16 15.2 15.2 16 14.222 16H1.778C.8 16 0 15.2 0 14.222V1.778zM6.8 11.7l2.5.8V6.2h1.6v5.5l2.5.8 1.6-2.3h-1.6V4.8L10.9 4 9.3 5.9V4.8L6.8 4 5.1 5.9V4.8L2.6 4 1 6.2h1.6v5.5l2.5.8V6.2h1.7v5.5z" />'
208
- },
209
- cross: {
210
- width: 18,
211
- height: 18,
212
- content: '<path fill="none" fill-rule="evenodd" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" vector-effect="non-scaling-stroke" d="M2 2l14 14M16 2L2 16" />'
213
- },
214
- link: {
215
- width: 24,
216
- height: 24,
217
- content: '<path d="M9.158 18.928c-1.065 0-2.13-.405-2.94-1.215-1.624-1.623-1.624-4.262 0-5.884l.643-.645c.327-.326.854-.326 1.18 0 .325.326.325.853 0 1.178l-.645.645c-.972.972-.972 2.554 0 3.526.973.972 2.554.973 3.526 0l2.842-2.84c.97-.972.97-2.555 0-3.527-.325-.325-.325-.854 0-1.18.325-.324.853-.324 1.178 0 1.623 1.625 1.623 4.264 0 5.885l-2.84 2.84c-.81.81-1.877 1.216-2.942 1.216" /> <path d="M10.578 14.184c-.213 0-.426-.082-.59-.244-.784-.785-1.217-1.83-1.217-2.94 0-1.113.433-2.158 1.22-2.944l2.84-2.84c1.622-1.62 4.26-1.62 5.883 0 1.622 1.623 1.622 4.262 0 5.883l-.645.643c-.325.326-.852.326-1.178 0-.325-.325-.325-.852 0-1.178l.645-.644c.972-.97.972-2.554 0-3.526s-2.556-.972-3.527 0l-2.84 2.842c-.47.47-.73 1.096-.73 1.762 0 .667.26 1.293.73 1.763.325.327.325.854 0 1.18-.163.162-.376.244-.59.244" />'
218
- },
219
- search: {
220
- width: 16,
221
- height: 16,
222
- content: '<g transform="translate(2 1)" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.5" vector-effect="non-scaling-stroke"><circle cx="5.5" cy="5.5" r="5.5"/><path d="M11.37 13.442l-.995-1.272"/></g>'
223
- },
224
- card: {
225
- width: 15,
226
- height: 15,
227
- content: '<path d="M9 5.5a.5.5 0 0 1 .5.5v5a.5.5 0 0 1-.5.5H4a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5h5zm-.5 1h-4v4h4v-4zm2.5-3a.5.5 0 0 1 .5.5v5a.5.5 0 1 1-1 0V4.5H6a.5.5 0 0 1 0-1h5z" fill-rule="nonzero"/>'
228
- },
229
- podcast: {
230
- width: 15,
231
- height: 15,
232
- content: '<path d="M5.252 11.432A.5.5 0 0 1 4.5 11V4a.5.5 0 0 1 .752-.432l6 3.5a.5.5 0 0 1 0 .864l-6 3.5zm.248-1.303L10.008 7.5 5.5 4.87v5.26z" fill-rule="nonzero" />'
233
- },
234
- arrow: {
235
- width: 12,
236
- height: 12,
237
- content: '<path d="M3 7l3 3.5L9 7M6 10V1" fill="none" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.2" vector-effect="non-scaling-stroke" />'
238
- },
239
- brent: {
240
- width: 9,
241
- height: 12,
242
- content: '<g fill="#999" fill-rule="nonzero"><path d="M4.332 0l.528.606c2.528 2.902 3.804 5.07 3.804 6.634A4.332 4.332 0 110 7.24C0 5.676 1.276 3.508 3.804.606L4.332 0zm0 2.143l-.176.212C2.313 4.589 1.4 6.248 1.4 7.24a2.932 2.932 0 105.864 0c0-.992-.914-2.651-2.756-4.885l-.176-.212z"/><path d="M2.973 7.475c0 .415.417.863.835.924l.097.008v.7c-.79 0-1.548-.716-1.626-1.5l-.006-.132h.7z"/></g> '
243
- },
244
- user: {
245
- width: 16,
246
- height: 16,
247
- content: '<path fill="currentColor" fill-rule="nonzero" d="M8 1a4.25 4.25 0 012.676 7.552 6.751 6.751 0 014.074 6.198.75.75 0 11-1.5 0 5.25 5.25 0 00-10.5 0 .75.75 0 11-1.5 0 6.752 6.752 0 014.074-6.199A4.25 4.25 0 018 1zm0 1.5A2.75 2.75 0 108 8a2.75 2.75 0 000-5.5z" />'
248
- },
249
- bookmark: {
250
- width: 17,
251
- height: 21,
252
- content: '<path d="M16 20l-7.5-6.333L1 20V1h15z" stroke="currentColor" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"/>'
253
- },
254
- shareBookmark: {
255
- width: 11,
256
- height: 15,
257
- content: '<path clip-rule="evenodd" d="M10 14 5.5 9.667 1 14V1h9v13Z" stroke="currentColor" stroke-width="1.2" stroke-linecap="round" stroke-linejoin="round"/>'
258
- },
259
- receipt: {
260
- width: 10,
261
- height: 13,
262
- content: '<g fill="currentColor" fill-rule="nonzero"><path d="M10 0H0v13l2-1.74 1.5 1.305L5 11.26l1.5 1.305L8 11.26 10 13V0zM9 .997v9.81l-1-.87-1.5 1.304L5 9.937 3.5 11.24 2 9.937l-1 .87V.996h8z"/><path d="M7 3v1H3V3zM7 6v1H3V6z"/></g>'
263
- },
264
- read: {
265
- width: 15,
266
- height: 15,
267
- content: '<g fill="none" fill-rule="evenodd"><path opacity=".98" d="M0 0h15v15H0z"/><path d="M13.085 1.694a.513.513 0 01.855.56l-.051.077-3.163 3.975a.514.514 0 01-.73.075l-.068-.069-1.812-2.208a.512.512 0 01.729-.716l.065.066 1.409 1.718 2.766-3.478z" fill="#6EAC65" fill-rule="nonzero"/><path d="M6.454 12.997l-.06-.01-.078-.023a.49.49 0 01-.266-.24l.011.015a2.349 2.349 0 00-.535-.607c-.89-.745-2.117-.917-3.813-.12a.5.5 0 01-.706-.37L1 11.558V4.568a.5.5 0 01.287-.453c2.053-.963 3.695-.733 4.88.26.327.272.556.548.698.77l.084.144.018.04.022.076.01.071L7 11.233l.126-.09c.95-.656 2.16-.857 3.608-.417l.266.087v-2.81a.5.5 0 01.41-.491l.09-.008a.5.5 0 01.492.41l.008.09v3.555a.5.5 0 01-.713.452c-1.696-.796-2.922-.624-3.813.12a2.533 2.533 0 00-.497.544l-.038.064a.486.486 0 01-.485.258zm-4.29-8.17L2 4.892v5.92c1.637-.572 2.977-.348 4 .42l.002-5.58a2.605 2.605 0 00-.476-.513c-.81-.677-1.897-.88-3.362-.314z" fill="currentColor" fill-rule="nonzero"/></g>'
268
- },
269
- listened: {
270
- width: 15,
271
- height: 15,
272
- content: '<g fill-rule="nonzero"><path d="M4.978 4.354a.5.5 0 01-.332.624c-1.197.367-2.064 1.527-2.14 2.897l-.005.167a.749.749 0 01.999.708v3a.75.75 0 01-1.458.248L2 12a1 1 0 01-1-1v-1a1 1 0 01.5-.866V8.072c0-1.886 1.172-3.535 2.854-4.05a.5.5 0 01.624.332zM10 7a.5.5 0 01.492.41l.008.09.001 1.634a1 1 0 01.492.745L11 10v1a1 1 0 01-.883.993L10 12l-.042-.002a.75.75 0 01-1.451-.146L8.5 11.75v-3a.75.75 0 011.001-.707L9.5 7.5l.008-.09A.5.5 0 0110 7z" fill="currentColor" /><path d="M11.585 1.194a.513.513 0 01.855.56l-.051.077-3.163 3.975a.514.514 0 01-.73.075l-.068-.069-1.812-2.208a.512.512 0 01.729-.716l.065.066 1.409 1.718 2.766-3.478z" fill="#6EAC65" /></g>'
273
- },
274
- magic: {
275
- width: 15,
276
- height: 15,
277
- content: '<g fill-rule="evenodd" clip-rule="evenodd"> <path d="M7.804.4a.6.6 0 0 1 .6.6v2.035a.6.6 0 0 1-1.2 0V1a.6.6 0 0 1 .6-.6ZM7.804 10.577a.6.6 0 0 1 .6.6v2.035a.6.6 0 1 1-1.2 0v-2.035a.6.6 0 0 1 .6-.6ZM14.636 7.106a.6.6 0 0 1-.6.6h-2.078a.6.6 0 1 1 0-1.2h2.078a.6.6 0 0 1 .6.6ZM4.25 7.106a.6.6 0 0 1-.6.6H1.573a.6.6 0 0 1 0-1.2H3.65a.6.6 0 0 1 .6.6ZM12.639 2.37a.585.585 0 0 1 0 .84l-1.442 1.412a.615.615 0 0 1-.857 0 .585.585 0 0 1 0-.84l1.442-1.412a.615.615 0 0 1 .857 0ZM12.639 11.843a.615.615 0 0 1-.857 0L10.34 10.43a.585.585 0 0 1 0-.84.615.615 0 0 1 .857 0l1.442 1.413a.585.585 0 0 1 0 .84ZM5.269 4.621a.615.615 0 0 1-.858 0L2.97 3.208a.585.585 0 0 1 0-.84.615.615 0 0 1 .858 0l1.442 1.413a.585.585 0 0 1 0 .84ZM8.926 6.074a.6.6 0 0 1 0 .849l-.863.863-.849-.849.863-.863a.6.6 0 0 1 .849 0ZM7.348 8.5l-5.924 5.924a.6.6 0 1 1-.848-.848L6.5 7.652l.848.848Z"/> </g>'
278
- }
279
- };
280
-
281
- var styles$H = {"root":"SvgSymbol-module_root__WctNR","small":"SvgSymbol-module_small__h9V-w","normal":"SvgSymbol-module_normal__gFAVe","medium":"SvgSymbol-module_medium__QaYjY","large":"SvgSymbol-module_large__o6A4o","adaptive":"SvgSymbol-module_adaptive__gL9qn","fb":"SvgSymbol-module_fb__HZqcB","vk":"SvgSymbol-module_vk__XctB2","ok":"SvgSymbol-module_ok__IM6Z9","tw":"SvgSymbol-module_tw__fio-Q","tg":"SvgSymbol-module_tg__GRhd-","magic":"SvgSymbol-module_magic__N-jKk","reaction":"SvgSymbol-module_reaction__xSbgo","card":"SvgSymbol-module_card__2nVFu","podcast":"SvgSymbol-module_podcast__Yp05r","read":"SvgSymbol-module_read__Bu653","listened":"SvgSymbol-module_listened__AOn7j","menu":"SvgSymbol-module_menu__z-dLm","cross":"SvgSymbol-module_cross__3Xej1","isInFeature":"SvgSymbol-module_isInFeature__BmyI-","isInCard":"SvgSymbol-module_isInCard__USxBS","isInTopicBlockItem":"SvgSymbol-module_isInTopicBlockItem__cnCgw","isInPageStatic":"SvgSymbol-module_isInPageStatic__7kMP-","isInMaterialMeta":"SvgSymbol-module_isInMaterialMeta__lIKJO","isInAudioPlayer":"SvgSymbol-module_isInAudioPlayer__mamWa","isInEpisodeBlock":"SvgSymbol-module_isInEpisodeBlock__oZ6JG","isInButtonPlaybackRate":"SvgSymbol-module_isInButtonPlaybackRate__NnADm","isInButtonBackward":"SvgSymbol-module_isInButtonBackward__x8L9a","isInButtonForward":"SvgSymbol-module_isInButtonForward__TtixK","isInToolbar":"SvgSymbol-module_isInToolbar__RzbaX","play":"SvgSymbol-module_play__dAES0","meduzaLogo":"SvgSymbol-module_meduzaLogo__aVKzZ","arrow":"SvgSymbol-module_arrow__lWTSJ","oil":"SvgSymbol-module_oil__VFGTp","search":"SvgSymbol-module_search__h06cc","user":"SvgSymbol-module_user__ORMm-","bookmark":"SvgSymbol-module_bookmark__JPKyG","shareBookmark":"SvgSymbol-module_shareBookmark__7w9X9","receipt":"SvgSymbol-module_receipt__o3V8u","isInHeader":"SvgSymbol-module_isInHeader__M5Tzw"};
282
-
283
- const SvgSymbol = ({
284
- icon,
285
- size,
286
- styleContext
287
- }) => {
288
- const data = icons[icon];
289
- return /*#__PURE__*/React.createElement("svg", {
290
- "data-testid": "svg-symbol",
291
- xmlns: "http://www.w3.org/2000/svg",
292
- xmlnsXlink: "http://www.w3.org/1999/xlink",
293
- className: makeClassName([[styles$H.root, true], [styles$H[size], !!styles$H[size]], [styles$H[icon], !!styles$H[icon]], [styles$H[styleContext], !!styles$H[styleContext]]]),
294
- width: data.width,
295
- height: data.height,
296
- viewBox: `0 0 ${data.width} ${data.height}`,
297
- dangerouslySetInnerHTML: {
298
- __html: data.content
299
- }
300
- });
301
- };
302
-
303
- var styles$G = {"root":"Switcher-module_root__cBsJB","dark":"Switcher-module_dark__1QQsH","control":"Switcher-module_control__60WMX","input":"Switcher-module_input__5UDnv","knob":"Switcher-module_knob__PwA1A","children":"Switcher-module_children__uLapU","left":"Switcher-module_left__5-HNa","right":"Switcher-module_right__82Edk","isInPanel":"Switcher-module_isInPanel__-nBSf","isInMenu":"Switcher-module_isInMenu__RQVhp","isInLive":"Switcher-module_isInLive__ZyMCT"};
304
-
305
- const Switcher = ({
306
- enabled,
307
- children,
308
- childrenPosition = 'left',
309
- onChange,
310
- styleContext,
311
- theme = 'light'
312
- }) => ( /*#__PURE__*/React.createElement("label", {
313
- "data-testid": "switcher",
314
- className: makeClassName([[styles$G.root, true], [styles$G[theme], !!styles$G[theme]], [styles$G[styleContext], !!styles$G[styleContext]]])
315
- }, children && childrenPosition === 'left' && ( /*#__PURE__*/React.createElement("div", {
316
- className: makeClassName([[styles$G.children, true], [styles$G.left, true]])
317
- }, children)), /*#__PURE__*/React.createElement("input", {
318
- className: styles$G.input,
319
- type: "checkbox",
320
- checked: enabled,
321
- onChange: onChange
322
- }), /*#__PURE__*/React.createElement("span", {
323
- className: styles$G.control
324
- }, /*#__PURE__*/React.createElement("span", {
325
- className: styles$G.knob
326
- })), children && childrenPosition === 'right' && ( /*#__PURE__*/React.createElement("div", {
327
- className: makeClassName([[styles$G.children, true], [styles$G.right, true]])
328
- }, children))));
329
-
330
- const makeStyleContext = (classNames, styleContext, styles) => {
331
- const context = Array.isArray(styleContext) ? styleContext.filter(ctx => styles[ctx]).map(ctx => [[styles[ctx]], true]) : [[styles[styleContext], !!styleContext && !!styles[styleContext]]];
332
- return classNames.concat(context);
333
- };
334
-
335
- const BlockContext = /*#__PURE__*/React.createContext({
336
- lightBox: null
337
- });
338
- const BlockProvider = BlockContext.Provider;
339
-
340
- const POST_MESSAGE_PREFIX = 'mdzKitMsg';
341
- const postMessage = (category, element, action) => {
342
- const target = window.top;
343
- const msg = `${POST_MESSAGE_PREFIX}=${JSON.stringify({
344
- category,
345
- element,
346
- action
347
- })}`;
348
- if (typeof target !== 'undefined') {
349
- target.postMessage(msg, '*');
350
- }
351
- };
352
-
353
- var styles$F = {"root":"Lazy-module_root__DWw8D"};
354
-
355
- const Lazy = ({
356
- children,
357
- threshold
358
- }) => {
359
- const [ref, inView, entry] = reactIntersectionObserver.useInView({
360
- threshold: threshold || 0
361
- });
362
- const [visible, setVisible] = React.useState(false);
363
- React.useEffect(() => {
364
- if (entry && entry.boundingClientRect && entry.boundingClientRect.y < 0) {
365
- setVisible(true);
366
- }
367
- }, [entry]);
368
- React.useEffect(() => {
369
- if (inView) {
370
- setVisible(true);
371
- }
372
- }, [inView]);
373
- return /*#__PURE__*/React.createElement("div", {
374
- className: makeClassName([[styles$F.root, true], [styles$F.visible, visible]]),
375
- ref: ref,
376
- "data-testid": "lazy"
377
- }, visible && children);
378
- };
379
-
380
- const MediaQuerySizes = {
381
- MOBILE: 512,
382
- PORTRAIT_TABLET: 768,
383
- LANDSCAPE_TABLET: 1024,
384
- DESKTOP: 1010,
385
- WIDE_DESKTOP: 1200
386
- };
387
- const imageBreakpoints = {
388
- 325: '(min-width: 0)',
389
- 520: '(min-width: 325px)',
390
- 600: '(min-width: 600px)',
391
- 650: '(min-width: 650px)',
392
- 980: '(min-width: 1000px)',
393
- 1335: '(min-width: 1000px)'
394
- };
395
- const imageConditionalKeys = {
396
- xs: [325],
397
- superFull: [1335, 650, 520, 325],
398
- full: [980, 650, 520, 325],
399
- default: [650, 520, 325],
400
- narrow: [600, 325]
401
- };
402
- const SocialLabels = {
403
- ru: {
404
- tg: 'Телеграм',
405
- fb: 'Фейсбук',
406
- tw: 'Твиттер',
407
- pdf: 'PDF',
408
- unblock: 'Magic link',
409
- bookmark: 'В закладки',
410
- reaction: 'Напишите нам'
411
- },
412
- en: {
413
- tg: 'Telegram',
414
- fb: 'Fb',
415
- tw: 'Twitter',
416
- pdf: 'PDF',
417
- unblock: 'Magic link',
418
- bookmark: 'Add to bookmarks'
419
- }
420
- };
421
-
422
- const toCamel = s => s.replace(/([_][a-z])/gi, str => str.toUpperCase().replace('_', ''));
423
- const toCapitalize = s => s[0].toUpperCase() + s.slice(1);
424
-
425
- const RenderPicture = ({
426
- source,
427
- fallbackSource,
428
- optimized,
429
- alt,
430
- display,
431
- onLoad
432
- }) => {
433
- const [fallback, setFallback] = React.useState(false);
434
- React.useEffect(() => {
435
- setFallback(!window.HTMLPictureElement);
436
- }, []);
437
- const keys = imageConditionalKeys[toCamel(display)] || imageConditionalKeys.default;
438
- return /*#__PURE__*/React.createElement("picture", null, source && ( /*#__PURE__*/React.createElement("source", {
439
- media: "(min-width: 325px)",
440
- srcSet: `${source[1]} 2x`
441
- })), optimized && !optimized.w325 && ( /*#__PURE__*/React.createElement("source", {
442
- media: "(min-width: 0)",
443
- srcSet: `${optimized.original}`
444
- })), optimized && keys.map(key => {
445
- const breakpoint = optimized[`w${key}`];
446
- if (!breakpoint) {
447
- return null;
448
- }
449
- return /*#__PURE__*/React.createElement(React.Fragment, {
450
- key: key
451
- }, /*#__PURE__*/React.createElement("source", {
452
- type: "image/webp",
453
- media: imageBreakpoints[key],
454
- srcSet: `${breakpoint['2x_webp']} 2x, ${breakpoint['1x_webp']} 1x `
455
- }), /*#__PURE__*/React.createElement("source", {
456
- type: "image/png",
457
- media: imageBreakpoints[key],
458
- srcSet: `${breakpoint['2x']} 2x, ${breakpoint['1x']} 1x `
459
- }));
460
- }), /*#__PURE__*/React.createElement("img", {
461
- src: fallback ? fallbackSource : 'data:image/gif;base64,R0lGODlhAQABAPAAAPLy8gAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==',
462
- alt: alt,
463
- onLoad: () => onLoad(true)
464
- }));
465
- };
466
-
467
- var styles$E = {"root":"Image-module_root__H5wAh","isStatic":"Image-module_isStatic__TmQ1V","isLoaded":"Image-module_isLoaded__keFnD","wrapper":"Image-module_wrapper__gJtbB","fullscreen":"Image-module_fullscreen__4PU9c","dark":"Image-module_dark__qjo5O"};
468
-
469
- const Image = ({
470
- alt,
471
- display,
472
- optimized,
473
- width,
474
- height,
475
- source,
476
- lazy,
477
- ratio,
478
- styleContext,
479
- fullscreen = true
480
- }) => {
481
- const {
482
- lightBox
483
- } = React.useContext(BlockContext);
484
- const [isLoaded, setIsLoaded] = React.useState(lazy ? false : true);
485
- const handleClick = () => {
486
- if (!lightBox || !fullscreen || optimized && !optimized.original) {
487
- return;
488
- }
489
- postMessage('', 'fullscreen_click', 'click');
490
- lightBox.show(optimized, width, height, alt);
491
- };
492
- const blockStyles = {
493
- maxWidth: width <= 649 ? width : '100%'
494
- };
495
- const pictureStyles = {
496
- paddingBottom: styleContext === 'isInDynamicBlock' ? '100%' : `${100 / (ratio || width / height)}%`
497
- };
498
- /* fallback w325 url until w6 was released */
499
- const fallbackSource = source && source[0] || optimized.w325 && optimized.w325['1x'] || optimized.original;
500
- let classNames = [[styles$E.root, true], [styles$E.isLoaded, isLoaded], [styles$E.fullscreen, lightBox && optimized && optimized.original && fullscreen]];
501
- if (styleContext) {
502
- classNames = makeStyleContext(classNames, styleContext, styles$E);
503
- }
504
- return /*#__PURE__*/React.createElement("div", {
505
- className: makeClassName(classNames),
506
- style: blockStyles,
507
- "data-testid": "image"
508
- }, /*#__PURE__*/React.createElement("div", {
509
- className: styles$E.wrapper,
510
- style: pictureStyles,
511
- onClick: () => handleClick(),
512
- onKeyPress: () => handleClick(),
513
- role: "button",
514
- tabIndex: 0
515
- }, lazy ? ( /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Lazy, {
516
- threshold: 0.25
517
- }, /*#__PURE__*/React.createElement(RenderPicture, {
518
- fallbackSource: fallbackSource,
519
- source: source,
520
- optimized: optimized,
521
- alt: alt,
522
- display: display,
523
- onLoad: setIsLoaded
524
- })), /*#__PURE__*/React.createElement("noscript", null, /*#__PURE__*/React.createElement("img", {
525
- src: fallbackSource,
526
- alt: alt
527
- })))) : ( /*#__PURE__*/React.createElement(RenderPicture, {
528
- fallbackSource: fallbackSource,
529
- source: source,
530
- optimized: optimized,
531
- alt: alt,
532
- display: display,
533
- onLoad: setIsLoaded
534
- }))));
535
- };
536
-
537
- var styles$D = {"root":"Popover-module_root__nBiV4","fadeOut":"Popover-module_fadeOut__Y88V7","visible":"Popover-module_visible__XVQLW","fadeIn":"Popover-module_fadeIn__FK1gd","overlay":"Popover-module_overlay__NAPar","container":"Popover-module_container__y4SB1","disappear":"Popover-module_disappear__uUn2b","dismiss":"Popover-module_dismiss__W8KFF","background":"Popover-module_background__apiio","appear":"Popover-module_appear__b-CZ2","body":"Popover-module_body__UJEZf"};
538
-
539
- const Popover = ({
540
- children,
541
- onClose
542
- }) => {
543
- const [visible, setVisible] = React.useState(true);
544
- const handleClose = () => {
545
- setVisible(false);
546
- setTimeout(onClose, 350);
547
- };
548
- const handleScroll = () => {
549
- handleClose();
550
- };
551
- const escFunction = event => {
552
- if (event.key === 'Escape') {
553
- handleClose();
554
- }
555
- };
556
- React.useEffect(() => {
557
- document.body.dataset.popover = 'true';
558
- window.addEventListener('keydown', escFunction, false);
559
- window.addEventListener('scroll', handleScroll, false);
560
- return () => {
561
- document.body.removeAttribute('data-popover');
562
- window.removeEventListener('keydown', escFunction, false);
563
- window.removeEventListener('scroll', handleScroll, false);
564
- };
565
- }, [visible]);
566
- /* eslint-disable jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions */
567
- return /*#__PURE__*/React.createElement("div", {
568
- "data-testid": "popover",
569
- className: makeClassName([[styles$D.root, true], [styles$D.visible, visible]])
570
- }, /*#__PURE__*/React.createElement("div", {
571
- className: styles$D.overlay,
572
- onClick: () => handleClose()
573
- }), /*#__PURE__*/React.createElement("div", {
574
- className: styles$D.container
575
- }, /*#__PURE__*/React.createElement("button", {
576
- type: "button",
577
- className: styles$D.dismiss,
578
- onClick: () => handleClose(),
579
- "aria-label": "dismiss"
580
- }), /*#__PURE__*/React.createElement("svg", {
581
- width: "100%",
582
- className: styles$D.background
583
- }, /*#__PURE__*/React.createElement("defs", null, /*#__PURE__*/React.createElement("mask", {
584
- id: "myMask",
585
- x: "0",
586
- y: "0",
587
- width: "100%",
588
- height: "100%"
589
- }, /*#__PURE__*/React.createElement("rect", {
590
- fill: "white",
591
- y: "0",
592
- width: "100%",
593
- height: "100%",
594
- x: "0"
595
- }), /*#__PURE__*/React.createElement("svg", {
596
- x: "50%",
597
- overflow: "visible"
598
- }, /*#__PURE__*/React.createElement("g", {
599
- transform: "translate(-12 0)"
600
- }, /*#__PURE__*/React.createElement("path", {
601
- d: "M4.61852778e-14,9.76996262e-15 L9.84597532,5.80270273 C11.0992017,6.54128882 12.6546044,6.54128882 13.9078308,5.80270273 L23.7538061,9.76996262e-15 L4.61852778e-14,9.76996262e-15 Z"
602
- }))))), /*#__PURE__*/React.createElement("rect", {
603
- fill: "#F7F7F7",
604
- id: "base-mask",
605
- mask: "url(#myMask)",
606
- x: "0",
607
- y: "0",
608
- width: "100%",
609
- height: "100%"
610
- })), /*#__PURE__*/React.createElement("div", {
611
- className: styles$D.body
612
- }, children)));
613
- };
614
-
615
- var styles$C = {"root":"Footnote-module_root__W5D8G","body":"Footnote-module_body__C-ZC-","dismiss":"Footnote-module_dismiss__Q2hAX"};
616
-
617
- const Footnote = ({
618
- children,
619
- onClose
620
- }) => {
621
- return /*#__PURE__*/React.createElement("div", {
622
- "data-testid": "footnote",
623
- className: makeClassName([[styles$C.root, true]])
624
- }, /*#__PURE__*/React.createElement("button", {
625
- className: styles$C.dismiss,
626
- type: "button",
627
- onClick: () => onClose()
628
- }, /*#__PURE__*/React.createElement(SvgSymbol, {
629
- icon: "cross",
630
- size: "unset"
631
- })), /*#__PURE__*/React.createElement("div", {
632
- className: styles$C.body
633
- }, children));
634
- };
635
-
636
- var viewportSize = () => ({
637
- width: window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth,
638
- height: window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight
639
- });
640
-
641
- var styles$B = {"root":"DotsOnImage-module_root__8UQf2","isVisible":"DotsOnImage-module_isVisible__rA5x9","marker":"DotsOnImage-module_marker__pLdQT","show":"DotsOnImage-module_show__Ec0lG","dot":"DotsOnImage-module_dot__e2MWx","isActive":"DotsOnImage-module_isActive__Bhb58","popover":"DotsOnImage-module_popover__zHSbU","isRight":"DotsOnImage-module_isRight__IaUbc","isTop":"DotsOnImage-module_isTop__RMK49","isLeft":"DotsOnImage-module_isLeft__Q6JZ-","isBottom":"DotsOnImage-module_isBottom__c-aLe"};
642
-
643
- const DotsOnImage = ({
644
- block: {
645
- optimized,
646
- width,
647
- height,
648
- credit,
649
- display,
650
- dots
651
- }
652
- }) => {
653
- const [ratio, setRatio] = React.useState(1);
654
- const [ref, inView, entry] = reactIntersectionObserver.useInView();
655
- const container = React.useRef(null);
656
- const [popover, setPopover] = React.useState({
657
- title: null,
658
- body: null,
659
- show: false,
660
- id: null
661
- });
662
- const [visible, setVisible] = React.useState(false);
663
- const defaultWidth = 375;
664
- React.useEffect(() => {
665
- if (entry && entry.boundingClientRect && entry.boundingClientRect.y < 0) {
666
- setVisible(true);
667
- }
668
- }, [entry]);
669
- React.useEffect(() => {
670
- if (inView) {
671
- setVisible(true);
672
- }
673
- }, [inView]);
674
- React.useEffect(() => {
675
- if (popover.id) {
676
- document.addEventListener('click', handleClickOutside);
677
- } else {
678
- document.removeEventListener('click', handleClickOutside);
679
- }
680
- return () => document.removeEventListener('click', handleClickOutside);
681
- }, [popover]);
682
- React.useEffect(() => {
683
- setDotSize();
684
- window.addEventListener('resize', setDotSize);
685
- return () => document.removeEventListener('resize', setDotSize);
686
- }, [visible]);
687
- const setDotSize = () => {
688
- const width = window.innerWidth;
689
- if (width < defaultWidth) {
690
- const ratio = width / defaultWidth;
691
- setRatio(ratio);
692
- } else {
693
- setRatio(1);
694
- }
695
- };
696
- const handleClickOutside = event => {
697
- const path = event.composedPath();
698
- if (path.indexOf(container.current) === -1) {
699
- setPopover({
700
- show: false
701
- });
702
- }
703
- };
704
- const handleDotClick = dot => {
705
- const shouldShow = dot.id !== popover.id;
706
- const side = dot.position.x > 50 ? 'isLeft' : 'isRight';
707
- const align = dot.position.y > 50 ? 'isBottom' : 'isTop';
708
- const style = {
709
- top: `${dot.position.y}%`,
710
- left: `${dot.position.x}%`
711
- };
712
- setPopover({
713
- title: dot.title,
714
- body: dot.body,
715
- show: shouldShow,
716
- id: shouldShow ? dot.id : null,
717
- style,
718
- side,
719
- align
720
- });
721
- };
722
- return /*#__PURE__*/React.createElement("div", {
723
- className: makeClassName([[styles$B.root, true], [styles$B.isVisible, visible]]),
724
- "data-testid": "dots-on-image",
725
- ref: ref
726
- }, /*#__PURE__*/React.createElement(Image, {
727
- fullscreen: false,
728
- optimized: optimized,
729
- width: width,
730
- height: height,
731
- alt: credit,
732
- display: display
733
- }), /*#__PURE__*/React.createElement("div", {
734
- ref: container
735
- }, dots.map(dot => ( /*#__PURE__*/React.createElement("div", {
736
- className: styles$B.dot,
737
- key: dot.id,
738
- style: {
739
- top: `${dot.position.y}%`,
740
- left: `${dot.position.x}%`,
741
- transform: `scale(${ratio}) translate(-${50 / ratio}%, -${50 / ratio}%)`
742
- }
743
- }, /*#__PURE__*/React.createElement("button", {
744
- className: makeClassName([[styles$B.marker, true], [styles$B.isActive, dot.id === popover.id]]),
745
- type: "button",
746
- style: {
747
- backgroundColor: dot.icon.color
748
- },
749
- onClick: () => handleDotClick(dot)
750
- }, dot.icon.type === 'svg' && ( /*#__PURE__*/React.createElement("div", {
751
- dangerouslySetInnerHTML: {
752
- __html: dot.icon.svg_string
753
- }
754
- })), dot.icon.type === 'number' && dot.icon.number)))), popover.show && ( /*#__PURE__*/React.createElement(React.Fragment, null, viewportSize().width >= MediaQuerySizes.LANDSCAPE_TABLET ? ( /*#__PURE__*/React.createElement("div", {
755
- className: makeClassName([[styles$B.popover, true], [styles$B[popover.side], !!popover.side], [styles$B[popover.align], !!popover.align]]),
756
- style: popover.style
757
- }, /*#__PURE__*/React.createElement(Footnote, {
758
- onClose: () => {
759
- setPopover({
760
- show: false
761
- });
762
- }
763
- }, popover.title && /*#__PURE__*/React.createElement("h3", null, popover.title), /*#__PURE__*/React.createElement("div", {
764
- dangerouslySetInnerHTML: {
765
- __html: popover.body
766
- }
767
- })))) : ( /*#__PURE__*/React.createElement(Popover, {
768
- onClose: () => {
769
- setPopover({
770
- show: false
771
- });
772
- }
773
- }, popover.title && /*#__PURE__*/React.createElement("h3", null, popover.title), /*#__PURE__*/React.createElement("div", {
774
- dangerouslySetInnerHTML: {
775
- __html: popover.body
776
- }
777
- })))))));
778
- };
779
-
780
- var styles$A = {"root":"Tag-module_root__sGbnM","small":"Tag-module_small__hcPrf","large":"Tag-module_large__EKMu6","dark":"Tag-module_dark__9SHCb","light":"Tag-module_light__qlfy3","gold":"Tag-module_gold__u0bzS","gray":"Tag-module_gray__eazPk","inherit":"Tag-module_inherit__z21c-","is1to1":"Tag-module_is1to1__V-fH5","is1to2":"Tag-module_is1to2__b9Obh","isInSuperBlock":"Tag-module_isInSuperBlock__wrFUY","is1to3":"Tag-module_is1to3__vZT-R","is1to4":"Tag-module_is1to4__MBh5V","slide":"Tag-module_slide__gzptP","game":"Tag-module_game__NmKec","podcastMaterial":"Tag-module_podcastMaterial__O-LBI","richRelated":"Tag-module_richRelated__Qs6Ei","isInBookRelated":"Tag-module_isInBookRelated__ikTaj","card":"Tag-module_card__TX87-","live":"Tag-module_live__ykyR7","episode":"Tag-module_episode__3OHmN","podcast":"Tag-module_podcast__K6dHn","rich":"Tag-module_rich__vPnWd","isInDynamicBlock":"Tag-module_isInDynamicBlock__WNleF","mobile":"Tag-module_mobile__19oMH","desktop":"Tag-module_desktop__cNyQs"};
781
-
782
- const Tag = ({
783
- children,
784
- size = 'small',
785
- theme = 'gold',
786
- styleContext,
787
- correlation,
788
- onlyOn
789
- }) => {
790
- let classNames = [[styles$A.root, true], [styles$A[size], !!size && !!styles$A[size]], [styles$A[theme], !!theme && !!styles$A[theme]], [styles$A[onlyOn], !!onlyOn && !!styles$A[onlyOn]], [styles$A[correlation], !!correlation && !!styles$A[correlation]]];
791
- if (styleContext) {
792
- classNames = makeStyleContext(classNames, styleContext, styles$A);
793
- }
794
- return /*#__PURE__*/React.createElement("div", {
795
- "data-testid": "tag",
796
- className: makeClassName(classNames)
797
- }, children);
798
- };
799
-
800
- var styles$z = {"root":"MediaCaption-module_root__1r0wu","caption":"MediaCaption-module_caption__ewfcc","credit":"MediaCaption-module_credit__7y4v8","dark":"MediaCaption-module_dark__7a9Cm","video":"MediaCaption-module_video__RDTUa","picture":"MediaCaption-module_picture__abCvw","desktop":"MediaCaption-module_desktop__e0lCY","isDark":"MediaCaption-module_isDark__IFb9X"};
801
-
802
- const MediaCaption = ({
803
- credit,
804
- caption,
805
- styleContext
806
- }) => {
807
- let classNames = [[styles$z.root, true]];
808
- if (styleContext) {
809
- classNames = makeStyleContext(classNames, styleContext, styles$z);
810
- }
811
- return /*#__PURE__*/React.createElement("div", {
812
- "data-testid": "media-caption",
813
- className: makeClassName(classNames)
814
- }, caption && ( /*#__PURE__*/React.createElement("div", {
815
- className: styles$z.caption,
816
- dangerouslySetInnerHTML: {
817
- __html: caption
818
- }
819
- })), credit && ( /*#__PURE__*/React.createElement("div", {
820
- className: styles$z.credit,
821
- dangerouslySetInnerHTML: {
822
- __html: credit
823
- }
824
- })));
825
- };
826
-
827
- var styles$y = {"root":"Table-module_root__fRuZq","card":"Table-module_card__8r-EA","table":"Table-module_table__7Pagp","slide":"Table-module_slide__dgMPV","wrapper":"Table-module_wrapper__AP4Pz","tracks":"Table-module_tracks__mRNG0","default":"Table-module_default__nwBEg","full":"Table-module_full__YZPDz","row":"Table-module_row__9OHT3","cell":"Table-module_cell__yFdqc","fixedColumn":"Table-module_fixedColumn__O2528","white":"Table-module_white__Laj3-","gray":"Table-module_gray__FPFh0","pink":"Table-module_pink__CGkAA","blue":"Table-module_blue__b8BHs","yellow":"Table-module_yellow__YOJgu","orange":"Table-module_orange__B-i8L","green":"Table-module_green__Bt6iC","violet":"Table-module_violet__yTZd7","header":"Table-module_header__YPDzO","s":"Table-module_s__I-CeX","m":"Table-module_m__vxhDf","l":"Table-module_l__GYHhk","xs":"Table-module_xs__imR8t"};
828
-
829
- const Table = ({
830
- styleContext,
831
- block: {
832
- rows,
833
- options,
834
- display,
835
- columns_widths: columnsWidth,
836
- table_credit: tableCredit
837
- }
838
- }) => {
839
- const colors = {
840
- '#ffffff': 'white',
841
- '#f5f5f5': 'gray',
842
- '#feeeee': 'pink',
843
- '#e6f3ff': 'blue',
844
- '#fffde6': 'yellow',
845
- '#fff9f2': 'orange',
846
- '#e7f2ef': 'green',
847
- '#f4f0f8': 'violet'
848
- };
849
- let classNames = [[styles$y.root, true], [styles$y[display], !!display && !!styles$y[display]]];
850
- if (styleContext) {
851
- classNames = makeStyleContext(classNames, styleContext, styles$y);
852
- }
853
- return /*#__PURE__*/React.createElement("div", {
854
- "data-testid": "table",
855
- className: makeClassName(classNames)
856
- }, /*#__PURE__*/React.createElement("div", {
857
- className: styles$y.wrapper
858
- }, /*#__PURE__*/React.createElement("div", {
859
- className: styles$y.table
860
- }, /*#__PURE__*/React.createElement("div", {
861
- className: styles$y.tracks
862
- }, rows.map((row, i) => {
863
- return /*#__PURE__*/React.createElement("div", {
864
- key: row.key,
865
- className: styles$y.row
866
- }, row.cells.map((cell, j) => ( /*#__PURE__*/React.createElement("div", {
867
- key: cell.key,
868
- className: makeClassName([[styles$y.cell, true], [styles$y.header, options.header && i === 0], [styles$y[colors[cell.color]], true], [styles$y[columnsWidth[j]], true], [styles$y.fixedColumn, options.fixed_first_column && j === 0]]),
869
- dangerouslySetInnerHTML: {
870
- __html: cell.val
871
- }
872
- }))));
873
- })))), tableCredit && ( /*#__PURE__*/React.createElement(MediaCaption, {
874
- credit: tableCredit,
875
- styleContext: styleContext
876
- })));
877
- };
878
-
879
- var styles$x = {"root":"MaterialNote-module_root__99HSA","dark":"MaterialNote-module_dark__etjym","note_credit":"MaterialNote-module_note_credit__J1skG","note_caption":"MaterialNote-module_note_caption__G2Ad0","center":"MaterialNote-module_center__mDLEO","default":"MaterialNote-module_default__ozgd7","card":"MaterialNote-module_card__EVuZe","slide":"MaterialNote-module_slide__mg8XV","game":"MaterialNote-module_game__c-r0n","gameSurvey":"MaterialNote-module_gameSurvey__azhu6"};
880
-
881
- const MaterialNote = ({
882
- block: {
883
- data
884
- },
885
- styleContext
886
- }) => {
887
- let classNames = [[styles$x.root, true]];
888
- if (styleContext) {
889
- classNames = makeStyleContext(classNames, styleContext, styles$x);
890
- }
891
- return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
892
- "data-testid": "material-note",
893
- className: makeClassName(classNames)
894
- }, data && data.map(item => ( /*#__PURE__*/React.createElement("p", {
895
- className: styles$x[item.type],
896
- key: item.id,
897
- dangerouslySetInnerHTML: {
898
- __html: item.data
899
- }
900
- })))));
901
- };
902
-
903
- var styles$w = {"root":"BookmarkButton-module_root__A-75w","control":"BookmarkButton-module_control__-xy5O","dark":"BookmarkButton-module_dark__GkMEC","light":"BookmarkButton-module_light__1W6tx","isInBookmarks":"BookmarkButton-module_isInBookmarks__YSjjj","isInGrid":"BookmarkButton-module_isInGrid__Desh-"};
904
-
905
- const BookmarkButton = ({
906
- styleContext,
907
- theme,
908
- isInBookmarks,
909
- onClick
910
- }) => {
911
- let classNames = [[styles$w.root, true], [styles$w.isInBookmarks, isInBookmarks], [styles$w[theme], !!theme && !!styles$w[theme]]];
912
- if (styleContext) {
913
- classNames = makeStyleContext(classNames, styleContext, styles$w);
914
- }
915
- return /*#__PURE__*/React.createElement("div", {
916
- "data-testid": "bookmark-button",
917
- className: makeClassName(classNames)
918
- }, /*#__PURE__*/React.createElement("button", {
919
- className: styles$w.control,
920
- onClick: () => onClick(),
921
- type: "button"
922
- }, /*#__PURE__*/React.createElement(SvgSymbol, {
923
- icon: "bookmark",
924
- size: "unset"
925
- })));
926
- };
927
-
928
- var styles$v = {"root":"MaterialTitle-module_root__VSphO","primary":"MaterialTitle-module_primary__XGnpb","secondary":"MaterialTitle-module_secondary__7IDEp"};
929
-
930
- const Primary = ({
931
- children
932
- }) => {
933
- return /*#__PURE__*/React.createElement("span", {
934
- className: styles$v.primary
935
- }, children);
936
- };
937
- const Secondary = ({
938
- children
939
- }) => {
940
- return /*#__PURE__*/React.createElement("span", {
941
- className: styles$v.secondary
942
- }, children);
943
- };
944
- const MaterialTitle = ({
945
- children
946
- }) => {
947
- return /*#__PURE__*/React.createElement("h1", {
948
- className: styles$v.root,
949
- "data-testid": "material-title"
950
- }, children);
951
- };
952
-
953
- var styles$u = {"root":"Dropdown-module_root__Wv7S-","menu":"Dropdown-module_menu__11IQL","inactive":"Dropdown-module_inactive__E5CP6","isInAudioPanel":"Dropdown-module_isInAudioPanel__UniSV"};
954
-
955
- const Menu = ({
956
- children
957
- }) => {
958
- return /*#__PURE__*/React.createElement("div", {
959
- "data-testid": "dropdown",
960
- className: styles$u.menu
961
- }, children);
962
- };
963
- const Dropdown = ({
964
- children,
965
- active,
966
- styleContext
967
- }) => {
968
- let classNames = [[styles$u.root, true], [styles$u.inactive, !active && styleContext === 'isPodcastSeason' && !!styles$u.inactive]];
969
- if (styleContext) {
970
- classNames = makeStyleContext(classNames, styleContext, styles$u);
971
- }
972
- return /*#__PURE__*/React.createElement("div", {
973
- "data-testid": "dropdown",
974
- className: makeClassName(classNames)
975
- }, children);
976
- };
977
-
978
- var styles$t = {"root":"Toolbar-module_root__RnmlI","list":"Toolbar-module_list__-IhdP","item":"Toolbar-module_item__CWmGM","isInTopbar":"Toolbar-module_isInTopbar__WEDi8","center":"Toolbar-module_center__pvdiJ","game":"Toolbar-module_game__etwIA","gameSurvey":"Toolbar-module_gameSurvey__v4D31","slide":"Toolbar-module_slide__PtB3l","card":"Toolbar-module_card__Lutyq","isDark":"Toolbar-module_isDark__MG6Ar","dark":"Toolbar-module_dark__a9sgz"};
979
-
980
- const ToolbarItem = ({
981
- children
982
- }) => {
983
- return /*#__PURE__*/React.createElement("li", {
984
- className: styles$t.item
985
- }, children);
986
- };
987
-
988
- const Toolbar = ({
989
- children,
990
- styleContext
991
- }) => {
992
- let classNames = [[styles$t.root, true]];
993
- if (styleContext) {
994
- classNames = makeStyleContext(classNames, styleContext, styles$t);
995
- }
996
- return /*#__PURE__*/React.createElement("div", {
997
- "data-testid": "toolbar",
998
- className: makeClassName(classNames)
999
- }, /*#__PURE__*/React.createElement("ul", {
1000
- className: styles$t.list
1001
- }, children));
1002
- };
1003
-
1004
- var styles$s = {"containerInDynamicBlock":"Meta-module_containerInDynamicBlock__YSh66","containerInDynamicBlockAndMaterial":"Meta-module_containerInDynamicBlockAndMaterial__4v4A9","root":"Meta-module_root__H-Q4d","rich":"Meta-module_rich__dCkJK","podcast":"Meta-module_podcast__MI8gD","episode":"Meta-module_episode__0n9CF","simple":"Meta-module_simple__tztcr","slide":"Meta-module_slide__3OyIN","card":"Meta-module_card__2vqfN","game":"Meta-module_game__HNcgr","isInMaterial":"Meta-module_isInMaterial__vKcTK","isInSearchItem":"Meta-module_isInSearchItem__ENqHo","isInMediaBlock":"Meta-module_isInMediaBlock__TENZG","center":"Meta-module_center__seHro","half":"Meta-module_half__aoa9h","podcastMaterial":"Meta-module_podcastMaterial__GTPyD","light":"Meta-module_light__oW3kc","dark":"Meta-module_dark__tLQNJ","isDark":"Meta-module_isDark__xSl1J","hasSource":"Meta-module_hasSource__OZJ0y","bookmark":"Meta-module_bookmark__jcFWn","isInBookRelated":"Meta-module_isInBookRelated__Ohidg","mobile":"Meta-module_mobile__PbG8N","desktop":"Meta-module_desktop__W5AB7"};
1005
-
1006
- const Meta = ({
1007
- hasSource,
1008
- theme,
1009
- children,
1010
- onlyOn,
1011
- styleContext
1012
- }) => {
1013
- let classNames = [[styles$s.root, true], [styles$s[theme], !!theme && !!styles$s[theme]], [styles$s[onlyOn], !!onlyOn], [styles$s.hasSource, hasSource]];
1014
- if (styleContext) {
1015
- classNames = makeStyleContext(classNames, styleContext, styles$s);
1016
- }
1017
- return /*#__PURE__*/React.createElement("div", {
1018
- "data-testid": "meta",
1019
- className: makeClassName(classNames)
1020
- }, children);
1021
- };
1022
-
1023
- var styles$r = {"root":"Timestamp-module_root__jPJ6w"};
1024
-
1025
- const Timestamp = ({
1026
- publishedAt,
1027
- locale = 'ru',
1028
- type
1029
- }) => {
1030
- let published;
1031
- const timeFormat = locale === 'ru' ? 'HH:mm, D MMMM YYYY' : 'h:mm a, MMMM D, YYYY';
1032
- const preparedPublishedAt = publishedAt * 1000;
1033
- dayjs.locale(locale);
1034
- dayjs.extend(relativeTime);
1035
- if (type === 'fromNow') {
1036
- published = dayjs(preparedPublishedAt).fromNow();
1037
- } else if (type === 'format') {
1038
- published = dayjs(preparedPublishedAt).format('HH:mm');
1039
- } else if (type === 'date') {
1040
- published = dayjs(preparedPublishedAt).format(timeFormat);
1041
- } else {
1042
- throw new Error('Unknown time type');
1043
- }
1044
- return /*#__PURE__*/React.createElement("time", {
1045
- suppressHydrationWarning: true,
1046
- "data-testid": "timestamp",
1047
- className: styles$r.root
1048
- }, published);
1049
- };
1050
-
1051
- const DangerousHTML = ({
1052
- className = '',
1053
- tagName: TagName = 'div',
1054
- html
1055
- }) => {
1056
- const element = React.useRef(null);
1057
- const [canRenderHtml, setCanRenderHtml] = React.useState(false);
1058
- React.useEffect(() => {
1059
- setCanRenderHtml(true);
1060
- }, []);
1061
- const replaceScriptElementsRecursive = React.useCallback(node => {
1062
- if (node.tagName === 'SCRIPT' && (!node.id || node.id.indexOf('script-') !== 0)) {
1063
- const script = document.createElement('script');
1064
- script.id = `script-${Math.random().toString(16).slice(2)}`;
1065
- script.innerHTML = node.innerHTML;
1066
- const attrs = node.attributes;
1067
- for (let i = 0; i < attrs.length; i += 1) {
1068
- const {
1069
- name,
1070
- value
1071
- } = attrs[i];
1072
- script.setAttribute(name, value);
1073
- }
1074
- node.parentElement.replaceChild(script, node);
1075
- } else {
1076
- let i = 0;
1077
- const children = node.childNodes;
1078
- while (i < children.length) {
1079
- replaceScriptElementsRecursive(children[i]);
1080
- i += 1;
1081
- }
1082
- }
1083
- }, []);
1084
- const prepareAnchors = React.useCallback(() => {
1085
- const anchors = Array.from(element.current.querySelectorAll('a'));
1086
- anchors.forEach(a => {
1087
- a.setAttribute('target', '_blank');
1088
- });
1089
- }, []);
1090
- React.useEffect(() => {
1091
- if (canRenderHtml && html.indexOf('script') > -1 && element.current.firstElementChild) {
1092
- element.current.firstElementChild.innerHTML = html;
1093
- replaceScriptElementsRecursive(element.current.firstElementChild);
1094
- prepareAnchors();
1095
- }
1096
- }, [canRenderHtml, element, html, replaceScriptElementsRecursive, prepareAnchors]);
1097
- return /*#__PURE__*/React.createElement("div", {
1098
- ref: element
1099
- }, /*#__PURE__*/React.createElement(TagName, {
1100
- className: className,
1101
- dangerouslySetInnerHTML: {
1102
- __html: html
1103
- }
1104
- }));
1105
- };
1106
-
1107
- var styles$q = {"root":"EmbedBlock-module_root__wNZlD","object":"EmbedBlock-module_object__DONQ0","objectWrap":"EmbedBlock-module_objectWrap__qpbni","gameEmbed":"EmbedBlock-module_gameEmbed__tO5Ha","proportional":"EmbedBlock-module_proportional__zDPfm","default":"EmbedBlock-module_default__np8MO","xs":"EmbedBlock-module_xs__PNHGz","full":"EmbedBlock-module_full__Gmz7o","super_full":"EmbedBlock-module_super_full__-h382","figure":"EmbedBlock-module_figure__fNZB-","dark":"EmbedBlock-module_dark__S2R9f","isInGroupedBlock":"EmbedBlock-module_isInGroupedBlock__Wjj7k","control":"EmbedBlock-module_control__9bJUa","raw_html":"EmbedBlock-module_raw_html__EfYVy","mobileFullwidth":"EmbedBlock-module_mobileFullwidth__1MDT5","isInCard":"EmbedBlock-module_isInCard__WnLHG","isInSlide":"EmbedBlock-module_isInSlide__BtdnY","cc":"EmbedBlock-module_cc__Gyw44","isInSensitiveBlock":"EmbedBlock-module_isInSensitiveBlock__nYajZ","isInAnswer":"EmbedBlock-module_isInAnswer__WuZ0H","picture":"EmbedBlock-module_picture__Weamy","wrapper":"EmbedBlock-module_wrapper__ynT7R","mobile":"EmbedBlock-module_mobile__lEuww","desktop":"EmbedBlock-module_desktop__599S7"};
1108
-
1109
- const EmbedGif = ({
1110
- gif,
1111
- mp4Url,
1112
- style
1113
- }) => {
1114
- const [videoFrozen, setVideoFrozen] = React.useState(false);
1115
- const videoElem = React.useRef(null);
1116
- const handleVideoTouch = () => {
1117
- videoElem.current.play();
1118
- setVideoFrozen(false);
1119
- };
1120
- const handleVideoError = () => {
1121
- const video = videoElem.current;
1122
- video.setAttribute('poster', video.dataset.gif);
1123
- setVideoFrozen(false);
1124
- };
1125
- React.useEffect(() => {
1126
- const video = videoElem.current;
1127
- const {
1128
- width: viewportWidth
1129
- } = viewportSize();
1130
- if (viewportWidth >= MediaQuerySizes.MOBILE) {
1131
- video.setAttribute('autoplay', true);
1132
- video.play();
1133
- } else {
1134
- setVideoFrozen(true);
1135
- video.pause();
1136
- video.addEventListener('touchstart', handleVideoTouch);
1137
- }
1138
- video.addEventListener('error', handleVideoError);
1139
- return () => {
1140
- video.removeEventListener('touchstart', handleVideoTouch);
1141
- video.removeEventListener('error', handleVideoError);
1142
- };
1143
- }, []);
1144
- return /*#__PURE__*/React.createElement("div", {
1145
- className: styles$q.figure
1146
- }, /*#__PURE__*/React.createElement("div", {
1147
- className: styles$q.objectWrap,
1148
- style: style,
1149
- "data-frozen": videoFrozen
1150
- }, /*#__PURE__*/React.createElement("video", {
1151
- playsInline: true,
1152
- muted: true,
1153
- loop: true,
1154
- autoPlay: true,
1155
- preload: "metadata",
1156
- "data-gif": gif,
1157
- ref: videoElem
1158
- }, /*#__PURE__*/React.createElement("source", {
1159
- src: `https://meduza.io${mp4Url}`,
1160
- type: "video/mp4"
1161
- }))));
1162
- };
1163
-
1164
- const EmbedBlock = ({
1165
- block,
1166
- block: {
1167
- data,
1168
- data: {
1169
- html,
1170
- display,
1171
- only_on: onlyOn,
1172
- provider,
1173
- cc,
1174
- optimized,
1175
- small_url: small,
1176
- large_url: large,
1177
- gif_url: gifUrl,
1178
- mp4_url: mp4Url
1179
- }
1180
- },
1181
- styleContext,
1182
- children
1183
- }) => {
1184
- const [isPopoverShown, setIsPopoverShown] = React.useState(false);
1185
- const style = {};
1186
- const isProportional = block.data.height && block.data.width;
1187
- const fullWidthProviders = ['youtube', 'vimeo', 'onetv', 'coub', 'meduza', 'facebook_video'];
1188
- const mobileFullwidth = fullWidthProviders.indexOf(provider) > -1 || block.type === 'dots_on_image';
1189
- const renderCC = context => ( /*#__PURE__*/React.createElement(MediaCaption, {
1190
- credit: data.credit,
1191
- caption: data.caption,
1192
- styleContext: context || styleContext
1193
- }));
1194
- const renderEmbed = style => {
1195
- switch (block.type) {
1196
- case 'gif':
1197
- {
1198
- return /*#__PURE__*/React.createElement(EmbedGif, {
1199
- gif: gifUrl,
1200
- mp4Url: mp4Url,
1201
- style: style
1202
- });
1203
- }
1204
- case 'image':
1205
- {
1206
- return /*#__PURE__*/React.createElement("div", {
1207
- className: styles$q.figure
1208
- }, /*#__PURE__*/React.createElement(Image, {
1209
- source: !optimized && [small, large],
1210
- optimized: block.data.optimized,
1211
- width: block.data.width,
1212
- height: block.data.height,
1213
- alt: block.data.caption,
1214
- display: block.data.display,
1215
- lazy: block.data.lazy,
1216
- styleContext: styleContext
1217
- }));
1218
- }
1219
- case 'game_embed':
1220
- {
1221
- return /*#__PURE__*/React.createElement("div", {
1222
- className: styles$q.gameEmbed
1223
- }, /*#__PURE__*/React.createElement("iframe", {
1224
- src: block.data.game_src,
1225
- id: block.data.game_id,
1226
- title: "Game embed"
1227
- }));
1228
- }
1229
- case 'dots_on_image':
1230
- {
1231
- return /*#__PURE__*/React.createElement("div", {
1232
- className: styles$q.figure
1233
- }, /*#__PURE__*/React.createElement(DotsOnImage, {
1234
- block: data
1235
- }));
1236
- }
1237
- default:
1238
- {
1239
- return /*#__PURE__*/React.createElement("div", {
1240
- className: styles$q.object
1241
- }, /*#__PURE__*/React.createElement("div", {
1242
- className: styles$q.wrapper,
1243
- style: style
1244
- }, /*#__PURE__*/React.createElement(DangerousHTML, {
1245
- className: styles$q.objectWrap,
1246
- html: html
1247
- })));
1248
- }
1249
- }
1250
- };
1251
- if (isProportional) {
1252
- style.paddingBottom = `${block.data.height / block.data.width * 100}%`;
1253
- style.height = 0;
1254
- }
1255
- let classNames = [[styles$q.root, true], [styles$q.cc, cc], [styles$q[display], !!display && styles$q[display]], [styles$q[provider], !!provider && !!styles$q[provider]], [styles$q[onlyOn], !!onlyOn && styles$q[onlyOn]], [styles$q.mobileFullwidth, mobileFullwidth], [styles$q.proportional, isProportional]];
1256
- // Убираем из контекста все, что не начинается с приставки isIn,
1257
- // чтобы не применились лишние модификаторы
1258
- // TODO: в w6 модификаторы должны передаваться явно
1259
- if (styleContext && Array.isArray(styleContext)) {
1260
- const filteredContext = styleContext.filter(key => key.startsWith('isIn') && styles$q[key]).reduce((acc, key) => {
1261
- acc.push(key);
1262
- return acc;
1263
- }, []);
1264
- classNames = makeStyleContext(classNames, filteredContext, styles$q);
1265
- }
1266
- return /*#__PURE__*/React.createElement("figure", {
1267
- className: makeClassName(classNames)
1268
- }, children && ( /*#__PURE__*/React.createElement("div", {
1269
- className: styles$q.object
1270
- }, /*#__PURE__*/React.createElement("div", {
1271
- className: styles$q.wrapper,
1272
- style: style
1273
- }, /*#__PURE__*/React.createElement("div", {
1274
- className: styles$q.objectWrap
1275
- }, children)))), !children && renderEmbed(style), cc === 'default' && /*#__PURE__*/React.createElement("figcaption", null, renderCC()), cc === 'button' && ( /*#__PURE__*/React.createElement("button", {
1276
- className: styles$q.control,
1277
- type: "button",
1278
- "aria-label": "Open",
1279
- onClick: () => {
1280
- setIsPopoverShown(!isPopoverShown);
1281
- }
1282
- })), cc === 'button' && isPopoverShown && ( /*#__PURE__*/React.createElement(Popover, {
1283
- onClose: () => {
1284
- setIsPopoverShown(false);
1285
- }
1286
- }, renderCC('isInPopover'))));
1287
- };
1288
-
1289
- const IframeBlock = ({
1290
- block,
1291
- block: {
1292
- id
1293
- },
1294
- styleContext,
1295
- lang = 'ru'
1296
- }) => {
1297
- const element = React.useRef(null);
1298
- const renderIframe = () => {
1299
- const rootEl = document.createElement('div');
1300
- const contentEl = document.createElement('div');
1301
- const scriptEl = document.createElement('script');
1302
- const style = document.createElement('style');
1303
- const range = document.createRange();
1304
- range.setStart(contentEl, 0);
1305
- contentEl.setAttribute('id', 'content');
1306
- scriptEl.textContent = `
1307
- function getDocHeight() {
1308
- var doc = document;
1309
- var body = doc.body;
1310
- var html = doc.documentElement;
1311
- var height = Math.max( body.scrollHeight, body.offsetHeight,
1312
- html.clientHeight, html.scrollHeight, html.offsetHeight );
1313
-
1314
- doc.body.style.margin="0";
1315
-
1316
- return document.getElementById('content') ? document.getElementById('content').offsetHeight : height;
1317
- }
1318
-
1319
- function sendDocHeightMsg() {
1320
- var height = getDocHeight();
1321
- var message = JSON.stringify({
1322
- action: {
1323
- type: "UPDATE_HEIGHT",
1324
- payload: {
1325
- id: "${block.id}",
1326
- height: height
1327
- }
1328
- }
1329
- });
1330
- parent.postMessage("mdzMaterialEmbedHeight=" + message, '*');
1331
- }
1332
-
1333
- setInterval(sendDocHeightMsg, 300);
1334
- `;
1335
- style.type = 'text/css';
1336
- style.innerHTML = block.type === 'embed_code' ? '.twitter-tweet { padding-top: 15px; margin: 0 !important; }' : '.twitter-tweet { margin: 0 !important; } .fb-post { display: block; } .instagram-media { min-width: 0 !important; }';
1337
- contentEl.appendChild(range.createContextualFragment(block.data.html));
1338
- rootEl.appendChild(scriptEl);
1339
- rootEl.appendChild(contentEl);
1340
- contentEl.appendChild(style);
1341
- const frame = element.current.querySelector('iframe').contentDocument;
1342
- frame.open();
1343
- frame.close();
1344
- frame.documentElement.setAttribute('lang', lang);
1345
- frame.body.appendChild(rootEl);
1346
- };
1347
- React.useEffect(() => {
1348
- renderIframe();
1349
- }, []);
1350
- return /*#__PURE__*/React.createElement(EmbedBlock, {
1351
- block: block,
1352
- styleContext: styleContext
1353
- }, /*#__PURE__*/React.createElement("div", {
1354
- ref: element,
1355
- dangerouslySetInnerHTML: {
1356
- __html: `<iframe id=${id} frameBorder="0" scrolling="no"></iframe>`
1357
- }
1358
- }));
1359
- };
1360
-
1361
- const EmbedBlockContainer = ({
1362
- block,
1363
- styleContext,
1364
- lang
1365
- }) => {
1366
- if (block.data && block.data.wrap_with_iframe) {
1367
- return /*#__PURE__*/React.createElement(IframeBlock, {
1368
- block: block,
1369
- styleContext: styleContext,
1370
- lang: lang
1371
- });
1372
- }
1373
- return /*#__PURE__*/React.createElement(EmbedBlock, {
1374
- block: block,
1375
- styleContext: styleContext
1376
- });
1377
- };
1378
-
1379
- var styles$p = {"root":"QuoteBlock-module_root__4qa1J","center":"QuoteBlock-module_center__1f83y"};
1380
-
1381
- const QuoteBlock = ({
1382
- block: {
1383
- data
1384
- },
1385
- styleContext
1386
- }) => {
1387
- let classNames = [[styles$p.root, true]];
1388
- if (styleContext) {
1389
- classNames = makeStyleContext(classNames, styleContext, styles$p);
1390
- }
1391
- return /*#__PURE__*/React.createElement("div", {
1392
- "data-testid": "quote-block",
1393
- className: makeClassName(classNames)
1394
- }, /*#__PURE__*/React.createElement("p", {
1395
- dangerouslySetInnerHTML: {
1396
- __html: data
1397
- }
1398
- }));
1399
- };
1400
-
1401
- var styles$o = {"root":"CardTitle-module_root__Pvx--","index":"CardTitle-module_index__Keled","title":"CardTitle-module_title__Lkflo","mobile":"CardTitle-module_mobile__6N3hB","desktop":"CardTitle-module_desktop__sBokS"};
1402
-
1403
- const CardTitle = ({
1404
- block: {
1405
- data: {
1406
- only_on: onlyOn,
1407
- index,
1408
- text
1409
- },
1410
- id
1411
- },
1412
- styleContext
1413
- }) => {
1414
- return /*#__PURE__*/React.createElement("div", {
1415
- "data-testid": "card-title",
1416
- id: id,
1417
- className: makeClassName([[styles$o.root, true], [styles$o[onlyOn], !!onlyOn], [styles$o[styleContext], !!styleContext && !!styles$o[styleContext]]])
1418
- }, /*#__PURE__*/React.createElement("div", {
1419
- className: styles$o.index
1420
- }, index), /*#__PURE__*/React.createElement("h3", {
1421
- className: styles$o.title
1422
- }, text));
1423
- };
1424
-
1425
- var styles$n = {"root":"ChapterBlock-module_root__iw7d2","subtitle":"ChapterBlock-module_subtitle__IpWgz","mobile":"ChapterBlock-module_mobile__V1Eye","desktop":"ChapterBlock-module_desktop__9xWf4"};
1426
-
1427
- const ChapterBlock = ({
1428
- block: {
1429
- data,
1430
- only_on: onlyOn
1431
- },
1432
- styleContext,
1433
- id
1434
- }) => {
1435
- return /*#__PURE__*/React.createElement("div", {
1436
- "data-testid": "chapter-block",
1437
- id: id,
1438
- className: makeClassName([[styles$n.root, true], [styles$n[onlyOn], !!onlyOn]])
1439
- }, /*#__PURE__*/React.createElement("div", {
1440
- className: makeClassName([[styles$n.subtitle, true], [styles$n[styleContext], !!styleContext && !!styles$n[styleContext]]]),
1441
- dangerouslySetInnerHTML: {
1442
- __html: data
1443
- }
1444
- }));
1445
- };
1446
-
1447
- const generateGradient = (color, type) => {
1448
- const steps = {
1449
- mediaBlockBottom: [[0, 7], [0.08, 12], [0.16, 17], [0.22, 21], [0.32, 26], [0.42, 32], [0.52, 38], [0.62, 47], [0.72, 57], [0.82, 65], [1, 82]],
1450
- mediaBlockTop: [[0.5, 0], [0, 97]]
1451
- };
1452
- const gradient = steps[type].map(i => `rgba(${color}, ${i[0]}) ${i[1]}%`);
1453
- return `linear-gradient(-180deg, ${gradient})`;
1454
- };
1455
-
1456
- var styles$m = {"root":"SimpleTitle-module_root__YOzNn","mobile":"SimpleTitle-module_mobile__1QiJd","desktop":"SimpleTitle-module_desktop__ZF5Af"};
1457
-
1458
- const SimpleTitle = ({
1459
- block: {
1460
- data: {
1461
- first
1462
- },
1463
- only_on: onlyOn
1464
- },
1465
- styleContext
1466
- }) => {
1467
- let classNames = [[styles$m.root, true], [styles$m[onlyOn], true]];
1468
- if (styleContext) {
1469
- classNames = makeStyleContext(classNames, styleContext, styles$m);
1470
- }
1471
- return /*#__PURE__*/React.createElement("h1", {
1472
- "data-testid": "simple-title",
1473
- className: makeClassName(classNames)
1474
- }, first);
1475
- };
1476
-
1477
- var styles$l = {"root":"RichTitle-module_root__U5XQu","slide":"RichTitle-module_slide__eU9Ob","game":"RichTitle-module_game__S1csb","podcastMaterial":"RichTitle-module_podcastMaterial__AulVF","half":"RichTitle-module_half__yBMby","featured":"RichTitle-module_featured__ULNQn","isInMediaBlock":"RichTitle-module_isInMediaBlock__2h6rl","isInBookRelated":"RichTitle-module_isInBookRelated__LcCPV","isInDynamicBlock":"RichTitle-module_isInDynamicBlock__J-gM6","mobile":"RichTitle-module_mobile__W5L9E","desktop":"RichTitle-module_desktop__k0PkC"};
1478
-
1479
- const RichTitle = ({
1480
- block: {
1481
- only_on: onlyOn,
1482
- data: {
1483
- featured,
1484
- first,
1485
- second,
1486
- as: TagName = 'h1'
1487
- }
1488
- },
1489
- styleContext
1490
- }) => {
1491
- let classNames = [[styles$l.root, true], [styles$l[onlyOn], true], [styles$l.featured, !!featured]];
1492
- if (styleContext) {
1493
- classNames = makeStyleContext(classNames, styleContext, styles$l);
1494
- }
1495
- return /*#__PURE__*/React.createElement(TagName, {
1496
- "data-testid": "rich-title",
1497
- className: makeClassName(classNames)
1498
- }, first, second && /*#__PURE__*/React.createElement("span", null, " ", second));
1499
- };
1500
-
1501
- var styles$k = {"p":"SimpleBlock-module_p__7aRnT","h2":"SimpleBlock-module_h2__aWlMn","h3":"SimpleBlock-module_h3__uPh0-","h4":"SimpleBlock-module_h4__MxGXA","lead":"SimpleBlock-module_lead__NzEPT","lead_hr":"SimpleBlock-module_lead_hr__XN0rm","context_p":"SimpleBlock-module_context_p__Mdu1R","blockquote":"SimpleBlock-module_blockquote__nX-Ab","game":"SimpleBlock-module_game__uVeJJ","slide":"SimpleBlock-module_slide__MaaUF","dark":"SimpleBlock-module_dark__qtLhq","divider":"SimpleBlock-module_divider__-VXBu","isInIntro":"SimpleBlock-module_isInIntro__UOePf","center":"SimpleBlock-module_center__D1CsV","isInImportantLead":"SimpleBlock-module_isInImportantLead__qzKDo","podcastMaterial":"SimpleBlock-module_podcastMaterial__XEMjh","isInAnswer":"SimpleBlock-module_isInAnswer__Asx7d","mobile":"SimpleBlock-module_mobile__EVGYJ","desktop":"SimpleBlock-module_desktop__6ZH5e","isDark":"SimpleBlock-module_isDark__ehYKr"};
1502
-
1503
- const SimpleBlock = ({
1504
- block: {
1505
- data,
1506
- type,
1507
- only_on: onlyOn
1508
- },
1509
- styleContext,
1510
- id = null
1511
- }) => {
1512
- let TagName;
1513
- let classNames = [[styles$k[type], !!type && !!styles$k[type]], [styles$k[onlyOn], true]];
1514
- if (styleContext) {
1515
- classNames = makeStyleContext(classNames, styleContext, styles$k);
1516
- }
1517
- switch (type) {
1518
- case 'context_p':
1519
- case 'lead':
1520
- case 'note_caption':
1521
- case 'note_credit':
1522
- {
1523
- TagName = 'p';
1524
- break;
1525
- }
1526
- case 'divider':
1527
- return /*#__PURE__*/React.createElement("hr", {
1528
- className: makeClassName(classNames)
1529
- });
1530
- case 'lead_hr':
1531
- {
1532
- TagName = 'div';
1533
- break;
1534
- }
1535
- default:
1536
- TagName = type;
1537
- }
1538
- return /*#__PURE__*/React.createElement(TagName, {
1539
- className: makeClassName(classNames),
1540
- dangerouslySetInnerHTML: {
1541
- __html: data
1542
- },
1543
- id: id
1544
- });
1545
- };
1546
-
1547
- var styles$j = {"root":"ListBlock-module_root__dqomP","ol":"ListBlock-module_ol__1l6nP","ul":"ListBlock-module_ul__bgHlv","center":"ListBlock-module_center__bEBN-","isInImportantLead":"ListBlock-module_isInImportantLead__ewcD1","dark":"ListBlock-module_dark__NzpYz","mobile":"ListBlock-module_mobile__qEBsn","desktop":"ListBlock-module_desktop__HN0IU"};
1548
-
1549
- const ListBlock = ({
1550
- block: {
1551
- type,
1552
- data,
1553
- only_on: onlyOn
1554
- },
1555
- styleContext
1556
- }) => {
1557
- const TagName = type;
1558
- let classNames = [[styles$j.root, true], [styles$j[onlyOn], true], [styles$j[type], !!type && !!styles$j[type]]];
1559
- if (styleContext) {
1560
- classNames = makeStyleContext(classNames, styleContext, styles$j);
1561
- }
1562
- return /*#__PURE__*/React.createElement(TagName, {
1563
- className: makeClassName(classNames),
1564
- "data-testid": "list-block"
1565
- }, data.map((item, index) => ( /*#__PURE__*/React.createElement("li", {
1566
- key: index,
1567
- dangerouslySetInnerHTML: {
1568
- __html: item
1569
- }
1570
- }))));
1571
- };
1572
-
1573
- var styles$i = {"root":"RelatedBlock-module_root__cr1c-","header":"RelatedBlock-module_header__bfUJD","items":"RelatedBlock-module_items__rzzam","rich":"RelatedBlock-module_rich__1cWdn","first":"RelatedBlock-module_first__ZkcP5","simple":"RelatedBlock-module_simple__m22bj","center":"RelatedBlock-module_center__WVpIJ","isInSlideMaterial":"RelatedBlock-module_isInSlideMaterial__VumDw","mobile":"RelatedBlock-module_mobile__AScBA","desktop":"RelatedBlock-module_desktop__uMXUY"};
1574
-
1575
- const RelatedBlock = ({
1576
- block: {
1577
- data: {
1578
- title,
1579
- related
1580
- },
1581
- only_on: onlyOn
1582
- },
1583
- styleContext
1584
- }) => {
1585
- let classNames = [[styles$i.root, true], [styles$i[onlyOn], true]];
1586
- if (styleContext) {
1587
- classNames = makeStyleContext(classNames, styleContext, styles$i);
1588
- }
1589
- return /*#__PURE__*/React.createElement("div", {
1590
- "data-testid": "related-block",
1591
- className: makeClassName(classNames)
1592
- }, /*#__PURE__*/React.createElement("h3", {
1593
- className: styles$i.header
1594
- }, title), /*#__PURE__*/React.createElement("ul", {
1595
- className: styles$i.items
1596
- }, related.map((item, index) => ( /*#__PURE__*/React.createElement("li", {
1597
- key: item.id || index,
1598
- className: styles$i[item.layout]
1599
- }, /*#__PURE__*/React.createElement(reactRouterDom.Link, {
1600
- to: item.full_url || `/${item.url}`
1601
- }, /*#__PURE__*/React.createElement("span", {
1602
- className: styles$i.first
1603
- }, item.title), item.second_title && ' ', item.second_title && /*#__PURE__*/React.createElement("span", null, item.second_title)))))));
1604
- };
1605
-
1606
- var styles$h = {"root":"SourceBlock-module_root__9dnI4","text":"SourceBlock-module_text__M5-uy","origin":"SourceBlock-module_origin__fyvxH","center":"SourceBlock-module_center__UOMwy","mobile":"SourceBlock-module_mobile__QVEyg","desktop":"SourceBlock-module_desktop__xdXWm","isDark":"SourceBlock-module_isDark__etwk1"};
1607
-
1608
- const SourceBlock = ({
1609
- block: {
1610
- only_on: onlyOn,
1611
- data: {
1612
- quote,
1613
- origin,
1614
- url
1615
- }
1616
- },
1617
- styleContext
1618
- }) => {
1619
- let classNames = [[styles$h.root, true], [styles$h[onlyOn], true]];
1620
- if (styleContext) {
1621
- classNames = makeStyleContext(classNames, styleContext, styles$h);
1622
- }
1623
- return /*#__PURE__*/React.createElement("blockquote", {
1624
- "data-testid": "source-block",
1625
- cite: url,
1626
- className: makeClassName(classNames)
1627
- }, /*#__PURE__*/React.createElement("a", {
1628
- className: styles$h.text,
1629
- href: url,
1630
- target: "_blank",
1631
- rel: "noopener noreferrer"
1632
- }, quote.map((item, index) => ( /*#__PURE__*/React.createElement("p", {
1633
- key: index,
1634
- dangerouslySetInnerHTML: {
1635
- __html: item.data
1636
- }
1637
- }))), /*#__PURE__*/React.createElement("footer", null, /*#__PURE__*/React.createElement("cite", {
1638
- className: styles$h.origin
1639
- }, origin))));
1640
- };
1641
-
1642
- var styles$g = {"root":"SensitiveBlock-module_root__1Nl9-","container":"SensitiveBlock-module_container__GE2tW","overlay":"SensitiveBlock-module_overlay__tEsK8","content":"SensitiveBlock-module_content__RYbdd","button":"SensitiveBlock-module_button__LGEEM","default":"SensitiveBlock-module_default__pkWhC","full":"SensitiveBlock-module_full__hlH41","media":"SensitiveBlock-module_media__nuL1S","super_full":"SensitiveBlock-module_super_full__C7UyP","visible":"SensitiveBlock-module_visible__bXhYO","isInCard":"SensitiveBlock-module_isInCard__uANYL","isInSlide":"SensitiveBlock-module_isInSlide__ZAVUU"};
1643
-
1644
- const SensitiveBlock = ({
1645
- block,
1646
- block: {
1647
- cc,
1648
- caption,
1649
- credit,
1650
- blurred_image: blurredImage
1651
- },
1652
- block: {
1653
- item: {
1654
- data: {
1655
- display
1656
- }
1657
- }
1658
- },
1659
- styleContext
1660
- }) => {
1661
- const [visible, isVisible] = React.useState(false);
1662
- const handleClick = () => {
1663
- isVisible(true);
1664
- };
1665
- let classNames = [[styles$g.root, true], [styles$g.visible, visible], [styles$g[display], display && styles$g[display]]];
1666
- let context = ['isInSensitiveBlock'];
1667
- if (styleContext) {
1668
- classNames = makeStyleContext(classNames, styleContext, styles$g);
1669
- context = [...styleContext, 'isInSensitiveBlock'];
1670
- }
1671
- return /*#__PURE__*/React.createElement("div", {
1672
- "data-testid": "sensitive-block",
1673
- className: makeClassName(classNames)
1674
- }, /*#__PURE__*/React.createElement("div", {
1675
- className: styles$g.container
1676
- }, /*#__PURE__*/React.createElement("div", {
1677
- className: styles$g.overlay,
1678
- style: {
1679
- backgroundImage: `url(${blurredImage})`
1680
- }
1681
- }, /*#__PURE__*/React.createElement("div", {
1682
- className: styles$g.content
1683
- }, /*#__PURE__*/React.createElement("p", {
1684
- dangerouslySetInnerHTML: {
1685
- __html: block.title
1686
- }
1687
- }), /*#__PURE__*/React.createElement("div", {
1688
- className: styles$g.button
1689
- }, /*#__PURE__*/React.createElement(Button, {
1690
- onClick: () => handleClick(),
1691
- theme: "light"
1692
- }, block.button.text)))), /*#__PURE__*/React.createElement("div", {
1693
- className: styles$g.media
1694
- }, /*#__PURE__*/React.createElement(EmbedBlockContainer, {
1695
- block: block.item,
1696
- styleContext: context
1697
- }))), cc && ( /*#__PURE__*/React.createElement("figcaption", {
1698
- className: styles$g.figcaption
1699
- }, /*#__PURE__*/React.createElement(MediaCaption, {
1700
- credit: credit,
1701
- caption: caption,
1702
- styleContext: styleContext
1703
- }))));
1704
- };
1705
-
1706
- var styles$f = {"root":"GroupedBlock-module_root__MQQin","hasFigcaption":"GroupedBlock-module_hasFigcaption__Y05ed","item":"GroupedBlock-module_item__-InqF","items":"GroupedBlock-module_items__8X4js","figcaption":"GroupedBlock-module_figcaption__OE5-u","default":"GroupedBlock-module_default__Tha8f","full":"GroupedBlock-module_full__SNwyE","super_full":"GroupedBlock-module_super_full__HTA9D","mobile":"GroupedBlock-module_mobile__xqMw5","desktop":"GroupedBlock-module_desktop__Oobdp"};
1707
-
1708
- const GroupedBlock = ({
1709
- block,
1710
- block: {
1711
- only_on: onlyOn
1712
- },
1713
- styleContext
1714
- }) => {
1715
- const maxHeight = Math.min(...block.data.map(item => item.data && item.data.height || item.item && item.item.data.height));
1716
- const normalizedBoxesWidth = block.data.map(item => {
1717
- const width = item.data && item.data.width || item.item && item.item.data.heigh;
1718
- const height = item.data && item.data.height || item.item && item.item.data.heigh;
1719
- return width / (height / maxHeight);
1720
- });
1721
- const sumWidth = normalizedBoxesWidth.reduce((sum, x) => sum + x);
1722
- let classNames = [[styles$f.root, true], [styles$f[onlyOn], true], [styles$f.hasFigcaption, block.cc === 'default'], [styles$f[block.display], !!block.display && styles$f[block.display]]];
1723
- if (styleContext) {
1724
- classNames = makeStyleContext(classNames, styleContext, styles$f);
1725
- }
1726
- return /*#__PURE__*/React.createElement("div", {
1727
- "data-testid": "grouped-block",
1728
- className: makeClassName(classNames)
1729
- }, /*#__PURE__*/React.createElement("div", {
1730
- className: styles$f.items
1731
- }, block.data.map((item, index) => {
1732
- const percentWidth = normalizedBoxesWidth[index] / sumWidth * 100;
1733
- return /*#__PURE__*/React.createElement("div", {
1734
- className: styles$f.item,
1735
- key: item.id,
1736
- style: {
1737
- width: `${percentWidth}%`
1738
- }
1739
- }, item.type === 'sensitive' ? ( /*#__PURE__*/React.createElement(SensitiveBlock, {
1740
- block: item,
1741
- styleContext: ['isInGroupedBlock']
1742
- })) : ( /*#__PURE__*/React.createElement(EmbedBlockContainer, {
1743
- block: item,
1744
- styleContext: ['isInGroupedBlock']
1745
- })));
1746
- })), block.cc && ( /*#__PURE__*/React.createElement("figcaption", {
1747
- className: styles$f.figcaption
1748
- }, /*#__PURE__*/React.createElement(MediaCaption, {
1749
- credit: block.credit,
1750
- caption: block.caption,
1751
- styleContext: styleContext
1752
- }))));
1753
- };
1754
-
1755
- var styles$e = {"root":"MetaItem-module_root__sRbrZ","hasBullets":"MetaItem-module_hasBullets__b1eW9","hasSource":"MetaItem-module_hasSource__35olm","listened":"MetaItem-module_listened__XZWFQ","read":"MetaItem-module_read__O3cUz","datetime":"MetaItem-module_datetime__--O8c"};
1756
-
1757
- const MetaItem = ({
1758
- hasSource,
1759
- type,
1760
- children,
1761
- bullets
1762
- }) => {
1763
- const classNames = [[styles$e.root, true], [styles$e[type], !!type && !!styles$e[type]], [styles$e.hasSource, !!hasSource], [styles$e.hasBullets, !!bullets]];
1764
- return /*#__PURE__*/React.createElement("div", {
1765
- "data-testid": "meta-item",
1766
- className: makeClassName(classNames)
1767
- }, children);
1768
- };
1769
-
1770
- var styles$d = {"root":"MetaItemLive-module_root__XfQiW","gold":"MetaItemLive-module_gold__f1UOy","frame":"MetaItemLive-module_frame__FHByQ","liveMiddle":"MetaItemLive-module_liveMiddle__SX4Gs","liveFirstWave":"MetaItemLive-module_liveFirstWave__QqstP","liveSecondWave":"MetaItemLive-module_liveSecondWave__hlbpt"};
1771
-
1772
- const MetaItemLive = ({
1773
- theme = 'gold'
1774
- }) => {
1775
- const classNames = [[styles$d.root, true], [styles$d[theme], !!theme && styles$d[theme]]];
1776
- return /*#__PURE__*/React.createElement("div", {
1777
- "data-testid": "meta-item-live",
1778
- "data-meta": "live",
1779
- className: makeClassName(classNames)
1780
- }, /*#__PURE__*/React.createElement("div", {
1781
- className: styles$d.frame
1782
- }));
1783
- };
1784
-
1785
- const pluralize = (number, one, two, five) => {
1786
- let n = Math.abs(number);
1787
- n %= 100;
1788
- if (n >= 5 && n <= 20) {
1789
- return five;
1790
- }
1791
- n %= 10;
1792
- if (n === 1) {
1793
- return one;
1794
- }
1795
- if (n >= 2 && n <= 4) {
1796
- return two;
1797
- }
1798
- return five;
1799
- };
1800
-
1801
- var styles$c = {"root":"DocumentItemsCount-module_root__u4M3y","items":"DocumentItemsCount-module_items__OE-hf"};
1802
-
1803
- const DocumentItemsCount = ({
1804
- type,
1805
- lang = 'ru',
1806
- items,
1807
- children
1808
- }) => {
1809
- const i18n = {
1810
- ru: {
1811
- card: {
1812
- one: 'карточка',
1813
- two: 'карточки',
1814
- five: 'карточек'
1815
- },
1816
- podcast: {
1817
- one: 'эпизод',
1818
- two: 'эпизода',
1819
- five: 'эпизодов'
1820
- }
1821
- },
1822
- en: {
1823
- card: {
1824
- one: 'card',
1825
- two: 'cards',
1826
- five: 'cards'
1827
- },
1828
- podcast: {
1829
- one: 'episode',
1830
- two: 'episodes',
1831
- five: 'episodes'
1832
- }
1833
- }
1834
- };
1835
- const itemsCount = `${items} ${pluralize(items, i18n[lang][type].one, i18n[lang][type].two, i18n[lang][type].five)}`;
1836
- return /*#__PURE__*/React.createElement("div", {
1837
- "data-testid": "document-items-count",
1838
- className: styles$c.root
1839
- }, children, /*#__PURE__*/React.createElement("span", {
1840
- className: styles$c.items
1841
- }, itemsCount));
1842
- };
1843
-
1844
- const MetaContainer = ({
1845
- lang,
1846
- block,
1847
- isRead,
1848
- isListened,
1849
- bookmarkAction,
1850
- isInBookmarks,
1851
- block: {
1852
- data: {
1853
- components,
1854
- theme
1855
- }
1856
- },
1857
- styleContext,
1858
- type
1859
- }) => {
1860
- const themeColor = styleContext && styleContext.indexOf('dark') !== -1 ? 'light' : 'unset';
1861
- const isPodcast = styleContext && styleContext.indexOf('podcast') !== -1;
1862
- const isSlides = styleContext && styleContext.indexOf('slide') !== -1;
1863
- let context = [];
1864
- if (styleContext && Array.isArray(styleContext)) {
1865
- context = styleContext.filter(item => {
1866
- return item !== 'dark';
1867
- });
1868
- }
1869
- const hasSource = !!components.find(item => item.type === 'source_name');
1870
- const classNames = [[styles$s.containerInDynamicBlock, styleContext === 'isInDynamicBlock'], [styles$s.containerInDynamicBlockAndMaterial, styleContext === 'isInDynamicBlock' && type === 'isInMaterial']];
1871
- return /*#__PURE__*/React.createElement("div", {
1872
- className: makeClassName(classNames)
1873
- }, /*#__PURE__*/React.createElement(Meta, {
1874
- styleContext: context,
1875
- theme: theme || themeColor,
1876
- onlyOn: block.only_on,
1877
- hasSource: hasSource
1878
- }, components.map(component => {
1879
- switch (component.type) {
1880
- case 'source_name':
1881
- {
1882
- return /*#__PURE__*/React.createElement(MetaItem, {
1883
- hasSource: hasSource,
1884
- bullets: true,
1885
- key: component.id
1886
- }, /*#__PURE__*/React.createElement(React.Fragment, null, lang === 'ru' ? 'Источник: ' : 'Source: ', component.url && ( /*#__PURE__*/React.createElement("a", {
1887
- href: component.url,
1888
- rel: "noopener noreferrer",
1889
- target: "_blank"
1890
- }, component.text)), !component.url && component.text));
1891
- }
1892
- case 'duration':
1893
- {
1894
- if (styleContext === 'isInDynamicBlock') {
1895
- return /*#__PURE__*/React.createElement(MetaItem, {
1896
- hasSource: hasSource,
1897
- bullets: true,
1898
- key: component.id
1899
- }, component.text);
1900
- }
1901
- return /*#__PURE__*/React.createElement(MetaItem, {
1902
- hasSource: hasSource,
1903
- bullets: true,
1904
- key: component.id
1905
- }, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(SvgSymbol, {
1906
- icon: "podcast",
1907
- size: "small"
1908
- }), component.text));
1909
- }
1910
- case 'datetime':
1911
- {
1912
- const format = component.format && toCamel(component.format) || 'date';
1913
- return /*#__PURE__*/React.createElement(MetaItem, {
1914
- hasSource: hasSource,
1915
- bullets: true,
1916
- key: component.id,
1917
- type: "datetime"
1918
- }, /*#__PURE__*/React.createElement(Timestamp, {
1919
- publishedAt: component.datetime,
1920
- type: styleContext === 'isInDynamicBlock' ? 'fromNow' : format || 'date',
1921
- locale: lang
1922
- }));
1923
- }
1924
- case 'items_count':
1925
- {
1926
- return /*#__PURE__*/React.createElement(MetaItem, {
1927
- hasSource: hasSource,
1928
- bullets: true,
1929
- key: component.id
1930
- }, /*#__PURE__*/React.createElement(DocumentItemsCount, {
1931
- items: component.count,
1932
- type: isPodcast ? 'podcast' : 'card',
1933
- lang: lang
1934
- }, /*#__PURE__*/React.createElement(SvgSymbol, {
1935
- icon: "card",
1936
- size: "unset"
1937
- })));
1938
- }
1939
- case 'broadcast_active':
1940
- {
1941
- return /*#__PURE__*/React.createElement(MetaItem, {
1942
- hasSource: hasSource,
1943
- bullets: true,
1944
- key: component.id
1945
- }, /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(MetaItemLive, null), " \u041F\u0440\u044F\u043C\u043E\u0439 \u044D\u0444\u0438\u0440"));
1946
- }
1947
- case 'broadcast':
1948
- {
1949
- return /*#__PURE__*/React.createElement(MetaItem, {
1950
- hasSource: hasSource,
1951
- bullets: true,
1952
- key: component.id
1953
- }, /*#__PURE__*/React.createElement(React.Fragment, null, component.with_icon && /*#__PURE__*/React.createElement(MetaItemLive, null), component.label));
1954
- }
1955
- case 'string':
1956
- {
1957
- return /*#__PURE__*/React.createElement(MetaItem, {
1958
- hasSource: hasSource,
1959
- bullets: true,
1960
- key: component.id
1961
- }, component.text);
1962
- }
1963
- default:
1964
- {
1965
- return null;
1966
- }
1967
- }
1968
- }), (isRead || isListened) && ( /*#__PURE__*/React.createElement(MetaItem, {
1969
- hasSource: hasSource,
1970
- bullets: true,
1971
- type: isListened ? 'listened' : 'read'
1972
- }, /*#__PURE__*/React.createElement(SvgSymbol, {
1973
- icon: isListened ? 'listened' : 'read',
1974
- size: "unset"
1975
- }))), isSlides && lang === 'ru' && ( /*#__PURE__*/React.createElement("div", {
1976
- className: styles$s.bookmark
1977
- }, /*#__PURE__*/React.createElement(BookmarkButton, {
1978
- isInBookmarks: isInBookmarks,
1979
- onClick: () => bookmarkAction('bookmark', 'top')
1980
- })))));
1981
- };
1982
-
1983
- var styles$b = {"root":"DonatesTeaser-module_root__XQCVy","main":"DonatesTeaser-module_main__eN9kd","title":"DonatesTeaser-module_title__9umo1","text":"DonatesTeaser-module_text__s6tyf","cta":"DonatesTeaser-module_cta__-50aB","center":"DonatesTeaser-module_center__gxLvW","isInCard":"DonatesTeaser-module_isInCard__vaUhd","isInSlide":"DonatesTeaser-module_isInSlide__Dh4NH","ru":"DonatesTeaser-module_ru__y-PlJ","en":"DonatesTeaser-module_en__0Iisr"};
1984
-
1985
- const DonatesTeaser = ({
1986
- styleContext,
1987
- lang = 'ru'
1988
- }) => {
1989
- let classNames = [[styles$b.root, true], [styles$b[lang], styles$b[lang]]];
1990
- if (styleContext) {
1991
- classNames = makeStyleContext(classNames, styleContext, styles$b);
1992
- }
1993
- const data = {
1994
- ru: {
1995
- title: '«Медуза». Работаем 24/7. И&nbsp;только&nbsp;в&nbsp;интересах читателей',
1996
- subtitle: 'Нам срочно нужна ваша поддержка',
1997
- button: 'Хочу помочь',
1998
- href: 'https://support.meduza.io/'
1999
- },
2000
- en: {
2001
- title: 'Meduza, working 24/7, always&nbsp;for our readers',
2002
- subtitle: 'We&nbsp;need&nbsp;your&nbsp;help like never&nbsp;before',
2003
- button: 'Okay!',
2004
- href: 'https://support.meduza.io/en'
2005
- }
2006
- };
2007
- return /*#__PURE__*/React.createElement("div", {
2008
- "data-testid": "donates-teaser",
2009
- className: makeClassName(classNames)
2010
- }, /*#__PURE__*/React.createElement("div", {
2011
- className: styles$b.main
2012
- }, /*#__PURE__*/React.createElement("h3", {
2013
- className: styles$b.title
2014
- }, /*#__PURE__*/React.createElement("span", {
2015
- dangerouslySetInnerHTML: {
2016
- __html: data[lang].title
2017
- }
2018
- }), ` `, /*#__PURE__*/React.createElement("span", {
2019
- className: styles$b.text,
2020
- dangerouslySetInnerHTML: {
2021
- __html: data[lang].subtitle
2022
- }
2023
- }))), /*#__PURE__*/React.createElement("div", {
2024
- className: styles$b.cta
2025
- }, /*#__PURE__*/React.createElement("a", {
2026
- href: data[lang].href,
2027
- target: "_blank",
2028
- rel: "noreferrer"
2029
- }, /*#__PURE__*/React.createElement("span", null, data[lang].button))));
2030
- };
2031
-
2032
- var styles$a = {"root":"AnnouncementInText-module_root__C4-Oo","body":"AnnouncementInText-module_body__lZy-L","title":"AnnouncementInText-module_title__cb6i1","footer":"AnnouncementInText-module_footer__jRk9p","button":"AnnouncementInText-module_button__JuT-E","link":"AnnouncementInText-module_link__C0YxL","center":"AnnouncementInText-module_center__1DJjd","isInCard":"AnnouncementInText-module_isInCard__jIqpa","isInSlide":"AnnouncementInText-module_isInSlide__BWO-A","ru":"AnnouncementInText-module_ru__QHQad","en":"AnnouncementInText-module_en__r0PvM"};
2033
-
2034
- const AnnouncementInText = ({
2035
- styleContext,
2036
- lang = 'ru'
2037
- }) => {
2038
- let classNames = [[styles$a.root, true], [styles$a[lang], styles$a[lang]]];
2039
- if (styleContext) {
2040
- classNames = makeStyleContext(classNames, styleContext, styles$a);
2041
- }
2042
- const data = {
2043
- ru: {
2044
- title: '&laquo;Медуза&raquo; заблокирована в&nbsp;России. Мы&nbsp;были к&nbsp;этому готовы&nbsp;&mdash; и&nbsp;продолжаем работать. Несмотря&nbsp;ни&nbsp;на&nbsp;что',
2045
- text: '<p>Нам нужна ваша помощь как никогда. Прямо сейчас. Дальше всем нам будет еще труднее. Мы&nbsp;независимое издание и&nbsp;работаем только в&nbsp;интересах читателей.</p>',
2046
- button: 'Хочу помочь',
2047
- href: 'https://mdza.io/yiNxPZ7Bs-k'
2048
- },
2049
- en: {
2050
- title: 'Meduza has been blocked in Russia. We&nbsp;were ready for this and our work continues, no matter what, but we need your support like never before. ',
2051
- text: '<p>We need it now. Tomorrow could be too late. We are an independent publication, and we work only in the interests of our readers. Many&nbsp;of&nbsp;our&nbsp;readers in Russia can no longer contribute, so we turn to you, our audience around the world.</p>',
2052
- button: 'I want to help',
2053
- href: 'https://support.meduza.io/en'
2054
- }
2055
- };
2056
- const localeData = data[lang];
2057
- return /*#__PURE__*/React.createElement("div", {
2058
- "data-testid": "announcement-in-text",
2059
- className: makeClassName(classNames)
2060
- }, /*#__PURE__*/React.createElement("div", {
2061
- className: styles$a.body
2062
- }, /*#__PURE__*/React.createElement("h3", {
2063
- className: styles$a.title,
2064
- dangerouslySetInnerHTML: {
2065
- __html: localeData.title
2066
- }
2067
- }), /*#__PURE__*/React.createElement("div", {
2068
- dangerouslySetInnerHTML: {
2069
- __html: localeData.text
2070
- }
2071
- })), /*#__PURE__*/React.createElement("div", {
2072
- className: styles$a.footer
2073
- }, /*#__PURE__*/React.createElement("a", {
2074
- className: styles$a.link,
2075
- href: localeData.href,
2076
- target: "_blank",
2077
- rel: "noreferrer"
2078
- }, /*#__PURE__*/React.createElement("span", null, localeData.button)), /*#__PURE__*/React.createElement("span", {
2079
- className: styles$a.button
2080
- }, /*#__PURE__*/React.createElement("span", null, localeData.button))));
2081
- };
2082
-
2083
- var styles$9 = {"root":"VersesBlock-module_root__CrgSZ","ol":"VersesBlock-module_ol__ToXjg","ul":"VersesBlock-module_ul__wfaQD","center":"VersesBlock-module_center__E1IS-","isInImportantLead":"VersesBlock-module_isInImportantLead__pdugk","dark":"VersesBlock-module_dark__FwaPS","mobile":"VersesBlock-module_mobile__EcHvz","desktop":"VersesBlock-module_desktop__quKfJ"};
2084
-
2085
- const VersesBlock = ({
2086
- block: {
2087
- type,
2088
- data,
2089
- only_on: onlyOn
2090
- },
2091
- styleContext
2092
- }) => {
2093
- let classNames = [[styles$9.root, true], [styles$9[onlyOn], true], [styles$9[type], !!type && !!styles$9[type]]];
2094
- if (styleContext) {
2095
- classNames = makeStyleContext(classNames, styleContext, styles$9);
2096
- }
2097
- return /*#__PURE__*/React.createElement("ul", {
2098
- className: makeClassName(classNames),
2099
- "data-testid": "verses-block"
2100
- }, data.map((item, index) => ( /*#__PURE__*/React.createElement("li", {
2101
- key: index,
2102
- dangerouslySetInnerHTML: {
2103
- __html: item
2104
- }
2105
- }))));
2106
- };
2107
-
2108
- const RenderBlocks = ({
2109
- block,
2110
- styleContext,
2111
- lang,
2112
- isRead,
2113
- isListened,
2114
- bookmarkAction,
2115
- isInBookmarks,
2116
- type = 'default'
2117
- }) => {
2118
- switch (block.type) {
2119
- case 'tag':
2120
- {
2121
- return /*#__PURE__*/React.createElement(Tag, {
2122
- size: "large",
2123
- onlyOn: block.only_on,
2124
- theme: block.data.theme,
2125
- styleContext: styleContext
2126
- }, block.data.text);
2127
- }
2128
- case 'simple_title':
2129
- {
2130
- return /*#__PURE__*/React.createElement(SimpleTitle, {
2131
- block: block,
2132
- styleContext: styleContext
2133
- });
2134
- }
2135
- case 'rich_title':
2136
- {
2137
- return /*#__PURE__*/React.createElement(RichTitle, {
2138
- block: block,
2139
- styleContext: styleContext
2140
- });
2141
- }
2142
- case 'meta':
2143
- {
2144
- return /*#__PURE__*/React.createElement(MetaContainer, {
2145
- block: block,
2146
- lang: block.data.lang,
2147
- styleContext: styleContext,
2148
- isRead: isRead,
2149
- isListened: isListened,
2150
- isInBookmarks: isInBookmarks,
2151
- bookmarkAction: bookmarkAction,
2152
- type: type
2153
- });
2154
- }
2155
- case 'blockquote':
2156
- case 'p':
2157
- case 'context_p':
2158
- case 'divider':
2159
- case 'lead':
2160
- case 'lead_hr':
2161
- {
2162
- return /*#__PURE__*/React.createElement(SimpleBlock, {
2163
- block: block,
2164
- styleContext: styleContext
2165
- });
2166
- }
2167
- case 'h1':
2168
- case 'h2':
2169
- case 'h3':
2170
- case 'h4':
2171
- {
2172
- return /*#__PURE__*/React.createElement(SimpleBlock, {
2173
- block: block,
2174
- styleContext: styleContext,
2175
- id: block.id
2176
- });
2177
- }
2178
- case 'quote':
2179
- return /*#__PURE__*/React.createElement(QuoteBlock, {
2180
- block: block,
2181
- styleContext: styleContext
2182
- });
2183
- case 'ol':
2184
- case 'ul':
2185
- {
2186
- return /*#__PURE__*/React.createElement(ListBlock, {
2187
- block: block,
2188
- styleContext: styleContext
2189
- });
2190
- }
2191
- case 'verses':
2192
- {
2193
- return /*#__PURE__*/React.createElement(VersesBlock, {
2194
- block: block,
2195
- styleContext: styleContext
2196
- });
2197
- }
2198
- case 'chapter-subtitle':
2199
- {
2200
- return /*#__PURE__*/React.createElement(ChapterBlock, {
2201
- block: block,
2202
- styleContext: styleContext,
2203
- id: block.id
2204
- });
2205
- }
2206
- case 'card_title':
2207
- {
2208
- return /*#__PURE__*/React.createElement(CardTitle, {
2209
- block: block,
2210
- styleContext: styleContext
2211
- });
2212
- }
2213
- case 'related':
2214
- {
2215
- return /*#__PURE__*/React.createElement(RelatedBlock, {
2216
- block: block,
2217
- styleContext: styleContext
2218
- });
2219
- }
2220
- case 'source':
2221
- return /*#__PURE__*/React.createElement(SourceBlock, {
2222
- block: block,
2223
- styleContext: styleContext
2224
- });
2225
- case 'table':
2226
- return /*#__PURE__*/React.createElement(Table, {
2227
- block: block,
2228
- styleContext: styleContext
2229
- });
2230
- case 'sensitive':
2231
- return /*#__PURE__*/React.createElement(SensitiveBlock, {
2232
- block: block,
2233
- styleContext: styleContext
2234
- });
2235
- case 'embed':
2236
- case 'embed_code':
2237
- case 'game_embed':
2238
- case 'image':
2239
- case 'dots_on_image':
2240
- case 'gif':
2241
- return /*#__PURE__*/React.createElement(EmbedBlockContainer, {
2242
- block: block,
2243
- styleContext: styleContext,
2244
- lang: lang
2245
- });
2246
- case 'grouped':
2247
- return /*#__PURE__*/React.createElement(GroupedBlock, {
2248
- block: block,
2249
- styleContext: styleContext
2250
- });
2251
- case 'donation':
2252
- return /*#__PURE__*/React.createElement(DonatesTeaser, {
2253
- styleContext: styleContext,
2254
- lang: lang
2255
- });
2256
- case 'material_note':
2257
- return /*#__PURE__*/React.createElement(MaterialNote, {
2258
- block: block,
2259
- styleContext: styleContext
2260
- });
2261
- case 'announcement_in_text':
2262
- return /*#__PURE__*/React.createElement(AnnouncementInText, {
2263
- styleContext: styleContext,
2264
- lang: lang
2265
- });
2266
- default:
2267
- {
2268
- return null;
2269
- }
2270
- }
2271
- };
2272
-
2273
- var styles$8 = {"root":"Cover-module_root__3pscq","body":"Cover-module_body__eJpUI","image":"Cover-module_image__frrrH","rich":"Cover-module_rich__YcxWa","dark":"Cover-module_dark__cRucL","light":"Cover-module_light__la-sk","control":"Cover-module_control__WP0G3","isInDynamicBlock":"Cover-module_isInDynamicBlock__qO-yt","mobile":"Cover-module_mobile__aotep","desktop":"Cover-module_desktop__dfbC-"};
2274
-
2275
- const Cover = ({
2276
- block: {
2277
- only_on: onlyOn,
2278
- data: {
2279
- blocks,
2280
- cover: {
2281
- credit,
2282
- caption,
2283
- urls,
2284
- mobile_ratio: mobileRatio,
2285
- gradients,
2286
- cc
2287
- }
2288
- }
2289
- },
2290
- styleContext
2291
- }) => {
2292
- const [isPopoverShown, setIsPopoverShown] = React.useState(false);
2293
- const style = {};
2294
- let classNames = [[styles$8.root, true], [styles$8[onlyOn], !!onlyOn && !!styles$8[onlyOn]]];
2295
- if (styleContext) {
2296
- classNames = makeStyleContext(classNames, styleContext, styles$8);
2297
- }
2298
- if (gradients) {
2299
- const theme = [gradients.text_rgb === '0,0,0' ? 'dark' : 'light'];
2300
- classNames = makeStyleContext(classNames, theme, styles$8);
2301
- style.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockBottom');
2302
- }
2303
- const renderCC = context => ( /*#__PURE__*/React.createElement(MediaCaption, {
2304
- credit: credit,
2305
- caption: caption,
2306
- styleContext: context || styleContext
2307
- }));
2308
- return /*#__PURE__*/React.createElement("div", {
2309
- "data-testid": "cover",
2310
- className: makeClassName(classNames)
2311
- }, /*#__PURE__*/React.createElement("div", {
2312
- className: styles$8.image
2313
- }, /*#__PURE__*/React.createElement(Image, {
2314
- optimized: urls,
2315
- ratio: mobileRatio,
2316
- display: "narrow"
2317
- })), /*#__PURE__*/React.createElement("div", {
2318
- className: styles$8.body,
2319
- style: style
2320
- }, blocks.map(item => ( /*#__PURE__*/React.createElement(RenderBlocks, {
2321
- key: item.id,
2322
- block: item,
2323
- styleContext: styleContext
2324
- })))), cc === 'button' && ( /*#__PURE__*/React.createElement("button", {
2325
- className: styles$8.control,
2326
- type: "button",
2327
- "aria-label": "Open",
2328
- onClick: () => {
2329
- setIsPopoverShown(!isPopoverShown);
2330
- }
2331
- })), cc === 'button' && isPopoverShown && ( /*#__PURE__*/React.createElement(Popover, {
2332
- onClose: () => {
2333
- setIsPopoverShown(false);
2334
- }
2335
- }, renderCC('isInPopover'))));
2336
- };
2337
-
2338
- var styles$7 = {"root":"HalfBlock-module_root__EXQbz","main":"HalfBlock-module_main__eIcRo","body":"HalfBlock-module_body__HPhGj","footer":"HalfBlock-module_footer__TFfCQ","image":"HalfBlock-module_image__XWLbK","mobile":"HalfBlock-module_mobile__uGGpm","desktop":"HalfBlock-module_desktop__p-hAq"};
2339
-
2340
- const HalfBlock = ({
2341
- block: {
2342
- only_on: onlyOn,
2343
- data,
2344
- data: {
2345
- cover: {
2346
- optimized,
2347
- ratio,
2348
- credit,
2349
- caption
2350
- }
2351
- }
2352
- },
2353
- styleContext
2354
- }) => {
2355
- let classNames = [[styles$7.root, true], [styles$7[onlyOn], true]];
2356
- if (styleContext) {
2357
- classNames = makeStyleContext(classNames, styleContext, styles$7);
2358
- }
2359
- return /*#__PURE__*/React.createElement("div", {
2360
- "data-testid": "half-block",
2361
- className: makeClassName(classNames)
2362
- }, /*#__PURE__*/React.createElement("div", {
2363
- className: styles$7.main
2364
- }, /*#__PURE__*/React.createElement("div", {
2365
- className: styles$7.image
2366
- }, /*#__PURE__*/React.createElement(Image, {
2367
- optimized: optimized,
2368
- ratio: ratio,
2369
- display: "super_full"
2370
- })), /*#__PURE__*/React.createElement("div", {
2371
- className: styles$7.body
2372
- }, data.blocks.map(item => ( /*#__PURE__*/React.createElement(RenderBlocks, {
2373
- key: item.id,
2374
- block: item,
2375
- styleContext: ['rich']
2376
- }))))), /*#__PURE__*/React.createElement("div", {
2377
- className: styles$7.footer
2378
- }, /*#__PURE__*/React.createElement(MediaCaption, {
2379
- credit: credit,
2380
- caption: caption,
2381
- styleContext: styleContext
2382
- })));
2383
- };
2384
-
2385
- var styles$6 = {"root":"ImportantLead-module_root__-rnt6","slide":"ImportantLead-module_slide__zcovu","mobile":"ImportantLead-module_mobile__msInp","desktop":"ImportantLead-module_desktop__ELC2-"};
2386
-
2387
- const ImportantLead = ({
2388
- block: {
2389
- only_on: onlyOn,
2390
- data
2391
- },
2392
- styleContext
2393
- }) => {
2394
- let classNames = [[styles$6.root, true], [styles$6[onlyOn], !!onlyOn]];
2395
- if (styleContext) {
2396
- classNames = makeStyleContext(classNames, styleContext, styles$6);
2397
- }
2398
- return /*#__PURE__*/React.createElement("div", {
2399
- "data-testid": "important-lead",
2400
- className: makeClassName(classNames)
2401
- }, data.map(item => ( /*#__PURE__*/React.createElement(RenderBlocks, {
2402
- key: item.id,
2403
- block: item,
2404
- styleContext: "isInImportantLead"
2405
- }))));
2406
- };
2407
-
2408
- var styles$5 = {"root":"Spoiler-module_root__fAbb9","header":"Spoiler-module_header__iEKsQ","body":"Spoiler-module_body__jjqIn","spoiled":"Spoiler-module_spoiled__ENI93","footer":"Spoiler-module_footer__g21Zn","spoilerSticky":"Spoiler-module_spoilerSticky__YTiyF","spoilerStickyBg":"Spoiler-module_spoilerStickyBg__tmDnG","center":"Spoiler-module_center__0XCWo","full":"Spoiler-module_full__FtKDT","default":"Spoiler-module_default__wvlKw","mobile":"Spoiler-module_mobile__PWCMW","desktop":"Spoiler-module_desktop__qTakd"};
2409
-
2410
- const Spoiler = ({
2411
- block: {
2412
- display,
2413
- button,
2414
- only_on: onlyOn,
2415
- btn_title: buttonTitle,
2416
- title,
2417
- blocks
2418
- },
2419
- styleContext
2420
- }) => {
2421
- const [spoiled, setSpoiled] = React.useState(false);
2422
- const ref = React.useRef(null);
2423
- const handleButtonClick = () => {
2424
- setSpoiled(!spoiled);
2425
- if (spoiled) {
2426
- postMessage('', 'closeSpoiler', 'click');
2427
- const rect = ref.current.getBoundingClientRect();
2428
- if (rect.top < 0) {
2429
- ref.current.scrollIntoView({
2430
- behavior: 'smooth'
2431
- });
2432
- }
2433
- } else {
2434
- postMessage('', 'openSpoiler', 'click');
2435
- }
2436
- };
2437
- let classNames = [[styles$5.root, true], [styles$5[onlyOn], !!onlyOn], [styles$5[display], !!display && styles$5[display]], [[styles$5.spoiled], !!spoiled]];
2438
- const context = ['center'];
2439
- if (styleContext) {
2440
- context.concat(styleContext);
2441
- classNames = makeStyleContext(classNames, styleContext, styles$5);
2442
- }
2443
- const buttonCollapse = button ? button.collapse : 'Свернуть';
2444
- const buttonExpande = button ? button.expand : buttonTitle;
2445
- return /*#__PURE__*/React.createElement("div", {
2446
- ref: ref,
2447
- className: makeClassName(classNames),
2448
- "data-testid": "spoiler"
2449
- }, /*#__PURE__*/React.createElement("div", {
2450
- className: styles$5.header
2451
- }, title && /*#__PURE__*/React.createElement("h3", null, title)), /*#__PURE__*/React.createElement("div", {
2452
- className: styles$5.body
2453
- }, blocks.map(item => ( /*#__PURE__*/React.createElement(RenderBlocks, {
2454
- key: item.id,
2455
- block: item,
2456
- styleContext: context
2457
- })))), /*#__PURE__*/React.createElement("div", {
2458
- className: styles$5.footer
2459
- }, /*#__PURE__*/React.createElement(Button, {
2460
- size: "default",
2461
- theme: "gray",
2462
- onClick: () => handleButtonClick(),
2463
- styleContext: "isInSpoiler"
2464
- }, spoiled ? buttonCollapse : buttonExpande, /*#__PURE__*/React.createElement(SvgSymbol, {
2465
- icon: "arrow"
2466
- }))));
2467
- };
2468
-
2469
- var styles$4 = {"root":"RelatedRichBlock-module_root__-SEe7","wrapper":"RelatedRichBlock-module_wrapper__YkEpr","overlay":"RelatedRichBlock-module_overlay__tWuyR","overlayHeader":"RelatedRichBlock-module_overlayHeader__V3ynX","body":"RelatedRichBlock-module_body__XhS0U","isRich":"RelatedRichBlock-module_isRich__Z2kQ8","hasGradient":"RelatedRichBlock-module_hasGradient__s5Krh","picture":"RelatedRichBlock-module_picture__OmRKx","isCard":"RelatedRichBlock-module_isCard__wkMw-","cover":"RelatedRichBlock-module_cover__3gnIx","tag":"RelatedRichBlock-module_tag__c18sv","center":"RelatedRichBlock-module_center__KANd-","dark":"RelatedRichBlock-module_dark__cnk4R","light":"RelatedRichBlock-module_light__aJLn7","mobile":"RelatedRichBlock-module_mobile__N-G4U","desktop":"RelatedRichBlock-module_desktop__EaPOr"};
2470
-
2471
- /* eslint-disable react/jsx-no-target-blank */
2472
- const RelatedRichBlock = ({
2473
- block: {
2474
- only_on: onlyOn,
2475
- data: {
2476
- blocks,
2477
- url,
2478
- cover: {
2479
- urls,
2480
- gradients,
2481
- tag,
2482
- layout,
2483
- ratio
2484
- }
2485
- }
2486
- },
2487
- styleContext
2488
- }) => {
2489
- const style = {};
2490
- const styleHeader = {};
2491
- const cardType = `is${toCapitalize(layout)}`;
2492
- const [ref, inView] = reactIntersectionObserver.useInView({
2493
- threshold: 0,
2494
- triggerOnce: true
2495
- });
2496
- React.useEffect(() => {
2497
- if (inView) {
2498
- if (onlyOn === 'mobile' && window.innerWidth <= 511 || onlyOn === 'desktop' && window.innerWidth >= 512 || !onlyOn) {
2499
- postMessage('richRelated', url, 'view');
2500
- }
2501
- }
2502
- }, [inView]);
2503
- const handleClick = () => {
2504
- postMessage('richRelated', url, 'click');
2505
- };
2506
- let classNames = [[styles$4.root, true], [styles$4[cardType], !!layout && !!styles$4[cardType]], [styles$4.hasGradient, !!gradients], [styles$4[onlyOn], !!onlyOn && !!styles$4[onlyOn]]];
2507
- let context = ['isInMediaBlock'];
2508
- if (styleContext) {
2509
- classNames = makeStyleContext(classNames, styleContext, styles$4);
2510
- context = [...styleContext, 'isInMediaBlock'];
2511
- }
2512
- if (gradients) {
2513
- styleHeader.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockTop');
2514
- const theme = [gradients.text_rgb === '0,0,0' ? 'dark' : 'light'];
2515
- classNames = makeStyleContext(classNames, theme, styles$4);
2516
- if (onlyOn === 'desktop') {
2517
- style.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockBottom');
2518
- }
2519
- }
2520
- return /*#__PURE__*/React.createElement(reactRouterDom.Link, {
2521
- "data-testid": "related-rich-block",
2522
- className: makeClassName(classNames),
2523
- to: `/${url}`,
2524
- onClick: () => handleClick(),
2525
- ref: ref
2526
- }, layout === 'rich' && ( /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
2527
- className: styles$4.overlay,
2528
- style: style
2529
- }), /*#__PURE__*/React.createElement("div", {
2530
- className: styles$4.overlayHeader,
2531
- style: styleHeader
2532
- }))), /*#__PURE__*/React.createElement("div", {
2533
- className: styles$4.tag
2534
- }, /*#__PURE__*/React.createElement(Tag, {
2535
- size: "small",
2536
- theme: "inherit",
2537
- styleContext: "richRelated"
2538
- }, tag)), /*#__PURE__*/React.createElement("div", {
2539
- className: styles$4.cover
2540
- }, /*#__PURE__*/React.createElement("div", {
2541
- className: styles$4.picture
2542
- }, /*#__PURE__*/React.createElement(Image, {
2543
- optimized: urls,
2544
- ratio: ratio,
2545
- display: "narrow"
2546
- }))), /*#__PURE__*/React.createElement("div", {
2547
- className: styles$4.body
2548
- }, blocks.map(item => ( /*#__PURE__*/React.createElement(RenderBlocks, {
2549
- key: item.id,
2550
- block: item,
2551
- styleContext: context
2552
- })))));
2553
- };
2554
-
2555
- var styles$3 = {"root":"ShopRelatedBlock-module_root__eTGjC","wrapper":"ShopRelatedBlock-module_wrapper__v6yE3","overlay":"ShopRelatedBlock-module_overlay__oR67Y","overlayHeader":"ShopRelatedBlock-module_overlayHeader__YMcNw","body":"ShopRelatedBlock-module_body__W4pBN","hasGradient":"ShopRelatedBlock-module_hasGradient__50JTl","picture":"ShopRelatedBlock-module_picture__zjFL4","tag":"ShopRelatedBlock-module_tag__ixkda","center":"ShopRelatedBlock-module_center__IpBP4","title":"ShopRelatedBlock-module_title__COl93","price":"ShopRelatedBlock-module_price__5Qitu","dark":"ShopRelatedBlock-module_dark__d0QiW","light":"ShopRelatedBlock-module_light__lUDWA","mobile":"ShopRelatedBlock-module_mobile__I6Hih","desktop":"ShopRelatedBlock-module_desktop__ywKrb"};
2556
-
2557
- /* eslint-disable react/jsx-no-target-blank */
2558
- const ShopRelatedBlock = ({
2559
- block: {
2560
- only_on: onlyOn,
2561
- data: {
2562
- url,
2563
- cover: {
2564
- urls,
2565
- gradients,
2566
- tag,
2567
- layout,
2568
- ratio,
2569
- first_title: firstTitle,
2570
- second_title: secondTitle
2571
- }
2572
- }
2573
- },
2574
- styleContext
2575
- }) => {
2576
- const style = {};
2577
- const styleHeader = {};
2578
- const [ref, inView] = reactIntersectionObserver.useInView({
2579
- threshold: 0,
2580
- triggerOnce: true
2581
- });
2582
- React.useEffect(() => {
2583
- if (inView) {
2584
- if (onlyOn === 'mobile' && window.innerWidth <= 511 || onlyOn === 'desktop' && window.innerWidth >= 512 || !onlyOn) {
2585
- postMessage('productRelated', url, 'view');
2586
- }
2587
- }
2588
- }, [inView]);
2589
- const handleClick = () => {
2590
- postMessage('productRelated', url, 'click');
2591
- };
2592
- let classNames = [[styles$3.root, true], [styles$3.hasGradient, !!gradients], [styles$3[onlyOn], !!onlyOn && !!styles$3[onlyOn]]];
2593
- if (styleContext) {
2594
- classNames = makeStyleContext(classNames, styleContext, styles$3);
2595
- }
2596
- if (gradients) {
2597
- styleHeader.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockTop');
2598
- const theme = [gradients.text_rgb === '0,0,0' ? 'dark' : 'light'];
2599
- classNames = makeStyleContext(classNames, theme, styles$3);
2600
- if (onlyOn === 'desktop') {
2601
- style.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockBottom');
2602
- }
2603
- }
2604
- return /*#__PURE__*/React.createElement("a", {
2605
- "data-testid": "related-rich-block",
2606
- className: makeClassName(classNames),
2607
- href: url,
2608
- target: "_blank",
2609
- onClick: () => handleClick(),
2610
- ref: ref
2611
- }, layout === 'rich' && ( /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
2612
- className: styles$3.overlay,
2613
- style: style
2614
- }), /*#__PURE__*/React.createElement("div", {
2615
- className: styles$3.overlayHeader,
2616
- style: styleHeader
2617
- }))), /*#__PURE__*/React.createElement("div", {
2618
- className: styles$3.tag
2619
- }, /*#__PURE__*/React.createElement(Tag, {
2620
- size: "small",
2621
- theme: "inherit",
2622
- styleContext: "richRelated"
2623
- }, tag)), /*#__PURE__*/React.createElement("div", {
2624
- className: styles$3.cover
2625
- }, /*#__PURE__*/React.createElement("div", {
2626
- className: styles$3.picture
2627
- }, /*#__PURE__*/React.createElement(Image, {
2628
- optimized: urls,
2629
- ratio: ratio,
2630
- display: "narrow"
2631
- }))), /*#__PURE__*/React.createElement("div", {
2632
- className: styles$3.body
2633
- }, /*#__PURE__*/React.createElement("h2", {
2634
- className: styles$3.title
2635
- }, firstTitle, /*#__PURE__*/React.createElement("span", {
2636
- className: styles$3.price
2637
- }, secondTitle))));
2638
- };
2639
-
2640
- var styles$2 = {"root":"RelatedBook-module_root__QsOmA","container":"RelatedBook-module_container__vdDiZ","imageWrap":"RelatedBook-module_imageWrap__WmwnE","image":"RelatedBook-module_image__U1e5t","picture":"RelatedBook-module_picture__NXg-K","tag":"RelatedBook-module_tag__mSbbz","contentWrap":"RelatedBook-module_contentWrap__HIGRi","content":"RelatedBook-module_content__23Pfr","title":"RelatedBook-module_title__VRbr-","footer":"RelatedBook-module_footer__Z05t-","center":"RelatedBook-module_center__Fa6cj","isLight":"RelatedBook-module_isLight__W-0TO","isDark":"RelatedBook-module_isDark__0mrtK"};
2641
-
2642
- const RelatedBook = ({
2643
- block,
2644
- styleContext
2645
- }) => {
2646
- const theme = block.data.theme.text_color === '0,0,0' ? 'isDark' : 'isLight';
2647
- let classNames = [[styles$2.root, true], [styles$2[theme], theme], [styles$2[block.data.onlyOn], !!block.data.onlyOn && !!styles$2[block.data.onlyOn]]];
2648
- if (styleContext) {
2649
- classNames = makeStyleContext(classNames, styleContext, styles$2);
2650
- }
2651
- const cssProps = {
2652
- '--bgColor': `rgb(${block.data.theme.background_color || '0, 0, 0'})`
2653
- };
2654
- return /*#__PURE__*/React.createElement(reactRouterDom.Link, {
2655
- to: `/${block.data.url}`,
2656
- className: makeClassName(classNames),
2657
- style: cssProps
2658
- }, /*#__PURE__*/React.createElement("div", {
2659
- className: styles$2.container
2660
- }, /*#__PURE__*/React.createElement("div", {
2661
- className: styles$2.imageWrap
2662
- }, /*#__PURE__*/React.createElement("div", {
2663
- className: styles$2.image
2664
- }, /*#__PURE__*/React.createElement("picture", {
2665
- className: styles$2.picture
2666
- }, /*#__PURE__*/React.createElement(Image, {
2667
- optimized: block.data.cover.urls,
2668
- ratio: 0,
2669
- display: "narrow",
2670
- styleContext: ['isStatic'],
2671
- lazy: true
2672
- })))), /*#__PURE__*/React.createElement("div", {
2673
- className: styles$2.contentWrap
2674
- }, /*#__PURE__*/React.createElement("div", {
2675
- className: styles$2.content
2676
- }, block.data.blocks.map(item => ( /*#__PURE__*/React.createElement(RenderBlocks, {
2677
- key: item.id,
2678
- block: item,
2679
- styleContext: ['isInMediaBlock', 'isInBookRelated', 'isCustom']
2680
- })))))));
2681
- };
2682
-
2683
- const RawHtmlBlock = ({
2684
- block,
2685
- styleContext,
2686
- isRead,
2687
- isListened,
2688
- isInBookmarks,
2689
- bookmarkAction,
2690
- lightBox,
2691
- lang,
2692
- type = 'default'
2693
- }) => {
2694
- const context = {
2695
- lightBox: lightBox || null
2696
- };
2697
- switch (block.type) {
2698
- case 'important_lead':
2699
- {
2700
- return /*#__PURE__*/React.createElement(ImportantLead, {
2701
- block: block,
2702
- styleContext: styleContext
2703
- });
2704
- }
2705
- case 'spoiler':
2706
- {
2707
- return /*#__PURE__*/React.createElement(BlockProvider, {
2708
- value: context
2709
- }, /*#__PURE__*/React.createElement(Spoiler, {
2710
- block: block,
2711
- styleContext: styleContext
2712
- }));
2713
- }
2714
- case 'cover':
2715
- {
2716
- return /*#__PURE__*/React.createElement(Cover, {
2717
- block: block,
2718
- styleContext: styleContext
2719
- });
2720
- }
2721
- case 'half':
2722
- {
2723
- return /*#__PURE__*/React.createElement(HalfBlock, {
2724
- block: block,
2725
- styleContext: styleContext
2726
- });
2727
- }
2728
- case 'related_rich':
2729
- {
2730
- return /*#__PURE__*/React.createElement(RelatedRichBlock, {
2731
- block: block,
2732
- styleContext: styleContext
2733
- });
2734
- }
2735
- case 'related_book':
2736
- {
2737
- return /*#__PURE__*/React.createElement(RelatedBook, {
2738
- block: block,
2739
- styleContext: styleContext
2740
- });
2741
- }
2742
- case 'related_shop':
2743
- {
2744
- return /*#__PURE__*/React.createElement(ShopRelatedBlock, {
2745
- block: block,
2746
- styleContext: styleContext
2747
- });
2748
- }
2749
- default:
2750
- {
2751
- return /*#__PURE__*/React.createElement(BlockProvider, {
2752
- value: context
2753
- }, /*#__PURE__*/React.createElement(RenderBlocks, {
2754
- block: block,
2755
- styleContext: styleContext,
2756
- isRead: isRead,
2757
- isListened: isListened,
2758
- isInBookmarks: isInBookmarks,
2759
- bookmarkAction: bookmarkAction,
2760
- lang: lang,
2761
- type: type
2762
- }));
2763
- }
2764
- }
2765
- };
2766
-
2767
- var styles$1 = {"root":"ToolbarButton-module_root__upsEH","isDark":"ToolbarButton-module_isDark__gWpv-","dark":"ToolbarButton-module_dark__5XOEp","bookmark":"ToolbarButton-module_bookmark__7SWkm","isActive":"ToolbarButton-module_isActive__N4kkV","icon":"ToolbarButton-module_icon__Ldcgq","text":"ToolbarButton-module_text__4R2a0"};
2768
-
2769
- const ToolbarButton = ({
2770
- type,
2771
- theme,
2772
- isActive,
2773
- lang = 'ru',
2774
- text,
2775
- icon,
2776
- onClick
2777
- }) => {
2778
- const classNames = [[styles$1.root, true], [styles$1[type], !!styles$1[type]], [styles$1[theme], !!styles$1[theme] && !!theme], [styles$1.isActive, !!isActive]];
2779
- const label = SocialLabels[lang][type];
2780
- return /*#__PURE__*/React.createElement("button", {
2781
- "data-testid": "toolbar-button",
2782
- className: makeClassName(classNames),
2783
- type: "button",
2784
- onClick: event => onClick(event, type)
2785
- }, icon && ( /*#__PURE__*/React.createElement("div", {
2786
- className: styles$1.icon
2787
- }, /*#__PURE__*/React.createElement(SvgSymbol, {
2788
- size: "medium",
2789
- icon: icon,
2790
- styleContext: "isInToolbar"
2791
- }))), /*#__PURE__*/React.createElement("span", {
2792
- className: styles$1.text
2793
- }, text || label));
2794
- };
2795
-
2796
- var styles = {"root":"Tooltip-module_root__xK21R","isCenterBottom":"Tooltip-module_isCenterBottom__-qv7D","isLeftBottom":"Tooltip-module_isLeftBottom__0-f5z","isCenterTop":"Tooltip-module_isCenterTop__xQ3Ql","isLeftTop":"Tooltip-module_isLeftTop__yjKrV","body":"Tooltip-module_body__5qgzu","footer":"Tooltip-module_footer__swU9S"};
2797
-
2798
- const capitalizeFirstLetter = string => string.charAt(0).toUpperCase() + string.slice(1);
2799
-
2800
- const Tooltip = ({
2801
- children,
2802
- position
2803
- }) => {
2804
- const [x, y] = position;
2805
- const positionClass = `is${capitalizeFirstLetter(x)}${capitalizeFirstLetter(y)}`;
2806
- return /*#__PURE__*/React.createElement("div", {
2807
- className: makeClassName([[styles.root, true], [styles[positionClass], true]])
2808
- }, /*#__PURE__*/React.createElement("div", {
2809
- className: styles.body
2810
- }, children));
2811
- };
2812
-
2813
- const TooltipFooter = ({
2814
- children
2815
- }) => {
2816
- return /*#__PURE__*/React.createElement("div", {
2817
- className: styles.footer
2818
- }, children);
2819
- };
2820
-
2821
- exports.AnnouncementInText = AnnouncementInText;
2822
- exports.BookmarkButton = BookmarkButton;
2823
- exports.Button = Button;
2824
- exports.ButtonLoader = ButtonLoader;
2825
- exports.CardTitle = CardTitle;
2826
- exports.ChapterBlock = ChapterBlock;
2827
- exports.Cover = Cover;
2828
- exports.DocumentItemsCount = DocumentItemsCount;
2829
- exports.DonatesTeaser = DonatesTeaser;
2830
- exports.DotsOnImage = DotsOnImage;
2831
- exports.Dropdown = Dropdown;
2832
- exports.EmbedBlockContainer = EmbedBlockContainer;
2833
- exports.Footnote = Footnote;
2834
- exports.GroupedBlock = GroupedBlock;
2835
- exports.HalfBlock = HalfBlock;
2836
- exports.Image = Image;
2837
- exports.ImportantLead = ImportantLead;
2838
- exports.Lazy = Lazy;
2839
- exports.ListBlock = ListBlock;
2840
- exports.MaterialNote = MaterialNote;
2841
- exports.MaterialTitle = MaterialTitle;
2842
- exports.MediaCaption = MediaCaption;
2843
- exports.Menu = Menu;
2844
- exports.Meta = Meta;
2845
- exports.MetaItem = MetaItem;
2846
- exports.MetaItemLive = MetaItemLive;
2847
- exports.Popover = Popover;
2848
- exports.Primary = Primary;
2849
- exports.QuoteBlock = QuoteBlock;
2850
- exports.RawHtmlBlock = RawHtmlBlock;
2851
- exports.RelatedBlock = RelatedBlock;
2852
- exports.RelatedRichBlock = RelatedRichBlock;
2853
- exports.RenderBlocks = RenderBlocks;
2854
- exports.RichTitle = RichTitle;
2855
- exports.Secondary = Secondary;
2856
- exports.SensitiveBlock = SensitiveBlock;
2857
- exports.ShopRelatedBlock = ShopRelatedBlock;
2858
- exports.SimpleBlock = SimpleBlock;
2859
- exports.SimpleTitle = SimpleTitle;
2860
- exports.SourceBlock = SourceBlock;
2861
- exports.Spoiler = Spoiler;
2862
- exports.SvgSymbol = SvgSymbol;
2863
- exports.Switcher = Switcher;
2864
- exports.Table = Table;
2865
- exports.Tag = Tag;
2866
- exports.Timestamp = Timestamp;
2867
- exports.Toolbar = Toolbar;
2868
- exports.ToolbarButton = ToolbarButton;
2869
- exports.ToolbarItem = ToolbarItem;
2870
- exports.Tooltip = Tooltip;
2871
- exports.TooltipFooter = TooltipFooter;
2872
- //# sourceMappingURL=ui-kit-2.cjs.development.js.map