@entur-partner/common 5.3.1 → 6.0.1

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.
@@ -26,26 +26,21 @@ function _extends() {
26
26
  _extends = Object.assign ? Object.assign.bind() : function (target) {
27
27
  for (var i = 1; i < arguments.length; i++) {
28
28
  var source = arguments[i];
29
-
30
29
  for (var key in source) {
31
30
  if (Object.prototype.hasOwnProperty.call(source, key)) {
32
31
  target[key] = source[key];
33
32
  }
34
33
  }
35
34
  }
36
-
37
35
  return target;
38
36
  };
39
37
  return _extends.apply(this, arguments);
40
38
  }
41
-
42
39
  function _inheritsLoose(subClass, superClass) {
43
40
  subClass.prototype = Object.create(superClass.prototype);
44
41
  subClass.prototype.constructor = subClass;
45
-
46
42
  _setPrototypeOf(subClass, superClass);
47
43
  }
48
-
49
44
  function _setPrototypeOf(o, p) {
50
45
  _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
51
46
  o.__proto__ = p;
@@ -53,23 +48,20 @@ function _setPrototypeOf(o, p) {
53
48
  };
54
49
  return _setPrototypeOf(o, p);
55
50
  }
56
-
57
51
  function _objectWithoutPropertiesLoose(source, excluded) {
58
52
  if (source == null) return {};
59
53
  var target = {};
60
54
  var sourceKeys = Object.keys(source);
61
55
  var key, i;
62
-
63
56
  for (i = 0; i < sourceKeys.length; i++) {
64
57
  key = sourceKeys[i];
65
58
  if (excluded.indexOf(key) >= 0) continue;
66
59
  target[key] = source[key];
67
60
  }
68
-
69
61
  return target;
70
62
  }
71
63
 
72
- var _excluded$f = ["as", "children", "contrast", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "padding", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "margin", "display", "justifyContent", "alignItems", "maxWidth", "width", "background", "color", "flexDirection", "flexWrap", "className"];
64
+ var _excluded$e = ["as", "children", "contrast", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "paddingX", "paddingY", "padding", "marginTop", "marginRight", "marginBottom", "marginLeft", "marginX", "marginY", "margin", "display", "justifyContent", "alignItems", "maxWidth", "width", "background", "color", "flexDirection", "flexWrap", "className"];
73
65
  function responsiveProp(prefix, prop) {
74
66
  if (Array.isArray(prop)) {
75
67
  var classes = [];
@@ -78,40 +70,38 @@ function responsiveProp(prefix, prop) {
78
70
  prop[2] && classes.push("" + prefix + prop[2] + "-xl");
79
71
  return classes;
80
72
  }
81
-
82
73
  return [prefix + prop];
83
74
  }
84
75
  var Box = function Box(_ref) {
85
76
  var _ref$as = _ref.as,
86
- Component = _ref$as === void 0 ? 'div' : _ref$as,
87
- children = _ref.children,
88
- contrast = _ref.contrast,
89
- paddingTop = _ref.paddingTop,
90
- paddingRight = _ref.paddingRight,
91
- paddingBottom = _ref.paddingBottom,
92
- paddingLeft = _ref.paddingLeft,
93
- paddingX = _ref.paddingX,
94
- paddingY = _ref.paddingY,
95
- padding = _ref.padding,
96
- marginTop = _ref.marginTop,
97
- marginRight = _ref.marginRight,
98
- marginBottom = _ref.marginBottom,
99
- marginLeft = _ref.marginLeft,
100
- marginX = _ref.marginX,
101
- marginY = _ref.marginY,
102
- margin = _ref.margin,
103
- display = _ref.display,
104
- justifyContent = _ref.justifyContent,
105
- alignItems = _ref.alignItems,
106
- maxWidth = _ref.maxWidth,
107
- width = _ref.width,
108
- background = _ref.background,
109
- color = _ref.color,
110
- flexDirection = _ref.flexDirection,
111
- flexWrap = _ref.flexWrap,
112
- className = _ref.className,
113
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$f);
114
-
77
+ Component = _ref$as === void 0 ? 'div' : _ref$as,
78
+ children = _ref.children,
79
+ contrast = _ref.contrast,
80
+ paddingTop = _ref.paddingTop,
81
+ paddingRight = _ref.paddingRight,
82
+ paddingBottom = _ref.paddingBottom,
83
+ paddingLeft = _ref.paddingLeft,
84
+ paddingX = _ref.paddingX,
85
+ paddingY = _ref.paddingY,
86
+ padding = _ref.padding,
87
+ marginTop = _ref.marginTop,
88
+ marginRight = _ref.marginRight,
89
+ marginBottom = _ref.marginBottom,
90
+ marginLeft = _ref.marginLeft,
91
+ marginX = _ref.marginX,
92
+ marginY = _ref.marginY,
93
+ margin = _ref.margin,
94
+ display = _ref.display,
95
+ justifyContent = _ref.justifyContent,
96
+ alignItems = _ref.alignItems,
97
+ maxWidth = _ref.maxWidth,
98
+ width = _ref.width,
99
+ background = _ref.background,
100
+ color = _ref.color,
101
+ flexDirection = _ref.flexDirection,
102
+ flexWrap = _ref.flexWrap,
103
+ className = _ref.className,
104
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$e);
115
105
  var classes = [];
116
106
  var resolvedPaddingTop = paddingTop || paddingY || padding;
117
107
  var resolvedPaddingBottom = paddingBottom || paddingY || padding;
@@ -132,11 +122,9 @@ var Box = function Box(_ref) {
132
122
  resolvedMarginRight && classes.push.apply(classes, responsiveProp('eps-mr-', resolvedMarginRight));
133
123
  display && classes.push.apply(classes, responsiveProp('eps-', display));
134
124
  justifyContent && classes.push.apply(classes, responsiveProp('eps-justify-', justifyContent));
135
-
136
125
  if (alignItems) {
137
126
  classes.push.apply(classes, responsiveProp('eps-items-', alignItems));
138
127
  }
139
-
140
128
  maxWidth && classes.push.apply(classes, responsiveProp('eps-max-w-', maxWidth));
141
129
  width && classes.push.apply(classes, responsiveProp('eps-w-', width));
142
130
  color && classes.push("eps-color-" + color);
@@ -151,14 +139,12 @@ var Box = function Box(_ref) {
151
139
 
152
140
  var Stack = function Stack(_ref) {
153
141
  var children = _ref.children,
154
- space = _ref.space,
155
- className = _ref.className;
142
+ space = _ref.space,
143
+ className = _ref.className;
156
144
  var stackItems = React.Children.toArray(children);
157
-
158
145
  if (stackItems.length <= 1) {
159
146
  return React__default["default"].createElement(React__default["default"].Fragment, null, stackItems);
160
147
  }
161
-
162
148
  return React__default["default"].createElement("div", {
163
149
  className: className
164
150
  }, stackItems.map(function (child, index) {
@@ -177,14 +163,12 @@ var ActionBarLeft = function ActionBarLeft(_ref) {
177
163
  className: "eps-action-bar-left"
178
164
  }, children);
179
165
  };
180
-
181
166
  var ActionBarRight = function ActionBarRight(_ref2) {
182
167
  var children = _ref2.children;
183
168
  return React__default["default"].createElement("div", {
184
169
  className: "eps-action-bar-right"
185
170
  }, children);
186
171
  };
187
-
188
172
  var ActionBar = function ActionBar(_ref3) {
189
173
  var children = _ref3.children;
190
174
  return React__default["default"].createElement(React__default["default"].Fragment, null, React__default["default"].createElement("div", {
@@ -194,12 +178,11 @@ var ActionBar = function ActionBar(_ref3) {
194
178
  }, children));
195
179
  };
196
180
 
197
- var _excluded$e = ["children", "className"];
181
+ var _excluded$d = ["children", "className"];
198
182
  var LinkButton = function LinkButton(_ref) {
199
183
  var children = _ref.children,
200
- className = _ref.className,
201
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$e);
202
-
184
+ className = _ref.className,
185
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$d);
203
186
  return React__default["default"].createElement(typography.Link, _extends({}, rest, {
204
187
  as: "button",
205
188
  className: cx__default["default"]('eps-link-button', className)
@@ -213,10 +196,8 @@ var LinkButton = function LinkButton(_ref) {
213
196
  * @param flag case sensitive flag. If it is an environment variable
214
197
  * you can drop the REACT_APP_ prefix.
215
198
  */
216
-
217
199
  function featureFlag(flag) {
218
200
  var _window$localStorage, _window$localStorage2;
219
-
220
201
  return process.env["REACT_APP_" + flag] === 'true' || ((_window$localStorage = window.localStorage) == null ? void 0 : _window$localStorage.getItem(flag)) === 'true' || ((_window$localStorage2 = window.localStorage) == null ? void 0 : _window$localStorage2.getItem("REACT_APP_" + flag)) === 'true';
221
202
  }
222
203
  /**
@@ -226,40 +207,33 @@ function featureFlag(flag) {
226
207
  * @param flag case sensitive flag. If it is an environment variable
227
208
  * you can drop the REACT_APP_ prefix.
228
209
  */
229
-
230
210
  function useFeatureToggle(flag) {
231
211
  return featureFlag(flag);
232
212
  }
233
213
  var FeatureToggle = function FeatureToggle(_ref) {
234
214
  var children = _ref.children,
235
- flag = _ref.flag;
215
+ flag = _ref.flag;
236
216
  var feature = useFeatureToggle(flag);
237
-
238
217
  if (feature) {
239
218
  return React__default["default"].createElement(React__default["default"].Fragment, null, children);
240
219
  }
241
-
242
220
  return null;
243
221
  };
244
222
 
245
223
  var _environmentColors, _humanReadableEnviron;
246
-
247
224
  exports.Environment = void 0;
248
-
249
225
  (function (Environment) {
250
226
  Environment["Local"] = "local";
251
227
  Environment["Development"] = "dev";
252
228
  Environment["Staging"] = "staging";
253
229
  Environment["Production"] = "prod";
254
230
  })(exports.Environment || (exports.Environment = {}));
255
-
256
231
  var environmentColors = (_environmentColors = {}, _environmentColors[exports.Environment.Local] = '#B482FB', _environmentColors[exports.Environment.Development] = '#5AC39A', _environmentColors[exports.Environment.Staging] = '#FFCA28', _environmentColors);
257
232
  /**
258
233
  * Gets the color for the given environment. This is the color used for the environment
259
234
  * indicator. There is no color for production as it should not have any special environment
260
235
  * indication.
261
236
  */
262
-
263
237
  var getColorForEnvironment = function getColorForEnvironment(environment) {
264
238
  return environmentColors[environment];
265
239
  };
@@ -268,13 +242,12 @@ var getHumanReadableEnvironment = function getHumanReadableEnvironment(environme
268
242
  return humanReadableEnvironment[environment];
269
243
  };
270
244
 
271
- var _excluded$d = ["title", "accentColor"];
245
+ var _excluded$c = ["title", "accentColor"];
272
246
  var EnturPartnerLogoSvg = function EnturPartnerLogoSvg(_ref) {
273
247
  var title = _ref.title,
274
- _ref$accentColor = _ref.accentColor,
275
- accentColor = _ref$accentColor === void 0 ? '#FF5959' : _ref$accentColor,
276
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$d);
277
-
248
+ _ref$accentColor = _ref.accentColor,
249
+ accentColor = _ref$accentColor === void 0 ? '#FF5959' : _ref$accentColor,
250
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$c);
278
251
  return React__default["default"].createElement("svg", _extends({
279
252
  width: 257,
280
253
  height: 37,
@@ -299,10 +272,10 @@ var EnturPartnerLogoSvg = function EnturPartnerLogoSvg(_ref) {
299
272
  };
300
273
  var EnturPartnerLogo = function EnturPartnerLogo(_ref2) {
301
274
  var _ref2$as = _ref2.as,
302
- Component = _ref2$as === void 0 ? 'nav' : _ref2$as,
303
- className = _ref2.className,
304
- altText = _ref2.altText,
305
- environment = _ref2.environment;
275
+ Component = _ref2$as === void 0 ? 'nav' : _ref2$as,
276
+ className = _ref2.className,
277
+ altText = _ref2.altText,
278
+ environment = _ref2.environment;
306
279
  var classList = cx__default["default"](['eps-logo-wrapper', className]);
307
280
  return React__default["default"].createElement(Component, {
308
281
  className: classList
@@ -315,9 +288,9 @@ var EnturPartnerLogo = function EnturPartnerLogo(_ref2) {
315
288
 
316
289
  var Menu = function Menu(_ref) {
317
290
  var _ref$as = _ref.as,
318
- Component = _ref$as === void 0 ? 'nav' : _ref$as,
319
- className = _ref.className,
320
- children = _ref.children;
291
+ Component = _ref$as === void 0 ? 'nav' : _ref$as,
292
+ className = _ref.className,
293
+ children = _ref.children;
321
294
  var classList = cx__default["default"](['eds-contrast', 'eps-menu', className]);
322
295
  return React__default["default"].createElement(Component, {
323
296
  className: classList
@@ -326,34 +299,31 @@ var Menu = function Menu(_ref) {
326
299
 
327
300
  var Content = function Content(_ref) {
328
301
  var _ref$as = _ref.as,
329
- Component = _ref$as === void 0 ? 'main' : _ref$as,
330
- className = _ref.className,
331
- children = _ref.children;
302
+ Component = _ref$as === void 0 ? 'main' : _ref$as,
303
+ className = _ref.className,
304
+ children = _ref.children;
332
305
  var classList = cx__default["default"](['eps-content', className]);
333
306
  return React__default["default"].createElement(Component, {
334
307
  className: classList
335
308
  }, children);
336
309
  };
337
310
 
338
- var _excluded$c = ["className", "children", "userName", "open", "onOpenChange", "environment"];
311
+ var _excluded$b = ["className", "children", "userName", "open", "onOpenChange", "environment"];
339
312
  var UserMenu = function UserMenu(_ref) {
340
313
  var className = _ref.className,
341
- messages = _ref.messages,
342
- onLogout = _ref.onLogout,
343
- onLanguageChange = _ref.onLanguageChange,
344
- userName = _ref.userName,
345
- language = _ref.language,
346
- environment = _ref.environment,
347
- showVersionItem = _ref.showVersionItem,
348
- showMyProfileItem = _ref.showMyProfileItem,
349
- onNavigateToMyProfile = _ref.onNavigateToMyProfile;
350
- var history = reactRouterDom.useHistory();
314
+ messages = _ref.messages,
315
+ onLogout = _ref.onLogout,
316
+ onLanguageChange = _ref.onLanguageChange,
317
+ userName = _ref.userName,
318
+ language = _ref.language,
319
+ environment = _ref.environment,
320
+ showVersionItem = _ref.showVersionItem,
321
+ showMyProfileItem = _ref.showMyProfileItem,
322
+ onNavigateToMyProfile = _ref.onNavigateToMyProfile;
351
323
  var triggerClassList = cx__default["default"](['eps-user-menu__trigger-button', className]);
352
-
353
324
  var _useState = React.useState(false),
354
- open = _useState[0],
355
- setOpen = _useState[1];
356
-
325
+ open = _useState[0],
326
+ setOpen = _useState[1];
357
327
  return React__default["default"].createElement("div", {
358
328
  id: "eps-user-menu"
359
329
  }, React__default["default"].createElement(CustomOverflowMenu, {
@@ -388,19 +358,10 @@ var UserMenu = function UserMenu(_ref) {
388
358
  }, React__default["default"].createElement(icons.UKIcon, {
389
359
  size: "1rem",
390
360
  inline: true
391
- })), messages.switchLanguage), showVersionItem && messages.appVersion && React__default["default"].createElement(CustomOverflowMenuItem, {
392
- onClick: function onClick() {
393
- history.push('/app-version');
394
- setOpen(false);
395
- },
396
- className: "eps-overflow-menu__item"
397
- }, React__default["default"].createElement("span", {
398
- "aria-hidden": true
399
- }, React__default["default"].createElement(icons.ChannelsIcon, {
400
- className: "eps-version-icon",
401
- size: "1rem",
402
- inline: true
403
- })), messages.appVersion), showMyProfileItem && messages.myProfile && React__default["default"].createElement(reactRouterDom.Link, {
361
+ })), messages.switchLanguage), showVersionItem && messages.appVersion && React__default["default"].createElement(VersionCustomOverflowMenuItems, {
362
+ title: messages.appVersion,
363
+ setOpen: setOpen
364
+ }), showMyProfileItem && messages.myProfile && React__default["default"].createElement(reactRouterDom.Link, {
404
365
  to: "/permission-admin/my-profile",
405
366
  style: {
406
367
  textDecoration: 'none'
@@ -430,16 +391,14 @@ var UserMenu = function UserMenu(_ref) {
430
391
  inline: true
431
392
  })), messages.logout))));
432
393
  };
433
-
434
394
  var CustomOverflowMenu = function CustomOverflowMenu(_ref2) {
435
395
  var className = _ref2.className,
436
- children = _ref2.children,
437
- userName = _ref2.userName,
438
- open = _ref2.open,
439
- onOpenChange = _ref2.onOpenChange,
440
- environment = _ref2.environment,
441
- rest = _objectWithoutPropertiesLoose(_ref2, _excluded$c);
442
-
396
+ children = _ref2.children,
397
+ userName = _ref2.userName,
398
+ open = _ref2.open,
399
+ onOpenChange = _ref2.onOpenChange,
400
+ environment = _ref2.environment,
401
+ rest = _objectWithoutPropertiesLoose(_ref2, _excluded$b);
443
402
  var overflowItemsClasses = cx__default["default"]('eps-overflow-menu__group', {
444
403
  'eps-overflow-menu__group--open': open
445
404
  });
@@ -480,48 +439,57 @@ var CustomOverflowMenu = function CustomOverflowMenu(_ref2) {
480
439
  ref: overflowContentRef
481
440
  }, children));
482
441
  };
483
-
484
442
  var CustomOverflowMenuItem = function CustomOverflowMenuItem(props) {
485
443
  return React__default["default"].createElement("button", _extends({
486
444
  className: cx__default["default"](props.className, 'eps-overflow-menu__item'),
487
445
  role: "menuitem"
488
446
  }, props));
489
447
  };
490
-
448
+ var VersionCustomOverflowMenuItems = function VersionCustomOverflowMenuItems(_ref3) {
449
+ var title = _ref3.title,
450
+ setOpen = _ref3.setOpen;
451
+ var navigate = reactRouterDom.useNavigate(); // Hide useNavigate from standalone micro-frontends because it is not under RouterProvider
452
+ return React__default["default"].createElement(CustomOverflowMenuItem, {
453
+ onClick: function onClick() {
454
+ navigate('/app-version');
455
+ setOpen(false);
456
+ },
457
+ className: "eps-overflow-menu__item"
458
+ }, React__default["default"].createElement("span", {
459
+ "aria-hidden": true
460
+ }, React__default["default"].createElement(icons.ChannelsIcon, {
461
+ className: "eps-version-icon",
462
+ size: "1rem",
463
+ inline: true
464
+ })), title);
465
+ };
491
466
  function elementContainsEventTarget(element, event) {
492
467
  if (!element) {
493
468
  return false;
494
469
  }
495
-
496
470
  if (element.contains(event.target)) {
497
471
  return true;
498
- } // For elements inside a Shadow DOM we need to check the composedPath
499
-
500
-
472
+ }
473
+ // For elements inside a Shadow DOM we need to check the composedPath
501
474
  if (event.composed && event.composedPath) {
502
475
  var contains = event.composedPath().find(function (target) {
503
476
  if (target === window) {
504
477
  return false;
505
478
  }
506
-
507
479
  return element.contains(target);
508
480
  });
509
481
  return contains ? true : false;
510
482
  }
511
-
512
483
  return false;
513
484
  }
514
-
515
485
  function useOutsideClick(ref, buttonRef, handler) {
516
486
  React__default["default"].useEffect(function () {
517
487
  var listener = function listener(event) {
518
488
  if (elementContainsEventTarget(ref.current, event) || elementContainsEventTarget(buttonRef.current, event)) {
519
489
  return;
520
490
  }
521
-
522
491
  handler();
523
492
  };
524
-
525
493
  document.addEventListener('mousedown', listener);
526
494
  document.addEventListener('touchstart', listener);
527
495
  return function () {
@@ -531,14 +499,13 @@ function useOutsideClick(ref, buttonRef, handler) {
531
499
  }, [ref, buttonRef, handler]);
532
500
  }
533
501
 
534
- var _excluded$b = ["label", "organisations", "onChange", "selectedOrganisationId"];
502
+ var _excluded$a = ["label", "organisations", "onChange", "selectedOrganisationId"];
535
503
  var OrganisationDropDown = function OrganisationDropDown(_ref) {
536
504
  var label = _ref.label,
537
- organisations = _ref.organisations,
538
- handleChange = _ref.onChange,
539
- selectedOrganisationId = _ref.selectedOrganisationId,
540
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$b);
541
-
505
+ organisations = _ref.organisations,
506
+ handleChange = _ref.onChange,
507
+ selectedOrganisationId = _ref.selectedOrganisationId,
508
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$a);
542
509
  var selectedOrganisation = organisations.find(function (org) {
543
510
  return org.id === selectedOrganisationId;
544
511
  });
@@ -570,7 +537,6 @@ function useEventListener(eventName, handler, element) {
570
537
  if (element === void 0) {
571
538
  element = window;
572
539
  }
573
-
574
540
  var savedHandler = React.useRef();
575
541
  React.useEffect(function () {
576
542
  savedHandler.current = handler;
@@ -578,11 +544,9 @@ function useEventListener(eventName, handler, element) {
578
544
  React.useEffect(function () {
579
545
  var isSupported = element && element.addEventListener;
580
546
  if (!isSupported) return;
581
-
582
547
  var eventListener = function eventListener(event) {
583
548
  return savedHandler.current == null ? void 0 : savedHandler.current(event);
584
549
  };
585
-
586
550
  element.addEventListener(eventName, eventListener);
587
551
  return function () {
588
552
  element.removeEventListener(eventName, eventListener);
@@ -590,21 +554,19 @@ function useEventListener(eventName, handler, element) {
590
554
  }, [eventName, element]);
591
555
  }
592
556
 
593
- var _excluded$a = ["language", "options", "className", "onChange"];
557
+ var _excluded$9 = ["language", "options", "className", "onChange"];
594
558
  var LanguageSelect = function LanguageSelect(_ref) {
595
559
  var language = _ref.language,
596
- options = _ref.options,
597
- className = _ref.className,
598
- _onChange = _ref.onChange,
599
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$a);
600
-
560
+ options = _ref.options,
561
+ className = _ref.className,
562
+ _onChange = _ref.onChange,
563
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$9);
601
564
  var classNames = cx__default["default"]('eps-language-select', className);
602
565
  return React__default["default"].createElement("div", _extends({}, rest, {
603
566
  className: classNames
604
567
  }), React__default["default"].createElement(form.SegmentedControl, {
605
568
  onChange: function onChange(language) {
606
569
  util.assertIsDefined(language);
607
-
608
570
  _onChange(language);
609
571
  },
610
572
  selectedValue: language
@@ -618,30 +580,26 @@ var LanguageSelect = function LanguageSelect(_ref) {
618
580
  })));
619
581
  };
620
582
 
621
- var _excluded$9 = ["title", "inputComponent", "languages", "values", "onChange", "name", "variant", "feedback"];
583
+ var _excluded$8 = ["title", "inputComponent", "languages", "values", "onChange", "name", "variant", "feedback"];
622
584
  var ExpandableMultiLanguageInput = function ExpandableMultiLanguageInput(_ref) {
623
585
  var title = _ref.title,
624
- InputComponent = _ref.inputComponent,
625
- languages = _ref.languages,
626
- values = _ref.values,
627
- onChange = _ref.onChange,
628
- name = _ref.name,
629
- variant = _ref.variant,
630
- feedback = _ref.feedback,
631
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$9);
632
-
586
+ InputComponent = _ref.inputComponent,
587
+ languages = _ref.languages,
588
+ values = _ref.values,
589
+ onChange = _ref.onChange,
590
+ name = _ref.name,
591
+ variant = _ref.variant,
592
+ feedback = _ref.feedback,
593
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$8);
633
594
  var handleOnChange = function handleOnChange(language, value) {
634
595
  var changes = _extends({}, values);
635
-
636
596
  if (value === '' || !value) {
637
597
  delete changes[language];
638
598
  } else {
639
599
  changes[language] = value;
640
600
  }
641
-
642
601
  onChange(changes);
643
602
  };
644
-
645
603
  return React__default["default"].createElement(expand.ExpandablePanel, {
646
604
  title: title,
647
605
  defaultOpen: true,
@@ -654,8 +612,8 @@ var ExpandableMultiLanguageInput = function ExpandableMultiLanguageInput(_ref) {
654
612
  space: "medium"
655
613
  }, languages.map(function (_ref2) {
656
614
  var langKey = _ref2.value,
657
- label = _ref2.label,
658
- required = _ref2.required;
615
+ label = _ref2.label,
616
+ required = _ref2.required;
659
617
  return React__default["default"].createElement(InputComponent, _extends({
660
618
  "data-testid": "multi-lang-input-" + name + "-" + langKey,
661
619
  key: title + langKey,
@@ -671,35 +629,31 @@ var ExpandableMultiLanguageInput = function ExpandableMultiLanguageInput(_ref) {
671
629
  })));
672
630
  };
673
631
 
674
- var _excluded$8 = ["className", "inputComponent", "alertLabel", "alertLevel", "name", "languages", "values", "onChange", "defaultLanguage", "label", "onBlur"];
632
+ var _excluded$7 = ["className", "inputComponent", "alertLabel", "alertLevel", "name", "languages", "values", "onChange", "defaultLanguage", "label", "onBlur"];
675
633
  /**
676
634
  * @deprecated use ExpandableMultiLanguageInput
677
635
  */
678
-
679
636
  var MultiLanguageInput = function MultiLanguageInput(_ref) {
680
637
  var className = _ref.className,
681
- InputComponent = _ref.inputComponent,
682
- alertLabel = _ref.alertLabel,
683
- alertLevel = _ref.alertLevel,
684
- name = _ref.name,
685
- languages = _ref.languages,
686
- values = _ref.values,
687
- onChange = _ref.onChange,
688
- _ref$defaultLanguage = _ref.defaultLanguage,
689
- defaultLanguage = _ref$defaultLanguage === void 0 ? 'nob' : _ref$defaultLanguage,
690
- _ref$label = _ref.label,
691
- label = _ref$label === void 0 ? '' : _ref$label,
692
- _ref$onBlur = _ref.onBlur,
693
- onBlur = _ref$onBlur === void 0 ? function () {} : _ref$onBlur,
694
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$8);
695
-
638
+ InputComponent = _ref.inputComponent,
639
+ alertLabel = _ref.alertLabel,
640
+ alertLevel = _ref.alertLevel,
641
+ name = _ref.name,
642
+ languages = _ref.languages,
643
+ values = _ref.values,
644
+ onChange = _ref.onChange,
645
+ _ref$defaultLanguage = _ref.defaultLanguage,
646
+ defaultLanguage = _ref$defaultLanguage === void 0 ? 'nob' : _ref$defaultLanguage,
647
+ _ref$label = _ref.label,
648
+ label = _ref$label === void 0 ? '' : _ref$label,
649
+ _ref$onBlur = _ref.onBlur,
650
+ onBlur = _ref$onBlur === void 0 ? function () {} : _ref$onBlur,
651
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$7);
696
652
  var _useState = React.useState(defaultLanguage),
697
- language = _useState[0],
698
- setLanguage = _useState[1];
699
-
653
+ language = _useState[0],
654
+ setLanguage = _useState[1];
700
655
  var classNames = cx__default["default"]('multi-language-input', className);
701
656
  var currentValue = values[language];
702
-
703
657
  var handleOnBlur = function handleOnBlur(e) {
704
658
  e.persist();
705
659
  var currentTarget = e.currentTarget;
@@ -709,23 +663,18 @@ var MultiLanguageInput = function MultiLanguageInput(_ref) {
709
663
  }
710
664
  }, 0);
711
665
  };
712
-
713
666
  var handleLanguageChange = function handleLanguageChange(language) {
714
667
  setLanguage(language);
715
668
  };
716
-
717
669
  var handleOnChange = function handleOnChange(value) {
718
670
  var changes = Object.assign({}, values);
719
-
720
671
  if (value === '' || !value) {
721
672
  delete changes[language];
722
673
  } else {
723
674
  changes[language] = value;
724
675
  }
725
-
726
676
  onChange(changes);
727
677
  };
728
-
729
678
  return React__default["default"].createElement("div", {
730
679
  className: classNames,
731
680
  tabIndex: 0,
@@ -752,12 +701,11 @@ var MultiLanguageInput = function MultiLanguageInput(_ref) {
752
701
  }, rest))));
753
702
  };
754
703
 
755
- var _excluded$7 = ["children", "className"];
704
+ var _excluded$6 = ["children", "className"];
756
705
  var Unbutton = function Unbutton(_ref) {
757
706
  var children = _ref.children,
758
- className = _ref.className,
759
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$7);
760
-
707
+ className = _ref.className,
708
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$6);
761
709
  return React__default["default"].createElement(button.Button, _extends({
762
710
  variant: "primary"
763
711
  }, rest, {
@@ -772,40 +720,31 @@ function isFunction(functionToCheck) {
772
720
  var newAppVersionErrorMessage = "Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.";
773
721
  var ErrorBoundary = /*#__PURE__*/function (_Component) {
774
722
  _inheritsLoose(ErrorBoundary, _Component);
775
-
776
723
  function ErrorBoundary(props) {
777
724
  var _this;
778
-
779
725
  _this = _Component.call(this, props) || this;
780
726
  _this.state = {
781
727
  error: null
782
728
  };
783
729
  return _this;
784
730
  }
785
-
786
731
  ErrorBoundary.getDerivedStateFromError = function getDerivedStateFromError(error) {
787
732
  return {
788
733
  error: error
789
734
  };
790
735
  };
791
-
792
736
  var _proto = ErrorBoundary.prototype;
793
-
794
737
  _proto.componentDidCatch = function componentDidCatch(error, errorInfo) {
795
738
  var _this$props$handleErr, _this$props;
796
-
797
739
  // React always logs in development
798
740
  (_this$props$handleErr = (_this$props = this.props).handleError) == null ? void 0 : _this$props$handleErr.call(_this$props, error, errorInfo);
799
741
  };
800
-
801
742
  _proto.render = function render() {
802
743
  var _this2 = this;
803
-
804
744
  var error = this.state.error;
805
745
  var _this$props2 = this.props,
806
- fallback = _this$props2.fallback,
807
- children = _this$props2.children;
808
-
746
+ fallback = _this$props2.fallback,
747
+ children = _this$props2.children;
809
748
  if (error) {
810
749
  if (isFunction(fallback)) {
811
750
  return fallback({
@@ -819,17 +758,13 @@ var ErrorBoundary = /*#__PURE__*/function (_Component) {
819
758
  } else if (error.name === 'NotFoundError' && error.message === newAppVersionErrorMessage) {
820
759
  return React__default["default"].createElement(RefreshBannerInfo, null);
821
760
  }
822
-
823
761
  return fallback;
824
762
  }
825
-
826
763
  return children;
827
764
  };
828
-
829
765
  return ErrorBoundary;
830
766
  }(React.Component);
831
767
  var LANGUAGE_STORAGE_KEY = 'EP::locale';
832
-
833
768
  function RefreshBannerInfo() {
834
769
  // Taken from ./app-shell/src/storage.ts
835
770
  var language = localStorage.getItem(LANGUAGE_STORAGE_KEY);
@@ -850,25 +785,23 @@ function RefreshBannerInfo() {
850
785
  }, isNorwegian ? 'Oppdater' : 'Refresh')));
851
786
  }
852
787
 
853
- var _excluded$6 = ["date", "locale", "as", "hideTime"];
788
+ var _excluded$5 = ["date", "locale", "as", "hideTime"];
854
789
  var FormatDateTime = function FormatDateTime(_ref) {
855
790
  var date = _ref.date,
856
- locale = _ref.locale,
857
- _ref$as = _ref.as,
858
- Component = _ref$as === void 0 ? 'main' : _ref$as,
859
- hideTime = _ref.hideTime,
860
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$6);
861
-
791
+ locale = _ref.locale,
792
+ _ref$as = _ref.as,
793
+ Component = _ref$as === void 0 ? 'main' : _ref$as,
794
+ hideTime = _ref.hideTime,
795
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$5);
862
796
  return React__default["default"].createElement(Component, _extends({}, rest), hideTime ? util.localeDate(date, locale) : util.localeDateTime(date, locale));
863
797
  };
864
798
 
865
- var _excluded$5 = ["amount", "as"];
799
+ var _excluded$4 = ["amount", "as"];
866
800
  var FormatCurrencyAmount = function FormatCurrencyAmount(_ref) {
867
801
  var amount = _ref.amount,
868
- _ref$as = _ref.as,
869
- Component = _ref$as === void 0 ? 'span' : _ref$as,
870
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$5);
871
-
802
+ _ref$as = _ref.as,
803
+ Component = _ref$as === void 0 ? 'span' : _ref$as,
804
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
872
805
  var parsedAmount = Number(amount) || 0;
873
806
  var formattedAmount = new Intl.NumberFormat('nb-NO', {
874
807
  maximumFractionDigits: 2,
@@ -877,19 +810,18 @@ var FormatCurrencyAmount = function FormatCurrencyAmount(_ref) {
877
810
  return React__default["default"].createElement(Component, _extends({}, rest), formattedAmount);
878
811
  };
879
812
 
880
- var _excluded$4 = ["items", "locale", "className"];
813
+ var _excluded$3 = ["items", "locale", "className"];
881
814
  var AuditInfo = function AuditInfo(_ref) {
882
815
  var items = _ref.items,
883
- locale = _ref.locale,
884
- className = _ref.className,
885
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$4);
886
-
816
+ locale = _ref.locale,
817
+ className = _ref.className,
818
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
887
819
  var classNames = cx__default["default"]('ep-audit-info', className);
888
820
  return React__default["default"].createElement("div", _extends({
889
821
  className: classNames
890
822
  }, rest), items.map(function (_ref2, i) {
891
823
  var label = _ref2.label,
892
- value = _ref2.value;
824
+ value = _ref2.value;
893
825
  return React__default["default"].createElement(Stack, {
894
826
  space: "small",
895
827
  key: i
@@ -902,21 +834,20 @@ var AuditInfo = function AuditInfo(_ref) {
902
834
  }));
903
835
  };
904
836
 
905
- var _excluded$3 = ["isOpen", "children", "message", "size", "buttons", "onConfirm", "messages", "onClose", "onDismiss"];
837
+ var _excluded$2 = ["isOpen", "children", "message", "size", "buttons", "onConfirm", "messages", "onClose", "onDismiss"];
906
838
  var ConfirmModal = function ConfirmModal(_ref) {
907
839
  var _ref$isOpen = _ref.isOpen,
908
- isOpen = _ref$isOpen === void 0 ? false : _ref$isOpen,
909
- children = _ref.children,
910
- message = _ref.message,
911
- _ref$size = _ref.size,
912
- size = _ref$size === void 0 ? 'medium' : _ref$size,
913
- buttons = _ref.buttons,
914
- onConfirm = _ref.onConfirm,
915
- messages = _ref.messages,
916
- onClose = _ref.onClose,
917
- onDismiss = _ref.onDismiss,
918
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$3);
919
-
840
+ isOpen = _ref$isOpen === void 0 ? false : _ref$isOpen,
841
+ children = _ref.children,
842
+ message = _ref.message,
843
+ _ref$size = _ref.size,
844
+ size = _ref$size === void 0 ? 'medium' : _ref$size,
845
+ buttons = _ref.buttons,
846
+ onConfirm = _ref.onConfirm,
847
+ messages = _ref.messages,
848
+ onClose = _ref.onClose,
849
+ onDismiss = _ref.onDismiss,
850
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$2);
920
851
  var childrenToRender = children ? children : message;
921
852
  var handleDismiss = onClose ? onClose : onDismiss;
922
853
  return React__default["default"].createElement(modal.Modal, _extends({
@@ -934,54 +865,37 @@ var ConfirmModal = function ConfirmModal(_ref) {
934
865
  }, messages.confirm)) : buttons));
935
866
  };
936
867
 
937
- var _excluded$2 = ["children", "shouldBlockNavigation"];
868
+ var _excluded$1 = ["children", "shouldBlockNavigation"];
938
869
  var RouteLeavingGuard = function RouteLeavingGuard(_ref) {
939
870
  var children = _ref.children,
940
- shouldBlockNavigation = _ref.shouldBlockNavigation,
941
- rest = _objectWithoutPropertiesLoose(_ref, _excluded$2);
942
-
943
- var history = reactRouterDom.useHistory();
944
-
945
- var _useState = React.useState('ALLOW'),
946
- status = _useState[0],
947
- setStatus = _useState[1];
948
-
949
- var _useState2 = React.useState(history.location),
950
- lastLocation = _useState2[0],
951
- setLastLocation = _useState2[1];
952
-
953
- var closeModal = function closeModal() {
954
- setStatus('ALLOW');
955
- };
956
-
957
- var allowNavigation = function allowNavigation(nextLocation) {
958
- if (shouldBlockNavigation(nextLocation) && status === 'ALLOW') {
959
- setStatus('BLOCKED');
960
- setLastLocation(nextLocation);
961
- return false;
871
+ shouldBlockNavigation = _ref.shouldBlockNavigation,
872
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded$1);
873
+ util.assertIsDefined(reactRouterDom.useInRouterContext() ? true : undefined, "RouteLeavingGuard must be used within a data router.");
874
+ var blocker = reactRouterDom.useBlocker(function (_ref2) {
875
+ var currentLocation = _ref2.currentLocation,
876
+ nextLocation = _ref2.nextLocation;
877
+ return currentLocation.pathname !== nextLocation.pathname && shouldBlockNavigation(nextLocation);
878
+ });
879
+ return React__default["default"].createElement(ConfirmModal, _extends({
880
+ onDismiss: function onDismiss() {
881
+ if (blocker.state === 'blocked') {
882
+ blocker.reset();
883
+ }
884
+ },
885
+ open: blocker.state === 'blocked',
886
+ onConfirm: function onConfirm() {
887
+ if (blocker.state === 'blocked') {
888
+ blocker.proceed();
889
+ }
962
890
  }
963
-
964
- return true;
965
- };
966
-
967
- var handleConfirm = function handleConfirm() {
968
- history.push(lastLocation.pathname);
969
- };
970
-
971
- return React__default["default"].createElement(React__default["default"].Fragment, null, React__default["default"].createElement(reactRouterDom.Prompt, {
972
- message: allowNavigation
973
- }), React__default["default"].createElement(ConfirmModal, _extends({
974
- onDismiss: closeModal,
975
- open: status === 'BLOCKED',
976
- onConfirm: handleConfirm
977
- }, rest), children));
891
+ }, rest), children);
978
892
  };
979
893
 
980
894
  var Pager = function Pager(_ref) {
981
895
  var collectionSize = _ref.collectionSize,
982
- pageSize = _ref.pageSize,
983
- _onPageChange = _ref.onPageChange,
984
- currentPage = _ref.currentPage;
896
+ pageSize = _ref.pageSize,
897
+ _onPageChange = _ref.onPageChange,
898
+ currentPage = _ref.currentPage;
985
899
  var pageCount = Math.ceil(collectionSize / pageSize);
986
900
  return React__default["default"].createElement(menu.Pagination, {
987
901
  pageCount: pageCount,
@@ -994,12 +908,12 @@ var Pager = function Pager(_ref) {
994
908
 
995
909
  var StatusLabel = function StatusLabel(_ref) {
996
910
  var _ref$active = _ref.active,
997
- active = _ref$active === void 0 ? false : _ref$active,
998
- _ref$label = _ref.label,
999
- label = _ref$label === void 0 ? '' : _ref$label,
1000
- aggressiveInactive = _ref.aggressiveInactive,
1001
- showBullet = _ref.showBullet,
1002
- center = _ref.center;
911
+ active = _ref$active === void 0 ? false : _ref$active,
912
+ _ref$label = _ref.label,
913
+ label = _ref$label === void 0 ? '' : _ref$label,
914
+ aggressiveInactive = _ref.aggressiveInactive,
915
+ showBullet = _ref.showBullet,
916
+ center = _ref.center;
1003
917
  var bulletClassNames = cx__default["default"]('eps-status-label__bullet', {
1004
918
  active: active,
1005
919
  aggressive: aggressiveInactive
@@ -1019,51 +933,25 @@ var StatusLabel = function StatusLabel(_ref) {
1019
933
  * check BusinessCapabilities but because it represents a minimal subset of
1020
934
  * what we need to check.
1021
935
  */
1022
-
1023
936
  var PermissionCheck = function PermissionCheck(_ref) {
1024
937
  var children = _ref.children,
1025
- _ref$fallback = _ref.fallback,
1026
- fallback = _ref$fallback === void 0 ? null : _ref$fallback,
1027
- permissions = _ref.permissions,
1028
- _ref$oneOf = _ref.oneOf,
1029
- oneOf = _ref$oneOf === void 0 ? [] : _ref$oneOf,
1030
- _ref$all = _ref.all,
1031
- all = _ref$all === void 0 ? [] : _ref$all;
938
+ _ref$fallback = _ref.fallback,
939
+ fallback = _ref$fallback === void 0 ? null : _ref$fallback,
940
+ permissions = _ref.permissions,
941
+ _ref$oneOf = _ref.oneOf,
942
+ oneOf = _ref$oneOf === void 0 ? [] : _ref$oneOf,
943
+ _ref$all = _ref.all,
944
+ all = _ref$all === void 0 ? [] : _ref$all;
1032
945
  var allIsAllowed = util.hasAllPermissions(all, permissions);
1033
946
  var oneOfIsAllowed = util.hasOneOfPermissions(oneOf, permissions);
1034
947
  var allowed = allIsAllowed && oneOfIsAllowed;
1035
948
  return React__default["default"].createElement(React__default["default"].Fragment, null, allowed ? children : fallback);
1036
949
  };
1037
950
 
1038
- var _excluded$1 = ["children", "actualPermissions", "all", "oneOf", "onReject"];
1039
- var PermissionCheckedRoute = function PermissionCheckedRoute(_ref) {
1040
- var children = _ref.children,
1041
- actualPermissions = _ref.actualPermissions,
1042
- all = _ref.all,
1043
- oneOf = _ref.oneOf,
1044
- onReject = _ref.onReject,
1045
- props = _objectWithoutPropertiesLoose(_ref, _excluded$1);
1046
-
1047
- var redirect = React__default["default"].createElement(reactRouterDom.Redirect, {
1048
- to: {
1049
- pathname: '/unauthorized',
1050
- state: {
1051
- from: props.location
1052
- }
1053
- }
1054
- });
1055
- return React__default["default"].createElement(PermissionCheck, {
1056
- permissions: actualPermissions,
1057
- all: all,
1058
- oneOf: oneOf,
1059
- fallback: onReject ? onReject : redirect
1060
- }, React__default["default"].createElement(reactRouterDom.Route, _extends({}, props), children));
1061
- };
1062
-
1063
951
  var Breadcrumbs = function Breadcrumbs(_ref) {
1064
952
  var prependBreadcrumbItem = _ref.prependBreadcrumbItem,
1065
- pathname = _ref.pathname,
1066
- onBreadcrumbLookup = _ref.onBreadcrumbLookup;
953
+ pathname = _ref.pathname,
954
+ onBreadcrumbLookup = _ref.onBreadcrumbLookup;
1067
955
  var paths = util.splitUrlPath(pathname);
1068
956
  var breadcrumbs = paths.map(function (path) {
1069
957
  return {
@@ -1076,27 +964,23 @@ var Breadcrumbs = function Breadcrumbs(_ref) {
1076
964
  });
1077
965
  var breadcrumbElements = breadcrumbs.map(function (_ref3, i) {
1078
966
  var title = _ref3.title,
1079
- path = _ref3.path;
967
+ path = _ref3.path;
1080
968
  var isLast = i === breadcrumbs.length - 1;
1081
-
1082
969
  if (isLast) {
1083
970
  return React__default["default"].createElement(menu.BreadcrumbItem, {
1084
971
  key: path,
1085
972
  as: 'span'
1086
973
  }, title);
1087
974
  }
1088
-
1089
975
  return React__default["default"].createElement(menu.BreadcrumbItem, {
1090
976
  key: path,
1091
977
  as: reactRouterDom.Link,
1092
978
  to: path
1093
979
  }, title);
1094
980
  });
1095
-
1096
981
  if (prependBreadcrumbItem) {
1097
982
  return React__default["default"].createElement(menu.BreadcrumbNavigation, null, [prependBreadcrumbItem].concat(breadcrumbElements));
1098
983
  }
1099
-
1100
984
  return React__default["default"].createElement(menu.BreadcrumbNavigation, null, breadcrumbElements);
1101
985
  };
1102
986
 
@@ -1109,15 +993,14 @@ var Link = function Link(props) {
1109
993
  var _excluded = ["as", "children", "fontSize", "color", "lineHeight", "fontWeight", "className"];
1110
994
  var Text = function Text(_ref) {
1111
995
  var _ref$as = _ref.as,
1112
- component = _ref$as === void 0 ? 'span' : _ref$as,
1113
- children = _ref.children,
1114
- fontSize = _ref.fontSize,
1115
- color = _ref.color,
1116
- lineHeight = _ref.lineHeight,
1117
- fontWeight = _ref.fontWeight,
1118
- className = _ref.className,
1119
- rest = _objectWithoutPropertiesLoose(_ref, _excluded);
1120
-
996
+ component = _ref$as === void 0 ? 'span' : _ref$as,
997
+ children = _ref.children,
998
+ fontSize = _ref.fontSize,
999
+ color = _ref.color,
1000
+ lineHeight = _ref.lineHeight,
1001
+ fontWeight = _ref.fontWeight,
1002
+ className = _ref.className,
1003
+ rest = _objectWithoutPropertiesLoose(_ref, _excluded);
1121
1004
  var classes = [];
1122
1005
  fontSize && classes.push.apply(classes, responsiveProp('eps-font-size-', fontSize));
1123
1006
  lineHeight && classes.push.apply(classes, responsiveProp('eps-line-height-', lineHeight));
@@ -1138,10 +1021,9 @@ var Text = function Text(_ref) {
1138
1021
  * @param Props.onBreadcrumbLookup - A function that takes a path and returns a i18n translated string or undefined
1139
1022
  * @returns A Helmet component with updated title
1140
1023
  */
1141
-
1142
1024
  function PageTitle(_ref) {
1143
1025
  var pathname = _ref.pathname,
1144
- onBreadcrumbLookup = _ref.onBreadcrumbLookup;
1026
+ onBreadcrumbLookup = _ref.onBreadcrumbLookup;
1145
1027
  var paths = util.splitUrlPath(pathname);
1146
1028
  var pageTitles = paths.map(function (path) {
1147
1029
  return {
@@ -1182,7 +1064,6 @@ exports.OrganisationDropDown = OrganisationDropDown;
1182
1064
  exports.PageTitle = PageTitle;
1183
1065
  exports.Pager = Pager;
1184
1066
  exports.PermissionCheck = PermissionCheck;
1185
- exports.PermissionCheckedRoute = PermissionCheckedRoute;
1186
1067
  exports.RouteLeavingGuard = RouteLeavingGuard;
1187
1068
  exports.Stack = Stack;
1188
1069
  exports.StatusLabel = StatusLabel;