@commercetools-frontend/application-components 22.17.2 → 22.18.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/dist/commercetools-frontend-application-components.cjs.dev.js +266 -144
- package/dist/commercetools-frontend-application-components.cjs.prod.js +205 -101
- package/dist/commercetools-frontend-application-components.esm.js +265 -146
- package/dist/declarations/src/components/dialogs/confirmation-dialog/confirmation-dialog.d.ts +8 -4
- package/dist/declarations/src/components/dialogs/confirmation-dialog/index.d.ts +1 -1
- package/dist/declarations/src/components/dialogs/form-dialog/form-dialog.d.ts +8 -4
- package/dist/declarations/src/components/dialogs/form-dialog/index.d.ts +1 -1
- package/dist/declarations/src/components/dialogs/info-dialog/index.d.ts +1 -1
- package/dist/declarations/src/components/dialogs/info-dialog/info-dialog.d.ts +7 -3
- package/dist/declarations/src/components/dialogs/internals/dialog-container.d.ts +2 -1
- package/dist/declarations/src/components/dialogs/internals/dialog-header.d.ts +6 -2
- package/dist/declarations/src/components/project-stamp/messages.d.ts +19 -0
- package/dist/declarations/src/components/project-stamp/project-stamp.d.ts +9 -0
- package/dist/declarations/src/index.d.ts +1 -0
- package/package.json +10 -9
|
@@ -48,6 +48,9 @@ var _findInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/insta
|
|
|
48
48
|
var _Object$entries = require('@babel/runtime-corejs3/core-js-stable/object/entries');
|
|
49
49
|
var PageNotFoundSVG = require('@commercetools-frontend/assets/images/page-not-found.svg');
|
|
50
50
|
var FailedAuthorizationSVG = require('@commercetools-frontend/assets/images/doors-closed.svg');
|
|
51
|
+
var _objectWithoutProperties = require('@babel/runtime-corejs3/helpers/objectWithoutProperties');
|
|
52
|
+
var _valuesInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/values');
|
|
53
|
+
var Stamp = require('@commercetools-uikit/stamp');
|
|
51
54
|
var useResizeObserver = require('@react-hook/resize-observer');
|
|
52
55
|
var hooks = require('@commercetools-uikit/hooks');
|
|
53
56
|
|
|
@@ -82,20 +85,22 @@ var _findInstanceProperty__default = /*#__PURE__*/_interopDefault(_findInstanceP
|
|
|
82
85
|
var _Object$entries__default = /*#__PURE__*/_interopDefault(_Object$entries);
|
|
83
86
|
var PageNotFoundSVG__default = /*#__PURE__*/_interopDefault(PageNotFoundSVG);
|
|
84
87
|
var FailedAuthorizationSVG__default = /*#__PURE__*/_interopDefault(FailedAuthorizationSVG);
|
|
88
|
+
var _valuesInstanceProperty__default = /*#__PURE__*/_interopDefault(_valuesInstanceProperty);
|
|
89
|
+
var Stamp__default = /*#__PURE__*/_interopDefault(Stamp);
|
|
85
90
|
var useResizeObserver__default = /*#__PURE__*/_interopDefault(useResizeObserver);
|
|
86
91
|
|
|
87
92
|
// NOTE: This string will be replaced on build time with the package version.
|
|
88
|
-
var version = "22.
|
|
93
|
+
var version = "22.18.0";
|
|
89
94
|
|
|
90
95
|
const getBottomBorderStyles = background => /*#__PURE__*/react.css(":after{content:'';position:absolute;bottom:0;left:0;right:0;height:2px;border-radius:", designSystem.designTokens.borderRadius2, ";background-color:", background, ";transition:background-color ", designSystem.designTokens.transitionEaseinout150Ms, ";}" + ("" ), "" );
|
|
91
|
-
var _ref$
|
|
96
|
+
var _ref$8 = {
|
|
92
97
|
name: "1u0tiat",
|
|
93
98
|
styles: "&[aria-disabled='true']{cursor:not-allowed;opacity:0.5;&:active{pointer-events:none;}}"
|
|
94
99
|
} ;
|
|
95
|
-
const getLinkStyles = (isActive, isDisabled) => [/*#__PURE__*/react.css("font-size:", designSystem.designTokens.fontSize30, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";position:relative;text-align:center;display:inline-block;color:inherit;text-decoration:inherit;&:first-of-type{padding-left:", designSystem.designTokens.spacing30, ";}", getBottomBorderStyles('transparent'), ";" + ("" ), "" ), isActive && /*#__PURE__*/react.css(getBottomBorderStyles(designSystem.designTokens.colorPrimary), " & h4{color:", designSystem.designTokens.colorPrimary, "!important;}" + ("" ), "" ), isDisabled && _ref$
|
|
100
|
+
const getLinkStyles = (isActive, isDisabled) => [/*#__PURE__*/react.css("font-size:", designSystem.designTokens.fontSize30, ";padding:", designSystem.designTokens.spacingS, " ", designSystem.designTokens.spacingM, ";position:relative;text-align:center;display:inline-block;color:inherit;text-decoration:inherit;&:first-of-type{padding-left:", designSystem.designTokens.spacing30, ";}", getBottomBorderStyles('transparent'), ";" + ("" ), "" ), isActive && /*#__PURE__*/react.css(getBottomBorderStyles(designSystem.designTokens.colorPrimary), " & h4{color:", designSystem.designTokens.colorPrimary, "!important;}" + ("" ), "" ), isDisabled && _ref$8, !isActive && !isDisabled && /*#__PURE__*/react.css(":hover,:focus,:active{& h4{color:", designSystem.designTokens.colorPrimary, "!important;}}" + ("" ), "" )];
|
|
96
101
|
|
|
97
|
-
function ownKeys$
|
|
98
|
-
function _objectSpread$
|
|
102
|
+
function ownKeys$8(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
103
|
+
function _objectSpread$8(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$8(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$8(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
99
104
|
const pathWithoutSearch$1 = path => typeof path === 'string' ? path.split('?')[0] : path.pathname;
|
|
100
105
|
const warnIfMissingContent = props => {
|
|
101
106
|
Boolean(props.intlMessage) || Boolean(props.label);
|
|
@@ -127,7 +132,7 @@ const TabHeader = props => {
|
|
|
127
132
|
label = intl.formatMessage(props.intlMessage);
|
|
128
133
|
}
|
|
129
134
|
warnIfMissingContent(props);
|
|
130
|
-
return jsxRuntime.jsx(reactRouterDom.Link, _objectSpread$
|
|
135
|
+
return jsxRuntime.jsx(reactRouterDom.Link, _objectSpread$8(_objectSpread$8({
|
|
131
136
|
role: "tab",
|
|
132
137
|
"aria-selected": isActive,
|
|
133
138
|
to: props.to,
|
|
@@ -184,13 +189,13 @@ const getModalContentStyles = props => {
|
|
|
184
189
|
const getOverlayStyles$1 = props => /*#__PURE__*/react.css("display:flex;position:absolute;z-index:", typeof props.zIndex === 'number' ? // Use `!important` to overwrite the default value assigned by the Stacking Layer System.
|
|
185
190
|
"".concat(props.zIndex, " !important") : 'auto', ";top:0;width:100%;height:100%;background-color:rgba(32, 62, 72, 0.5);opacity:1;" + ("" ), "" );
|
|
186
191
|
|
|
187
|
-
function ownKeys$
|
|
188
|
-
function _objectSpread$
|
|
192
|
+
function ownKeys$7(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
193
|
+
function _objectSpread$7(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$7(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$7(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
189
194
|
const getDefaultParentSelector$1 = () => document.querySelector("#".concat(constants.PORTALS_CONTAINER_ID));
|
|
190
195
|
const getOverlayElement$1 = (props, contentElement) =>
|
|
191
196
|
// Assign the `data-role` to the overlay container, which is used as
|
|
192
197
|
// the CSS selector in the `<PortalsContainer>`.
|
|
193
|
-
jsxRuntime.jsx("div", _objectSpread$
|
|
198
|
+
jsxRuntime.jsx("div", _objectSpread$7(_objectSpread$7({}, props), {}, {
|
|
194
199
|
"data-role": "dialog-overlay",
|
|
195
200
|
children: contentElement
|
|
196
201
|
}));
|
|
@@ -205,7 +210,7 @@ const defaultProps$i = {
|
|
|
205
210
|
const GridArea = /*#__PURE__*/_styled__default["default"]("div", {
|
|
206
211
|
target: "elx55gk0"
|
|
207
212
|
} )("grid-area:", props => props.name, ";" + ("" ));
|
|
208
|
-
var _ref$
|
|
213
|
+
var _ref$7 = {
|
|
209
214
|
name: "1daj17f",
|
|
210
215
|
styles: "display:flex;flex-direction:column;align-items:stretch;height:100%;min-height:0"
|
|
211
216
|
} ;
|
|
@@ -213,45 +218,48 @@ var _ref2$3 = {
|
|
|
213
218
|
name: "1187q51",
|
|
214
219
|
styles: "display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;overflow:hidden"
|
|
215
220
|
} ;
|
|
216
|
-
const DialogContainer = props =>
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
css:
|
|
248
|
-
children:
|
|
221
|
+
const DialogContainer = props => {
|
|
222
|
+
utils.useWarning(typeof props.title === 'string' || typeof props.title !== 'string' && Boolean(props['aria-label']), 'app-kit/DialogHeader: "aria-label" prop is required when the "title" prop is not a string.');
|
|
223
|
+
return jsxRuntime.jsx(react.ClassNames, {
|
|
224
|
+
children: _ref3 => {
|
|
225
|
+
let makeClassName = _ref3.css;
|
|
226
|
+
return jsxRuntime.jsxs(Modal__default["default"], {
|
|
227
|
+
isOpen: props.isOpen,
|
|
228
|
+
onRequestClose: props.onClose,
|
|
229
|
+
shouldCloseOnOverlayClick: Boolean(props.onClose),
|
|
230
|
+
shouldCloseOnEsc: Boolean(props.onClose),
|
|
231
|
+
overlayElement: getOverlayElement$1,
|
|
232
|
+
overlayClassName: makeClassName(getOverlayStyles$1(props)),
|
|
233
|
+
className: makeClassName(getModalContentStyles(props)),
|
|
234
|
+
contentLabel: typeof props.title === 'string' ? props.title : props['aria-label'],
|
|
235
|
+
parentSelector: props.getParentSelector,
|
|
236
|
+
ariaHideApp: false,
|
|
237
|
+
children: [jsxRuntime.jsx(GridArea, {
|
|
238
|
+
name: "top"
|
|
239
|
+
}), jsxRuntime.jsx(GridArea, {
|
|
240
|
+
name: "left"
|
|
241
|
+
}), jsxRuntime.jsx(GridArea, {
|
|
242
|
+
name: "right"
|
|
243
|
+
}), jsxRuntime.jsx(GridArea, {
|
|
244
|
+
name: "bottom"
|
|
245
|
+
}), jsxRuntime.jsx(GridArea, {
|
|
246
|
+
name: "main",
|
|
247
|
+
css: _ref2$3,
|
|
248
|
+
children: jsxRuntime.jsx(Card__default["default"]
|
|
249
|
+
// 1. For the min-height: https://stackoverflow.com/questions/28636832/firefox-overflow-y-not-working-with-nested-flexbox/28639686#28639686
|
|
250
|
+
// 2. For the actual "> div" container with the content, we need to use normal pointer events so that clicking on it does not close the dialog.
|
|
251
|
+
, {
|
|
252
|
+
css: /*#__PURE__*/react.css("min-height:0;padding:", designSystem.designTokens.spacing20, " ", designSystem.designTokens.spacing30, ";>div{display:flex;flex-direction:column;height:100%;pointer-events:auto;min-height:0;}" + ("" ), "" ),
|
|
253
|
+
children: jsxRuntime.jsx("div", {
|
|
254
|
+
css: _ref$7,
|
|
255
|
+
children: props.children
|
|
256
|
+
})
|
|
249
257
|
})
|
|
250
|
-
})
|
|
251
|
-
})
|
|
252
|
-
}
|
|
253
|
-
}
|
|
254
|
-
}
|
|
258
|
+
})]
|
|
259
|
+
});
|
|
260
|
+
}
|
|
261
|
+
});
|
|
262
|
+
};
|
|
255
263
|
DialogContainer.propTypes = {};
|
|
256
264
|
DialogContainer.displayName = 'DialogContainer';
|
|
257
265
|
DialogContainer.defaultProps = defaultProps$i;
|
|
@@ -261,13 +269,23 @@ const DialogContent = /*#__PURE__*/_styled__default["default"]("div", {
|
|
|
261
269
|
target: "eo6zkz80"
|
|
262
270
|
} )("border-top:1px solid ", designSystem.designTokens.colorNeutral90, ";padding:", designSystem.designTokens.spacing40, " 0 0;flex:1;overflow:auto;" + ("" ));
|
|
263
271
|
|
|
272
|
+
const TextTitle = props => jsxRuntime.jsx(Text__default["default"].Headline, {
|
|
273
|
+
as: "h3",
|
|
274
|
+
title: props.title,
|
|
275
|
+
truncate: true,
|
|
276
|
+
children: props.title
|
|
277
|
+
});
|
|
278
|
+
TextTitle.propTypes = {};
|
|
264
279
|
const Title$1 = props => {
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
280
|
+
if (typeof props.title === 'string') {
|
|
281
|
+
return jsxRuntime.jsx(TextTitle, {
|
|
282
|
+
title: props.title
|
|
283
|
+
});
|
|
284
|
+
} else {
|
|
285
|
+
return jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
286
|
+
children: props.title
|
|
287
|
+
});
|
|
288
|
+
}
|
|
271
289
|
};
|
|
272
290
|
const DialogHeader = props => jsxRuntime.jsx("div", {
|
|
273
291
|
css: /*#__PURE__*/react.css("flex:0 1 auto;display:flex;flex-direction:column;margin-bottom:", designSystem.designTokens.spacing30, ";" + ("" ), "" ),
|
|
@@ -294,6 +312,7 @@ const InfoDialog = props => jsxRuntime.jsxs(DialogContainer, {
|
|
|
294
312
|
size: props.size,
|
|
295
313
|
zIndex: props.zIndex,
|
|
296
314
|
title: props.title,
|
|
315
|
+
"aria-label": props['aria-label'],
|
|
297
316
|
getParentSelector: props.getParentSelector,
|
|
298
317
|
children: [jsxRuntime.jsx(DialogHeader, {
|
|
299
318
|
title: props.title,
|
|
@@ -305,12 +324,16 @@ const InfoDialog = props => jsxRuntime.jsxs(DialogContainer, {
|
|
|
305
324
|
InfoDialog.propTypes = {};
|
|
306
325
|
InfoDialog.displayName = 'InfoDialog';
|
|
307
326
|
|
|
327
|
+
// Allow consumers who want to use a custom title to reuse the same title styles
|
|
328
|
+
// as the default dialog title.
|
|
329
|
+
InfoDialog.TextTitle = TextTitle;
|
|
330
|
+
|
|
308
331
|
function filterDataAttributes(obj) {
|
|
309
332
|
return omitBy__default["default"](obj, (_value, key) => !_startsWithInstanceProperty__default["default"](key).call(key, 'data-'));
|
|
310
333
|
}
|
|
311
334
|
|
|
312
|
-
function ownKeys$
|
|
313
|
-
function _objectSpread$
|
|
335
|
+
function ownKeys$6(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
336
|
+
function _objectSpread$6(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$6(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$6(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
314
337
|
const defaultProps$h = {
|
|
315
338
|
isPrimaryButtonDisabled: false,
|
|
316
339
|
dataAttributesPrimaryButton: {},
|
|
@@ -325,11 +348,11 @@ const DialogFooter = props => {
|
|
|
325
348
|
scale: "m",
|
|
326
349
|
alignItems: "center",
|
|
327
350
|
justifyContent: "flex-end",
|
|
328
|
-
children: [jsxRuntime.jsx(SecondaryButton__default["default"], _objectSpread$
|
|
351
|
+
children: [jsxRuntime.jsx(SecondaryButton__default["default"], _objectSpread$6({
|
|
329
352
|
label: getFormattedLabel(props.labelSecondary, intl),
|
|
330
353
|
onClick: props.onCancel,
|
|
331
354
|
iconLeft: props.iconLeftSecondaryButton
|
|
332
|
-
}, filterDataAttributes(props.dataAttributesSecondaryButton))), jsxRuntime.jsx(PrimaryButton__default["default"], _objectSpread$
|
|
355
|
+
}, filterDataAttributes(props.dataAttributesSecondaryButton))), jsxRuntime.jsx(PrimaryButton__default["default"], _objectSpread$6({
|
|
333
356
|
label: getFormattedLabel(props.labelPrimary, intl),
|
|
334
357
|
onClick: props.onConfirm,
|
|
335
358
|
isDisabled: props.isPrimaryButtonDisabled
|
|
@@ -351,6 +374,7 @@ const ConfirmationDialog = props => jsxRuntime.jsxs(DialogContainer, {
|
|
|
351
374
|
size: props.size,
|
|
352
375
|
zIndex: props.zIndex,
|
|
353
376
|
title: props.title,
|
|
377
|
+
"aria-label": props['aria-label'],
|
|
354
378
|
getParentSelector: props.getParentSelector,
|
|
355
379
|
children: [jsxRuntime.jsx(DialogHeader, {
|
|
356
380
|
title: props.title,
|
|
@@ -373,6 +397,9 @@ ConfirmationDialog.defaultProps = defaultProps$g;
|
|
|
373
397
|
// This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
|
|
374
398
|
// The Intl messages can be used for button labels.
|
|
375
399
|
ConfirmationDialog.Intl = i18n.sharedMessages;
|
|
400
|
+
// Allow consumers who want to use a custom title to reuse the same title styles
|
|
401
|
+
// as the default dialog title.
|
|
402
|
+
ConfirmationDialog.TextTitle = TextTitle;
|
|
376
403
|
|
|
377
404
|
const defaultProps$f = {
|
|
378
405
|
labelSecondary: i18n.sharedMessages.cancel,
|
|
@@ -384,6 +411,7 @@ const FormDialog = props => jsxRuntime.jsxs(DialogContainer, {
|
|
|
384
411
|
size: props.size,
|
|
385
412
|
zIndex: props.zIndex,
|
|
386
413
|
title: props.title,
|
|
414
|
+
"aria-label": props['aria-label'],
|
|
387
415
|
getParentSelector: props.getParentSelector,
|
|
388
416
|
children: [jsxRuntime.jsx(DialogHeader, {
|
|
389
417
|
title: props.title,
|
|
@@ -407,8 +435,11 @@ FormDialog.defaultProps = defaultProps$f;
|
|
|
407
435
|
// This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
|
|
408
436
|
// The Intl messages can be used for button labels.
|
|
409
437
|
FormDialog.Intl = i18n.sharedMessages;
|
|
438
|
+
// Allow consumers who want to use a custom title to reuse the same title styles
|
|
439
|
+
// as the default dialog title.
|
|
440
|
+
FormDialog.TextTitle = TextTitle;
|
|
410
441
|
|
|
411
|
-
const messages$
|
|
442
|
+
const messages$5 = reactIntl.defineMessages({
|
|
412
443
|
back: {
|
|
413
444
|
id: 'Components.ModalPage.TopBar.Back',
|
|
414
445
|
defaultMessage: 'Go Back'
|
|
@@ -437,10 +468,10 @@ const LargeIconWrapper = props => jsxRuntime.jsx("span", {
|
|
|
437
468
|
LargeIconWrapper.propTypes = {};
|
|
438
469
|
const defaultProps$e = {
|
|
439
470
|
color: 'surface',
|
|
440
|
-
previousPathLabel: messages$
|
|
471
|
+
previousPathLabel: messages$5.back,
|
|
441
472
|
hidePathLabel: false
|
|
442
473
|
};
|
|
443
|
-
var _ref$
|
|
474
|
+
var _ref$6 = {
|
|
444
475
|
name: "uvw8rn",
|
|
445
476
|
styles: "display:flex;overflow:hidden;button:first-of-type svg{height:12px!important;width:12px!important;}"
|
|
446
477
|
} ;
|
|
@@ -449,7 +480,7 @@ const ModalPageTopBar = props => {
|
|
|
449
480
|
return jsxRuntime.jsxs("div", {
|
|
450
481
|
css: /*#__PURE__*/react.css("position:relative;display:flex;align-items:center;justify-content:space-between;padding:", designSystem.designTokens.spacing40, " ", designSystem.designTokens.spacing55, " 0;background-color:", designSystem.designTokens.colorSurface, ";border-bottom:1px solid ", designSystem.designTokens.colorSurface, ";& *+*{margin-left:", designSystem.designTokens.spacingS, ";}p{font-size:12px!important;}" + ("" ), "" ),
|
|
451
482
|
children: [jsxRuntime.jsxs("div", {
|
|
452
|
-
css: _ref$
|
|
483
|
+
css: _ref$6,
|
|
453
484
|
children: [!props.hidePathLabel && jsxRuntime.jsx(FlatButton__default["default"], {
|
|
454
485
|
tone: "primary",
|
|
455
486
|
label: typeof props.previousPathLabel === 'string' ? props.previousPathLabel : intl.formatMessage(props.previousPathLabel),
|
|
@@ -470,7 +501,7 @@ const ModalPageTopBar = props => {
|
|
|
470
501
|
})]
|
|
471
502
|
})]
|
|
472
503
|
}), props.onClose && jsxRuntime.jsx(SecondaryIconButton__default["default"], {
|
|
473
|
-
label: intl.formatMessage(messages$
|
|
504
|
+
label: intl.formatMessage(messages$5.close),
|
|
474
505
|
onClick: props.onClose,
|
|
475
506
|
icon: jsxRuntime.jsx(LargeIconWrapper, {
|
|
476
507
|
children: jsxRuntime.jsx(icons.CloseIcon, {})
|
|
@@ -520,19 +551,19 @@ var _ref2$1 = {
|
|
|
520
551
|
} ;
|
|
521
552
|
const getAfterOpenOverlayAnimation = () => _ref2$1;
|
|
522
553
|
const getBeforeCloseContainerAnimation = props => /*#__PURE__*/react.css("transform:translate3d(\n ", props.size !== 'scale' ? stylesBySize[props.size].width : '30px', ",\n ,\n 0,\n 0\n )!important;" + ("" ), "" );
|
|
523
|
-
var _ref$
|
|
554
|
+
var _ref$5 = {
|
|
524
555
|
name: "728dx5",
|
|
525
556
|
styles: "opacity:0!important"
|
|
526
557
|
} ;
|
|
527
|
-
const getBeforeCloseOverlayAnimation = () => _ref$
|
|
558
|
+
const getBeforeCloseOverlayAnimation = () => _ref$5;
|
|
528
559
|
|
|
529
|
-
function ownKeys$
|
|
530
|
-
function _objectSpread$
|
|
560
|
+
function ownKeys$5(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
561
|
+
function _objectSpread$5(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$5(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$5(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
531
562
|
const getDefaultParentSelector = () => document.querySelector("#".concat(constants.PORTALS_CONTAINER_ID));
|
|
532
563
|
const getOverlayElement = (props, contentElement) =>
|
|
533
564
|
// Assign the `data-role` to the overlay container, which is used as
|
|
534
565
|
// the CSS selector in the `<PortalsContainer>`.
|
|
535
|
-
jsxRuntime.jsx("div", _objectSpread$
|
|
566
|
+
jsxRuntime.jsx("div", _objectSpread$5(_objectSpread$5({}, props), {}, {
|
|
536
567
|
"data-role": "modal-overlay",
|
|
537
568
|
children: contentElement
|
|
538
569
|
}));
|
|
@@ -621,7 +652,7 @@ ModalPage.propTypes = {};
|
|
|
621
652
|
ModalPage.displayName = 'ModalPage';
|
|
622
653
|
ModalPage.defaultProps = defaultProps$d;
|
|
623
654
|
|
|
624
|
-
const messages$
|
|
655
|
+
const messages$4 = reactIntl.defineMessages({
|
|
625
656
|
loadError: {
|
|
626
657
|
id: 'CustomViewLoader.error.load',
|
|
627
658
|
defaultMessage: 'We could not load the Custom View. Please contact your administrator to check its configuration.'
|
|
@@ -682,7 +713,7 @@ function CustomViewLoader(props) {
|
|
|
682
713
|
showNotification({
|
|
683
714
|
domain: constants.DOMAINS.PAGE,
|
|
684
715
|
kind: constants.NOTIFICATION_KINDS_PAGE.error,
|
|
685
|
-
text: intl.formatMessage(messages$
|
|
716
|
+
text: intl.formatMessage(messages$4.loadError)
|
|
686
717
|
});
|
|
687
718
|
return;
|
|
688
719
|
}
|
|
@@ -745,7 +776,7 @@ function CustomViewLoader(props) {
|
|
|
745
776
|
}
|
|
746
777
|
CustomViewLoader.propTypes = {};
|
|
747
778
|
|
|
748
|
-
var messages$
|
|
779
|
+
var messages$3 = reactIntl.defineMessages({
|
|
749
780
|
title: {
|
|
750
781
|
id: 'CustomViewsSelector.title',
|
|
751
782
|
defaultMessage: 'Custom Views:'
|
|
@@ -776,8 +807,8 @@ const useCustomViewsConnector = _ref => {
|
|
|
776
807
|
};
|
|
777
808
|
};
|
|
778
809
|
|
|
779
|
-
function ownKeys$
|
|
780
|
-
function _objectSpread$
|
|
810
|
+
function ownKeys$4(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
811
|
+
function _objectSpread$4(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$4(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$4(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
781
812
|
const COMPONENT_HEIGHT = '52px';
|
|
782
813
|
const Wrapper = /*#__PURE__*/_styled__default["default"]("div", {
|
|
783
814
|
target: "e16cb3zv3"
|
|
@@ -852,7 +883,7 @@ function CustomViewSelector(props) {
|
|
|
852
883
|
color: "neutral60"
|
|
853
884
|
}), jsxRuntime.jsx(Text__default["default"].Detail, {
|
|
854
885
|
tone: "secondary",
|
|
855
|
-
intlMessage: messages$
|
|
886
|
+
intlMessage: messages$3.title
|
|
856
887
|
})]
|
|
857
888
|
}), _mapInstanceProperty__default["default"](customViews).call(customViews, (customView, index) => {
|
|
858
889
|
const isNotLastItem = index !== customViews.length - 1;
|
|
@@ -882,7 +913,7 @@ const CustomViewSelectorOrNothing = props => {
|
|
|
882
913
|
if (!props.customViewLocatorCode) {
|
|
883
914
|
return null;
|
|
884
915
|
}
|
|
885
|
-
return jsxRuntime.jsx(CustomViewSelector, _objectSpread$
|
|
916
|
+
return jsxRuntime.jsx(CustomViewSelector, _objectSpread$4(_objectSpread$4({}, props), {}, {
|
|
886
917
|
customViewLocatorCode: props.customViewLocatorCode
|
|
887
918
|
}));
|
|
888
919
|
};
|
|
@@ -942,12 +973,12 @@ Subtitle.propTypes = {};
|
|
|
942
973
|
Subtitle.defaultProps = {
|
|
943
974
|
truncate: false
|
|
944
975
|
};
|
|
945
|
-
var _ref$
|
|
976
|
+
var _ref$4 = {
|
|
946
977
|
name: "d3v9zr",
|
|
947
978
|
styles: "overflow:hidden"
|
|
948
979
|
} ;
|
|
949
980
|
const PageHeaderTitle = props => jsxRuntime.jsxs("div", {
|
|
950
|
-
css: _ref$
|
|
981
|
+
css: _ref$4,
|
|
951
982
|
children: [jsxRuntime.jsx(Title, {
|
|
952
983
|
title: props.title,
|
|
953
984
|
titleSize: props.titleSize,
|
|
@@ -1033,8 +1064,8 @@ const InfoModalPage = props => jsxRuntime.jsxs(ModalPage, {
|
|
|
1033
1064
|
InfoModalPage.propTypes = {};
|
|
1034
1065
|
InfoModalPage.displayName = 'InfoModalPage';
|
|
1035
1066
|
|
|
1036
|
-
function ownKeys$
|
|
1037
|
-
function _objectSpread$
|
|
1067
|
+
function ownKeys$3(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1068
|
+
function _objectSpread$3(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$3(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$3(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1038
1069
|
const primaryDefaultProps = {
|
|
1039
1070
|
label: i18n.sharedMessages.confirm,
|
|
1040
1071
|
isDisabled: false,
|
|
@@ -1046,7 +1077,7 @@ const useFormattedLabel = label => {
|
|
|
1046
1077
|
};
|
|
1047
1078
|
const FormPrimaryButton = props => {
|
|
1048
1079
|
const label = useFormattedLabel(props.label);
|
|
1049
|
-
return jsxRuntime.jsx(PrimaryButton__default["default"], _objectSpread$
|
|
1080
|
+
return jsxRuntime.jsx(PrimaryButton__default["default"], _objectSpread$3({
|
|
1050
1081
|
label: label,
|
|
1051
1082
|
onClick: props.onClick,
|
|
1052
1083
|
isDisabled: props.isDisabled
|
|
@@ -1062,7 +1093,7 @@ const secondaryDefaultProps = {
|
|
|
1062
1093
|
};
|
|
1063
1094
|
const FormSecondaryButton = props => {
|
|
1064
1095
|
const label = useFormattedLabel(props.label);
|
|
1065
|
-
return jsxRuntime.jsx(SecondaryButton__default["default"], _objectSpread$
|
|
1096
|
+
return jsxRuntime.jsx(SecondaryButton__default["default"], _objectSpread$3({
|
|
1066
1097
|
label: label,
|
|
1067
1098
|
onClick: props.onClick,
|
|
1068
1099
|
isDisabled: props.isDisabled,
|
|
@@ -1079,7 +1110,7 @@ const deleteDefaultProps = {
|
|
|
1079
1110
|
};
|
|
1080
1111
|
const FormDeleteButton = props => {
|
|
1081
1112
|
const label = useFormattedLabel(props.label);
|
|
1082
|
-
return jsxRuntime.jsx(IconButton__default["default"], _objectSpread$
|
|
1113
|
+
return jsxRuntime.jsx(IconButton__default["default"], _objectSpread$3({
|
|
1083
1114
|
icon: jsxRuntime.jsx(icons.BinLinearIcon, {}),
|
|
1084
1115
|
label: label,
|
|
1085
1116
|
onClick: props.onClick,
|
|
@@ -1268,7 +1299,7 @@ TabularModalPage.Intl = i18n.sharedMessages;
|
|
|
1268
1299
|
|
|
1269
1300
|
const defaultProps$8 = {
|
|
1270
1301
|
color: 'surface',
|
|
1271
|
-
previousPathLabel: messages$
|
|
1302
|
+
previousPathLabel: messages$5.back
|
|
1272
1303
|
};
|
|
1273
1304
|
const PageTopBar = props => {
|
|
1274
1305
|
const intl = reactIntl.useIntl();
|
|
@@ -1618,7 +1649,7 @@ TabularMainPage.PageHeaderTitle = PageHeaderTitle;
|
|
|
1618
1649
|
// This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
|
|
1619
1650
|
TabularMainPage.Intl = i18n.sharedMessages;
|
|
1620
1651
|
|
|
1621
|
-
var _ref$
|
|
1652
|
+
var _ref$3 = {
|
|
1622
1653
|
name: "zl1inp",
|
|
1623
1654
|
styles: "display:flex;justify-content:center"
|
|
1624
1655
|
} ;
|
|
@@ -1646,7 +1677,7 @@ const MaintenancePageLayout = props => jsxRuntime.jsx("div", {
|
|
|
1646
1677
|
}), jsxRuntime.jsx(Text__default["default"].Body, {
|
|
1647
1678
|
children: props.paragraph1
|
|
1648
1679
|
}), props.bodyContent && jsxRuntime.jsx("div", {
|
|
1649
|
-
css: _ref$
|
|
1680
|
+
css: _ref$3,
|
|
1650
1681
|
children: props.bodyContent
|
|
1651
1682
|
}), props.paragraph2 && jsxRuntime.jsx(Text__default["default"].Body, {
|
|
1652
1683
|
children: props.paragraph2
|
|
@@ -1657,7 +1688,7 @@ const MaintenancePageLayout = props => jsxRuntime.jsx("div", {
|
|
|
1657
1688
|
MaintenancePageLayout.propTypes = {};
|
|
1658
1689
|
MaintenancePageLayout.displayName = 'MaintenancePageLayout';
|
|
1659
1690
|
|
|
1660
|
-
var messages$
|
|
1691
|
+
var messages$2 = reactIntl.defineMessages({
|
|
1661
1692
|
title: {
|
|
1662
1693
|
id: 'PageNotFound.title',
|
|
1663
1694
|
defaultMessage: 'We could not find what you are looking for'
|
|
@@ -1668,8 +1699,8 @@ var messages$1 = reactIntl.defineMessages({
|
|
|
1668
1699
|
}
|
|
1669
1700
|
});
|
|
1670
1701
|
|
|
1671
|
-
function ownKeys$
|
|
1672
|
-
function _objectSpread$
|
|
1702
|
+
function ownKeys$2(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1703
|
+
function _objectSpread$2(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$2(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$2(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1673
1704
|
const getLink = msg => jsxRuntime.jsx("a", {
|
|
1674
1705
|
href: constants.SUPPORT_PORTAL_URL,
|
|
1675
1706
|
target: "_blank",
|
|
@@ -1680,9 +1711,9 @@ const PageNotFound = () => {
|
|
|
1680
1711
|
const intl = reactIntl.useIntl();
|
|
1681
1712
|
return jsxRuntime.jsx(MaintenancePageLayout, {
|
|
1682
1713
|
imageSrc: PageNotFoundSVG__default["default"],
|
|
1683
|
-
title: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
1684
|
-
label: intl.formatMessage(messages$
|
|
1685
|
-
paragraph1: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$
|
|
1714
|
+
title: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$2({}, messages$2.title)),
|
|
1715
|
+
label: intl.formatMessage(messages$2.title),
|
|
1716
|
+
paragraph1: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$2(_objectSpread$2({}, messages$2.paragraph1), {}, {
|
|
1686
1717
|
values: {
|
|
1687
1718
|
a: getLink
|
|
1688
1719
|
}
|
|
@@ -1691,7 +1722,7 @@ const PageNotFound = () => {
|
|
|
1691
1722
|
};
|
|
1692
1723
|
PageNotFound.displayName = 'PageNotFound';
|
|
1693
1724
|
|
|
1694
|
-
var messages = reactIntl.defineMessages({
|
|
1725
|
+
var messages$1 = reactIntl.defineMessages({
|
|
1695
1726
|
title: {
|
|
1696
1727
|
id: 'PageUnauthorized.title',
|
|
1697
1728
|
defaultMessage: 'We could not find what you are looking for'
|
|
@@ -1706,8 +1737,8 @@ var messages = reactIntl.defineMessages({
|
|
|
1706
1737
|
}
|
|
1707
1738
|
});
|
|
1708
1739
|
|
|
1709
|
-
function ownKeys(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1710
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1740
|
+
function ownKeys$1(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1741
|
+
function _objectSpread$1(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$1(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$1(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1711
1742
|
const getSupportUrlLink = msg => jsxRuntime.jsx("a", {
|
|
1712
1743
|
href: constants.SUPPORT_PORTAL_URL,
|
|
1713
1744
|
target: "_blank",
|
|
@@ -1718,10 +1749,10 @@ const PageUnauthorized = () => {
|
|
|
1718
1749
|
const intl = reactIntl.useIntl();
|
|
1719
1750
|
return jsxRuntime.jsx(MaintenancePageLayout, {
|
|
1720
1751
|
imageSrc: FailedAuthorizationSVG__default["default"],
|
|
1721
|
-
title: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread({}, messages.title)),
|
|
1722
|
-
label: intl.formatMessage(messages.title),
|
|
1723
|
-
paragraph1: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread({}, messages.paragraph1)),
|
|
1724
|
-
paragraph2: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread(_objectSpread({}, messages.paragraph2), {}, {
|
|
1752
|
+
title: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$1({}, messages$1.title)),
|
|
1753
|
+
label: intl.formatMessage(messages$1.title),
|
|
1754
|
+
paragraph1: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$1({}, messages$1.paragraph1)),
|
|
1755
|
+
paragraph2: jsxRuntime.jsx(reactIntl.FormattedMessage, _objectSpread$1(_objectSpread$1({}, messages$1.paragraph2), {}, {
|
|
1725
1756
|
values: {
|
|
1726
1757
|
a: getSupportUrlLink
|
|
1727
1758
|
}
|
|
@@ -1820,13 +1851,13 @@ const defaultProps$1 = {
|
|
|
1820
1851
|
};
|
|
1821
1852
|
PageContentWide.defaultProps = defaultProps$1;
|
|
1822
1853
|
|
|
1823
|
-
var _ref$
|
|
1854
|
+
var _ref$2 = {
|
|
1824
1855
|
name: "1d3w5wq",
|
|
1825
1856
|
styles: "width:100%"
|
|
1826
1857
|
} ;
|
|
1827
1858
|
function PageContentFull(props) {
|
|
1828
1859
|
return jsxRuntime.jsx("div", {
|
|
1829
|
-
css: _ref$
|
|
1860
|
+
css: _ref$2,
|
|
1830
1861
|
children: jsxRuntime.jsx("section", {
|
|
1831
1862
|
children: props.children
|
|
1832
1863
|
})
|
|
@@ -1871,7 +1902,7 @@ function Drawer(props) {
|
|
|
1871
1902
|
children: props.subtitle
|
|
1872
1903
|
})
|
|
1873
1904
|
}), props.onClose && jsxRuntime.jsx(SecondaryIconButton__default["default"], {
|
|
1874
|
-
label: intl.formatMessage(messages$
|
|
1905
|
+
label: intl.formatMessage(messages$5.close),
|
|
1875
1906
|
onClick: props.onClose,
|
|
1876
1907
|
icon: jsxRuntime.jsx(LargeIconWrapper, {
|
|
1877
1908
|
children: jsxRuntime.jsx(icons.CloseIcon, {})
|
|
@@ -1912,6 +1943,78 @@ Drawer.FormSecondaryButton = FormSecondaryButton;
|
|
|
1912
1943
|
// The Intl messages can be used for button labels.
|
|
1913
1944
|
Drawer.Intl = i18n.sharedMessages;
|
|
1914
1945
|
|
|
1946
|
+
var messages = reactIntl.defineMessages({
|
|
1947
|
+
ProjectProduction: {
|
|
1948
|
+
id: 'ProjectStamp.production',
|
|
1949
|
+
defaultMessage: 'Production'
|
|
1950
|
+
},
|
|
1951
|
+
ProjectSuspended: {
|
|
1952
|
+
id: 'ProjectStamp.suspended',
|
|
1953
|
+
defaultMessage: 'Suspended'
|
|
1954
|
+
},
|
|
1955
|
+
ProjectExpired: {
|
|
1956
|
+
id: 'ProjectStamp.expired',
|
|
1957
|
+
defaultMessage: 'Trial expired'
|
|
1958
|
+
},
|
|
1959
|
+
ProjectWillExpire: {
|
|
1960
|
+
id: 'ProjectStamp.willExpire',
|
|
1961
|
+
defaultMessage: '{daysLeft, select, 0 {Trial ends today} 1 {Trial ends in 1 day} other {Trial ends in {daysLeft} days}}'
|
|
1962
|
+
}
|
|
1963
|
+
});
|
|
1964
|
+
|
|
1965
|
+
const _excluded = ["values"];
|
|
1966
|
+
function ownKeys(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
1967
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
|
|
1968
|
+
function CustomStamp(props) {
|
|
1969
|
+
const intl = reactIntl.useIntl();
|
|
1970
|
+
const _props$label = props.label,
|
|
1971
|
+
values = _valuesInstanceProperty__default["default"](_props$label),
|
|
1972
|
+
message = _objectWithoutProperties(_props$label, _excluded);
|
|
1973
|
+
return jsxRuntime.jsx(Stamp__default["default"], {
|
|
1974
|
+
tone: props.tone,
|
|
1975
|
+
isCondensed: true,
|
|
1976
|
+
label: intl.formatMessage(message, values || {}),
|
|
1977
|
+
icon: props.icon
|
|
1978
|
+
});
|
|
1979
|
+
}
|
|
1980
|
+
CustomStamp.propTypes = {};
|
|
1981
|
+
var _ref$1 = {
|
|
1982
|
+
name: "ph6b5m",
|
|
1983
|
+
styles: "height:18px;svg{height:18px;width:12px;}"
|
|
1984
|
+
} ;
|
|
1985
|
+
const IsProduction = () => jsxRuntime.jsx(CustomStamp, {
|
|
1986
|
+
tone: "positive",
|
|
1987
|
+
label: messages.ProjectProduction,
|
|
1988
|
+
icon: jsxRuntime.jsx("div", {
|
|
1989
|
+
css: _ref$1,
|
|
1990
|
+
children: jsxRuntime.jsx(icons.DotIcon, {
|
|
1991
|
+
color: "primary"
|
|
1992
|
+
})
|
|
1993
|
+
})
|
|
1994
|
+
});
|
|
1995
|
+
const IsSuspended = () => jsxRuntime.jsx(CustomStamp, {
|
|
1996
|
+
tone: "critical",
|
|
1997
|
+
label: messages.ProjectSuspended
|
|
1998
|
+
});
|
|
1999
|
+
const IsExpired = () => jsxRuntime.jsx(CustomStamp, {
|
|
2000
|
+
tone: "critical",
|
|
2001
|
+
label: messages.ProjectExpired
|
|
2002
|
+
});
|
|
2003
|
+
const WillExpire = props => jsxRuntime.jsx(CustomStamp, {
|
|
2004
|
+
tone: "information",
|
|
2005
|
+
label: _objectSpread(_objectSpread({}, messages.ProjectWillExpire), {}, {
|
|
2006
|
+
values: {
|
|
2007
|
+
daysLeft: props.daysLeft
|
|
2008
|
+
}
|
|
2009
|
+
})
|
|
2010
|
+
});
|
|
2011
|
+
const ProjectStamp = {
|
|
2012
|
+
IsProduction,
|
|
2013
|
+
IsSuspended,
|
|
2014
|
+
IsExpired,
|
|
2015
|
+
WillExpire
|
|
2016
|
+
};
|
|
2017
|
+
|
|
1915
2018
|
const useObserverElementDimensions = element => {
|
|
1916
2019
|
const _useState = react$1.useState({
|
|
1917
2020
|
height: 0,
|
|
@@ -2048,6 +2151,7 @@ exports.PageContentWide = PageContentWide;
|
|
|
2048
2151
|
exports.PageNotFound = PageNotFound;
|
|
2049
2152
|
exports.PageUnauthorized = PageUnauthorized;
|
|
2050
2153
|
exports.PortalsContainer = PortalsContainer;
|
|
2154
|
+
exports.ProjectStamp = ProjectStamp;
|
|
2051
2155
|
exports.PublicPageLayout = PublicPageLayout;
|
|
2052
2156
|
exports.TabHeader = TabHeader;
|
|
2053
2157
|
exports.TabularDetailPage = TabularDetailPage;
|