@jetbrains/ring-ui-built 7.0.19 → 7.0.21
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/components/_helpers/_rollupPluginBabelHelpers.js +5 -5
- package/components/_helpers/card.js +5 -5
- package/components/_helpers/input.js +7 -7
- package/components/_helpers/list.js +1 -1
- package/components/_helpers/select__filter.js +2 -2
- package/components/_helpers/sidebar.js +2 -2
- package/components/alert/alert.js +2 -2
- package/components/alert-service/alert-service.js +2 -2
- package/components/analytics/analytics.js +1 -1
- package/components/analytics/analytics__custom-plugin.js +8 -8
- package/components/auth/auth__core.js +54 -54
- package/components/auth/background-flow.js +4 -4
- package/components/auth/iframe-flow.js +7 -7
- package/components/auth/request-builder.js +3 -3
- package/components/auth/response-parser.js +4 -4
- package/components/auth/storage.js +12 -12
- package/components/auth/token-validator.js +7 -7
- package/components/auth/window-flow.js +7 -7
- package/components/auth-dialog/auth-dialog.js +1 -1
- package/components/avatar/avatar.d.ts +2 -0
- package/components/avatar/avatar.js +8 -0
- package/components/avatar-stack/avatar-stack.d.ts +15 -0
- package/components/avatar-stack/avatar-stack.js +117 -0
- package/components/button/button.js +2 -2
- package/components/caret/caret.js +6 -6
- package/components/checkbox/checkbox.js +1 -1
- package/components/clipboard/clipboard-fallback.js +3 -3
- package/components/code/code.js +1 -1
- package/components/collapse/collapse-content.js +2 -2
- package/components/collapse/collapse.js +1 -1
- package/components/data-list/data-list.js +3 -3
- package/components/data-list/item.js +1 -1
- package/components/date-picker/consts.js +1 -1
- package/components/date-picker/date-input.js +5 -5
- package/components/date-picker/date-picker.js +9 -9
- package/components/date-picker/date-popup.js +4 -4
- package/components/date-picker/years.js +1 -1
- package/components/dialog/dialog.js +1 -1
- package/components/dropdown/dropdown.js +4 -4
- package/components/editable-heading/editable-heading.js +4 -4
- package/components/global/focus-sensor-hoc.js +10 -10
- package/components/global/memoize.js +1 -1
- package/components/global/normalize-indent.js +1 -1
- package/components/global/react-dom-renderer.js +1 -1
- package/components/global/schedule-raf.js +1 -1
- package/components/header/profile.js +8 -8
- package/components/header/smart-profile.js +2 -2
- package/components/header/smart-services.js +4 -4
- package/components/http/http.js +9 -9
- package/components/http/http.mock.js +3 -3
- package/components/hub-source/hub-source.js +6 -6
- package/components/hub-source/hub-source__user.js +2 -2
- package/components/hub-source/hub-source__users-groups.js +4 -4
- package/components/i18n/i18n.js +1 -1
- package/components/island/adaptive-island-hoc.js +1 -1
- package/components/island/content.js +3 -3
- package/components/island/header.js +1 -1
- package/components/list/list.js +4 -4
- package/components/list/list__item.js +2 -2
- package/components/list/list__link.js +1 -1
- package/components/list/list__users-groups-source.js +2 -2
- package/components/loader/loader.js +2 -2
- package/components/loader/loader__core.js +27 -27
- package/components/login-dialog/login-dialog.js +1 -1
- package/components/message/message.js +14 -14
- package/components/old-browsers-message/white-list.js +3 -3
- package/components/pager/pager.js +9 -9
- package/components/permissions/permissions.js +7 -7
- package/components/permissions/permissions__cache.js +4 -4
- package/components/popup/popup.js +8 -8
- package/components/popup/position.js +1 -1
- package/components/popup-menu/popup-menu.js +1 -1
- package/components/progress-bar/progress-bar.js +2 -2
- package/components/query-assist/query-assist.js +43 -43
- package/components/radio/radio__item.js +2 -2
- package/components/select/select.js +27 -27
- package/components/select/select__popup.js +9 -9
- package/components/shortcuts/core.js +1 -1
- package/components/slider/slider.js +8 -8
- package/components/slider/slider.utils.js +1 -1
- package/components/storage/storage__local.js +1 -1
- package/components/style.css +1 -1
- package/components/tab-trap/tab-trap.js +4 -4
- package/components/table/header-cell.js +2 -2
- package/components/table/multitable.js +7 -7
- package/components/table/row-with-focus-sensor.js +4 -4
- package/components/table/row.js +1 -1
- package/components/table/selection-shortcuts-hoc.js +12 -12
- package/components/table/selection.js +7 -7
- package/components/table/table.js +1 -1
- package/components/tabs/collapsible-tab.js +3 -3
- package/components/tabs/collapsible-tabs.js +6 -6
- package/components/tabs/dumb-tabs.js +1 -1
- package/components/tabs/smart-tabs.js +1 -1
- package/components/tag/tag.js +2 -2
- package/components/tags-input/tags-input.js +17 -17
- package/components/tooltip/tooltip.js +10 -10
- package/components/upload/upload.js +3 -3
- package/components/user-agreement/service.js +3 -3
- package/components/user-agreement/user-agreement.js +8 -8
- package/components/user-card/card.js +2 -2
- package/components/user-card/user-card.js +2 -2
- package/package.json +3 -3
- package/typings.d.ts +5 -0
@@ -14,12 +14,12 @@ class Particle {
|
|
14
14
|
radius,
|
15
15
|
color
|
16
16
|
} = _ref;
|
17
|
-
_defineProperty(this, "radius",
|
18
|
-
_defineProperty(this, "x",
|
19
|
-
_defineProperty(this, "y",
|
20
|
-
_defineProperty(this, "color",
|
21
|
-
_defineProperty(this, "decay",
|
22
|
-
_defineProperty(this, "life",
|
17
|
+
_defineProperty(this, "radius", undefined);
|
18
|
+
_defineProperty(this, "x", undefined);
|
19
|
+
_defineProperty(this, "y", undefined);
|
20
|
+
_defineProperty(this, "color", undefined);
|
21
|
+
_defineProperty(this, "decay", undefined);
|
22
|
+
_defineProperty(this, "life", undefined);
|
23
23
|
this.radius = radius;
|
24
24
|
this.x = x;
|
25
25
|
this.y = y;
|
@@ -56,26 +56,26 @@ class LoaderCore {
|
|
56
56
|
}
|
57
57
|
constructor(containerNode, props) {
|
58
58
|
var _this$ctx;
|
59
|
-
_defineProperty(this, "props",
|
60
|
-
_defineProperty(this, "canvas",
|
61
|
-
_defineProperty(this, "textNode",
|
62
|
-
_defineProperty(this, "ctx",
|
63
|
-
_defineProperty(this, "height",
|
64
|
-
_defineProperty(this, "width",
|
65
|
-
_defineProperty(this, "particles",
|
66
|
-
_defineProperty(this, "baseSpeed",
|
67
|
-
_defineProperty(this, "colorIndex",
|
68
|
-
_defineProperty(this, "maxRadius",
|
69
|
-
_defineProperty(this, "minRadius",
|
70
|
-
_defineProperty(this, "colorChangeTick",
|
71
|
-
_defineProperty(this, "x",
|
72
|
-
_defineProperty(this, "y",
|
73
|
-
_defineProperty(this, "radius",
|
74
|
-
_defineProperty(this, "hSpeed",
|
75
|
-
_defineProperty(this, "vSpeed",
|
76
|
-
_defineProperty(this, "radiusSpeed",
|
77
|
-
_defineProperty(this, "tick",
|
78
|
-
_defineProperty(this, "isRunning",
|
59
|
+
_defineProperty(this, "props", undefined);
|
60
|
+
_defineProperty(this, "canvas", undefined);
|
61
|
+
_defineProperty(this, "textNode", undefined);
|
62
|
+
_defineProperty(this, "ctx", undefined);
|
63
|
+
_defineProperty(this, "height", undefined);
|
64
|
+
_defineProperty(this, "width", undefined);
|
65
|
+
_defineProperty(this, "particles", undefined);
|
66
|
+
_defineProperty(this, "baseSpeed", undefined);
|
67
|
+
_defineProperty(this, "colorIndex", undefined);
|
68
|
+
_defineProperty(this, "maxRadius", undefined);
|
69
|
+
_defineProperty(this, "minRadius", undefined);
|
70
|
+
_defineProperty(this, "colorChangeTick", undefined);
|
71
|
+
_defineProperty(this, "x", undefined);
|
72
|
+
_defineProperty(this, "y", undefined);
|
73
|
+
_defineProperty(this, "radius", undefined);
|
74
|
+
_defineProperty(this, "hSpeed", undefined);
|
75
|
+
_defineProperty(this, "vSpeed", undefined);
|
76
|
+
_defineProperty(this, "radiusSpeed", undefined);
|
77
|
+
_defineProperty(this, "tick", undefined);
|
78
|
+
_defineProperty(this, "isRunning", undefined);
|
79
79
|
this.props = Object.assign({}, LoaderCore.defaultProps, props);
|
80
80
|
this.canvas = document.createElement('canvas');
|
81
81
|
this.canvas.dataset.test = 'ring-loader';
|
@@ -94,7 +94,7 @@ class LoaderCore {
|
|
94
94
|
this.canvas.style.width = "".concat(this.props.size, "px");
|
95
95
|
this.canvas.style.height = "".concat(this.props.size, "px");
|
96
96
|
this.ctx = this.canvas.getContext('2d');
|
97
|
-
(_this$ctx = this.ctx) === null || _this$ctx ===
|
97
|
+
(_this$ctx = this.ctx) === null || _this$ctx === undefined || _this$ctx.scale(pixelRatio, pixelRatio);
|
98
98
|
this.height = this.props.size;
|
99
99
|
this.width = this.props.size;
|
100
100
|
this.particles = [];
|
@@ -71,7 +71,7 @@ class LoginDialog extends Component {
|
|
71
71
|
height: DEFAULT_HEIGHT,
|
72
72
|
width: DEFAULT_WIDTH
|
73
73
|
});
|
74
|
-
_defineProperty(this, "showFallbackTimout",
|
74
|
+
_defineProperty(this, "showFallbackTimout", undefined);
|
75
75
|
_defineProperty(this, "onMessage", event => {
|
76
76
|
const {
|
77
77
|
data
|
@@ -62,17 +62,17 @@ const getTailOffsets = offset => ({
|
|
62
62
|
transform: 'rotate(135deg)'
|
63
63
|
},
|
64
64
|
[Directions.TOP_RIGHT]: {
|
65
|
-
bottom: -
|
65
|
+
bottom: -11,
|
66
66
|
left: offset - UNIT,
|
67
67
|
transform: 'rotate(-45deg)'
|
68
68
|
},
|
69
69
|
[Directions.TOP_LEFT]: {
|
70
|
-
bottom: -
|
70
|
+
bottom: -11,
|
71
71
|
right: offset + UNIT - TAIL_SIZE,
|
72
72
|
transform: 'rotate(-45deg)'
|
73
73
|
},
|
74
74
|
[Directions.TOP_CENTER]: {
|
75
|
-
bottom: -
|
75
|
+
bottom: -11,
|
76
76
|
left: offset - UNIT,
|
77
77
|
transform: 'rotate(-45deg)'
|
78
78
|
},
|
@@ -93,17 +93,17 @@ const getTailOffsets = offset => ({
|
|
93
93
|
},
|
94
94
|
[Directions.LEFT_TOP]: {
|
95
95
|
bottom: offset - UNIT - TAIL_SIZE,
|
96
|
-
right: -
|
96
|
+
right: -11,
|
97
97
|
transform: 'rotate(-135deg)'
|
98
98
|
},
|
99
99
|
[Directions.LEFT_BOTTOM]: {
|
100
100
|
top: offset + UNIT,
|
101
|
-
right: -
|
101
|
+
right: -11,
|
102
102
|
transform: 'rotate(-135deg)'
|
103
103
|
},
|
104
104
|
[Directions.LEFT_CENTER]: {
|
105
105
|
top: offset + UNIT,
|
106
|
-
right: -
|
106
|
+
right: -11,
|
107
107
|
transform: 'rotate(-135deg)'
|
108
108
|
}
|
109
109
|
});
|
@@ -117,12 +117,12 @@ class Message extends Component {
|
|
117
117
|
_defineProperty(this, "_onDirectionChange", direction => this.setState({
|
118
118
|
direction
|
119
119
|
}));
|
120
|
-
_defineProperty(this, "popup",
|
121
|
-
_defineProperty(this, "node",
|
120
|
+
_defineProperty(this, "popup", undefined);
|
121
|
+
_defineProperty(this, "node", undefined);
|
122
122
|
_defineProperty(this, "popupRef", el => {
|
123
123
|
var _this$popup;
|
124
124
|
this.popup = el;
|
125
|
-
this.node = (_this$popup = this.popup) === null || _this$popup ===
|
125
|
+
this.node = (_this$popup = this.popup) === null || _this$popup === undefined ? undefined : _this$popup.node;
|
126
126
|
});
|
127
127
|
}
|
128
128
|
getTailOffset() {
|
@@ -134,14 +134,14 @@ class Message extends Component {
|
|
134
134
|
if (this.props.tailOffset != null) {
|
135
135
|
return this.props.tailOffset;
|
136
136
|
}
|
137
|
-
const anchor = (popupProps === null || popupProps ===
|
137
|
+
const anchor = (popupProps === null || popupProps === undefined ? undefined : popupProps.anchorElement) || ((_this$popup2 = this.popup) === null || _this$popup2 === undefined ? undefined : _this$popup2.parent);
|
138
138
|
if (!anchor) {
|
139
139
|
return DEFAULT_OFFSET;
|
140
140
|
}
|
141
141
|
const offset = Math.floor(anchor.offsetWidth / 2);
|
142
142
|
const isOpenedToRight = this.state.direction != null && [Directions.TOP_RIGHT, Directions.BOTTOM_RIGHT].includes(this.state.direction);
|
143
|
-
if (popupProps !== null && popupProps !==
|
144
|
-
return offset - (popupProps === null || popupProps ===
|
143
|
+
if (popupProps !== null && popupProps !== undefined && popupProps.left && isOpenedToRight) {
|
144
|
+
return offset - (popupProps === null || popupProps === undefined ? undefined : popupProps.left);
|
145
145
|
}
|
146
146
|
return offset;
|
147
147
|
}
|
@@ -205,11 +205,11 @@ class Message extends Component {
|
|
205
205
|
onClick: onClose,
|
206
206
|
primary: true
|
207
207
|
}, buttonProps), {}, {
|
208
|
-
children: (_translations$gotIt = translations === null || translations ===
|
208
|
+
children: (_translations$gotIt = translations === null || translations === undefined ? undefined : translations.gotIt) !== null && _translations$gotIt !== undefined ? _translations$gotIt : translate('gotIt')
|
209
209
|
})), onDismiss && jsx(Button, {
|
210
210
|
onClick: onDismiss,
|
211
211
|
inline: true,
|
212
|
-
children: (_translations$dismiss = translations === null || translations ===
|
212
|
+
children: (_translations$dismiss = translations === null || translations === undefined ? undefined : translations.dismiss) !== null && _translations$dismiss !== undefined ? _translations$dismiss : translate('dismiss')
|
213
213
|
})]
|
214
214
|
})
|
215
215
|
}));
|
@@ -8,15 +8,15 @@ const MAJOR_VERSION_INDEX = 0;
|
|
8
8
|
/**
|
9
9
|
* SUPPORTED_BROWSERS are defined by Babel plugin, see babel config
|
10
10
|
*/
|
11
|
-
if (!["and_chr 131", "chrome 131", "chrome
|
11
|
+
if (!["and_chr 131", "chrome 131", "chrome 125", "chrome 109", "edge 131", "firefox 133", "ios_saf 18.1", "ios_saf 17.6-17.7", "op_mob 80", "safari 18.1", "samsung 27"]) {
|
12
12
|
// eslint-disable-next-line no-console
|
13
13
|
console.warn('Ring UI: no SUPPORTED_BROWSERS passed. Please check babel config.');
|
14
14
|
}
|
15
|
-
const SUPPORTED = ["and_chr 131", "chrome 131", "chrome
|
15
|
+
const SUPPORTED = ["and_chr 131", "chrome 131", "chrome 125", "chrome 109", "edge 131", "firefox 133", "ios_saf 18.1", "ios_saf 17.6-17.7", "op_mob 80", "safari 18.1", "samsung 27"];
|
16
16
|
const WHITE_LISTED_BROWSERS = ['chrome', 'firefox', 'safari', 'edge'];
|
17
17
|
const WHITE_LIST = SUPPORTED.reduce((acc, item) => {
|
18
18
|
var _item$match;
|
19
|
-
const [, browserName, version] = (_item$match = item.match(/(\S+)\s(\S+)/)) !== null && _item$match !==
|
19
|
+
const [, browserName, version] = (_item$match = item.match(/(\S+)\s(\S+)/)) !== null && _item$match !== undefined ? _item$match : [];
|
20
20
|
if (!WHITE_LISTED_BROWSERS.includes(browserName)) {
|
21
21
|
return acc;
|
22
22
|
}
|
@@ -104,7 +104,7 @@ class Pager extends PureComponent {
|
|
104
104
|
if (currentPage !== 1) {
|
105
105
|
var _this$props$onPageCha, _this$props;
|
106
106
|
const prevPage = currentPage - 1;
|
107
|
-
(_this$props$onPageCha = (_this$props = this.props).onPageChange) === null || _this$props$onPageCha ===
|
107
|
+
(_this$props$onPageCha = (_this$props = this.props).onPageChange) === null || _this$props$onPageCha === undefined || _this$props$onPageCha.call(_this$props, prevPage);
|
108
108
|
}
|
109
109
|
});
|
110
110
|
_defineProperty(this, "handleNextClick", () => {
|
@@ -116,14 +116,14 @@ class Pager extends PureComponent {
|
|
116
116
|
const total = this.getTotalPages();
|
117
117
|
if (currentPage !== total) {
|
118
118
|
var _this$props$onPageCha2, _this$props2;
|
119
|
-
(_this$props$onPageCha2 = (_this$props2 = this.props).onPageChange) === null || _this$props$onPageCha2 ===
|
119
|
+
(_this$props$onPageCha2 = (_this$props2 = this.props).onPageChange) === null || _this$props$onPageCha2 === undefined || _this$props$onPageCha2.call(_this$props2, nextPage);
|
120
120
|
} else if (this.props.openTotal) {
|
121
121
|
onLoadPage(nextPage);
|
122
122
|
}
|
123
123
|
});
|
124
124
|
_defineProperty(this, "handlePageChange", memoize(i => event => {
|
125
125
|
var _this$props$onPageCha3, _this$props3;
|
126
|
-
(_this$props$onPageCha3 = (_this$props3 = this.props).onPageChange) === null || _this$props$onPageCha3 ===
|
126
|
+
(_this$props$onPageCha3 = (_this$props3 = this.props).onPageChange) === null || _this$props$onPageCha3 === undefined || _this$props$onPageCha3.call(_this$props3, i, event);
|
127
127
|
}));
|
128
128
|
_defineProperty(this, "handleLoadMore", memoize(i => () => {
|
129
129
|
this.props.onLoadPage(i);
|
@@ -141,7 +141,7 @@ class Pager extends PureComponent {
|
|
141
141
|
var _this$props$translati, _this$props$translati2;
|
142
142
|
return {
|
143
143
|
key: size,
|
144
|
-
label: "".concat(size, " ").concat((_this$props$translati = (_this$props$translati2 = this.props.translations) === null || _this$props$translati2 ===
|
144
|
+
label: "".concat(size, " ").concat((_this$props$translati = (_this$props$translati2 = this.props.translations) === null || _this$props$translati2 === undefined ? undefined : _this$props$translati2.perPage) !== null && _this$props$translati !== undefined ? _this$props$translati : translate('perPage'))
|
145
145
|
};
|
146
146
|
});
|
147
147
|
const selected = data.find(it => it.key === pageSize);
|
@@ -211,8 +211,8 @@ class Pager extends PureComponent {
|
|
211
211
|
const prevIcon = jsx(Icon, {
|
212
212
|
glyph: chevronLeftIcon
|
213
213
|
}, "icon");
|
214
|
-
const prevText = (_this$props$translati3 = (_this$props$translati4 = this.props.translations) === null || _this$props$translati4 ===
|
215
|
-
const nextText = (_this$props$translati5 = (_this$props$translati6 = this.props.translations) === null || _this$props$translati6 ===
|
214
|
+
const prevText = (_this$props$translati3 = (_this$props$translati4 = this.props.translations) === null || _this$props$translati4 === undefined ? undefined : _this$props$translati4.previousPage) !== null && _this$props$translati3 !== undefined ? _this$props$translati3 : translate('previousPage');
|
215
|
+
const nextText = (_this$props$translati5 = (_this$props$translati6 = this.props.translations) === null || _this$props$translati6 === undefined ? undefined : _this$props$translati6.nextPage) !== null && _this$props$translati5 !== undefined ? _this$props$translati5 : translate('nextPage');
|
216
216
|
const nextLinkContent = [jsx("span", {
|
217
217
|
children: nextText
|
218
218
|
}, "text"), nextIcon];
|
@@ -269,7 +269,7 @@ class Pager extends PureComponent {
|
|
269
269
|
} = this.context;
|
270
270
|
if (totalPages < this.props.currentPage) {
|
271
271
|
var _this$props$onPageCha4, _this$props4;
|
272
|
-
(_this$props$onPageCha4 = (_this$props4 = this.props).onPageChange) === null || _this$props$onPageCha4 ===
|
272
|
+
(_this$props$onPageCha4 = (_this$props4 = this.props).onPageChange) === null || _this$props$onPageCha4 === undefined || _this$props$onPageCha4.call(_this$props4, totalPages);
|
273
273
|
}
|
274
274
|
let start = 1;
|
275
275
|
let end = totalPages;
|
@@ -301,14 +301,14 @@ class Pager extends PureComponent {
|
|
301
301
|
children: [this.getPagerLinks(), jsxs("div", {
|
302
302
|
className: style.actions,
|
303
303
|
children: [jsxs(ButtonToolbar, {
|
304
|
-
children: [start > 1 && this.getButton(1, (_this$props$translati7 = (_this$props$translati8 = this.props.translations) === null || _this$props$translati8 ===
|
304
|
+
children: [start > 1 && this.getButton(1, (_this$props$translati7 = (_this$props$translati8 = this.props.translations) === null || _this$props$translati8 === undefined ? undefined : _this$props$translati8.firstPage) !== null && _this$props$translati7 !== undefined ? _this$props$translati7 : translate('firstPage')), jsxs(ButtonGroup, {
|
305
305
|
children: [start > 1 && this.getButton(start - 1, '...'), buttons, end < totalPages && this.getButton(end + 1, '...'), end === totalPages && this.props.openTotal && jsx(Button, _objectSpread2(_objectSpread2({
|
306
306
|
href: this.generateHref(end + 1),
|
307
307
|
disabled: this.props.loader
|
308
308
|
}, this.getClickProps(this.handleLoadMore(end + 1))), {}, {
|
309
309
|
children: '...'
|
310
310
|
}))]
|
311
|
-
}), lastPageButtonAvailable && this.getButton(this.props.openTotal ? -1 : totalPages, (_this$props$translati9 = (_this$props$translati10 = this.props.translations) === null || _this$props$translati10 ===
|
311
|
+
}), lastPageButtonAvailable && this.getButton(this.props.openTotal ? -1 : totalPages, (_this$props$translati9 = (_this$props$translati10 = this.props.translations) === null || _this$props$translati10 === undefined ? undefined : _this$props$translati10.lastPage) !== null && _this$props$translati9 !== undefined ? _this$props$translati9 : translate('lastPage'))]
|
312
312
|
}), this.getPageSizeSelector()]
|
313
313
|
})]
|
314
314
|
});
|
@@ -28,13 +28,13 @@ import PermissionCache from './permissions__cache.js';
|
|
28
28
|
class Permissions {
|
29
29
|
constructor(auth) {
|
30
30
|
let config = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
31
|
-
_defineProperty(this, "query",
|
32
|
-
_defineProperty(this, "namesConverter",
|
33
|
-
_defineProperty(this, "_auth",
|
34
|
-
_defineProperty(this, "_datasource",
|
35
|
-
_defineProperty(this, "_promise",
|
36
|
-
_defineProperty(this, "_subscribed",
|
37
|
-
_defineProperty(this, "_permissionCache",
|
31
|
+
_defineProperty(this, "query", undefined);
|
32
|
+
_defineProperty(this, "namesConverter", undefined);
|
33
|
+
_defineProperty(this, "_auth", undefined);
|
34
|
+
_defineProperty(this, "_datasource", undefined);
|
35
|
+
_defineProperty(this, "_promise", undefined);
|
36
|
+
_defineProperty(this, "_subscribed", undefined);
|
37
|
+
_defineProperty(this, "_permissionCache", undefined);
|
38
38
|
_defineProperty(this, "_defaultDatasource", query => this._auth.http.get(Permissions.API_PERMISSION_CACHE_PATH, {
|
39
39
|
query: {
|
40
40
|
fields: 'permission/key,global,projects(id)',
|
@@ -32,9 +32,9 @@ class PermissionCache {
|
|
32
32
|
return projectIdSet;
|
33
33
|
}
|
34
34
|
constructor(permissions, namesConverter) {
|
35
|
-
_defineProperty(this, "namesConverter",
|
36
|
-
_defineProperty(this, "_permissions",
|
37
|
-
_defineProperty(this, "permissionCache",
|
35
|
+
_defineProperty(this, "namesConverter", undefined);
|
36
|
+
_defineProperty(this, "_permissions", undefined);
|
37
|
+
_defineProperty(this, "permissionCache", undefined);
|
38
38
|
this.namesConverter = namesConverter || (key => key);
|
39
39
|
this.set(permissions);
|
40
40
|
}
|
@@ -206,7 +206,7 @@ class PermissionCache {
|
|
206
206
|
testPermission(permissionName, projectId) {
|
207
207
|
const permissionCache = this.permissionCache;
|
208
208
|
const convertedName = this.namesConverter(permissionName);
|
209
|
-
const cachedPermission = (permissionCache === null || permissionCache ===
|
209
|
+
const cachedPermission = (permissionCache === null || permissionCache === undefined ? undefined : permissionCache[permissionName]) || convertedName && (permissionCache === null || permissionCache === undefined ? undefined : permissionCache[convertedName]);
|
210
210
|
// Hasn't the permission in any project
|
211
211
|
if (!cachedPermission) {
|
212
212
|
return false;
|
@@ -66,11 +66,11 @@ class Popup extends PureComponent {
|
|
66
66
|
_defineProperty(this, "state", {
|
67
67
|
display: Display.SHOWING
|
68
68
|
});
|
69
|
-
_defineProperty(this, "popup",
|
70
|
-
_defineProperty(this, "node",
|
71
|
-
_defineProperty(this, "parent",
|
72
|
-
_defineProperty(this, "container",
|
73
|
-
_defineProperty(this, "ringPopupTarget",
|
69
|
+
_defineProperty(this, "popup", undefined);
|
70
|
+
_defineProperty(this, "node", undefined);
|
71
|
+
_defineProperty(this, "parent", undefined);
|
72
|
+
_defineProperty(this, "container", undefined);
|
73
|
+
_defineProperty(this, "ringPopupTarget", undefined);
|
74
74
|
_defineProperty(this, "listeners", new Listeners());
|
75
75
|
_defineProperty(this, "redrawScheduler", scheduleRAF(true));
|
76
76
|
_defineProperty(this, "uid", getUID('popup-'));
|
@@ -131,8 +131,8 @@ class Popup extends PureComponent {
|
|
131
131
|
this.redrawScheduler(this._updatePosition);
|
132
132
|
}
|
133
133
|
});
|
134
|
-
_defineProperty(this, "_listenersEnabled",
|
135
|
-
_defineProperty(this, "_prevTimeout",
|
134
|
+
_defineProperty(this, "_listenersEnabled", undefined);
|
135
|
+
_defineProperty(this, "_prevTimeout", undefined);
|
136
136
|
_defineProperty(this, "_onEscPress", evt => {
|
137
137
|
this.props.onEscPress(evt);
|
138
138
|
this._onCloseAttempt(evt, true);
|
@@ -143,7 +143,7 @@ class Popup extends PureComponent {
|
|
143
143
|
*/
|
144
144
|
_defineProperty(this, "_onDocumentClick", evt => {
|
145
145
|
var _this$_getAnchor;
|
146
|
-
if (this.container && evt.target instanceof Node && this.container.contains(evt.target) || !this._listenersEnabled || this.props.dontCloseOnAnchorClick && evt.target instanceof Node && (_this$_getAnchor = this._getAnchor()) !== null && _this$_getAnchor !==
|
146
|
+
if (this.container && evt.target instanceof Node && this.container.contains(evt.target) || !this._listenersEnabled || this.props.dontCloseOnAnchorClick && evt.target instanceof Node && (_this$_getAnchor = this._getAnchor()) !== null && _this$_getAnchor !== undefined && _this$_getAnchor.contains(evt.target)) {
|
147
147
|
return;
|
148
148
|
}
|
149
149
|
this.props.onOutsideClick(evt);
|
@@ -246,7 +246,7 @@ function position(attrs) {
|
|
246
246
|
anchorRect,
|
247
247
|
maxHeight,
|
248
248
|
direction: chosenDirection,
|
249
|
-
popupScrollHeight: (_popup$scrollHeight = popup === null || popup ===
|
249
|
+
popupScrollHeight: (_popup$scrollHeight = popup === null || popup === undefined ? undefined : popup.scrollHeight) !== null && _popup$scrollHeight !== undefined ? _popup$scrollHeight : 0,
|
250
250
|
scroll
|
251
251
|
});
|
252
252
|
}
|
@@ -13,11 +13,11 @@ const _excluded = ["className", "global", "max", "value", "label", "staticColor"
|
|
13
13
|
class ProgressBar extends PureComponent {
|
14
14
|
constructor() {
|
15
15
|
super(...arguments);
|
16
|
-
_defineProperty(this, "progressbarWrapper",
|
16
|
+
_defineProperty(this, "progressbarWrapper", undefined);
|
17
17
|
_defineProperty(this, "progressbarWrapperRef", el => {
|
18
18
|
this.progressbarWrapper = el;
|
19
19
|
});
|
20
|
-
_defineProperty(this, "progressbar",
|
20
|
+
_defineProperty(this, "progressbar", undefined);
|
21
21
|
_defineProperty(this, "progressbarRef", el => {
|
22
22
|
this.progressbar = el;
|
23
23
|
});
|