@prom-ui/core 0.0.100 → 0.0.102-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Avatar/cjs/index.development.js +0 -2
- package/Avatar/cjs/index.development.v2.js +151 -0
- package/Avatar/cjs/index.production.js +1 -1
- package/Avatar/cjs/index.production.v2.js +1 -0
- package/Avatar/cjs/style.development.v2.css +1 -0
- package/Avatar/cjs/style.production.v2.css +1 -0
- package/Avatar/index.js +14 -2
- package/Avatar/package.json +1 -1
- package/Body/cjs/index.development.js +0 -2
- package/Body/cjs/index.development.v2.js +12 -0
- package/Body/cjs/index.production.js +1 -1
- package/Body/cjs/index.production.v2.js +1 -0
- package/Body/cjs/style.development.v2.css +1 -0
- package/Body/cjs/style.production.v2.css +1 -0
- package/Body/index.js +14 -2
- package/Body/package.json +1 -1
- package/Box/cjs/index.development.js +0 -2
- package/Box/cjs/index.development.v2.js +18 -0
- package/Box/cjs/index.production.js +1 -1
- package/Box/cjs/index.production.v2.js +1 -0
- package/Box/cjs/style.development.v2.css +1 -0
- package/Box/cjs/style.production.v2.css +1 -0
- package/Box/index.js +14 -2
- package/Box/package.json +1 -1
- package/Button/cjs/index.development.js +0 -2
- package/Button/cjs/index.development.v2.js +93 -0
- package/Button/cjs/index.production.js +1 -1
- package/Button/cjs/index.production.v2.js +1 -0
- package/Button/cjs/style.development.v2.css +1 -0
- package/Button/cjs/style.production.v2.css +1 -0
- package/Button/index.js +14 -2
- package/Button/package.json +1 -1
- package/ButtonPageUp/cjs/index.development.v2.js +174 -0
- package/ButtonPageUp/cjs/index.production.v2.js +1 -0
- package/ButtonPageUp/index.js +2 -2
- package/ButtonPageUp/package.json +1 -1
- package/Checkbox/cjs/index.development.js +0 -2
- package/Checkbox/cjs/index.development.v2.js +109 -0
- package/Checkbox/cjs/index.production.js +1 -1
- package/Checkbox/cjs/index.production.v2.js +1 -0
- package/Checkbox/cjs/style.development.v2.css +1 -0
- package/Checkbox/cjs/style.production.v2.css +1 -0
- package/Checkbox/index.js +14 -2
- package/Checkbox/package.json +1 -1
- package/Flex/cjs/index.development.js +0 -2
- package/Flex/cjs/index.development.v2.js +23 -0
- package/Flex/cjs/index.production.js +1 -1
- package/Flex/cjs/index.production.v2.js +1 -0
- package/Flex/cjs/style.development.v2.css +1 -0
- package/Flex/cjs/style.production.v2.css +1 -0
- package/Flex/index.js +14 -2
- package/Flex/package.json +1 -1
- package/Grid/cjs/index.development.js +0 -2
- package/Grid/cjs/index.development.v2.js +23 -0
- package/Grid/cjs/index.production.js +1 -1
- package/Grid/cjs/index.production.v2.js +1 -0
- package/Grid/cjs/style.development.v2.css +1 -0
- package/Grid/cjs/style.production.v2.css +1 -0
- package/Grid/index.js +14 -2
- package/Grid/package.json +1 -1
- package/Icon/cjs/index.development.js +0 -2
- package/Icon/cjs/index.development.v2.js +39 -0
- package/Icon/cjs/index.production.js +1 -1
- package/Icon/cjs/index.production.v2.js +1 -0
- package/Icon/cjs/style.development.v2.css +1 -0
- package/Icon/cjs/style.production.v2.css +1 -0
- package/Icon/index.js +14 -2
- package/Icon/package.json +1 -1
- package/Image/cjs/index.development.js +0 -2
- package/Image/cjs/index.development.v2.js +18 -0
- package/Image/cjs/index.production.js +1 -1
- package/Image/cjs/index.production.v2.js +1 -0
- package/Image/cjs/style.development.v2.css +1 -0
- package/Image/cjs/style.production.v2.css +1 -0
- package/Image/index.js +14 -2
- package/Image/package.json +1 -1
- package/ImageEmoji/cjs/index.development.v2.js +90 -0
- package/ImageEmoji/cjs/index.production.v2.js +1 -0
- package/ImageEmoji/index.js +2 -2
- package/ImageEmoji/package.json +1 -1
- package/Input/cjs/index.development.js +0 -2
- package/Input/cjs/index.development.v2.js +37 -0
- package/Input/cjs/index.production.js +1 -1
- package/Input/cjs/index.production.v2.js +1 -0
- package/Input/cjs/style.development.v2.css +1 -0
- package/Input/cjs/style.production.v2.css +1 -0
- package/Input/index.js +14 -2
- package/Input/package.json +1 -1
- package/KeyPress/cjs/index.development.v2.js +56 -0
- package/KeyPress/cjs/index.production.v2.js +1 -0
- package/KeyPress/index.js +2 -2
- package/KeyPress/package.json +1 -1
- package/Line/cjs/index.development.js +0 -2
- package/Line/cjs/index.development.v2.js +18 -0
- package/Line/cjs/index.production.js +1 -1
- package/Line/cjs/index.production.v2.js +1 -0
- package/Line/cjs/style.development.v2.css +1 -0
- package/Line/cjs/style.production.v2.css +1 -0
- package/Line/index.js +14 -2
- package/Line/package.json +1 -1
- package/Link/cjs/index.development.js +0 -2
- package/Link/cjs/index.development.v2.js +20 -0
- package/Link/cjs/index.production.js +1 -1
- package/Link/cjs/index.production.v2.js +1 -0
- package/Link/cjs/style.development.v2.css +1 -0
- package/Link/cjs/style.production.v2.css +1 -0
- package/Link/index.js +14 -2
- package/Link/package.json +1 -1
- package/List/cjs/index.development.js +0 -2
- package/List/cjs/index.development.v2.js +23 -0
- package/List/cjs/index.production.js +1 -1
- package/List/cjs/index.production.v2.js +1 -0
- package/List/cjs/style.development.v2.css +1 -0
- package/List/cjs/style.production.v2.css +1 -0
- package/List/index.js +14 -2
- package/List/package.json +1 -1
- package/Media/cjs/index.development.v2.js +98 -0
- package/Media/cjs/index.production.v2.js +1 -0
- package/Media/index.js +2 -2
- package/Media/package.json +1 -1
- package/OutsideClick/cjs/index.development.v2.js +84 -0
- package/OutsideClick/cjs/index.production.v2.js +1 -0
- package/OutsideClick/index.js +2 -2
- package/OutsideClick/package.json +1 -1
- package/Overlay/cjs/index.development.js +0 -2
- package/Overlay/cjs/index.development.v2.js +473 -0
- package/Overlay/cjs/index.production.js +1 -1
- package/Overlay/cjs/index.production.v2.js +1 -0
- package/Overlay/cjs/style.development.v2.css +1 -0
- package/Overlay/cjs/style.production.v2.css +1 -0
- package/Overlay/index.js +14 -2
- package/Overlay/package.json +1 -1
- package/Picture/cjs/index.development.js +0 -2
- package/Picture/cjs/index.development.v2.js +23 -0
- package/Picture/cjs/index.production.js +1 -1
- package/Picture/cjs/index.production.v2.js +1 -0
- package/Picture/cjs/style.development.v2.css +1 -0
- package/Picture/cjs/style.production.v2.css +1 -0
- package/Picture/index.js +14 -2
- package/Picture/package.json +1 -1
- package/PortableOverlay/cjs/index.development.js +0 -2
- package/PortableOverlay/cjs/index.development.v2.js +109 -0
- package/PortableOverlay/cjs/index.production.js +1 -1
- package/PortableOverlay/cjs/index.production.v2.js +1 -0
- package/PortableOverlay/cjs/style.development.v2.css +1 -0
- package/PortableOverlay/cjs/style.production.v2.css +1 -0
- package/PortableOverlay/index.js +14 -2
- package/PortableOverlay/package.json +1 -1
- package/Portal/cjs/index.development.v2.js +57 -0
- package/Portal/cjs/index.production.v2.js +1 -0
- package/Portal/index.js +2 -2
- package/Portal/package.json +1 -1
- package/QRCode/cjs/index.development.js +0 -2
- package/QRCode/cjs/index.development.v2.js +50 -0
- package/QRCode/cjs/index.production.js +1 -1
- package/QRCode/cjs/index.production.v2.js +1 -0
- package/QRCode/cjs/style.development.v2.css +1 -0
- package/QRCode/cjs/style.production.v2.css +1 -0
- package/QRCode/index.js +14 -2
- package/QRCode/package.json +1 -1
- package/Rating/cjs/index.development.js +0 -2
- package/Rating/cjs/index.development.v2.js +105 -0
- package/Rating/cjs/index.production.js +1 -1
- package/Rating/cjs/index.production.v2.js +1 -0
- package/Rating/cjs/style.development.v2.css +1 -0
- package/Rating/cjs/style.production.v2.css +1 -0
- package/Rating/index.js +14 -2
- package/Rating/package.json +1 -1
- package/SafeQuery/cjs/index.development.js +0 -2
- package/SafeQuery/cjs/index.development.v2.js +179 -0
- package/SafeQuery/cjs/index.production.js +1 -1
- package/SafeQuery/cjs/index.production.v2.js +1 -0
- package/SafeQuery/cjs/style.development.v2.css +1 -0
- package/SafeQuery/cjs/style.production.v2.css +1 -0
- package/SafeQuery/index.js +14 -2
- package/SafeQuery/package.json +1 -1
- package/Scroll/cjs/index.development.js +0 -2
- package/Scroll/cjs/index.development.v2.js +38 -0
- package/Scroll/cjs/index.production.js +1 -1
- package/Scroll/cjs/index.production.v2.js +1 -0
- package/Scroll/cjs/style.development.v2.css +1 -0
- package/Scroll/cjs/style.production.v2.css +1 -0
- package/Scroll/index.js +14 -2
- package/Scroll/package.json +1 -1
- package/ScrollControls/cjs/index.development.js +0 -2
- package/ScrollControls/cjs/index.development.v2.js +241 -0
- package/ScrollControls/cjs/index.production.js +1 -1
- package/ScrollControls/cjs/index.production.v2.js +1 -0
- package/ScrollControls/cjs/style.development.v2.css +1 -0
- package/ScrollControls/cjs/style.production.v2.css +1 -0
- package/ScrollControls/index.js +14 -2
- package/ScrollControls/package.json +1 -1
- package/SideOverlay/cjs/index.development.js +0 -2
- package/SideOverlay/cjs/index.development.v2.js +208 -0
- package/SideOverlay/cjs/index.production.js +1 -1
- package/SideOverlay/cjs/index.production.v2.js +1 -0
- package/SideOverlay/cjs/style.development.v2.css +1 -0
- package/SideOverlay/cjs/style.production.v2.css +1 -0
- package/SideOverlay/index.js +14 -2
- package/SideOverlay/package.json +1 -1
- package/SimpleSlider/cjs/index.development.js +0 -2
- package/SimpleSlider/cjs/index.development.v2.js +433 -0
- package/SimpleSlider/cjs/index.production.js +1 -1
- package/SimpleSlider/cjs/index.production.v2.js +1 -0
- package/SimpleSlider/cjs/style.development.v2.css +1 -0
- package/SimpleSlider/cjs/style.production.v2.css +1 -0
- package/SimpleSlider/index.js +14 -2
- package/SimpleSlider/package.json +1 -1
- package/Skeleton/cjs/index.development.js +0 -2
- package/Skeleton/cjs/index.development.v2.js +101 -0
- package/Skeleton/cjs/index.production.js +1 -1
- package/Skeleton/cjs/index.production.v2.js +1 -0
- package/Skeleton/cjs/style.development.v2.css +1 -0
- package/Skeleton/cjs/style.production.v2.css +1 -0
- package/Skeleton/index.js +14 -2
- package/Skeleton/package.json +1 -1
- package/Spinner/cjs/index.development.js +0 -2
- package/Spinner/cjs/index.development.v2.js +83 -0
- package/Spinner/cjs/index.production.js +1 -1
- package/Spinner/cjs/index.production.v2.js +1 -0
- package/Spinner/cjs/style.development.v2.css +1 -0
- package/Spinner/cjs/style.production.v2.css +1 -0
- package/Spinner/index.d.ts +5 -0
- package/Spinner/index.js +14 -2
- package/Spinner/package.json +1 -1
- package/Text/cjs/index.development.js +1 -3
- package/Text/cjs/index.development.v2.js +18 -0
- package/Text/cjs/index.production.js +1 -1
- package/Text/cjs/index.production.v2.js +1 -0
- package/Text/cjs/style.development.css +1 -1
- package/Text/cjs/style.development.v2.css +1 -0
- package/Text/cjs/style.production.css +1 -1
- package/Text/cjs/style.production.v2.css +1 -0
- package/Text/index.js +14 -2
- package/Text/package.json +1 -1
- package/TextEmoji/cjs/index.development.v2.js +94 -0
- package/TextEmoji/cjs/index.production.v2.js +1 -0
- package/TextEmoji/index.js +2 -2
- package/TextEmoji/package.json +1 -1
- package/Tooltip/cjs/index.development.js +0 -2
- package/Tooltip/cjs/index.development.v2.js +149 -0
- package/Tooltip/cjs/index.production.js +1 -1
- package/Tooltip/cjs/index.production.v2.js +1 -0
- package/Tooltip/cjs/style.development.v2.css +1 -0
- package/Tooltip/cjs/style.production.v2.css +1 -0
- package/Tooltip/index.js +14 -2
- package/Tooltip/package.json +1 -1
- package/Tumbler/cjs/index.development.js +0 -2
- package/Tumbler/cjs/index.development.v2.js +108 -0
- package/Tumbler/cjs/index.production.js +1 -1
- package/Tumbler/cjs/index.production.v2.js +1 -0
- package/Tumbler/cjs/style.development.v2.css +1 -0
- package/Tumbler/cjs/style.production.v2.css +1 -0
- package/Tumbler/index.js +14 -2
- package/Tumbler/package.json +1 -1
- package/package.json +4 -4
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var React = require('react');
|
|
6
|
+
var classNames = require('classnames');
|
|
7
|
+
var ttag = require('ttag');
|
|
8
|
+
var Button = require('@prom-ui/core/Button');
|
|
9
|
+
var Icon = require('@prom-ui/core/Icon');
|
|
10
|
+
var Left = require('@prom-ui/icons/Left');
|
|
11
|
+
var Right = require('@prom-ui/icons/Right');
|
|
12
|
+
|
|
13
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
14
|
+
|
|
15
|
+
function _interopNamespace(e) {
|
|
16
|
+
if (e && e.__esModule) return e;
|
|
17
|
+
var n = Object.create(null);
|
|
18
|
+
if (e) {
|
|
19
|
+
Object.keys(e).forEach(function (k) {
|
|
20
|
+
if (k !== 'default') {
|
|
21
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
22
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
23
|
+
enumerable: true,
|
|
24
|
+
get: function () { return e[k]; }
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
n["default"] = e;
|
|
30
|
+
return Object.freeze(n);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
34
|
+
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
35
|
+
var classNames__default = /*#__PURE__*/_interopDefaultLegacy(classNames);
|
|
36
|
+
|
|
37
|
+
/******************************************************************************
|
|
38
|
+
Copyright (c) Microsoft Corporation.
|
|
39
|
+
|
|
40
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
41
|
+
purpose with or without fee is hereby granted.
|
|
42
|
+
|
|
43
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
44
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
45
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
46
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
47
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
48
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
49
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
50
|
+
***************************************************************************** */
|
|
51
|
+
|
|
52
|
+
var __assign = function() {
|
|
53
|
+
__assign = Object.assign || function __assign(t) {
|
|
54
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
55
|
+
s = arguments[i];
|
|
56
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
57
|
+
}
|
|
58
|
+
return t;
|
|
59
|
+
};
|
|
60
|
+
return __assign.apply(this, arguments);
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
function __rest(s, e) {
|
|
64
|
+
var t = {};
|
|
65
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
66
|
+
t[p] = s[p];
|
|
67
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
68
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
69
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
70
|
+
t[p[i]] = s[p[i]];
|
|
71
|
+
}
|
|
72
|
+
return t;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function __makeTemplateObject(cooked, raw) {
|
|
76
|
+
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
77
|
+
return cooked;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
var css = {"root":"ScrollControls__root___5xFyd","buttonCommon":"ScrollControls__buttonCommon___kQ3-r","prev":"ScrollControls__prev___YhapL ScrollControls__buttonCommon___kQ3-r","next":"ScrollControls__next___yCCvv ScrollControls__buttonCommon___kQ3-r","icon":"ScrollControls__icon___z7X7-","showOnHover":"ScrollControls__showOnHover___PVtmJ","hideOnDisabled":"ScrollControls__hideOnDisabled___hwEsJ"};
|
|
81
|
+
|
|
82
|
+
var DIRECTION_NEXT = 1;
|
|
83
|
+
var DIRECTION_PREV = -1;
|
|
84
|
+
var CONTROLS_UPDATE_DELAY = 100;
|
|
85
|
+
var ScrollControlsButton = function (_a) {
|
|
86
|
+
var _b, _c;
|
|
87
|
+
|
|
88
|
+
var scrollRef = _a.scrollRef,
|
|
89
|
+
_d = _a.hideOnDisabled,
|
|
90
|
+
hideOnDisabled = _d === void 0 ? false : _d,
|
|
91
|
+
_e = _a.isActive,
|
|
92
|
+
isActive = _e === void 0 ? true : _e,
|
|
93
|
+
onClickNext = _a.onClickNext,
|
|
94
|
+
onClickPrev = _a.onClickPrev,
|
|
95
|
+
zIndex = _a.zIndex,
|
|
96
|
+
_f = _a.theme,
|
|
97
|
+
theme = _f === void 0 ? 'white' : _f,
|
|
98
|
+
children = _a.children;
|
|
99
|
+
var updateControlsTimer = React.useRef(null);
|
|
100
|
+
|
|
101
|
+
var _g = React.useState({
|
|
102
|
+
prev: false,
|
|
103
|
+
next: false
|
|
104
|
+
}),
|
|
105
|
+
controlsVisible = _g[0],
|
|
106
|
+
setControlsVisible = _g[1];
|
|
107
|
+
|
|
108
|
+
var updateControlsVisible = function (nextScrollLeft) {
|
|
109
|
+
var _a = scrollRef.current,
|
|
110
|
+
scrollLeft = _a.scrollLeft,
|
|
111
|
+
scrollWidth = _a.scrollWidth,
|
|
112
|
+
clientWidth = _a.clientWidth;
|
|
113
|
+
var currentScrollLeft = (Number.isInteger(nextScrollLeft) ? nextScrollLeft : scrollLeft) || 0;
|
|
114
|
+
setControlsVisible({
|
|
115
|
+
prev: currentScrollLeft > 1,
|
|
116
|
+
next: currentScrollLeft < scrollWidth - clientWidth
|
|
117
|
+
});
|
|
118
|
+
};
|
|
119
|
+
|
|
120
|
+
var updateScrollLeft = function (direction) {
|
|
121
|
+
var _a = scrollRef.current,
|
|
122
|
+
scrollLeft = _a.scrollLeft,
|
|
123
|
+
clientWidth = _a.clientWidth;
|
|
124
|
+
var offset = clientWidth * direction;
|
|
125
|
+
updateControlsVisible(scrollLeft + offset);
|
|
126
|
+
requestAnimationFrame(function () {
|
|
127
|
+
if (scrollRef.current) {
|
|
128
|
+
scrollRef.current.scrollBy({
|
|
129
|
+
left: offset,
|
|
130
|
+
behavior: 'smooth'
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
};
|
|
135
|
+
|
|
136
|
+
var handleOnClickPrev = function () {
|
|
137
|
+
if (typeof onClickPrev === 'function') {
|
|
138
|
+
onClickPrev();
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
updateScrollLeft(DIRECTION_PREV);
|
|
142
|
+
};
|
|
143
|
+
|
|
144
|
+
var handleOnClickNext = function () {
|
|
145
|
+
if (typeof onClickNext === 'function') {
|
|
146
|
+
onClickNext();
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
updateScrollLeft(DIRECTION_NEXT);
|
|
150
|
+
};
|
|
151
|
+
|
|
152
|
+
var handleOnScroll = function () {
|
|
153
|
+
clearTimeout(updateControlsTimer.current || 0);
|
|
154
|
+
updateControlsTimer.current = setTimeout(updateControlsVisible, CONTROLS_UPDATE_DELAY);
|
|
155
|
+
};
|
|
156
|
+
|
|
157
|
+
React.useEffect(function () {
|
|
158
|
+
if (scrollRef.current && isActive) {
|
|
159
|
+
updateControlsVisible();
|
|
160
|
+
scrollRef.current.addEventListener('scroll', handleOnScroll);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
return function () {
|
|
164
|
+
if (scrollRef.current && isActive) {
|
|
165
|
+
scrollRef.current.removeEventListener('scroll', handleOnScroll);
|
|
166
|
+
}
|
|
167
|
+
};
|
|
168
|
+
}, [isActive, children]);
|
|
169
|
+
|
|
170
|
+
if (isActive && (controlsVisible.prev || controlsVisible.next)) {
|
|
171
|
+
return React__default["default"].createElement(React__default["default"].Fragment, null, React__default["default"].createElement(Button.Button, {
|
|
172
|
+
"button-theme": theme,
|
|
173
|
+
"button-round": 'xs',
|
|
174
|
+
"button-weight": 'normal',
|
|
175
|
+
"button-padding": 'none xxs',
|
|
176
|
+
className: classNames__default["default"](css.prev, (_b = {}, _b[css.hideOnDisabled] = hideOnDisabled, _b)),
|
|
177
|
+
onClick: handleOnClickPrev,
|
|
178
|
+
style: {
|
|
179
|
+
zIndex: zIndex
|
|
180
|
+
},
|
|
181
|
+
disabled: !controlsVisible.prev,
|
|
182
|
+
title: ttag.t(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\u041D\u0430\u0437\u0430\u0434"], ["\u041D\u0430\u0437\u0430\u0434"])))
|
|
183
|
+
}, React__default["default"].createElement(Icon.Icon, {
|
|
184
|
+
className: css.icon,
|
|
185
|
+
"icon-as": Left.Left
|
|
186
|
+
})), React__default["default"].createElement(Button.Button, {
|
|
187
|
+
"button-theme": theme,
|
|
188
|
+
"button-round": 'xs',
|
|
189
|
+
"button-weight": 'normal',
|
|
190
|
+
"button-padding": 'none xxs',
|
|
191
|
+
className: classNames__default["default"](css.next, (_c = {}, _c[css.hideOnDisabled] = hideOnDisabled, _c)),
|
|
192
|
+
onClick: handleOnClickNext,
|
|
193
|
+
style: {
|
|
194
|
+
zIndex: zIndex
|
|
195
|
+
},
|
|
196
|
+
disabled: !controlsVisible.next,
|
|
197
|
+
title: ttag.t(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\u0414\u0430\u043B\u0435\u0435"], ["\u0414\u0430\u043B\u0435\u0435"])))
|
|
198
|
+
}, React__default["default"].createElement(Icon.Icon, {
|
|
199
|
+
className: css.icon,
|
|
200
|
+
"icon-as": Right.Right
|
|
201
|
+
})));
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
return null;
|
|
205
|
+
};
|
|
206
|
+
var templateObject_1, templateObject_2;
|
|
207
|
+
|
|
208
|
+
var ScrollControls = React__namespace.forwardRef(function (_a, ref) {
|
|
209
|
+
var _b;
|
|
210
|
+
|
|
211
|
+
var children = _a.children,
|
|
212
|
+
className = _a.className,
|
|
213
|
+
_c = _a.hideOnDisabled,
|
|
214
|
+
hideOnDisabled = _c === void 0 ? false : _c,
|
|
215
|
+
_d = _a.isActive,
|
|
216
|
+
isActive = _d === void 0 ? true : _d,
|
|
217
|
+
onClickNext = _a.onClickNext,
|
|
218
|
+
onClickPrev = _a.onClickPrev,
|
|
219
|
+
_e = _a.showOnHover,
|
|
220
|
+
showOnHover = _e === void 0 ? false : _e,
|
|
221
|
+
zIndex = _a.zIndex,
|
|
222
|
+
_f = _a.theme,
|
|
223
|
+
theme = _f === void 0 ? 'white' : _f,
|
|
224
|
+
props = __rest(_a, ["children", "className", "hideOnDisabled", "isActive", "onClickNext", "onClickPrev", "showOnHover", "zIndex", "theme"]);
|
|
225
|
+
|
|
226
|
+
var scrollRef = React__namespace.useRef(null);
|
|
227
|
+
return React__namespace.createElement("div", __assign({
|
|
228
|
+
ref: ref,
|
|
229
|
+
className: classNames__default["default"](css.root, className, (_b = {}, _b[css.showOnHover] = showOnHover, _b))
|
|
230
|
+
}, props), children(scrollRef), React__namespace.createElement(ScrollControlsButton, {
|
|
231
|
+
scrollRef: scrollRef,
|
|
232
|
+
hideOnDisabled: hideOnDisabled,
|
|
233
|
+
isActive: isActive,
|
|
234
|
+
onClickNext: onClickNext,
|
|
235
|
+
onClickPrev: onClickPrev,
|
|
236
|
+
zIndex: zIndex,
|
|
237
|
+
theme: theme
|
|
238
|
+
}, children));
|
|
239
|
+
});
|
|
240
|
+
|
|
241
|
+
exports.ScrollControls = ScrollControls;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("classnames"),r=require("ttag"),n=require("@prom-ui/core/Button"),o=require("@prom-ui/core/Icon"),i=require("@prom-ui/icons/Left"),c=require("@prom-ui/icons/Right");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function u(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}var a=l(e),s=u(e),f=l(t),d=function(){return d=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},d.apply(this,arguments)};function v(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var m,p
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("classnames"),r=require("ttag"),n=require("@prom-ui/core/Button"),o=require("@prom-ui/core/Icon"),i=require("@prom-ui/icons/Left"),c=require("@prom-ui/icons/Right");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function u(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}var a=l(e),s=u(e),f=l(t),d=function(){return d=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},d.apply(this,arguments)};function v(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var m,b,p="mOlOq",h="cF2KB rZcyK",O="_9B-9g rZcyK",y="lzBzL",x="StbVV",g="IONkE",j=function(t){var l,u,s=t.scrollRef,d=t.hideOnDisabled,p=void 0!==d&&d,x=t.isActive,j=void 0===x||x,w=t.onClickNext,E=t.onClickPrev,N=t.zIndex,P=t.theme,k=void 0===P?"white":P,I=t.children,C=e.useRef(null),q=e.useState({prev:!1,next:!1}),z=q[0],B=q[1],L=function(e){var t=s.current,r=t.scrollLeft,n=t.scrollWidth,o=t.clientWidth,i=(Number.isInteger(e)?e:r)||0;B({prev:i>1,next:i<n-o})},R=function(e){var t=s.current,r=t.scrollLeft,n=t.clientWidth*e;L(r+n),requestAnimationFrame((function(){s.current&&s.current.scrollBy({left:n,behavior:"smooth"})}))},A=function(){clearTimeout(C.current||0),C.current=setTimeout(L,100)};return e.useEffect((function(){return s.current&&j&&(L(),s.current.addEventListener("scroll",A)),function(){s.current&&j&&s.current.removeEventListener("scroll",A)}}),[j,I]),j&&(z.prev||z.next)?a.default.createElement(a.default.Fragment,null,a.default.createElement(n.Button,{"button-theme":k,"button-round":"xs","button-weight":"normal","button-padding":"none xxs",className:f.default(h,(l={},l[g]=p,l)),onClick:function(){"function"==typeof E&&E(),R(-1)},style:{zIndex:N},disabled:!z.prev,title:r.t(m||(m=v(["Назад"],["Назад"])))},a.default.createElement(o.Icon,{className:y,"icon-as":i.Left})),a.default.createElement(n.Button,{"button-theme":k,"button-round":"xs","button-weight":"normal","button-padding":"none xxs",className:f.default(O,(u={},u[g]=p,u)),onClick:function(){"function"==typeof w&&w(),R(1)},style:{zIndex:N},disabled:!z.next,title:r.t(b||(b=v(["Далее"],["Далее"])))},a.default.createElement(o.Icon,{className:y,"icon-as":c.Right}))):null},w=s.forwardRef((function(e,t){var r,n=e.children,o=e.className,i=e.hideOnDisabled,c=void 0!==i&&i,l=e.isActive,u=void 0===l||l,a=e.onClickNext,v=e.onClickPrev,m=e.showOnHover,b=void 0!==m&&m,h=e.zIndex,O=e.theme,y=void 0===O?"white":O,g=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}(e,["children","className","hideOnDisabled","isActive","onClickNext","onClickPrev","showOnHover","zIndex","theme"]),w=s.useRef(null);return s.createElement("div",d({ref:t,className:f.default(p,o,(r={},r[x]=b,r))},g),n(w),s.createElement(j,{scrollRef:w,hideOnDisabled:c,isActive:u,onClickNext:a,onClickPrev:v,zIndex:h,theme:y},n))}));exports.ScrollControls=w;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("classnames"),r=require("ttag"),n=require("@prom-ui/core/Button"),o=require("@prom-ui/core/Icon"),i=require("@prom-ui/icons/Left"),c=require("@prom-ui/icons/Right");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function u(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}var a=l(e),s=u(e),f=l(t),d=function(){return d=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},d.apply(this,arguments)};function v(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var m,p,b="_5xFyd",h="YhapL kQ3-r",O="yCCvv kQ3-r",y="z7X7-",x="PVtmJ",g="hwEsJ",j=function(t){var l,u,s=t.scrollRef,d=t.hideOnDisabled,b=void 0!==d&&d,x=t.isActive,j=void 0===x||x,w=t.onClickNext,P=t.onClickPrev,k=t.zIndex,C=t.theme,E=void 0===C?"white":C,N=t.children,I=e.useRef(null),q=e.useState({prev:!1,next:!1}),z=q[0],L=q[1],R=function(e){var t=s.current,r=t.scrollLeft,n=t.scrollWidth,o=t.clientWidth,i=(Number.isInteger(e)?e:r)||0;L({prev:i>1,next:i<n-o})},A=function(e){var t=s.current,r=t.scrollLeft,n=t.clientWidth*e;R(r+n),requestAnimationFrame((function(){s.current&&s.current.scrollBy({left:n,behavior:"smooth"})}))},D=function(){clearTimeout(I.current||0),I.current=setTimeout(R,100)};return e.useEffect((function(){return s.current&&j&&(R(),s.current.addEventListener("scroll",D)),function(){s.current&&j&&s.current.removeEventListener("scroll",D)}}),[j,N]),j&&(z.prev||z.next)?a.default.createElement(a.default.Fragment,null,a.default.createElement(n.Button,{"button-theme":E,"button-round":"xs","button-weight":"normal","button-padding":"none xxs",className:f.default(h,(l={},l[g]=b,l)),onClick:function(){"function"==typeof P&&P(),A(-1)},style:{zIndex:k},disabled:!z.prev,title:r.t(m||(m=v(["Назад"],["Назад"])))},a.default.createElement(o.Icon,{className:y,"icon-as":i.Left})),a.default.createElement(n.Button,{"button-theme":E,"button-round":"xs","button-weight":"normal","button-padding":"none xxs",className:f.default(O,(u={},u[g]=b,u)),onClick:function(){"function"==typeof w&&w(),A(1)},style:{zIndex:k},disabled:!z.next,title:r.t(p||(p=v(["Далее"],["Далее"])))},a.default.createElement(o.Icon,{className:y,"icon-as":c.Right}))):null},w=s.forwardRef((function(e,t){var r,n=e.children,o=e.className,i=e.hideOnDisabled,c=void 0!==i&&i,l=e.isActive,u=void 0===l||l,a=e.onClickNext,v=e.onClickPrev,m=e.showOnHover,p=void 0!==m&&m,h=e.zIndex,O=e.theme,y=void 0===O?"white":O,g=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}(e,["children","className","hideOnDisabled","isActive","onClickNext","onClickPrev","showOnHover","zIndex","theme"]),w=s.useRef(null);return s.createElement("div",d({ref:t,className:f.default(b,o,(r={},r[x]=p,r))},g),n(w),s.createElement(j,{scrollRef:w,hideOnDisabled:c,isActive:u,onClickNext:a,onClickPrev:v,zIndex:h,theme:y},n))}));exports.ScrollControls=w;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ScrollControls__root___5xFyd{position:relative;overflow:hidden}.ScrollControls__buttonCommon___kQ3-r{position:absolute;top:50%;transform:translateY(-50%);border:0;box-shadow:0 0 10px rgba(0,0,0,.08);height:66px;max-width:30px;max-height:50%;min-height:24px}.ScrollControls__buttonCommon___kQ3-r:disabled{opacity:.3;pointer-events:auto}.ScrollControls__buttonCommon___kQ3-r:active{background:var(--black-200)}.ScrollControls__prev___YhapL{left:0;margin-left:var(--pds-spacing-xs)}.ScrollControls__next___yCCvv{right:0;margin-right:var(--pds-spacing-xs)}.ScrollControls__icon___z7X7-{display:block;width:auto;height:24px;fill:currentColor;max-height:80%}.ScrollControls__showOnHover___PVtmJ .ScrollControls__next___yCCvv{right:-40px}.ScrollControls__showOnHover___PVtmJ .ScrollControls__prev___YhapL{left:-40px}.ScrollControls__hideOnDisabled___hwEsJ:disabled{opacity:0;pointer-events:none;visibility:hidden}@media (hover:hover){.ScrollControls__showOnHover___PVtmJ:hover .ScrollControls__next___yCCvv{right:0}.ScrollControls__showOnHover___PVtmJ:hover .ScrollControls__prev___YhapL{left:0}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._5xFyd{position:relative;overflow:hidden}.kQ3-r{position:absolute;top:50%;transform:translateY(-50%);border:0;box-shadow:0 0 10px rgba(0,0,0,.08);height:66px;max-width:30px;max-height:50%;min-height:24px}.kQ3-r:disabled{opacity:.3;pointer-events:auto}.kQ3-r:active{background:var(--black-200)}.YhapL{left:0;margin-left:var(--pds-spacing-xs)}.yCCvv{right:0;margin-right:var(--pds-spacing-xs)}.z7X7-{display:block;width:auto;height:24px;fill:currentColor;max-height:80%}.PVtmJ .yCCvv{right:-40px}.PVtmJ .YhapL{left:-40px}.hwEsJ:disabled{opacity:0;pointer-events:none;visibility:hidden}@media (hover:hover){.PVtmJ:hover .yCCvv{right:0}.PVtmJ:hover .YhapL{left:0}}
|
package/ScrollControls/index.js
CHANGED
|
@@ -1,7 +1,19 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
if (process.env.NODE_ENV === 'production') {
|
|
4
|
-
|
|
4
|
+
if (process.env.PROM_UI_CSS_HASH === 'v2') {
|
|
5
|
+
module.exports = require('./cjs/index.production.v2.js');
|
|
6
|
+
require('./cjs/style.production.v2.js');
|
|
7
|
+
} else {
|
|
8
|
+
module.exports = require('./cjs/index.production.js');
|
|
9
|
+
require('./cjs/style.production.js');
|
|
10
|
+
}
|
|
5
11
|
} else {
|
|
6
|
-
|
|
12
|
+
if (process.env.PROM_UI_CSS_HASH === 'v2') {
|
|
13
|
+
module.exports = require('./cjs/index.development.v2.js');
|
|
14
|
+
require('./cjs/style.development.v2.js');
|
|
15
|
+
} else {
|
|
16
|
+
module.exports = require('./cjs/index.development.js');
|
|
17
|
+
require('./cjs/style.development.js');
|
|
18
|
+
}
|
|
7
19
|
}
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var React = require('react');
|
|
6
|
+
var ttag = require('ttag');
|
|
7
|
+
var ScrollLock = require('react-scrolllock');
|
|
8
|
+
var Portal = require('@prom-ui/core/Portal');
|
|
9
|
+
var KeyPress = require('@prom-ui/core/KeyPress');
|
|
10
|
+
var evokit = require('evokit');
|
|
11
|
+
var reactTransitionGroup = require('react-transition-group');
|
|
12
|
+
|
|
13
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
14
|
+
|
|
15
|
+
function _interopNamespace(e) {
|
|
16
|
+
if (e && e.__esModule) return e;
|
|
17
|
+
var n = Object.create(null);
|
|
18
|
+
if (e) {
|
|
19
|
+
Object.keys(e).forEach(function (k) {
|
|
20
|
+
if (k !== 'default') {
|
|
21
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
22
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
23
|
+
enumerable: true,
|
|
24
|
+
get: function () { return e[k]; }
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
n["default"] = e;
|
|
30
|
+
return Object.freeze(n);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
34
|
+
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
35
|
+
var ScrollLock__default = /*#__PURE__*/_interopDefaultLegacy(ScrollLock);
|
|
36
|
+
|
|
37
|
+
/******************************************************************************
|
|
38
|
+
Copyright (c) Microsoft Corporation.
|
|
39
|
+
|
|
40
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
41
|
+
purpose with or without fee is hereby granted.
|
|
42
|
+
|
|
43
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
44
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
45
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
46
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
47
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
48
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
49
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
50
|
+
***************************************************************************** */
|
|
51
|
+
|
|
52
|
+
var __assign = function() {
|
|
53
|
+
__assign = Object.assign || function __assign(t) {
|
|
54
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
55
|
+
s = arguments[i];
|
|
56
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
57
|
+
}
|
|
58
|
+
return t;
|
|
59
|
+
};
|
|
60
|
+
return __assign.apply(this, arguments);
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
function __rest(s, e) {
|
|
64
|
+
var t = {};
|
|
65
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
66
|
+
t[p] = s[p];
|
|
67
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
68
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
69
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
70
|
+
t[p[i]] = s[p[i]];
|
|
71
|
+
}
|
|
72
|
+
return t;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function __makeTemplateObject(cooked, raw) {
|
|
76
|
+
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
77
|
+
return cooked;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
var css = {"root":"SideOverlay__root___0hSa2","backdrop":"SideOverlay__backdrop___wUZLN","popup":"SideOverlay__popup___Ulqfh","content":"SideOverlay__content___N1Cdb","close":"SideOverlay__close___D-QIP","popup_placement_top":"SideOverlay__popup_placement_top___qJTjO","popup_placement_bottom":"SideOverlay__popup_placement_bottom___TDEZ7","popup_placement_right":"SideOverlay__popup_placement_right___xZVWW","popup_placement_left":"SideOverlay__popup_placement_left___ywgfV","enter":"SideOverlay__enter___5IZPy","exit":"SideOverlay__exit___N9pJ7","enterActive":"SideOverlay__enterActive___SiX-q","exitActive":"SideOverlay__exitActive___oRVo0"};
|
|
81
|
+
|
|
82
|
+
var BLOCKS_PRESET = {
|
|
83
|
+
css: css,
|
|
84
|
+
b: ''
|
|
85
|
+
};
|
|
86
|
+
var Root = evokit.createBlock('div', 'root', [], BLOCKS_PRESET);
|
|
87
|
+
var Backdrop = evokit.createBlock('div', 'backdrop', [], BLOCKS_PRESET);
|
|
88
|
+
var Popup = evokit.createBlock('div', 'popup', ['placement'], BLOCKS_PRESET);
|
|
89
|
+
var Content = evokit.createBlock('div', 'content', [], BLOCKS_PRESET);
|
|
90
|
+
var Close = evokit.createBlock('button', 'close', [], BLOCKS_PRESET);
|
|
91
|
+
var Animate = function (_a) {
|
|
92
|
+
var _b = _a.open,
|
|
93
|
+
open = _b === void 0 ? false : _b,
|
|
94
|
+
children = _a.children,
|
|
95
|
+
_c = _a.enabled,
|
|
96
|
+
enabled = _c === void 0 ? true : _c,
|
|
97
|
+
onEnter = _a.onEnter;
|
|
98
|
+
return React__default["default"].createElement(reactTransitionGroup.CSSTransition, {
|
|
99
|
+
in: open,
|
|
100
|
+
timeout: enabled ? 225 : 0,
|
|
101
|
+
classNames: css,
|
|
102
|
+
unmountOnExit: true,
|
|
103
|
+
onEnter: onEnter
|
|
104
|
+
}, children);
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
var getPopupStyle = function (placement, size) {
|
|
108
|
+
if (['top', 'bottom'].includes(placement)) {
|
|
109
|
+
return {
|
|
110
|
+
height: size
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
return {
|
|
115
|
+
width: size
|
|
116
|
+
};
|
|
117
|
+
};
|
|
118
|
+
|
|
119
|
+
var SideOverlay = function (_a) {
|
|
120
|
+
var children = _a.children,
|
|
121
|
+
_b = _a.classNames,
|
|
122
|
+
classNames = _b === void 0 ? {} : _b,
|
|
123
|
+
onClose = _a.onClose,
|
|
124
|
+
onOpen = _a.onOpen,
|
|
125
|
+
_c = _a.open,
|
|
126
|
+
open = _c === void 0 ? false : _c,
|
|
127
|
+
_d = _a.padding,
|
|
128
|
+
padding = _d === void 0 ? '45px 30px 30px 30px' : _d,
|
|
129
|
+
_e = _a.placement,
|
|
130
|
+
placement = _e === void 0 ? 'left' : _e,
|
|
131
|
+
_f = _a.size,
|
|
132
|
+
size = _f === void 0 ? 400 : _f,
|
|
133
|
+
_g = _a.useCloseButton,
|
|
134
|
+
useCloseButton = _g === void 0 ? true : _g,
|
|
135
|
+
_h = _a.useEscapeClose,
|
|
136
|
+
useEscapeClose = _h === void 0 ? true : _h,
|
|
137
|
+
_j = _a.useOutsideClose,
|
|
138
|
+
useOutsideClose = _j === void 0 ? true : _j,
|
|
139
|
+
_k = _a.usePortal,
|
|
140
|
+
usePortal = _k === void 0 ? true : _k,
|
|
141
|
+
_l = _a.useScrollLock,
|
|
142
|
+
useScrollLock = _l === void 0 ? true : _l,
|
|
143
|
+
_m = _a.useTouchScrollable,
|
|
144
|
+
useTouchScrollable = _m === void 0 ? true : _m,
|
|
145
|
+
_o = _a.zIndex,
|
|
146
|
+
zIndex = _o === void 0 ? 5000 : _o,
|
|
147
|
+
dataQaId = _a.dataQaId,
|
|
148
|
+
contentRef = _a.contentRef,
|
|
149
|
+
_p = _a.animationEnabled,
|
|
150
|
+
animationEnabled = _p === void 0 ? true : _p,
|
|
151
|
+
props = __rest(_a, ["children", "classNames", "onClose", "onOpen", "open", "padding", "placement", "size", "useCloseButton", "useEscapeClose", "useOutsideClose", "usePortal", "useScrollLock", "useTouchScrollable", "zIndex", "dataQaId", "contentRef", "animationEnabled"]);
|
|
152
|
+
|
|
153
|
+
return React__namespace.createElement(Animate, {
|
|
154
|
+
open: open,
|
|
155
|
+
onEnter: function () {
|
|
156
|
+
onOpen && onOpen();
|
|
157
|
+
},
|
|
158
|
+
enabled: animationEnabled
|
|
159
|
+
}, React__namespace.createElement(Portal.Portal, {
|
|
160
|
+
isActive: usePortal
|
|
161
|
+
}, React__namespace.createElement(Root, __assign({
|
|
162
|
+
role: 'presentation',
|
|
163
|
+
style: {
|
|
164
|
+
zIndex: zIndex
|
|
165
|
+
},
|
|
166
|
+
className: classNames.Root
|
|
167
|
+
}, props), React__namespace.createElement(ScrollLock__default["default"], {
|
|
168
|
+
isActive: useScrollLock
|
|
169
|
+
}), React__namespace.createElement(KeyPress.KeyPress, {
|
|
170
|
+
isActive: useEscapeClose,
|
|
171
|
+
code: 'Escape',
|
|
172
|
+
onKeyDown: onClose
|
|
173
|
+
}), React__namespace.createElement(Backdrop, {
|
|
174
|
+
className: classNames.Backdrop,
|
|
175
|
+
"aria-hidden": true,
|
|
176
|
+
onClick: function (e) {
|
|
177
|
+
if (useOutsideClose && onClose) {
|
|
178
|
+
onClose(e);
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
}), React__namespace.createElement(Popup, {
|
|
182
|
+
"popup-placement": placement,
|
|
183
|
+
className: classNames.Popup,
|
|
184
|
+
style: getPopupStyle(placement, size),
|
|
185
|
+
"data-qaid": dataQaId
|
|
186
|
+
}, useCloseButton && onClose && React__namespace.createElement(Close, {
|
|
187
|
+
className: classNames.Close,
|
|
188
|
+
type: 'button',
|
|
189
|
+
onClick: onClose,
|
|
190
|
+
"aria-label": ttag.t(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\u0417\u0430\u043A\u0440\u044B\u0442\u044C"], ["\u0417\u0430\u043A\u0440\u044B\u0442\u044C"]))),
|
|
191
|
+
"data-qaid": 'close'
|
|
192
|
+
}), useTouchScrollable ? React__namespace.createElement(ScrollLock.TouchScrollable, null, React__namespace.createElement(Content, {
|
|
193
|
+
ref: contentRef,
|
|
194
|
+
className: classNames.Content,
|
|
195
|
+
style: {
|
|
196
|
+
padding: padding
|
|
197
|
+
}
|
|
198
|
+
}, children)) : React__namespace.createElement(Content, {
|
|
199
|
+
ref: contentRef,
|
|
200
|
+
className: classNames.Content,
|
|
201
|
+
style: {
|
|
202
|
+
padding: padding
|
|
203
|
+
}
|
|
204
|
+
}, children)))));
|
|
205
|
+
};
|
|
206
|
+
var templateObject_1;
|
|
207
|
+
|
|
208
|
+
exports.SideOverlay = SideOverlay;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("ttag"),o=require("react-scrolllock"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("ttag"),o=require("react-scrolllock"),n=require("@prom-ui/core/Portal"),r=require("@prom-ui/core/KeyPress"),a=require("evokit"),c=require("react-transition-group");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function i(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(o){if("default"!==o){var n=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(t,o,n.get?n:{enumerable:!0,get:function(){return e[o]}})}})),t.default=e,Object.freeze(t)}var s=l(e),u=i(e),p=l(o),d=function(){return d=Object.assign||function(e){for(var t,o=1,n=arguments.length;o<n;o++)for(var r in t=arguments[o])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},d.apply(this,arguments)};var f,m={root:"zoSc7",backdrop:"v5Neh",popup:"LsB4w",content:"D9ezA",close:"aiN5k",popup_placement_top:"BSFf7",popup_placement_bottom:"k1gGY",popup_placement_right:"w9HUr",popup_placement_left:"DWBxa",enter:"ukL-B",exit:"QE5yq",enterActive:"VPRAq",exitActive:"FhiSX"},v={css:m,b:""},b=a.createBlock("div","root",[],v),y=a.createBlock("div","backdrop",[],v),O=a.createBlock("div","popup",["placement"],v),E=a.createBlock("div","content",[],v),h=a.createBlock("button","close",[],v),k=function(e){var t=e.open,o=void 0!==t&&t,n=e.children,r=e.enabled,a=void 0===r||r,l=e.onEnter;return s.default.createElement(c.CSSTransition,{in:o,timeout:a?225:0,classNames:m,unmountOnExit:!0,onEnter:l},n)},g=function(e,t){return["top","bottom"].includes(e)?{height:t}:{width:t}};exports.SideOverlay=function(e){var a,c,l=e.children,i=e.classNames,s=void 0===i?{}:i,m=e.onClose,v=e.onOpen,P=e.open,j=void 0!==P&&P,x=e.padding,C=void 0===x?"45px 30px 30px 30px":x,S=e.placement,B=void 0===S?"left":S,_=e.size,q=void 0===_?400:_,w=e.useCloseButton,N=void 0===w||w,z=e.useEscapeClose,A=void 0===z||z,I=e.useOutsideClose,D=void 0===I||I,L=e.usePortal,R=void 0===L||L,T=e.useScrollLock,K=void 0===T||T,Q=e.useTouchScrollable,F=void 0===Q||Q,M=e.zIndex,G=void 0===M?5e3:M,H=e.dataQaId,U=e.contentRef,V=e.animationEnabled,W=void 0===V||V,X=function(e,t){var o={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(o[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(o[n[r]]=e[n[r]])}return o}(e,["children","classNames","onClose","onOpen","open","padding","placement","size","useCloseButton","useEscapeClose","useOutsideClose","usePortal","useScrollLock","useTouchScrollable","zIndex","dataQaId","contentRef","animationEnabled"]);return u.createElement(k,{open:j,onEnter:function(){v&&v()},enabled:W},u.createElement(n.Portal,{isActive:R},u.createElement(b,d({role:"presentation",style:{zIndex:G},className:s.Root},X),u.createElement(p.default,{isActive:K}),u.createElement(r.KeyPress,{isActive:A,code:"Escape",onKeyDown:m}),u.createElement(y,{className:s.Backdrop,"aria-hidden":!0,onClick:function(e){D&&m&&m(e)}}),u.createElement(O,{"popup-placement":B,className:s.Popup,style:g(B,q),"data-qaid":H},N&&m&&u.createElement(h,{className:s.Close,type:"button",onClick:m,"aria-label":t.t(f||(a=["Закрыть"],c=["Закрыть"],Object.defineProperty?Object.defineProperty(a,"raw",{value:c}):a.raw=c,f=a)),"data-qaid":"close"}),F?u.createElement(o.TouchScrollable,null,u.createElement(E,{ref:U,className:s.Content,style:{padding:C}},l)):u.createElement(E,{ref:U,className:s.Content,style:{padding:C}},l)))))};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("ttag"),o=require("react-scrolllock"),n=require("@prom-ui/core/Portal"),r=require("@prom-ui/core/KeyPress"),a=require("evokit"),c=require("react-transition-group");function l(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function i(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(o){if("default"!==o){var n=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(t,o,n.get?n:{enumerable:!0,get:function(){return e[o]}})}})),t.default=e,Object.freeze(t)}var s=l(e),p=i(e),u=l(o),d=function(){return d=Object.assign||function(e){for(var t,o=1,n=arguments.length;o<n;o++)for(var r in t=arguments[o])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},d.apply(this,arguments)};var f,m={root:"_0hSa2",backdrop:"wUZLN",popup:"Ulqfh",content:"N1Cdb",close:"D-QIP",popup_placement_top:"qJTjO",popup_placement_bottom:"TDEZ7",popup_placement_right:"xZVWW",popup_placement_left:"ywgfV",enter:"_5IZPy",exit:"N9pJ7",enterActive:"SiX-q",exitActive:"oRVo0"},v={css:m,b:""},b=a.createBlock("div","root",[],v),y=a.createBlock("div","backdrop",[],v),O=a.createBlock("div","popup",["placement"],v),E=a.createBlock("div","content",[],v),h=a.createBlock("button","close",[],v),P=function(e){var t=e.open,o=void 0!==t&&t,n=e.children,r=e.enabled,a=void 0===r||r,l=e.onEnter;return s.default.createElement(c.CSSTransition,{in:o,timeout:a?225:0,classNames:m,unmountOnExit:!0,onEnter:l},n)},g=function(e,t){return["top","bottom"].includes(e)?{height:t}:{width:t}};exports.SideOverlay=function(e){var a,c,l=e.children,i=e.classNames,s=void 0===i?{}:i,m=e.onClose,v=e.onOpen,j=e.open,k=void 0!==j&&j,x=e.padding,C=void 0===x?"45px 30px 30px 30px":x,_=e.placement,q=void 0===_?"left":_,N=e.size,S=void 0===N?400:N,w=e.useCloseButton,B=void 0===w||w,I=e.useEscapeClose,z=void 0===I||I,T=e.useOutsideClose,A=void 0===T||T,D=e.usePortal,R=void 0===D||D,Z=e.useScrollLock,K=void 0===Z||Z,L=e.useTouchScrollable,Q=void 0===L||L,V=e.zIndex,J=void 0===V?5e3:V,M=e.dataQaId,U=e.contentRef,W=e.animationEnabled,X=void 0===W||W,F=function(e,t){var o={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(o[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(n=Object.getOwnPropertySymbols(e);r<n.length;r++)t.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(e,n[r])&&(o[n[r]]=e[n[r]])}return o}(e,["children","classNames","onClose","onOpen","open","padding","placement","size","useCloseButton","useEscapeClose","useOutsideClose","usePortal","useScrollLock","useTouchScrollable","zIndex","dataQaId","contentRef","animationEnabled"]);return p.createElement(P,{open:k,onEnter:function(){v&&v()},enabled:X},p.createElement(n.Portal,{isActive:R},p.createElement(b,d({role:"presentation",style:{zIndex:J},className:s.Root},F),p.createElement(u.default,{isActive:K}),p.createElement(r.KeyPress,{isActive:z,code:"Escape",onKeyDown:m}),p.createElement(y,{className:s.Backdrop,"aria-hidden":!0,onClick:function(e){A&&m&&m(e)}}),p.createElement(O,{"popup-placement":q,className:s.Popup,style:g(q,S),"data-qaid":M},B&&m&&p.createElement(h,{className:s.Close,type:"button",onClick:m,"aria-label":t.t(f||(a=["Закрыть"],c=["Закрыть"],Object.defineProperty?Object.defineProperty(a,"raw",{value:c}):a.raw=c,f=a)),"data-qaid":"close"}),Q?p.createElement(o.TouchScrollable,null,p.createElement(E,{ref:U,className:s.Content,style:{padding:C}},l)):p.createElement(E,{ref:U,className:s.Content,style:{padding:C}},l)))))};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.SideOverlay__root___0hSa2{position:fixed;right:0;bottom:0;top:0;left:0;width:100%;height:100%}.SideOverlay__backdrop___wUZLN{top:0;left:0;right:0;bottom:0;display:flex;z-index:-1;position:fixed;align-items:center;justify-content:center;opacity:.5;background-color:var(--black-400);-webkit-tap-highlight-color:transparent;will-change:opacity}.SideOverlay__popup___Ulqfh{z-index:1200;position:fixed;background:var(--white);box-sizing:border-box}.SideOverlay__content___N1Cdb{width:100%;height:100%;box-sizing:border-box;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch}.SideOverlay__close___D-QIP{position:absolute;right:0;top:0;font-size:30px;line-height:24px;color:inherit;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:0 0;-webkit-user-select:none;-moz-user-select:none;user-select:none;outline:0;cursor:pointer;border:0;padding:0;font-weight:400;width:24px;height:24px;margin:10px}.SideOverlay__close___D-QIP::after{content:"×"}.SideOverlay__popup_placement_top___qJTjO,.SideOverlay__popup_placement_bottom___TDEZ7,.SideOverlay__popup_placement_right___xZVWW,.SideOverlay__popup_placement_left___ywgfV{transform:none;will-change:transform}.SideOverlay__popup_placement_top___qJTjO,.SideOverlay__popup_placement_bottom___TDEZ7{right:0;left:0;max-height:90%}.SideOverlay__popup_placement_right___xZVWW,.SideOverlay__popup_placement_left___ywgfV{top:0;bottom:0;max-width:90%}.SideOverlay__popup_placement_top___qJTjO{top:0;box-shadow:0 3px 6px 0 rgba(0,0,0,.1)}.SideOverlay__popup_placement_bottom___TDEZ7{bottom:0;box-shadow:0-3px 6px 0 rgba(0,0,0,.1)}.SideOverlay__popup_placement_right___xZVWW{right:0;box-shadow:-3px 0 6px 0 rgba(0,0,0,.1)}.SideOverlay__popup_placement_left___ywgfV{left:0;box-shadow:3px 0 6px 0 rgba(0,0,0,.1)}.SideOverlay__enter___5IZPy,.SideOverlay__exit___N9pJ7{pointer-events:auto}.SideOverlay__enterActive___SiX-q,.SideOverlay__exitActive___oRVo0{pointer-events:none}.SideOverlay__enterActive___SiX-q .SideOverlay__backdrop___wUZLN,.SideOverlay__exitActive___oRVo0 .SideOverlay__backdrop___wUZLN{transition:opacity 225ms cubic-bezier(.4,0,.2,1) 0ms}.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_top___qJTjO,.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_top___qJTjO,.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_right___xZVWW,.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_right___xZVWW,.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_bottom___TDEZ7,.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_bottom___TDEZ7,.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_left___ywgfV,.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_left___ywgfV{transition:transform 225ms cubic-bezier(.4,0,.2,1) 0ms}.SideOverlay__enter___5IZPy .SideOverlay__backdrop___wUZLN{opacity:0}.SideOverlay__enter___5IZPy .SideOverlay__popup_placement_top___qJTjO{transform:translateY(-100%)}.SideOverlay__enter___5IZPy .SideOverlay__popup_placement_right___xZVWW{transform:translateX(100%)}.SideOverlay__enter___5IZPy .SideOverlay__popup_placement_bottom___TDEZ7{transform:translateY(100%)}.SideOverlay__enter___5IZPy .SideOverlay__popup_placement_left___ywgfV{transform:translateX(-100%)}.SideOverlay__enterActive___SiX-q .SideOverlay__backdrop___wUZLN{opacity:.5}.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_top___qJTjO,.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_bottom___TDEZ7{transform:translateY(0)}.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_left___ywgfV,.SideOverlay__enterActive___SiX-q .SideOverlay__popup_placement_right___xZVWW{transform:translateX(0)}.SideOverlay__exit___N9pJ7 .SideOverlay__backdrop___wUZLN{opacity:.5}.SideOverlay__exit___N9pJ7 .SideOverlay__popup_placement_top___qJTjO,.SideOverlay__exit___N9pJ7 .SideOverlay__popup_placement_bottom___TDEZ7{transform:translateY(0)}.SideOverlay__exit___N9pJ7 .SideOverlay__popup_placement_left___ywgfV,.SideOverlay__exit___N9pJ7 .SideOverlay__popup_placement_right___xZVWW{transform:translateX(0)}.SideOverlay__exitActive___oRVo0 .SideOverlay__backdrop___wUZLN{opacity:0}.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_top___qJTjO{transform:translateY(-100%)}.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_right___xZVWW{transform:translateX(100%)}.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_bottom___TDEZ7{transform:translateY(100%)}.SideOverlay__exitActive___oRVo0 .SideOverlay__popup_placement_left___ywgfV{transform:translateX(-100%)}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._0hSa2{position:fixed;right:0;bottom:0;top:0;left:0;width:100%;height:100%}.wUZLN{top:0;left:0;right:0;bottom:0;display:flex;z-index:-1;position:fixed;align-items:center;justify-content:center;opacity:.5;background-color:var(--black-400);-webkit-tap-highlight-color:transparent;will-change:opacity}.Ulqfh{z-index:1200;position:fixed;background:var(--white);box-sizing:border-box}.N1Cdb{width:100%;height:100%;box-sizing:border-box;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:touch}.D-QIP{position:absolute;right:0;top:0;font-size:30px;line-height:24px;color:inherit;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none;background:0 0;-webkit-user-select:none;-moz-user-select:none;user-select:none;outline:0;cursor:pointer;border:0;padding:0;font-weight:400;width:24px;height:24px;margin:10px}.D-QIP::after{content:"×"}.qJTjO,.TDEZ7,.xZVWW,.ywgfV{transform:none;will-change:transform}.qJTjO,.TDEZ7{right:0;left:0;max-height:90%}.xZVWW,.ywgfV{top:0;bottom:0;max-width:90%}.qJTjO{top:0;box-shadow:0 3px 6px 0 rgba(0,0,0,.1)}.TDEZ7{bottom:0;box-shadow:0-3px 6px 0 rgba(0,0,0,.1)}.xZVWW{right:0;box-shadow:-3px 0 6px 0 rgba(0,0,0,.1)}.ywgfV{left:0;box-shadow:3px 0 6px 0 rgba(0,0,0,.1)}._5IZPy,.N9pJ7{pointer-events:auto}.SiX-q,.oRVo0{pointer-events:none}.SiX-q .wUZLN,.oRVo0 .wUZLN{transition:opacity 225ms cubic-bezier(.4,0,.2,1) 0ms}.SiX-q .qJTjO,.oRVo0 .qJTjO,.SiX-q .xZVWW,.oRVo0 .xZVWW,.SiX-q .TDEZ7,.oRVo0 .TDEZ7,.SiX-q .ywgfV,.oRVo0 .ywgfV{transition:transform 225ms cubic-bezier(.4,0,.2,1) 0ms}._5IZPy .wUZLN{opacity:0}._5IZPy .qJTjO{transform:translateY(-100%)}._5IZPy .xZVWW{transform:translateX(100%)}._5IZPy .TDEZ7{transform:translateY(100%)}._5IZPy .ywgfV{transform:translateX(-100%)}.SiX-q .wUZLN{opacity:.5}.SiX-q .qJTjO,.SiX-q .TDEZ7{transform:translateY(0)}.SiX-q .ywgfV,.SiX-q .xZVWW{transform:translateX(0)}.N9pJ7 .wUZLN{opacity:.5}.N9pJ7 .qJTjO,.N9pJ7 .TDEZ7{transform:translateY(0)}.N9pJ7 .ywgfV,.N9pJ7 .xZVWW{transform:translateX(0)}.oRVo0 .wUZLN{opacity:0}.oRVo0 .qJTjO{transform:translateY(-100%)}.oRVo0 .xZVWW{transform:translateX(100%)}.oRVo0 .TDEZ7{transform:translateY(100%)}.oRVo0 .ywgfV{transform:translateX(-100%)}
|
package/SideOverlay/index.js
CHANGED
|
@@ -1,7 +1,19 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
if (process.env.NODE_ENV === 'production') {
|
|
4
|
-
|
|
4
|
+
if (process.env.PROM_UI_CSS_HASH === 'v2') {
|
|
5
|
+
module.exports = require('./cjs/index.production.v2.js');
|
|
6
|
+
require('./cjs/style.production.v2.js');
|
|
7
|
+
} else {
|
|
8
|
+
module.exports = require('./cjs/index.production.js');
|
|
9
|
+
require('./cjs/style.production.js');
|
|
10
|
+
}
|
|
5
11
|
} else {
|
|
6
|
-
|
|
12
|
+
if (process.env.PROM_UI_CSS_HASH === 'v2') {
|
|
13
|
+
module.exports = require('./cjs/index.development.v2.js');
|
|
14
|
+
require('./cjs/style.development.v2.js');
|
|
15
|
+
} else {
|
|
16
|
+
module.exports = require('./cjs/index.development.js');
|
|
17
|
+
require('./cjs/style.development.js');
|
|
18
|
+
}
|
|
7
19
|
}
|
package/SideOverlay/package.json
CHANGED