@doyourjob/gravity-ui-page-constructor 5.31.86-b → 5.31.87
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/build/cjs/blocks/Header/Header.css +1 -0
- package/build/cjs/blocks/HighlightTable/HighlightTable.css +1 -0
- package/build/cjs/blocks/HighlightTable/HighlightTable.js +9 -1
- package/build/cjs/blocks/ReportsSections/ReportsSections.css +10 -0
- package/build/cjs/blocks/ReportsSections/ReportsSections.js +2 -1
- package/build/cjs/blocks/Slider/Slider.css +34 -23
- package/build/cjs/blocks/Slider/Slider.js +5 -9
- package/build/cjs/components/Filters/FilterSelect/FilterSelect.css +3 -0
- package/build/esm/blocks/Header/Header.css +1 -0
- package/build/esm/blocks/HighlightTable/HighlightTable.css +1 -0
- package/build/esm/blocks/HighlightTable/HighlightTable.js +9 -1
- package/build/esm/blocks/ReportsSections/ReportsSections.css +10 -0
- package/build/esm/blocks/ReportsSections/ReportsSections.js +3 -2
- package/build/esm/blocks/Slider/Slider.css +34 -23
- package/build/esm/blocks/Slider/Slider.js +5 -9
- package/build/esm/components/Filters/FilterSelect/FilterSelect.css +3 -0
- package/package.json +1 -1
- package/widget/index.js +1 -1
|
@@ -37,7 +37,7 @@ const HighlightTableBlock = ({ title, description, table, legend = [], contentSi
|
|
|
37
37
|
if (!tableContentElem || !blockElem)
|
|
38
38
|
return () => { };
|
|
39
39
|
const updateSizes = (0, debounce_1.default)(() => {
|
|
40
|
-
const width = Math.max(
|
|
40
|
+
const width = Math.max(648, blockElem.clientWidth - 24 - 2); // 24 - padding, 2 - border
|
|
41
41
|
tableContentElem.style.setProperty('--block-width', `${width}px`);
|
|
42
42
|
});
|
|
43
43
|
updateSizes();
|
|
@@ -53,6 +53,14 @@ const HighlightTableBlock = ({ title, description, table, legend = [], contentSi
|
|
|
53
53
|
if (!tableElem || !scrollBar || !scrollThumb)
|
|
54
54
|
return () => { };
|
|
55
55
|
const updateProgress = (0, debounce_1.default)(() => {
|
|
56
|
+
if (tableElem.clientWidth === tableElem.scrollWidth) {
|
|
57
|
+
if (scrollBar.style.getPropertyValue('display') !== 'none') {
|
|
58
|
+
scrollBar.style.setProperty('display', `none`);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
else if (scrollBar.style.getPropertyValue('display') !== 'block') {
|
|
62
|
+
scrollBar.style.setProperty('display', `block`);
|
|
63
|
+
}
|
|
56
64
|
const scrollWidth = Math.round(scrollBar.clientWidth * (tableElem.clientWidth / tableElem.scrollWidth));
|
|
57
65
|
const scrollLeft = Math.round(scrollBar.clientWidth * (tableElem.scrollLeft / tableElem.scrollWidth));
|
|
58
66
|
scrollThumb.style.setProperty('transform', `translateX(${scrollLeft}px)`);
|
|
@@ -3,6 +3,16 @@ unpredictable css rules order in build */
|
|
|
3
3
|
.pc-reports-sections-block__title {
|
|
4
4
|
margin-bottom: 24px;
|
|
5
5
|
}
|
|
6
|
+
@media (min-width: 769px) {
|
|
7
|
+
.pc-reports-sections-block__wrap-sections.pc-AnimateBlock .pc-reports-sections-block__sections, .pc-AnimateBlock .pc-reports-sections-block__wrap-sections .pc-reports-sections-block__sections {
|
|
8
|
+
opacity: 0;
|
|
9
|
+
}
|
|
10
|
+
.pc-reports-sections-block__wrap-sections.pc-AnimateBlock.animate .pc-reports-sections-block__sections, .pc-AnimateBlock .pc-reports-sections-block__wrap-sections.animate .pc-reports-sections-block__sections {
|
|
11
|
+
opacity: 1;
|
|
12
|
+
transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
|
|
13
|
+
transition-delay: 0s;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
6
16
|
.pc-reports-sections-block__sections {
|
|
7
17
|
display: flex;
|
|
8
18
|
flex-direction: column;
|
|
@@ -30,7 +30,8 @@ const ReportsSectionsBlock = ({ title, typeKey, empty }) => {
|
|
|
30
30
|
return (react_1.default.createElement("div", { className: b() },
|
|
31
31
|
title && react_1.default.createElement(components_1.Title, { className: b('title'), title: titleProps, colSizes: titleColSizes }),
|
|
32
32
|
react_1.default.createElement(FilterSelects_1.default, { selects: selects, filters: localFilters, handleChange: handleChange }),
|
|
33
|
-
filteredItems.length ? (react_1.default.createElement(
|
|
33
|
+
filteredItems.length ? (react_1.default.createElement(components_1.AnimateBlock, { key: JSON.stringify(localFilters), className: b('wrap-sections'), animate: true },
|
|
34
|
+
react_1.default.createElement("div", { className: b('sections') }, filteredItems.map((item, index) => (react_1.default.createElement(Section_1.default, Object.assign({ key: index }, item))))))) : (react_1.default.createElement(components_1.EmptyPlug, { empty: empty, className: b('empty') }))));
|
|
34
35
|
};
|
|
35
36
|
exports.ReportsSectionsBlock = ReportsSectionsBlock;
|
|
36
37
|
exports.default = exports.ReportsSectionsBlock;
|
|
@@ -118,25 +118,6 @@ unpredictable css rules order in build */
|
|
|
118
118
|
.pc-SliderBlock .slick-arrow.slick-prev {
|
|
119
119
|
right: 42px;
|
|
120
120
|
}
|
|
121
|
-
.pc-SliderBlock__slick-mobile {
|
|
122
|
-
display: none;
|
|
123
|
-
}
|
|
124
|
-
.pc-SliderBlock__mobile-scroll {
|
|
125
|
-
display: flex;
|
|
126
|
-
margin: 0 -24px;
|
|
127
|
-
padding: 24px;
|
|
128
|
-
gap: 16px;
|
|
129
|
-
overflow-x: auto;
|
|
130
|
-
-webkit-overflow-scrolling: touch;
|
|
131
|
-
scrollbar-width: none;
|
|
132
|
-
}
|
|
133
|
-
.pc-SliderBlock__mobile-scroll::-webkit-scrollbar {
|
|
134
|
-
display: none;
|
|
135
|
-
}
|
|
136
|
-
.pc-SliderBlock__mobile-scroll-item {
|
|
137
|
-
flex: 0 0 auto;
|
|
138
|
-
width: 90%;
|
|
139
|
-
}
|
|
140
121
|
.pc-SliderBlock__header_no-description {
|
|
141
122
|
position: relative;
|
|
142
123
|
top: -3px;
|
|
@@ -672,6 +653,26 @@ unpredictable css rules order in build */
|
|
|
672
653
|
.pc-SliderBlock_type_header-card .slick-arrow.slick-prev {
|
|
673
654
|
left: 0;
|
|
674
655
|
}
|
|
656
|
+
@media (max-width: 577px) {
|
|
657
|
+
.pc-SliderBlock_type_header-card .slick-arrow {
|
|
658
|
+
display: none;
|
|
659
|
+
}
|
|
660
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-list {
|
|
661
|
+
margin-left: 0;
|
|
662
|
+
}
|
|
663
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-track {
|
|
664
|
+
padding-left: 0;
|
|
665
|
+
}
|
|
666
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-slide {
|
|
667
|
+
/* stylelint-disable declaration-no-important */
|
|
668
|
+
padding-right: 0 !important;
|
|
669
|
+
padding-left: 0 !important;
|
|
670
|
+
/* stylelint-enable declaration-no-important */
|
|
671
|
+
}
|
|
672
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-slide:last-child {
|
|
673
|
+
padding-right: 0;
|
|
674
|
+
}
|
|
675
|
+
}
|
|
675
676
|
@media (max-width: 769px) {
|
|
676
677
|
.pc-SliderBlock__footer {
|
|
677
678
|
display: block;
|
|
@@ -683,10 +684,20 @@ unpredictable css rules order in build */
|
|
|
683
684
|
}
|
|
684
685
|
}
|
|
685
686
|
@media (max-width: 577px) {
|
|
686
|
-
.pc-
|
|
687
|
-
|
|
687
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) {
|
|
688
|
+
margin-left: -24px;
|
|
689
|
+
padding-left: 24px;
|
|
690
|
+
width: calc(100% + 48px);
|
|
691
|
+
overflow-x: auto;
|
|
688
692
|
}
|
|
689
|
-
.pc-
|
|
690
|
-
|
|
693
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) .slick-list {
|
|
694
|
+
margin-left: -24px;
|
|
695
|
+
margin-right: 0;
|
|
696
|
+
}
|
|
697
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) .slick-track {
|
|
698
|
+
padding-left: 16px;
|
|
699
|
+
}
|
|
700
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) .slick-slide {
|
|
701
|
+
padding: 0 8px;
|
|
691
702
|
}
|
|
692
703
|
}
|
|
@@ -269,15 +269,11 @@ const SliderBlock = (props) => {
|
|
|
269
269
|
lazyLoad,
|
|
270
270
|
accessibility: false,
|
|
271
271
|
};
|
|
272
|
-
return (react_1.default.createElement(
|
|
273
|
-
react_1.default.createElement(
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
renderNavigation())),
|
|
278
|
-
react_1.default.createElement("div", { className: b('slick-mobile') },
|
|
279
|
-
react_1.default.createElement("div", { className: b('mobile-scroll') }, disclosedChildren.map((child, index) => (react_1.default.createElement("div", { key: index, className: b('mobile-scroll-item') }, child)))),
|
|
280
|
-
react_1.default.createElement("div", { className: b('footer') }, renderDisclaimer()))));
|
|
272
|
+
return (react_1.default.createElement(OutsideClick_1.default, { onOutsideClick: isMobile ? unsetFocus : noop_1.default },
|
|
273
|
+
react_1.default.createElement(react_slick_1.default, Object.assign({}, settings), disclosedChildren),
|
|
274
|
+
react_1.default.createElement("div", { className: b('footer') },
|
|
275
|
+
renderDisclaimer(),
|
|
276
|
+
renderNavigation())));
|
|
281
277
|
};
|
|
282
278
|
return (react_1.default.createElement(StylesContext_1.StylesContext.Provider, { value: Object.assign(Object.assign({}, childStyles), { setStyles: setChildStyles }) },
|
|
283
279
|
react_1.default.createElement("div", { className: b({
|
|
@@ -34,7 +34,7 @@ export const HighlightTableBlock = ({ title, description, table, legend = [], co
|
|
|
34
34
|
if (!tableContentElem || !blockElem)
|
|
35
35
|
return () => { };
|
|
36
36
|
const updateSizes = debounce(() => {
|
|
37
|
-
const width = Math.max(
|
|
37
|
+
const width = Math.max(648, blockElem.clientWidth - 24 - 2); // 24 - padding, 2 - border
|
|
38
38
|
tableContentElem.style.setProperty('--block-width', `${width}px`);
|
|
39
39
|
});
|
|
40
40
|
updateSizes();
|
|
@@ -50,6 +50,14 @@ export const HighlightTableBlock = ({ title, description, table, legend = [], co
|
|
|
50
50
|
if (!tableElem || !scrollBar || !scrollThumb)
|
|
51
51
|
return () => { };
|
|
52
52
|
const updateProgress = debounce(() => {
|
|
53
|
+
if (tableElem.clientWidth === tableElem.scrollWidth) {
|
|
54
|
+
if (scrollBar.style.getPropertyValue('display') !== 'none') {
|
|
55
|
+
scrollBar.style.setProperty('display', `none`);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
else if (scrollBar.style.getPropertyValue('display') !== 'block') {
|
|
59
|
+
scrollBar.style.setProperty('display', `block`);
|
|
60
|
+
}
|
|
53
61
|
const scrollWidth = Math.round(scrollBar.clientWidth * (tableElem.clientWidth / tableElem.scrollWidth));
|
|
54
62
|
const scrollLeft = Math.round(scrollBar.clientWidth * (tableElem.scrollLeft / tableElem.scrollWidth));
|
|
55
63
|
scrollThumb.style.setProperty('transform', `translateX(${scrollLeft}px)`);
|
|
@@ -3,6 +3,16 @@ unpredictable css rules order in build */
|
|
|
3
3
|
.pc-reports-sections-block__title {
|
|
4
4
|
margin-bottom: 24px;
|
|
5
5
|
}
|
|
6
|
+
@media (min-width: 769px) {
|
|
7
|
+
.pc-reports-sections-block__wrap-sections.pc-AnimateBlock .pc-reports-sections-block__sections, .pc-AnimateBlock .pc-reports-sections-block__wrap-sections .pc-reports-sections-block__sections {
|
|
8
|
+
opacity: 0;
|
|
9
|
+
}
|
|
10
|
+
.pc-reports-sections-block__wrap-sections.pc-AnimateBlock.animate .pc-reports-sections-block__sections, .pc-AnimateBlock .pc-reports-sections-block__wrap-sections.animate .pc-reports-sections-block__sections {
|
|
11
|
+
opacity: 1;
|
|
12
|
+
transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
|
|
13
|
+
transition-delay: 0s;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
6
16
|
.pc-reports-sections-block__sections {
|
|
7
17
|
display: flex;
|
|
8
18
|
flex-direction: column;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useCallback, useContext, useMemo, useState } from 'react';
|
|
2
|
-
import { EmptyPlug, Title } from '../../components';
|
|
2
|
+
import { AnimateBlock, EmptyPlug, Title } from '../../components';
|
|
3
3
|
import FilterSelects from '../../components/Filters/FilterSelects/FilterSelects';
|
|
4
4
|
import { ReportsSectionsContext } from '../../context/reportsSectionsContext';
|
|
5
5
|
import { block } from '../../utils';
|
|
@@ -27,6 +27,7 @@ export const ReportsSectionsBlock = ({ title, typeKey, empty }) => {
|
|
|
27
27
|
return (React.createElement("div", { className: b() },
|
|
28
28
|
title && React.createElement(Title, { className: b('title'), title: titleProps, colSizes: titleColSizes }),
|
|
29
29
|
React.createElement(FilterSelects, { selects: selects, filters: localFilters, handleChange: handleChange }),
|
|
30
|
-
filteredItems.length ? (React.createElement(
|
|
30
|
+
filteredItems.length ? (React.createElement(AnimateBlock, { key: JSON.stringify(localFilters), className: b('wrap-sections'), animate: true },
|
|
31
|
+
React.createElement("div", { className: b('sections') }, filteredItems.map((item, index) => (React.createElement(Section, Object.assign({ key: index }, item))))))) : (React.createElement(EmptyPlug, { empty: empty, className: b('empty') }))));
|
|
31
32
|
};
|
|
32
33
|
export default ReportsSectionsBlock;
|
|
@@ -118,25 +118,6 @@ unpredictable css rules order in build */
|
|
|
118
118
|
.pc-SliderBlock .slick-arrow.slick-prev {
|
|
119
119
|
right: 42px;
|
|
120
120
|
}
|
|
121
|
-
.pc-SliderBlock__slick-mobile {
|
|
122
|
-
display: none;
|
|
123
|
-
}
|
|
124
|
-
.pc-SliderBlock__mobile-scroll {
|
|
125
|
-
display: flex;
|
|
126
|
-
margin: 0 -24px;
|
|
127
|
-
padding: 24px;
|
|
128
|
-
gap: 16px;
|
|
129
|
-
overflow-x: auto;
|
|
130
|
-
-webkit-overflow-scrolling: touch;
|
|
131
|
-
scrollbar-width: none;
|
|
132
|
-
}
|
|
133
|
-
.pc-SliderBlock__mobile-scroll::-webkit-scrollbar {
|
|
134
|
-
display: none;
|
|
135
|
-
}
|
|
136
|
-
.pc-SliderBlock__mobile-scroll-item {
|
|
137
|
-
flex: 0 0 auto;
|
|
138
|
-
width: 90%;
|
|
139
|
-
}
|
|
140
121
|
.pc-SliderBlock__header_no-description {
|
|
141
122
|
position: relative;
|
|
142
123
|
top: -3px;
|
|
@@ -672,6 +653,26 @@ unpredictable css rules order in build */
|
|
|
672
653
|
.pc-SliderBlock_type_header-card .slick-arrow.slick-prev {
|
|
673
654
|
left: 0;
|
|
674
655
|
}
|
|
656
|
+
@media (max-width: 577px) {
|
|
657
|
+
.pc-SliderBlock_type_header-card .slick-arrow {
|
|
658
|
+
display: none;
|
|
659
|
+
}
|
|
660
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-list {
|
|
661
|
+
margin-left: 0;
|
|
662
|
+
}
|
|
663
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-track {
|
|
664
|
+
padding-left: 0;
|
|
665
|
+
}
|
|
666
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-slide {
|
|
667
|
+
/* stylelint-disable declaration-no-important */
|
|
668
|
+
padding-right: 0 !important;
|
|
669
|
+
padding-left: 0 !important;
|
|
670
|
+
/* stylelint-enable declaration-no-important */
|
|
671
|
+
}
|
|
672
|
+
.pc-SliderBlock_type_header-card.pc-SliderBlock:not(.pc-SliderBlock_type_header-card_one-slide) .slick-slide:last-child {
|
|
673
|
+
padding-right: 0;
|
|
674
|
+
}
|
|
675
|
+
}
|
|
675
676
|
@media (max-width: 769px) {
|
|
676
677
|
.pc-SliderBlock__footer {
|
|
677
678
|
display: block;
|
|
@@ -683,10 +684,20 @@ unpredictable css rules order in build */
|
|
|
683
684
|
}
|
|
684
685
|
}
|
|
685
686
|
@media (max-width: 577px) {
|
|
686
|
-
.pc-
|
|
687
|
-
|
|
687
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) {
|
|
688
|
+
margin-left: -24px;
|
|
689
|
+
padding-left: 24px;
|
|
690
|
+
width: calc(100% + 48px);
|
|
691
|
+
overflow-x: auto;
|
|
688
692
|
}
|
|
689
|
-
.pc-
|
|
690
|
-
|
|
693
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) .slick-list {
|
|
694
|
+
margin-left: -24px;
|
|
695
|
+
margin-right: 0;
|
|
696
|
+
}
|
|
697
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) .slick-track {
|
|
698
|
+
padding-left: 16px;
|
|
699
|
+
}
|
|
700
|
+
.pc-SliderBlock:not(.pc-SliderBlock_one-slide) .slick-slide {
|
|
701
|
+
padding: 0 8px;
|
|
691
702
|
}
|
|
692
703
|
}
|
|
@@ -266,15 +266,11 @@ export const SliderBlock = (props) => {
|
|
|
266
266
|
lazyLoad,
|
|
267
267
|
accessibility: false,
|
|
268
268
|
};
|
|
269
|
-
return (React.createElement(
|
|
270
|
-
React.createElement(
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
renderNavigation())),
|
|
275
|
-
React.createElement("div", { className: b('slick-mobile') },
|
|
276
|
-
React.createElement("div", { className: b('mobile-scroll') }, disclosedChildren.map((child, index) => (React.createElement("div", { key: index, className: b('mobile-scroll-item') }, child)))),
|
|
277
|
-
React.createElement("div", { className: b('footer') }, renderDisclaimer()))));
|
|
269
|
+
return (React.createElement(OutsideClick, { onOutsideClick: isMobile ? unsetFocus : noop },
|
|
270
|
+
React.createElement(SlickSlider, Object.assign({}, settings), disclosedChildren),
|
|
271
|
+
React.createElement("div", { className: b('footer') },
|
|
272
|
+
renderDisclaimer(),
|
|
273
|
+
renderNavigation())));
|
|
278
274
|
};
|
|
279
275
|
return (React.createElement(StylesContext.Provider, { value: Object.assign(Object.assign({}, childStyles), { setStyles: setChildStyles }) },
|
|
280
276
|
React.createElement("div", { className: b({
|