@meduza/ui-kit-2 0.1.53 → 0.1.54
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ui-kit-2.cjs.development.js +124 -131
- package/dist/ui-kit-2.cjs.development.js.map +1 -1
- package/dist/ui-kit-2.cjs.production.min.js +1 -1
- package/dist/ui-kit-2.cjs.production.min.js.map +1 -1
- package/dist/ui-kit-2.esm.js +125 -132
- package/dist/ui-kit-2.esm.js.map +1 -1
- package/dist/ui-kit.css +846 -846
- package/package.json +1 -1
- package/src/Toolbar/index.tsx +2 -9
- package/src/ToolbarButton/index.tsx +12 -9
|
@@ -1005,35 +1005,26 @@ var Dropdown = function Dropdown(_ref2) {
|
|
|
1005
1005
|
}, children);
|
|
1006
1006
|
};
|
|
1007
1007
|
|
|
1008
|
-
var
|
|
1008
|
+
var toolbarStyles = {"root":"Toolbar-module_root__2HF2r","list":"Toolbar-module_list__1n5ny","item":"Toolbar-module_item__36x7d","isInTopbar":"Toolbar-module_isInTopbar__223iP","center":"Toolbar-module_center__3_H8M","game":"Toolbar-module_game__5-jY_","gameSurvey":"Toolbar-module_gameSurvey__1hQEz","dark":"Toolbar-module_dark__2Ejc9"};
|
|
1009
1009
|
|
|
1010
1010
|
var Toolbar = function Toolbar(_ref) {
|
|
1011
1011
|
var children = _ref.children,
|
|
1012
1012
|
styleContext = _ref.styleContext;
|
|
1013
|
-
var classNames = [[
|
|
1013
|
+
var classNames = [[toolbarStyles.root, true]];
|
|
1014
1014
|
|
|
1015
1015
|
if (styleContext) {
|
|
1016
|
-
classNames = makeStyleContext(classNames, styleContext,
|
|
1016
|
+
classNames = makeStyleContext(classNames, styleContext, toolbarStyles);
|
|
1017
1017
|
}
|
|
1018
1018
|
|
|
1019
|
-
var renderItems = function renderItems() {
|
|
1020
|
-
return React.Children.map(children, function (item, index) {
|
|
1021
|
-
return React__default.createElement("li", {
|
|
1022
|
-
className: styles$f.item,
|
|
1023
|
-
key: index + "-" + item.props.type
|
|
1024
|
-
}, React__default.cloneElement(item));
|
|
1025
|
-
});
|
|
1026
|
-
};
|
|
1027
|
-
|
|
1028
1019
|
return React__default.createElement("div", {
|
|
1029
1020
|
"data-testid": "toolbar",
|
|
1030
1021
|
className: makeClassName(classNames)
|
|
1031
1022
|
}, React__default.createElement("ul", {
|
|
1032
|
-
className:
|
|
1033
|
-
},
|
|
1023
|
+
className: toolbarStyles.list
|
|
1024
|
+
}, children));
|
|
1034
1025
|
};
|
|
1035
1026
|
|
|
1036
|
-
var styles$
|
|
1027
|
+
var styles$f = {"root":"Meta-module_root__12AG7","rich":"Meta-module_rich__1XBtZ","podcast":"Meta-module_podcast__1m4zo","episode":"Meta-module_episode__1K2Xv","simple":"Meta-module_simple__3vUiI","slide":"Meta-module_slide__3g6fG","card":"Meta-module_card__LE1RK","game":"Meta-module_game__3aNlZ","isInMaterial":"Meta-module_isInMaterial__zaYMy","isInSearchItem":"Meta-module_isInSearchItem__1wbpx","isInMediaBlock":"Meta-module_isInMediaBlock__3xfPF","center":"Meta-module_center__3BBPr","half":"Meta-module_half__1xRkT","light":"Meta-module_light__2baE-","dark":"Meta-module_dark__24y9m","hasSource":"Meta-module_hasSource__2lXiN","bookmark":"Meta-module_bookmark__3ot3k","mobile":"Meta-module_mobile__22LGV","desktop":"Meta-module_desktop__1ZGUS"};
|
|
1037
1028
|
|
|
1038
1029
|
var Meta = function Meta(_ref) {
|
|
1039
1030
|
var hasSource = _ref.hasSource,
|
|
@@ -1041,10 +1032,10 @@ var Meta = function Meta(_ref) {
|
|
|
1041
1032
|
children = _ref.children,
|
|
1042
1033
|
onlyOn = _ref.onlyOn,
|
|
1043
1034
|
styleContext = _ref.styleContext;
|
|
1044
|
-
var classNames = [[styles$
|
|
1035
|
+
var classNames = [[styles$f.root, true], [styles$f[theme], !!theme && !!styles$f[theme]], [styles$f[onlyOn], !!onlyOn], [styles$f.hasSource, hasSource]];
|
|
1045
1036
|
|
|
1046
1037
|
if (styleContext) {
|
|
1047
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1038
|
+
classNames = makeStyleContext(classNames, styleContext, styles$f);
|
|
1048
1039
|
}
|
|
1049
1040
|
|
|
1050
1041
|
return React__default.createElement("div", {
|
|
@@ -1053,7 +1044,7 @@ var Meta = function Meta(_ref) {
|
|
|
1053
1044
|
}, children);
|
|
1054
1045
|
};
|
|
1055
1046
|
|
|
1056
|
-
var styles$
|
|
1047
|
+
var styles$g = {"root":"Timestamp-module_root__coOvT"};
|
|
1057
1048
|
|
|
1058
1049
|
var Timestamp = function Timestamp(_ref) {
|
|
1059
1050
|
var publishedAt = _ref.publishedAt,
|
|
@@ -1078,7 +1069,7 @@ var Timestamp = function Timestamp(_ref) {
|
|
|
1078
1069
|
|
|
1079
1070
|
return React__default.createElement("time", {
|
|
1080
1071
|
"data-testid": "timestamp",
|
|
1081
|
-
className: styles$
|
|
1072
|
+
className: styles$g.root
|
|
1082
1073
|
}, published);
|
|
1083
1074
|
};
|
|
1084
1075
|
|
|
@@ -1145,7 +1136,7 @@ var DangerousHTML = function DangerousHTML(_ref) {
|
|
|
1145
1136
|
}));
|
|
1146
1137
|
};
|
|
1147
1138
|
|
|
1148
|
-
var styles$
|
|
1139
|
+
var styles$h = {"root":"EmbedBlock-module_root__28k9U","object":"EmbedBlock-module_object__2_UZ7","objectWrap":"EmbedBlock-module_objectWrap__1aDVd","gameEmbed":"EmbedBlock-module_gameEmbed__AZQSo","proportional":"EmbedBlock-module_proportional__3lAv4","default":"EmbedBlock-module_default__LSDny","xs":"EmbedBlock-module_xs__1hFgW","full":"EmbedBlock-module_full__1TEjx","super_full":"EmbedBlock-module_super_full__1Fn9A","figure":"EmbedBlock-module_figure__vAvcN","dark":"EmbedBlock-module_dark__1be2G","isInGroupedBlock":"EmbedBlock-module_isInGroupedBlock__3r_i-","control":"EmbedBlock-module_control__xr8dZ","raw_html":"EmbedBlock-module_raw_html__MQoAA","mobileFullwidth":"EmbedBlock-module_mobileFullwidth__QFFLH","isInCard":"EmbedBlock-module_isInCard__37rtq","isInSlide":"EmbedBlock-module_isInSlide__2ea5q","cc":"EmbedBlock-module_cc__1BQ5g","isInSensitiveBlock":"EmbedBlock-module_isInSensitiveBlock__3wWYF","isInAnswer":"EmbedBlock-module_isInAnswer__tLlgs","picture":"EmbedBlock-module_picture__186q0","wrapper":"EmbedBlock-module_wrapper__33XvX","mobile":"EmbedBlock-module_mobile__1P-eo","desktop":"EmbedBlock-module_desktop__SF5a_"};
|
|
1149
1140
|
|
|
1150
1141
|
var EmbedGif = function EmbedGif(_ref) {
|
|
1151
1142
|
var gif = _ref.gif,
|
|
@@ -1191,9 +1182,9 @@ var EmbedGif = function EmbedGif(_ref) {
|
|
|
1191
1182
|
};
|
|
1192
1183
|
}, []);
|
|
1193
1184
|
return React__default.createElement("div", {
|
|
1194
|
-
className: styles$
|
|
1185
|
+
className: styles$h.figure
|
|
1195
1186
|
}, React__default.createElement("div", {
|
|
1196
|
-
className: styles$
|
|
1187
|
+
className: styles$h.objectWrap,
|
|
1197
1188
|
style: style,
|
|
1198
1189
|
"data-frozen": videoFrozen
|
|
1199
1190
|
}, React__default.createElement("video", {
|
|
@@ -1259,7 +1250,7 @@ var EmbedBlock = function EmbedBlock(_ref) {
|
|
|
1259
1250
|
case 'image':
|
|
1260
1251
|
{
|
|
1261
1252
|
return React__default.createElement("div", {
|
|
1262
|
-
className: styles$
|
|
1253
|
+
className: styles$h.figure
|
|
1263
1254
|
}, React__default.createElement(Image, {
|
|
1264
1255
|
source: !optimized && [small, large],
|
|
1265
1256
|
optimized: block.data.optimized,
|
|
@@ -1275,7 +1266,7 @@ var EmbedBlock = function EmbedBlock(_ref) {
|
|
|
1275
1266
|
case 'game_embed':
|
|
1276
1267
|
{
|
|
1277
1268
|
return React__default.createElement("div", {
|
|
1278
|
-
className: styles$
|
|
1269
|
+
className: styles$h.gameEmbed
|
|
1279
1270
|
}, React__default.createElement("iframe", {
|
|
1280
1271
|
src: block.data.game_src,
|
|
1281
1272
|
id: block.data.game_id,
|
|
@@ -1286,7 +1277,7 @@ var EmbedBlock = function EmbedBlock(_ref) {
|
|
|
1286
1277
|
case 'dots_on_image':
|
|
1287
1278
|
{
|
|
1288
1279
|
return React__default.createElement("div", {
|
|
1289
|
-
className: styles$
|
|
1280
|
+
className: styles$h.figure
|
|
1290
1281
|
}, React__default.createElement(DotsOnImage, {
|
|
1291
1282
|
block: data
|
|
1292
1283
|
}));
|
|
@@ -1295,12 +1286,12 @@ var EmbedBlock = function EmbedBlock(_ref) {
|
|
|
1295
1286
|
default:
|
|
1296
1287
|
{
|
|
1297
1288
|
return React__default.createElement("div", {
|
|
1298
|
-
className: styles$
|
|
1289
|
+
className: styles$h.object
|
|
1299
1290
|
}, React__default.createElement("div", {
|
|
1300
|
-
className: styles$
|
|
1291
|
+
className: styles$h.wrapper,
|
|
1301
1292
|
style: style
|
|
1302
1293
|
}, React__default.createElement(DangerousHTML, {
|
|
1303
|
-
className: styles$
|
|
1294
|
+
className: styles$h.objectWrap,
|
|
1304
1295
|
html: html
|
|
1305
1296
|
})));
|
|
1306
1297
|
}
|
|
@@ -1312,31 +1303,31 @@ var EmbedBlock = function EmbedBlock(_ref) {
|
|
|
1312
1303
|
style.height = 0;
|
|
1313
1304
|
}
|
|
1314
1305
|
|
|
1315
|
-
var classNames = [[styles$
|
|
1306
|
+
var classNames = [[styles$h.root, true], [styles$h.cc, cc], [styles$h[display], !!display && styles$h[display]], [styles$h[provider], !!provider && !!styles$h[provider]], [styles$h[onlyOn], !!onlyOn && styles$h[onlyOn]], [styles$h.mobileFullwidth, mobileFullwidth], [styles$h.proportional, isProportional]]; // Убираем из контекста все, что не начинается с приставки isIn,
|
|
1316
1307
|
// чтобы не применились лишние модификаторы
|
|
1317
1308
|
// TODO: в w6 модификаторы должны передаваться явно
|
|
1318
1309
|
|
|
1319
1310
|
if (styleContext && Array.isArray(styleContext)) {
|
|
1320
1311
|
var filteredContext = styleContext.filter(function (key) {
|
|
1321
|
-
return key.startsWith('isIn') && styles$
|
|
1312
|
+
return key.startsWith('isIn') && styles$h[key];
|
|
1322
1313
|
}).reduce(function (acc, key) {
|
|
1323
1314
|
acc.push(key);
|
|
1324
1315
|
return acc;
|
|
1325
1316
|
}, []);
|
|
1326
|
-
classNames = makeStyleContext(classNames, filteredContext, styles$
|
|
1317
|
+
classNames = makeStyleContext(classNames, filteredContext, styles$h);
|
|
1327
1318
|
}
|
|
1328
1319
|
|
|
1329
1320
|
return React__default.createElement("figure", {
|
|
1330
1321
|
className: makeClassName(classNames)
|
|
1331
1322
|
}, children && React__default.createElement("div", {
|
|
1332
|
-
className: styles$
|
|
1323
|
+
className: styles$h.object
|
|
1333
1324
|
}, React__default.createElement("div", {
|
|
1334
|
-
className: styles$
|
|
1325
|
+
className: styles$h.wrapper,
|
|
1335
1326
|
style: style
|
|
1336
1327
|
}, React__default.createElement("div", {
|
|
1337
|
-
className: styles$
|
|
1328
|
+
className: styles$h.objectWrap
|
|
1338
1329
|
}, children))), !children && renderEmbed(style), cc === 'default' && React__default.createElement("figcaption", null, renderCC()), cc === 'button' && React__default.createElement("button", {
|
|
1339
|
-
className: styles$
|
|
1330
|
+
className: styles$h.control,
|
|
1340
1331
|
type: "button",
|
|
1341
1332
|
"aria-label": "Open",
|
|
1342
1333
|
onClick: function onClick() {
|
|
@@ -1412,15 +1403,15 @@ var EmbedBlockContainer = function EmbedBlockContainer(_ref) {
|
|
|
1412
1403
|
});
|
|
1413
1404
|
};
|
|
1414
1405
|
|
|
1415
|
-
var styles$
|
|
1406
|
+
var styles$i = {"root":"QuoteBlock-module_root__2GrcC","center":"QuoteBlock-module_center__cTFNy"};
|
|
1416
1407
|
|
|
1417
1408
|
var QuoteBlock = function QuoteBlock(_ref) {
|
|
1418
1409
|
var data = _ref.block.data,
|
|
1419
1410
|
styleContext = _ref.styleContext;
|
|
1420
|
-
var classNames = [[styles$
|
|
1411
|
+
var classNames = [[styles$i.root, true]];
|
|
1421
1412
|
|
|
1422
1413
|
if (styleContext) {
|
|
1423
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1414
|
+
classNames = makeStyleContext(classNames, styleContext, styles$i);
|
|
1424
1415
|
}
|
|
1425
1416
|
|
|
1426
1417
|
return React__default.createElement("div", {
|
|
@@ -1433,7 +1424,7 @@ var QuoteBlock = function QuoteBlock(_ref) {
|
|
|
1433
1424
|
}));
|
|
1434
1425
|
};
|
|
1435
1426
|
|
|
1436
|
-
var styles$
|
|
1427
|
+
var styles$j = {"root":"CardTitle-module_root__1uqqF","index":"CardTitle-module_index__4FsTf","title":"CardTitle-module_title__2iTI6","mobile":"CardTitle-module_mobile__1_kij","desktop":"CardTitle-module_desktop__1l3_n"};
|
|
1437
1428
|
|
|
1438
1429
|
var CardTitle = function CardTitle(_ref) {
|
|
1439
1430
|
var _ref$block$data = _ref.block.data,
|
|
@@ -1443,15 +1434,15 @@ var CardTitle = function CardTitle(_ref) {
|
|
|
1443
1434
|
styleContext = _ref.styleContext;
|
|
1444
1435
|
return React__default.createElement("div", {
|
|
1445
1436
|
"data-testid": "card-title",
|
|
1446
|
-
className: makeClassName([[styles$
|
|
1437
|
+
className: makeClassName([[styles$j.root, true], [styles$j[onlyOn], !!onlyOn], [styles$j[styleContext], !!styleContext && !!styles$j[styleContext]]])
|
|
1447
1438
|
}, React__default.createElement("div", {
|
|
1448
|
-
className: styles$
|
|
1439
|
+
className: styles$j.index
|
|
1449
1440
|
}, index), React__default.createElement("h3", {
|
|
1450
|
-
className: styles$
|
|
1441
|
+
className: styles$j.title
|
|
1451
1442
|
}, text));
|
|
1452
1443
|
};
|
|
1453
1444
|
|
|
1454
|
-
var styles$
|
|
1445
|
+
var styles$k = {"root":"ChapterBlock-module_root__1WyVn","subtitle":"ChapterBlock-module_subtitle__3TXll","mobile":"ChapterBlock-module_mobile__CiO0w","desktop":"ChapterBlock-module_desktop__tk1Nk"};
|
|
1455
1446
|
|
|
1456
1447
|
var ChapterBlock = function ChapterBlock(_ref) {
|
|
1457
1448
|
var _ref$block = _ref.block,
|
|
@@ -1460,9 +1451,9 @@ var ChapterBlock = function ChapterBlock(_ref) {
|
|
|
1460
1451
|
styleContext = _ref.styleContext;
|
|
1461
1452
|
return React__default.createElement("div", {
|
|
1462
1453
|
"data-testid": "chapter-block",
|
|
1463
|
-
className: makeClassName([[styles$
|
|
1454
|
+
className: makeClassName([[styles$k.root, true], [styles$k[onlyOn], !!onlyOn]])
|
|
1464
1455
|
}, React__default.createElement("div", {
|
|
1465
|
-
className: makeClassName([[styles$
|
|
1456
|
+
className: makeClassName([[styles$k.subtitle, true], [styles$k[styleContext], !!styleContext && !!styles$k[styleContext]]]),
|
|
1466
1457
|
dangerouslySetInnerHTML: {
|
|
1467
1458
|
__html: data
|
|
1468
1459
|
}
|
|
@@ -1480,17 +1471,17 @@ var generateGradient = function generateGradient(color, type) {
|
|
|
1480
1471
|
return "linear-gradient(-180deg, " + gradient + ")";
|
|
1481
1472
|
};
|
|
1482
1473
|
|
|
1483
|
-
var styles$
|
|
1474
|
+
var styles$l = {"root":"SimpleTitle-module_root__2jVQN","mobile":"SimpleTitle-module_mobile__11gBz","desktop":"SimpleTitle-module_desktop__3yXgy"};
|
|
1484
1475
|
|
|
1485
1476
|
var SimpleTitle = function SimpleTitle(_ref) {
|
|
1486
1477
|
var _ref$block = _ref.block,
|
|
1487
1478
|
first = _ref$block.data.first,
|
|
1488
1479
|
onlyOn = _ref$block.only_on,
|
|
1489
1480
|
styleContext = _ref.styleContext;
|
|
1490
|
-
var classNames = [[styles$
|
|
1481
|
+
var classNames = [[styles$l.root, true], [styles$l[onlyOn], true]];
|
|
1491
1482
|
|
|
1492
1483
|
if (styleContext) {
|
|
1493
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1484
|
+
classNames = makeStyleContext(classNames, styleContext, styles$l);
|
|
1494
1485
|
}
|
|
1495
1486
|
|
|
1496
1487
|
return React__default.createElement("div", {
|
|
@@ -1499,7 +1490,7 @@ var SimpleTitle = function SimpleTitle(_ref) {
|
|
|
1499
1490
|
}, first);
|
|
1500
1491
|
};
|
|
1501
1492
|
|
|
1502
|
-
var styles$
|
|
1493
|
+
var styles$m = {"root":"RichTitle-module_root__BK_WT","slide":"RichTitle-module_slide__1A-gB","game":"RichTitle-module_game__1g8Bn","half":"RichTitle-module_half__10GRI","featured":"RichTitle-module_featured__wJfaQ","isInMediaBlock":"RichTitle-module_isInMediaBlock__3RDw4","mobile":"RichTitle-module_mobile__1Cb6E","desktop":"RichTitle-module_desktop__2ixSQ"};
|
|
1503
1494
|
|
|
1504
1495
|
var RichTitle = function RichTitle(_ref) {
|
|
1505
1496
|
var _ref$block = _ref.block,
|
|
@@ -1511,10 +1502,10 @@ var RichTitle = function RichTitle(_ref) {
|
|
|
1511
1502
|
_ref$block$data$as = _ref$block$data.as,
|
|
1512
1503
|
TagName = _ref$block$data$as === void 0 ? 'h1' : _ref$block$data$as,
|
|
1513
1504
|
styleContext = _ref.styleContext;
|
|
1514
|
-
var classNames = [[styles$
|
|
1505
|
+
var classNames = [[styles$m.root, true], [styles$m[onlyOn], true], [styles$m.featured, !!featured]];
|
|
1515
1506
|
|
|
1516
1507
|
if (styleContext) {
|
|
1517
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1508
|
+
classNames = makeStyleContext(classNames, styleContext, styles$m);
|
|
1518
1509
|
}
|
|
1519
1510
|
|
|
1520
1511
|
return React__default.createElement(TagName, {
|
|
@@ -1523,7 +1514,7 @@ var RichTitle = function RichTitle(_ref) {
|
|
|
1523
1514
|
}, first, second && React__default.createElement("span", null, " ", second));
|
|
1524
1515
|
};
|
|
1525
1516
|
|
|
1526
|
-
var styles$
|
|
1517
|
+
var styles$n = {"p":"SimpleBlock-module_p__Q3azD","h2":"SimpleBlock-module_h2__S0LRs","h3":"SimpleBlock-module_h3__2Kv7Y","h4":"SimpleBlock-module_h4__2TJO3","lead":"SimpleBlock-module_lead__35nXx","lead_hr":"SimpleBlock-module_lead_hr__1yD5v","context_p":"SimpleBlock-module_context_p__33saY","blockquote":"SimpleBlock-module_blockquote__pwpcX","game":"SimpleBlock-module_game__2sjgl","slide":"SimpleBlock-module_slide__Aqgfu","dark":"SimpleBlock-module_dark__1J_ov","isInIntro":"SimpleBlock-module_isInIntro__DfutD","center":"SimpleBlock-module_center__2rjif","isInImportantLead":"SimpleBlock-module_isInImportantLead__3VGzT","isInAnswer":"SimpleBlock-module_isInAnswer__3aX6X","mobile":"SimpleBlock-module_mobile__Ckgek","desktop":"SimpleBlock-module_desktop__2se2o"};
|
|
1527
1518
|
|
|
1528
1519
|
var SimpleBlock = function SimpleBlock(_ref) {
|
|
1529
1520
|
var _ref$block = _ref.block,
|
|
@@ -1532,10 +1523,10 @@ var SimpleBlock = function SimpleBlock(_ref) {
|
|
|
1532
1523
|
onlyOn = _ref$block.only_on,
|
|
1533
1524
|
styleContext = _ref.styleContext;
|
|
1534
1525
|
var TagName;
|
|
1535
|
-
var classNames = [[styles$
|
|
1526
|
+
var classNames = [[styles$n[type], !!type && !!styles$n[type]], [styles$n[onlyOn], true]];
|
|
1536
1527
|
|
|
1537
1528
|
if (styleContext) {
|
|
1538
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1529
|
+
classNames = makeStyleContext(classNames, styleContext, styles$n);
|
|
1539
1530
|
}
|
|
1540
1531
|
|
|
1541
1532
|
switch (type) {
|
|
@@ -1566,7 +1557,7 @@ var SimpleBlock = function SimpleBlock(_ref) {
|
|
|
1566
1557
|
});
|
|
1567
1558
|
};
|
|
1568
1559
|
|
|
1569
|
-
var styles$
|
|
1560
|
+
var styles$o = {"root":"ListBlock-module_root__3Q3Ga","ol":"ListBlock-module_ol__21CgV","ul":"ListBlock-module_ul__2MRrS","center":"ListBlock-module_center__tdIwd","isInImportantLead":"ListBlock-module_isInImportantLead__UP0ic","dark":"ListBlock-module_dark__3E3tV","mobile":"ListBlock-module_mobile__2-nuV","desktop":"ListBlock-module_desktop__1EE0g"};
|
|
1570
1561
|
|
|
1571
1562
|
var ListBlock = function ListBlock(_ref) {
|
|
1572
1563
|
var _ref$block = _ref.block,
|
|
@@ -1575,10 +1566,10 @@ var ListBlock = function ListBlock(_ref) {
|
|
|
1575
1566
|
onlyOn = _ref$block.only_on,
|
|
1576
1567
|
styleContext = _ref.styleContext;
|
|
1577
1568
|
var TagName = type;
|
|
1578
|
-
var classNames = [[styles$
|
|
1569
|
+
var classNames = [[styles$o.root, true], [styles$o[onlyOn], true], [styles$o[type], !!type && !!styles$o[type]]];
|
|
1579
1570
|
|
|
1580
1571
|
if (styleContext) {
|
|
1581
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1572
|
+
classNames = makeStyleContext(classNames, styleContext, styles$o);
|
|
1582
1573
|
}
|
|
1583
1574
|
|
|
1584
1575
|
return React__default.createElement(TagName, {
|
|
@@ -1594,7 +1585,7 @@ var ListBlock = function ListBlock(_ref) {
|
|
|
1594
1585
|
}));
|
|
1595
1586
|
};
|
|
1596
1587
|
|
|
1597
|
-
var styles$
|
|
1588
|
+
var styles$p = {"root":"RelatedBlock-module_root__IKcQq","header":"RelatedBlock-module_header__2SuWP","items":"RelatedBlock-module_items__2V-Ap","rich":"RelatedBlock-module_rich__ddaHq","first":"RelatedBlock-module_first__BKItW","simple":"RelatedBlock-module_simple__29HVO","center":"RelatedBlock-module_center__1LmW8","isInSlideMaterial":"RelatedBlock-module_isInSlideMaterial__2YSYG","mobile":"RelatedBlock-module_mobile__2XM5a","desktop":"RelatedBlock-module_desktop__2mXeq"};
|
|
1598
1589
|
|
|
1599
1590
|
var RelatedBlock = function RelatedBlock(_ref) {
|
|
1600
1591
|
var _ref$block = _ref.block,
|
|
@@ -1603,34 +1594,34 @@ var RelatedBlock = function RelatedBlock(_ref) {
|
|
|
1603
1594
|
related = _ref$block$data.related,
|
|
1604
1595
|
onlyOn = _ref$block.only_on,
|
|
1605
1596
|
styleContext = _ref.styleContext;
|
|
1606
|
-
var classNames = [[styles$
|
|
1597
|
+
var classNames = [[styles$p.root, true], [styles$p[onlyOn], true]];
|
|
1607
1598
|
|
|
1608
1599
|
if (styleContext) {
|
|
1609
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1600
|
+
classNames = makeStyleContext(classNames, styleContext, styles$p);
|
|
1610
1601
|
}
|
|
1611
1602
|
|
|
1612
1603
|
return React__default.createElement("div", {
|
|
1613
1604
|
"data-testid": "related-block",
|
|
1614
1605
|
className: makeClassName(classNames)
|
|
1615
1606
|
}, React__default.createElement("h3", {
|
|
1616
|
-
className: styles$
|
|
1607
|
+
className: styles$p.header
|
|
1617
1608
|
}, title), React__default.createElement("ul", {
|
|
1618
|
-
className: styles$
|
|
1609
|
+
className: styles$p.items
|
|
1619
1610
|
}, related.map(function (item, index) {
|
|
1620
1611
|
return React__default.createElement("li", {
|
|
1621
1612
|
key: item.id || index,
|
|
1622
|
-
className: styles$
|
|
1613
|
+
className: styles$p[item.layout]
|
|
1623
1614
|
}, React__default.createElement("a", {
|
|
1624
1615
|
href: item.full_url || "/" + item.url,
|
|
1625
1616
|
target: "_blank",
|
|
1626
1617
|
rel: "noopener noreferrer"
|
|
1627
1618
|
}, React__default.createElement("span", {
|
|
1628
|
-
className: styles$
|
|
1619
|
+
className: styles$p.first
|
|
1629
1620
|
}, item.title), item.second_title && ' ', item.second_title && React__default.createElement("span", null, item.second_title)));
|
|
1630
1621
|
})));
|
|
1631
1622
|
};
|
|
1632
1623
|
|
|
1633
|
-
var styles$
|
|
1624
|
+
var styles$q = {"root":"SourceBlock-module_root__1P3XD","text":"SourceBlock-module_text__Si4vm","origin":"SourceBlock-module_origin__l3JbO","center":"SourceBlock-module_center__3P93B","mobile":"SourceBlock-module_mobile__2gw4S","desktop":"SourceBlock-module_desktop__DecT6"};
|
|
1634
1625
|
|
|
1635
1626
|
var SourceBlock = function SourceBlock(_ref) {
|
|
1636
1627
|
var _ref$block = _ref.block,
|
|
@@ -1640,10 +1631,10 @@ var SourceBlock = function SourceBlock(_ref) {
|
|
|
1640
1631
|
origin = _ref$block$data.origin,
|
|
1641
1632
|
url = _ref$block$data.url,
|
|
1642
1633
|
styleContext = _ref.styleContext;
|
|
1643
|
-
var classNames = [[styles$
|
|
1634
|
+
var classNames = [[styles$q.root, true], [styles$q[onlyOn], true]];
|
|
1644
1635
|
|
|
1645
1636
|
if (styleContext) {
|
|
1646
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1637
|
+
classNames = makeStyleContext(classNames, styleContext, styles$q);
|
|
1647
1638
|
}
|
|
1648
1639
|
|
|
1649
1640
|
return React__default.createElement("blockquote", {
|
|
@@ -1651,7 +1642,7 @@ var SourceBlock = function SourceBlock(_ref) {
|
|
|
1651
1642
|
cite: url,
|
|
1652
1643
|
className: makeClassName(classNames)
|
|
1653
1644
|
}, React__default.createElement("a", {
|
|
1654
|
-
className: styles$
|
|
1645
|
+
className: styles$q.text,
|
|
1655
1646
|
href: url,
|
|
1656
1647
|
target: "_blank",
|
|
1657
1648
|
rel: "noopener noreferrer"
|
|
@@ -1663,11 +1654,11 @@ var SourceBlock = function SourceBlock(_ref) {
|
|
|
1663
1654
|
}
|
|
1664
1655
|
});
|
|
1665
1656
|
}), React__default.createElement("footer", null, React__default.createElement("cite", {
|
|
1666
|
-
className: styles$
|
|
1657
|
+
className: styles$q.origin
|
|
1667
1658
|
}, origin))));
|
|
1668
1659
|
};
|
|
1669
1660
|
|
|
1670
|
-
var styles$
|
|
1661
|
+
var styles$r = {"root":"SensitiveBlock-module_root__2iJbD","container":"SensitiveBlock-module_container__1Wtix","overlay":"SensitiveBlock-module_overlay__hfDVS","content":"SensitiveBlock-module_content__sNpxZ","button":"SensitiveBlock-module_button__3BGZK","default":"SensitiveBlock-module_default__2HgmZ","full":"SensitiveBlock-module_full__3Hph9","media":"SensitiveBlock-module_media__3wnlo","super_full":"SensitiveBlock-module_super_full__14UOv","visible":"SensitiveBlock-module_visible__1B-NV","isInCard":"SensitiveBlock-module_isInCard__1L-lu","isInSlide":"SensitiveBlock-module_isInSlide__f_Ql2"};
|
|
1671
1662
|
|
|
1672
1663
|
var SensitiveBlock = function SensitiveBlock(_ref) {
|
|
1673
1664
|
var block = _ref.block,
|
|
@@ -1687,11 +1678,11 @@ var SensitiveBlock = function SensitiveBlock(_ref) {
|
|
|
1687
1678
|
isVisible(true);
|
|
1688
1679
|
};
|
|
1689
1680
|
|
|
1690
|
-
var classNames = [[styles$
|
|
1681
|
+
var classNames = [[styles$r.root, true], [styles$r.visible, visible], [styles$r[display], display && styles$r[display]]];
|
|
1691
1682
|
var context = ['isInSensitiveBlock'];
|
|
1692
1683
|
|
|
1693
1684
|
if (styleContext) {
|
|
1694
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1685
|
+
classNames = makeStyleContext(classNames, styleContext, styles$r);
|
|
1695
1686
|
context = [].concat(styleContext, ['isInSensitiveBlock']);
|
|
1696
1687
|
}
|
|
1697
1688
|
|
|
@@ -1699,32 +1690,32 @@ var SensitiveBlock = function SensitiveBlock(_ref) {
|
|
|
1699
1690
|
"data-testid": "sensitive-block",
|
|
1700
1691
|
className: makeClassName(classNames)
|
|
1701
1692
|
}, React__default.createElement("div", {
|
|
1702
|
-
className: styles$
|
|
1693
|
+
className: styles$r.container
|
|
1703
1694
|
}, React__default.createElement("div", {
|
|
1704
|
-
className: styles$
|
|
1695
|
+
className: styles$r.overlay,
|
|
1705
1696
|
style: {
|
|
1706
1697
|
backgroundImage: "url(" + blurredImage + ")"
|
|
1707
1698
|
}
|
|
1708
1699
|
}, React__default.createElement("div", {
|
|
1709
|
-
className: styles$
|
|
1700
|
+
className: styles$r.content
|
|
1710
1701
|
}, React__default.createElement("p", {
|
|
1711
1702
|
dangerouslySetInnerHTML: {
|
|
1712
1703
|
__html: block.title
|
|
1713
1704
|
}
|
|
1714
1705
|
}), React__default.createElement("div", {
|
|
1715
|
-
className: styles$
|
|
1706
|
+
className: styles$r.button
|
|
1716
1707
|
}, React__default.createElement(Button, {
|
|
1717
1708
|
onClick: function onClick() {
|
|
1718
1709
|
return handleClick();
|
|
1719
1710
|
},
|
|
1720
1711
|
theme: "light"
|
|
1721
1712
|
}, block.button.text)))), React__default.createElement("div", {
|
|
1722
|
-
className: styles$
|
|
1713
|
+
className: styles$r.media
|
|
1723
1714
|
}, React__default.createElement(EmbedBlockContainer, {
|
|
1724
1715
|
block: block.item,
|
|
1725
1716
|
styleContext: context
|
|
1726
1717
|
}))), cc && React__default.createElement("figcaption", {
|
|
1727
|
-
className: styles$
|
|
1718
|
+
className: styles$r.figcaption
|
|
1728
1719
|
}, React__default.createElement(MediaCaption, {
|
|
1729
1720
|
credit: credit,
|
|
1730
1721
|
caption: caption,
|
|
@@ -1732,7 +1723,7 @@ var SensitiveBlock = function SensitiveBlock(_ref) {
|
|
|
1732
1723
|
})));
|
|
1733
1724
|
};
|
|
1734
1725
|
|
|
1735
|
-
var styles$
|
|
1726
|
+
var styles$s = {"root":"GroupedBlock-module_root__2qfQA","hasFigcaption":"GroupedBlock-module_hasFigcaption__2_mcf","item":"GroupedBlock-module_item__3sz9_","items":"GroupedBlock-module_items__2DV2X","figcaption":"GroupedBlock-module_figcaption__2Q_wf","default":"GroupedBlock-module_default__3ylw_","full":"GroupedBlock-module_full__1dzQR","super_full":"GroupedBlock-module_super_full__1PU72","mobile":"GroupedBlock-module_mobile__3n8Ub","desktop":"GroupedBlock-module_desktop__6ZRpA"};
|
|
1736
1727
|
|
|
1737
1728
|
var GroupedBlock = function GroupedBlock(_ref) {
|
|
1738
1729
|
var block = _ref.block,
|
|
@@ -1749,21 +1740,21 @@ var GroupedBlock = function GroupedBlock(_ref) {
|
|
|
1749
1740
|
var sumWidth = normalizedBoxesWidth.reduce(function (sum, x) {
|
|
1750
1741
|
return sum + x;
|
|
1751
1742
|
});
|
|
1752
|
-
var classNames = [[styles$
|
|
1743
|
+
var classNames = [[styles$s.root, true], [styles$s[onlyOn], true], [styles$s.hasFigcaption, block.cc === 'default'], [styles$s[block.display], !!block.display && styles$s[block.display]]];
|
|
1753
1744
|
|
|
1754
1745
|
if (styleContext) {
|
|
1755
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
1746
|
+
classNames = makeStyleContext(classNames, styleContext, styles$s);
|
|
1756
1747
|
}
|
|
1757
1748
|
|
|
1758
1749
|
return React__default.createElement("div", {
|
|
1759
1750
|
"data-testid": "grouped-block",
|
|
1760
1751
|
className: makeClassName(classNames)
|
|
1761
1752
|
}, React__default.createElement("div", {
|
|
1762
|
-
className: styles$
|
|
1753
|
+
className: styles$s.items
|
|
1763
1754
|
}, block.data.map(function (item, index) {
|
|
1764
1755
|
var percentWidth = normalizedBoxesWidth[index] / sumWidth * 100;
|
|
1765
1756
|
return React__default.createElement("div", {
|
|
1766
|
-
className: styles$
|
|
1757
|
+
className: styles$s.item,
|
|
1767
1758
|
key: item.id,
|
|
1768
1759
|
style: {
|
|
1769
1760
|
width: percentWidth + "%"
|
|
@@ -1776,7 +1767,7 @@ var GroupedBlock = function GroupedBlock(_ref) {
|
|
|
1776
1767
|
styleContext: ['isInGroupedBlock']
|
|
1777
1768
|
}));
|
|
1778
1769
|
})), block.cc && React__default.createElement("figcaption", {
|
|
1779
|
-
className: styles$
|
|
1770
|
+
className: styles$s.figcaption
|
|
1780
1771
|
}, React__default.createElement(MediaCaption, {
|
|
1781
1772
|
credit: block.credit,
|
|
1782
1773
|
caption: block.caption,
|
|
@@ -1784,32 +1775,32 @@ var GroupedBlock = function GroupedBlock(_ref) {
|
|
|
1784
1775
|
})));
|
|
1785
1776
|
};
|
|
1786
1777
|
|
|
1787
|
-
var styles$
|
|
1778
|
+
var styles$t = {"root":"MetaItem-module_root__2VQom","hasBullets":"MetaItem-module_hasBullets__CkQPI","hasSource":"MetaItem-module_hasSource__1DmCI","listened":"MetaItem-module_listened__lwvAO","read":"MetaItem-module_read__5eAIG","datetime":"MetaItem-module_datetime__3tOWm"};
|
|
1788
1779
|
|
|
1789
1780
|
var MetaItem = function MetaItem(_ref) {
|
|
1790
1781
|
var hasSource = _ref.hasSource,
|
|
1791
1782
|
type = _ref.type,
|
|
1792
1783
|
children = _ref.children,
|
|
1793
1784
|
bullets = _ref.bullets;
|
|
1794
|
-
var classNames = [[styles$
|
|
1785
|
+
var classNames = [[styles$t.root, true], [styles$t[type], !!type && !!styles$t[type]], [styles$t.hasSource, !!hasSource], [styles$t.hasBullets, !!bullets]];
|
|
1795
1786
|
return React__default.createElement("div", {
|
|
1796
1787
|
"data-testid": "meta-item",
|
|
1797
1788
|
className: makeClassName(classNames)
|
|
1798
1789
|
}, children);
|
|
1799
1790
|
};
|
|
1800
1791
|
|
|
1801
|
-
var styles$
|
|
1792
|
+
var styles$u = {"root":"MetaItemLive-module_root__2mpD3","gold":"MetaItemLive-module_gold__3yZEV","frame":"MetaItemLive-module_frame__1H_Ha","liveMiddle":"MetaItemLive-module_liveMiddle__wyuV3","liveFirstWave":"MetaItemLive-module_liveFirstWave__3dbvz","liveSecondWave":"MetaItemLive-module_liveSecondWave__12g57"};
|
|
1802
1793
|
|
|
1803
1794
|
var MetaItemLive = function MetaItemLive(_ref) {
|
|
1804
1795
|
var _ref$theme = _ref.theme,
|
|
1805
1796
|
theme = _ref$theme === void 0 ? 'gold' : _ref$theme;
|
|
1806
|
-
var classNames = [[styles$
|
|
1797
|
+
var classNames = [[styles$u.root, true], [styles$u[theme], !!theme && styles$u[theme]]];
|
|
1807
1798
|
return React__default.createElement("div", {
|
|
1808
1799
|
"data-testid": "meta-item-live",
|
|
1809
1800
|
"data-meta": "live",
|
|
1810
1801
|
className: makeClassName(classNames)
|
|
1811
1802
|
}, React__default.createElement("div", {
|
|
1812
|
-
className: styles$
|
|
1803
|
+
className: styles$u.frame
|
|
1813
1804
|
}));
|
|
1814
1805
|
};
|
|
1815
1806
|
|
|
@@ -1834,7 +1825,7 @@ var pluralize = function pluralize(number, one, two, five) {
|
|
|
1834
1825
|
return five;
|
|
1835
1826
|
};
|
|
1836
1827
|
|
|
1837
|
-
var styles$
|
|
1828
|
+
var styles$v = {"root":"DocumentItemsCount-module_root__P3q-z","items":"DocumentItemsCount-module_items__3pfxW"};
|
|
1838
1829
|
|
|
1839
1830
|
var DocumentItemsCount = function DocumentItemsCount(_ref) {
|
|
1840
1831
|
var type = _ref.type,
|
|
@@ -1871,9 +1862,9 @@ var DocumentItemsCount = function DocumentItemsCount(_ref) {
|
|
|
1871
1862
|
var itemsCount = items + " " + pluralize(items, i18n[lang][type].one, i18n[lang][type].two, i18n[lang][type].five);
|
|
1872
1863
|
return React__default.createElement("div", {
|
|
1873
1864
|
"data-testid": "document-items-count",
|
|
1874
|
-
className: styles$
|
|
1865
|
+
className: styles$v.root
|
|
1875
1866
|
}, children, React__default.createElement("span", {
|
|
1876
|
-
className: styles$
|
|
1867
|
+
className: styles$v.items
|
|
1877
1868
|
}, itemsCount));
|
|
1878
1869
|
};
|
|
1879
1870
|
|
|
@@ -1996,7 +1987,7 @@ var MetaContainer = function MetaContainer(_ref) {
|
|
|
1996
1987
|
icon: isListened ? 'listened' : 'read',
|
|
1997
1988
|
size: "unset"
|
|
1998
1989
|
})), isSlides && lang === 'ru' && React__default.createElement("div", {
|
|
1999
|
-
className: styles$
|
|
1990
|
+
className: styles$f.bookmark
|
|
2000
1991
|
}, React__default.createElement(BookmarkButton, {
|
|
2001
1992
|
isInBookmarks: isInBookmarks,
|
|
2002
1993
|
onClick: function onClick() {
|
|
@@ -2158,7 +2149,7 @@ var RenderBlocks = function RenderBlocks(_ref) {
|
|
|
2158
2149
|
}
|
|
2159
2150
|
};
|
|
2160
2151
|
|
|
2161
|
-
var styles$
|
|
2152
|
+
var styles$w = {"root":"Cover-module_root__18Z8J","body":"Cover-module_body__1xs8e","image":"Cover-module_image__2f3Qc","rich":"Cover-module_rich__1fAGA","dark":"Cover-module_dark__2Ac-w","light":"Cover-module_light__FUp5X","control":"Cover-module_control__VXbhi","isInDynamicBlock":"Cover-module_isInDynamicBlock__3eghb","mobile":"Cover-module_mobile__5DKa1","desktop":"Cover-module_desktop__2mrOc"};
|
|
2162
2153
|
|
|
2163
2154
|
var Cover = function Cover(_ref) {
|
|
2164
2155
|
var _ref$block = _ref.block,
|
|
@@ -2179,15 +2170,15 @@ var Cover = function Cover(_ref) {
|
|
|
2179
2170
|
setIsPopoverShown = _useState[1];
|
|
2180
2171
|
|
|
2181
2172
|
var style = {};
|
|
2182
|
-
var classNames = [[styles$
|
|
2173
|
+
var classNames = [[styles$w.root, true], [styles$w[onlyOn], !!onlyOn && !!styles$w[onlyOn]]];
|
|
2183
2174
|
|
|
2184
2175
|
if (styleContext) {
|
|
2185
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
2176
|
+
classNames = makeStyleContext(classNames, styleContext, styles$w);
|
|
2186
2177
|
}
|
|
2187
2178
|
|
|
2188
2179
|
if (gradients) {
|
|
2189
2180
|
var theme = [gradients.text_rgb === '0,0,0' ? 'dark' : 'light'];
|
|
2190
|
-
classNames = makeStyleContext(classNames, theme, styles$
|
|
2181
|
+
classNames = makeStyleContext(classNames, theme, styles$w);
|
|
2191
2182
|
style.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockBottom');
|
|
2192
2183
|
}
|
|
2193
2184
|
|
|
@@ -2203,13 +2194,13 @@ var Cover = function Cover(_ref) {
|
|
|
2203
2194
|
"data-testid": "cover",
|
|
2204
2195
|
className: makeClassName(classNames)
|
|
2205
2196
|
}, React__default.createElement("div", {
|
|
2206
|
-
className: styles$
|
|
2197
|
+
className: styles$w.image
|
|
2207
2198
|
}, React__default.createElement(Image, {
|
|
2208
2199
|
optimized: urls,
|
|
2209
2200
|
ratio: mobileRatio,
|
|
2210
2201
|
display: "narrow"
|
|
2211
2202
|
})), React__default.createElement("div", {
|
|
2212
|
-
className: styles$
|
|
2203
|
+
className: styles$w.body,
|
|
2213
2204
|
style: style
|
|
2214
2205
|
}, blocks.map(function (item) {
|
|
2215
2206
|
return React__default.createElement(RenderBlocks, {
|
|
@@ -2218,7 +2209,7 @@ var Cover = function Cover(_ref) {
|
|
|
2218
2209
|
styleContext: styleContext
|
|
2219
2210
|
});
|
|
2220
2211
|
})), cc === 'button' && React__default.createElement("button", {
|
|
2221
|
-
className: styles$
|
|
2212
|
+
className: styles$w.control,
|
|
2222
2213
|
type: "button",
|
|
2223
2214
|
"aria-label": "Open",
|
|
2224
2215
|
onClick: function onClick() {
|
|
@@ -2231,7 +2222,7 @@ var Cover = function Cover(_ref) {
|
|
|
2231
2222
|
}, renderCC('isInPopover')));
|
|
2232
2223
|
};
|
|
2233
2224
|
|
|
2234
|
-
var styles$
|
|
2225
|
+
var styles$x = {"root":"HalfBlock-module_root__2frv2","main":"HalfBlock-module_main__2XX73","body":"HalfBlock-module_body__3MnEN","footer":"HalfBlock-module_footer__1C0yp","image":"HalfBlock-module_image__2lYel","mobile":"HalfBlock-module_mobile__2latf","desktop":"HalfBlock-module_desktop__3B1Ej"};
|
|
2235
2226
|
|
|
2236
2227
|
var HalfBlock = function HalfBlock(_ref) {
|
|
2237
2228
|
var _ref$block = _ref.block,
|
|
@@ -2243,25 +2234,25 @@ var HalfBlock = function HalfBlock(_ref) {
|
|
|
2243
2234
|
credit = _ref$block$data$cover.credit,
|
|
2244
2235
|
caption = _ref$block$data$cover.caption,
|
|
2245
2236
|
styleContext = _ref.styleContext;
|
|
2246
|
-
var classNames = [[styles$
|
|
2237
|
+
var classNames = [[styles$x.root, true], [styles$x[onlyOn], true]];
|
|
2247
2238
|
|
|
2248
2239
|
if (styleContext) {
|
|
2249
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
2240
|
+
classNames = makeStyleContext(classNames, styleContext, styles$x);
|
|
2250
2241
|
}
|
|
2251
2242
|
|
|
2252
2243
|
return React__default.createElement("div", {
|
|
2253
2244
|
"data-testid": "half-block",
|
|
2254
2245
|
className: makeClassName(classNames)
|
|
2255
2246
|
}, React__default.createElement("div", {
|
|
2256
|
-
className: styles$
|
|
2247
|
+
className: styles$x.main
|
|
2257
2248
|
}, React__default.createElement("div", {
|
|
2258
|
-
className: styles$
|
|
2249
|
+
className: styles$x.image
|
|
2259
2250
|
}, React__default.createElement(Image, {
|
|
2260
2251
|
optimized: optimized,
|
|
2261
2252
|
ratio: ratio,
|
|
2262
2253
|
display: "super_full"
|
|
2263
2254
|
})), React__default.createElement("div", {
|
|
2264
|
-
className: styles$
|
|
2255
|
+
className: styles$x.body
|
|
2265
2256
|
}, data.blocks.map(function (item) {
|
|
2266
2257
|
return React__default.createElement(RenderBlocks, {
|
|
2267
2258
|
key: item.id,
|
|
@@ -2269,7 +2260,7 @@ var HalfBlock = function HalfBlock(_ref) {
|
|
|
2269
2260
|
styleContext: ['rich']
|
|
2270
2261
|
});
|
|
2271
2262
|
}))), React__default.createElement("div", {
|
|
2272
|
-
className: styles$
|
|
2263
|
+
className: styles$x.footer
|
|
2273
2264
|
}, React__default.createElement(MediaCaption, {
|
|
2274
2265
|
credit: credit,
|
|
2275
2266
|
caption: caption,
|
|
@@ -2277,17 +2268,17 @@ var HalfBlock = function HalfBlock(_ref) {
|
|
|
2277
2268
|
})));
|
|
2278
2269
|
};
|
|
2279
2270
|
|
|
2280
|
-
var styles$
|
|
2271
|
+
var styles$y = {"root":"ImportantLead-module_root__2BdT3","slide":"ImportantLead-module_slide__3kQ9x","mobile":"ImportantLead-module_mobile__3BXbm","desktop":"ImportantLead-module_desktop__3Zljc"};
|
|
2281
2272
|
|
|
2282
2273
|
var ImportantLead = function ImportantLead(_ref) {
|
|
2283
2274
|
var _ref$block = _ref.block,
|
|
2284
2275
|
onlyOn = _ref$block.only_on,
|
|
2285
2276
|
data = _ref$block.data,
|
|
2286
2277
|
styleContext = _ref.styleContext;
|
|
2287
|
-
var classNames = [[styles$
|
|
2278
|
+
var classNames = [[styles$y.root, true], [styles$y[onlyOn], !!onlyOn]];
|
|
2288
2279
|
|
|
2289
2280
|
if (styleContext) {
|
|
2290
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
2281
|
+
classNames = makeStyleContext(classNames, styleContext, styles$y);
|
|
2291
2282
|
}
|
|
2292
2283
|
|
|
2293
2284
|
return React__default.createElement("div", {
|
|
@@ -2302,7 +2293,7 @@ var ImportantLead = function ImportantLead(_ref) {
|
|
|
2302
2293
|
}));
|
|
2303
2294
|
};
|
|
2304
2295
|
|
|
2305
|
-
var styles$
|
|
2296
|
+
var styles$z = {"root":"Spoiler-module_root__1OfSR","header":"Spoiler-module_header__1rZUs","body":"Spoiler-module_body__Q1e_c","spoiled":"Spoiler-module_spoiled__1A5r4","footer":"Spoiler-module_footer__23mh7","spoilerSticky":"Spoiler-module_spoilerSticky__3Kd30","spoilerStickyBg":"Spoiler-module_spoilerStickyBg__nYdlo","center":"Spoiler-module_center__tq1m0","full":"Spoiler-module_full__1QFqR","default":"Spoiler-module_default__2Kjx8","mobile":"Spoiler-module_mobile__2BPt8","desktop":"Spoiler-module_desktop__1BIFJ"};
|
|
2306
2297
|
|
|
2307
2298
|
var Spoiler = function Spoiler(_ref) {
|
|
2308
2299
|
var _ref$block = _ref.block,
|
|
@@ -2337,11 +2328,11 @@ var Spoiler = function Spoiler(_ref) {
|
|
|
2337
2328
|
}
|
|
2338
2329
|
};
|
|
2339
2330
|
|
|
2340
|
-
var classNames = [[styles$
|
|
2331
|
+
var classNames = [[styles$z.root, true], [styles$z[onlyOn], !!onlyOn], [styles$z[display], !!display && styles$z[display]], [[styles$z.spoiled], !!spoiled]];
|
|
2341
2332
|
var context = ['center'];
|
|
2342
2333
|
|
|
2343
2334
|
if (styleContext) {
|
|
2344
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
2335
|
+
classNames = makeStyleContext(classNames, styleContext, styles$z);
|
|
2345
2336
|
}
|
|
2346
2337
|
|
|
2347
2338
|
var buttonCollapse = button ? button.collapse : 'Свернуть';
|
|
@@ -2351,9 +2342,9 @@ var Spoiler = function Spoiler(_ref) {
|
|
|
2351
2342
|
className: makeClassName(classNames),
|
|
2352
2343
|
"data-testid": "spoiler"
|
|
2353
2344
|
}, React__default.createElement("div", {
|
|
2354
|
-
className: styles$
|
|
2345
|
+
className: styles$z.header
|
|
2355
2346
|
}, title && React__default.createElement("h3", null, title)), React__default.createElement("div", {
|
|
2356
|
-
className: styles$
|
|
2347
|
+
className: styles$z.body
|
|
2357
2348
|
}, blocks.map(function (item) {
|
|
2358
2349
|
return React__default.createElement(RenderBlocks, {
|
|
2359
2350
|
key: item.id,
|
|
@@ -2361,7 +2352,7 @@ var Spoiler = function Spoiler(_ref) {
|
|
|
2361
2352
|
styleContext: context
|
|
2362
2353
|
});
|
|
2363
2354
|
})), React__default.createElement("div", {
|
|
2364
|
-
className: styles$
|
|
2355
|
+
className: styles$z.footer
|
|
2365
2356
|
}, React__default.createElement(Button, {
|
|
2366
2357
|
size: "default",
|
|
2367
2358
|
theme: "gray",
|
|
@@ -2374,7 +2365,7 @@ var Spoiler = function Spoiler(_ref) {
|
|
|
2374
2365
|
}))));
|
|
2375
2366
|
};
|
|
2376
2367
|
|
|
2377
|
-
var styles$
|
|
2368
|
+
var styles$A = {"root":"RelatedRichBlock-module_root__3NYmj","wrapper":"RelatedRichBlock-module_wrapper__1eLIQ","overlay":"RelatedRichBlock-module_overlay__3XSg_","overlayHeader":"RelatedRichBlock-module_overlayHeader__2Nmbv","body":"RelatedRichBlock-module_body__1ZHZS","isRich":"RelatedRichBlock-module_isRich__1LnA4","hasGradient":"RelatedRichBlock-module_hasGradient__27LOk","picture":"RelatedRichBlock-module_picture__128HJ","isCard":"RelatedRichBlock-module_isCard__2naDz","cover":"RelatedRichBlock-module_cover__3yygp","tag":"RelatedRichBlock-module_tag__3OLyG","center":"RelatedRichBlock-module_center__197sx","dark":"RelatedRichBlock-module_dark__3Y1fE","light":"RelatedRichBlock-module_light__2mUxL","mobile":"RelatedRichBlock-module_mobile__JpCS4","desktop":"RelatedRichBlock-module_desktop__trL0D"};
|
|
2378
2369
|
|
|
2379
2370
|
/* eslint-disable react/jsx-no-target-blank */
|
|
2380
2371
|
var RelatedRichBlock = function RelatedRichBlock(_ref) {
|
|
@@ -2413,18 +2404,18 @@ var RelatedRichBlock = function RelatedRichBlock(_ref) {
|
|
|
2413
2404
|
postMessage('richRelated', url, 'click');
|
|
2414
2405
|
};
|
|
2415
2406
|
|
|
2416
|
-
var classNames = [[styles$
|
|
2407
|
+
var classNames = [[styles$A.root, true], [styles$A[cardType], !!layout && !!styles$A[cardType]], [styles$A.hasGradient, !!gradients], [styles$A[onlyOn], !!onlyOn && !!styles$A[onlyOn]]];
|
|
2417
2408
|
var context = ['isInMediaBlock'];
|
|
2418
2409
|
|
|
2419
2410
|
if (styleContext) {
|
|
2420
|
-
classNames = makeStyleContext(classNames, styleContext, styles$
|
|
2411
|
+
classNames = makeStyleContext(classNames, styleContext, styles$A);
|
|
2421
2412
|
context = [].concat(styleContext, ['isInMediaBlock']);
|
|
2422
2413
|
}
|
|
2423
2414
|
|
|
2424
2415
|
if (gradients) {
|
|
2425
2416
|
styleHeader.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockTop');
|
|
2426
2417
|
var theme = [gradients.text_rgb === '0,0,0' ? 'dark' : 'light'];
|
|
2427
|
-
classNames = makeStyleContext(classNames, theme, styles$
|
|
2418
|
+
classNames = makeStyleContext(classNames, theme, styles$A);
|
|
2428
2419
|
|
|
2429
2420
|
if (onlyOn === 'desktop') {
|
|
2430
2421
|
style.backgroundImage = generateGradient(gradients.bg_rgb, 'mediaBlockBottom');
|
|
@@ -2441,27 +2432,27 @@ var RelatedRichBlock = function RelatedRichBlock(_ref) {
|
|
|
2441
2432
|
},
|
|
2442
2433
|
ref: ref
|
|
2443
2434
|
}, layout === 'rich' && React__default.createElement(React__default.Fragment, null, React__default.createElement("div", {
|
|
2444
|
-
className: styles$
|
|
2435
|
+
className: styles$A.overlay,
|
|
2445
2436
|
style: style
|
|
2446
2437
|
}), React__default.createElement("div", {
|
|
2447
|
-
className: styles$
|
|
2438
|
+
className: styles$A.overlayHeader,
|
|
2448
2439
|
style: styleHeader
|
|
2449
2440
|
})), React__default.createElement("div", {
|
|
2450
|
-
className: styles$
|
|
2441
|
+
className: styles$A.tag
|
|
2451
2442
|
}, React__default.createElement(Tag, {
|
|
2452
2443
|
size: "small",
|
|
2453
2444
|
theme: "inherit",
|
|
2454
2445
|
styleContext: "richRelated"
|
|
2455
2446
|
}, tag)), React__default.createElement("div", {
|
|
2456
|
-
className: styles$
|
|
2447
|
+
className: styles$A.cover
|
|
2457
2448
|
}, React__default.createElement("div", {
|
|
2458
|
-
className: styles$
|
|
2449
|
+
className: styles$A.picture
|
|
2459
2450
|
}, React__default.createElement(Image, {
|
|
2460
2451
|
optimized: urls,
|
|
2461
2452
|
ratio: ratio,
|
|
2462
2453
|
display: "narrow"
|
|
2463
2454
|
}))), React__default.createElement("div", {
|
|
2464
|
-
className: styles$
|
|
2455
|
+
className: styles$A.body
|
|
2465
2456
|
}, blocks.map(function (item) {
|
|
2466
2457
|
return React__default.createElement(RenderBlocks, {
|
|
2467
2458
|
key: item.id,
|
|
@@ -2542,7 +2533,7 @@ var RawHtmlBlock = function RawHtmlBlock(_ref) {
|
|
|
2542
2533
|
}
|
|
2543
2534
|
};
|
|
2544
2535
|
|
|
2545
|
-
var styles$
|
|
2536
|
+
var styles$B = {"root":"ToolbarButton-module_root__xN-fq","dark":"ToolbarButton-module_dark__GrIOr","bookmark":"ToolbarButton-module_bookmark__3369b","isActive":"ToolbarButton-module_isActive__3NLAE","text":"ToolbarButton-module_text__32m6s"};
|
|
2546
2537
|
|
|
2547
2538
|
var ToolbarButton = function ToolbarButton(_ref) {
|
|
2548
2539
|
var children = _ref.children,
|
|
@@ -2550,8 +2541,10 @@ var ToolbarButton = function ToolbarButton(_ref) {
|
|
|
2550
2541
|
theme = _ref.theme,
|
|
2551
2542
|
isActive = _ref.isActive,
|
|
2552
2543
|
_onClick = _ref.onClick;
|
|
2553
|
-
var classNames = [[styles$
|
|
2554
|
-
return React__default.createElement("
|
|
2544
|
+
var classNames = [[styles$B.root, true], [styles$B[type], !!styles$B[type]], [styles$B[theme], !!styles$B[theme] && !!theme], [styles$B.isActive, !!isActive]];
|
|
2545
|
+
return React__default.createElement("li", {
|
|
2546
|
+
className: toolbarStyles.item
|
|
2547
|
+
}, React__default.createElement("button", {
|
|
2555
2548
|
"data-testid": "toolbar-button",
|
|
2556
2549
|
className: makeClassName(classNames),
|
|
2557
2550
|
type: "button",
|
|
@@ -2563,8 +2556,8 @@ var ToolbarButton = function ToolbarButton(_ref) {
|
|
|
2563
2556
|
icon: type,
|
|
2564
2557
|
styleContext: "isInToolbar"
|
|
2565
2558
|
}), children && React__default.createElement("span", {
|
|
2566
|
-
className: styles$
|
|
2567
|
-
}, children));
|
|
2559
|
+
className: styles$B.text
|
|
2560
|
+
}, children)));
|
|
2568
2561
|
};
|
|
2569
2562
|
|
|
2570
2563
|
exports.BookmarkButton = BookmarkButton;
|