@commercetools-frontend/application-components 22.13.1 → 22.13.2

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.
@@ -40,10 +40,10 @@ var AccessibleButton = require('@commercetools-uikit/accessible-button');
40
40
  var Constraints = require('@commercetools-uikit/constraints');
41
41
  var actionsGlobal = require('@commercetools-frontend/actions-global');
42
42
  var applicationShellConnectors = require('@commercetools-frontend/application-shell-connectors');
43
- var IconButton = require('@commercetools-uikit/icon-button');
44
43
  var _setTimeout = require('@babel/runtime-corejs3/core-js-stable/set-timeout');
45
44
  var FlatButton = require('@commercetools-uikit/flat-button');
46
45
  var reactBroadcast = require('@flopflip/react-broadcast');
46
+ var IconButton = require('@commercetools-uikit/icon-button');
47
47
  var _findInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/find');
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');
@@ -75,9 +75,9 @@ var omitBy__default = /*#__PURE__*/_interopDefault(omitBy);
75
75
  var _mapInstanceProperty__default = /*#__PURE__*/_interopDefault(_mapInstanceProperty);
76
76
  var AccessibleButton__default = /*#__PURE__*/_interopDefault(AccessibleButton);
77
77
  var Constraints__default = /*#__PURE__*/_interopDefault(Constraints);
78
- var IconButton__default = /*#__PURE__*/_interopDefault(IconButton);
79
78
  var _setTimeout__default = /*#__PURE__*/_interopDefault(_setTimeout);
80
79
  var FlatButton__default = /*#__PURE__*/_interopDefault(FlatButton);
80
+ var IconButton__default = /*#__PURE__*/_interopDefault(IconButton);
81
81
  var _findInstanceProperty__default = /*#__PURE__*/_interopDefault(_findInstanceProperty);
82
82
  var _Object$entries__default = /*#__PURE__*/_interopDefault(_Object$entries);
83
83
  var PageNotFoundSVG__default = /*#__PURE__*/_interopDefault(PageNotFoundSVG);
@@ -85,7 +85,7 @@ var FailedAuthorizationSVG__default = /*#__PURE__*/_interopDefault(FailedAuthori
85
85
  var useResizeObserver__default = /*#__PURE__*/_interopDefault(useResizeObserver);
86
86
 
87
87
  // NOTE: This string will be replaced on build time with the package version.
88
- var version = "22.13.1";
88
+ var version = "22.13.2";
89
89
 
90
90
  var _context, _context2, _context3, _context4, _context5, _context6, _context7, _context8, _context9;
91
91
  const appKitSpacing55 = '40px';
@@ -481,63 +481,6 @@ FormDialog.defaultProps = defaultProps$f;
481
481
  // The Intl messages can be used for button labels.
482
482
  FormDialog.Intl = i18n.sharedMessages;
483
483
 
484
- 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; }
485
- 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; }
486
- const primaryDefaultProps = {
487
- label: i18n.sharedMessages.confirm,
488
- isDisabled: false,
489
- dataAttributes: {}
490
- };
491
- const useFormattedLabel = label => {
492
- const intl = reactIntl.useIntl();
493
- return typeof label === 'string' ? label : intl.formatMessage(label);
494
- };
495
- const FormPrimaryButton = props => {
496
- const label = useFormattedLabel(props.label);
497
- return jsxRuntime.jsx(PrimaryButton__default["default"], _objectSpread$4({
498
- label: label,
499
- onClick: props.onClick,
500
- isDisabled: props.isDisabled
501
- }, filterDataAttributes(props.dataAttributes)));
502
- };
503
- FormPrimaryButton.propTypes = {};
504
- FormPrimaryButton.displayName = 'FormPrimaryButton';
505
- FormPrimaryButton.defaultProps = primaryDefaultProps;
506
- const secondaryDefaultProps = {
507
- label: i18n.sharedMessages.cancel,
508
- isDisabled: false,
509
- dataAttributes: {}
510
- };
511
- const FormSecondaryButton = props => {
512
- const label = useFormattedLabel(props.label);
513
- return jsxRuntime.jsx(SecondaryButton__default["default"], _objectSpread$4({
514
- label: label,
515
- onClick: props.onClick,
516
- isDisabled: props.isDisabled,
517
- iconLeft: props.iconLeft
518
- }, filterDataAttributes(props.dataAttributes)));
519
- };
520
- FormSecondaryButton.propTypes = {};
521
- FormSecondaryButton.displayName = 'FormSecondaryButton';
522
- FormSecondaryButton.defaultProps = secondaryDefaultProps;
523
- const deleteDefaultProps = {
524
- label: i18n.sharedMessages.delete,
525
- isDisabled: false,
526
- dataAttributes: {}
527
- };
528
- const FormDeleteButton = props => {
529
- const label = useFormattedLabel(props.label);
530
- return jsxRuntime.jsx(IconButton__default["default"], _objectSpread$4({
531
- icon: jsxRuntime.jsx(icons.BinLinearIcon, {}),
532
- label: label,
533
- onClick: props.onClick,
534
- isDisabled: props.isDisabled
535
- }, filterDataAttributes(props.dataAttributes)));
536
- };
537
- FormDeleteButton.propTypes = {};
538
- FormDeleteButton.displayName = 'FormDeleteButton';
539
- FormDeleteButton.defaultProps = deleteDefaultProps;
540
-
541
484
  const messages$4 = reactIntl.defineMessages({
542
485
  back: {
543
486
  id: 'Components.ModalPage.TopBar.Back',
@@ -549,79 +492,6 @@ const messages$4 = reactIntl.defineMessages({
549
492
  }
550
493
  });
551
494
 
552
- const defaultProps$e = {
553
- titleSize: 'small',
554
- truncate: false
555
- };
556
- const SubtitleWrapper = /*#__PURE__*/_styled__default["default"]("div", {
557
- target: "epaiodd0"
558
- } )("margin-top:", designTokens.marginTopForPageSubtitle, ";" + ("" ));
559
- const Title = props => {
560
- switch (props.titleSize) {
561
- case 'big':
562
- return jsxRuntime.jsx(Text__default["default"].Headline, {
563
- as: "h1",
564
- title: props.title,
565
- truncate: props.truncate,
566
- children: props.title
567
- });
568
- case 'medium':
569
- return jsxRuntime.jsx(Text__default["default"].Headline, {
570
- as: "h2",
571
- title: props.title,
572
- truncate: props.truncate,
573
- children: props.title
574
- });
575
- default:
576
- return jsxRuntime.jsx(Text__default["default"].Subheadline, {
577
- as: "h4",
578
- title: props.title,
579
- truncate: props.truncate,
580
- children: props.title
581
- });
582
- }
583
- };
584
- const Subtitle = props => {
585
- if (!props.subtitle) {
586
- return null;
587
- }
588
- if ( /*#__PURE__*/react$1.isValidElement(props.subtitle)) {
589
- return jsxRuntime.jsx(SubtitleWrapper, {
590
- children: props.subtitle
591
- });
592
- }
593
- return jsxRuntime.jsx(SubtitleWrapper, {
594
- children: jsxRuntime.jsx(Text__default["default"].Body, {
595
- title: typeof props.subtitle === 'string' ? props.subtitle : undefined,
596
- truncate: props.truncate,
597
- tone: "secondary",
598
- children: props.subtitle
599
- })
600
- });
601
- };
602
- Subtitle.propTypes = {};
603
- Subtitle.defaultProps = {
604
- truncate: false
605
- };
606
- var _ref$5 = {
607
- name: "d3v9zr",
608
- styles: "overflow:hidden"
609
- } ;
610
- const PageHeaderTitle = props => jsxRuntime.jsxs("div", {
611
- css: _ref$5,
612
- children: [jsxRuntime.jsx(Title, {
613
- title: props.title,
614
- titleSize: props.titleSize,
615
- truncate: props.truncate
616
- }), jsxRuntime.jsx(Subtitle, {
617
- subtitle: props.subtitle,
618
- truncate: props.truncate
619
- })]
620
- });
621
- PageHeaderTitle.propTypes = {};
622
- PageHeaderTitle.displayName = 'PageHeaderTitle';
623
- PageHeaderTitle.defaultProps = defaultProps$e;
624
-
625
495
  // Component to have a larger clickable surface
626
496
  var _ref2$2 = {
627
497
  name: "1rxhroq",
@@ -638,12 +508,12 @@ const LargeIconWrapper = props => jsxRuntime.jsx("span", {
638
508
  // However, we need to explicitly define this otherwise the prop-types babel plugin
639
509
  // does not recognize the object shape.
640
510
  LargeIconWrapper.propTypes = {};
641
- const defaultProps$d = {
511
+ const defaultProps$e = {
642
512
  color: 'surface',
643
513
  previousPathLabel: messages$4.back,
644
514
  hidePathLabel: false
645
515
  };
646
- var _ref$4 = {
516
+ var _ref$5 = {
647
517
  name: "uvw8rn",
648
518
  styles: "display:flex;overflow:hidden;button:first-of-type svg{height:12px!important;width:12px!important;}"
649
519
  } ;
@@ -652,7 +522,7 @@ const ModalPageTopBar = props => {
652
522
  return jsxRuntime.jsxs("div", {
653
523
  css: /*#__PURE__*/react.css("position:relative;display:flex;align-items:center;justify-content:space-between;padding:", designTokens.paddingForModalTopBar, ";background-color:", props.color === 'neutral' ? designTokens.backgroundColorForPageHeader : designSystem.designTokens.colorSurface, ";border-bottom:1px solid ", props.color === 'neutral' ? designSystem.designTokens.colorSurface : designTokens.borderColorForModalTopBarWhenSurface, ";& *+*{margin-left:", designSystem.designTokens.spacingS, ";}p{font-size:12px!important;}" + ("" ), "" ),
654
524
  children: [jsxRuntime.jsxs("div", {
655
- css: _ref$4,
525
+ css: _ref$5,
656
526
  children: [!props.hidePathLabel && jsxRuntime.jsx(FlatButton__default["default"], {
657
527
  tone: "primary",
658
528
  label: typeof props.previousPathLabel === 'string' ? props.previousPathLabel : intl.formatMessage(props.previousPathLabel),
@@ -684,7 +554,7 @@ const ModalPageTopBar = props => {
684
554
  };
685
555
  ModalPageTopBar.propTypes = {};
686
556
  ModalPageTopBar.displayName = 'ModalPageTopBar';
687
- ModalPageTopBar.defaultProps = defaultProps$d;
557
+ ModalPageTopBar.defaultProps = defaultProps$e;
688
558
 
689
559
  const stylesBySize = {
690
560
  '10': {
@@ -718,19 +588,19 @@ var _ref2$1 = {
718
588
  } ;
719
589
  const getAfterOpenOverlayAnimation = () => _ref2$1;
720
590
  const getBeforeCloseContainerAnimation = props => /*#__PURE__*/react.css("transform:translate3d(\n ", props.size !== 'scale' ? stylesBySize[props.size].width : '30px', ",\n ,\n 0,\n 0\n )!important;" + ("" ), "" );
721
- var _ref$3 = {
591
+ var _ref$4 = {
722
592
  name: "728dx5",
723
593
  styles: "opacity:0!important"
724
594
  } ;
725
- const getBeforeCloseOverlayAnimation = () => _ref$3;
595
+ const getBeforeCloseOverlayAnimation = () => _ref$4;
726
596
 
727
- 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; }
728
- 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; }
597
+ 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; }
598
+ 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; }
729
599
  const getDefaultParentSelector = () => document.querySelector("#".concat(constants.PORTALS_CONTAINER_ID));
730
600
  const getOverlayElement = (props, contentElement) =>
731
601
  // Assign the `data-role` to the overlay container, which is used as
732
602
  // the CSS selector in the `<PortalsContainer>`.
733
- jsxRuntime.jsx("div", _objectSpread$3(_objectSpread$3({}, props), {}, {
603
+ jsxRuntime.jsx("div", _objectSpread$4(_objectSpread$4({}, props), {}, {
734
604
  "data-role": "modal-overlay",
735
605
  children: contentElement
736
606
  }));
@@ -738,7 +608,7 @@ jsxRuntime.jsx("div", _objectSpread$3(_objectSpread$3({}, props), {}, {
738
608
  // NOTE: the `MessageDescriptor` type is exposed by `react-intl`.
739
609
  // However, we need to explicitly define this otherwise the prop-types babel plugin
740
610
  // does not recognize the object shape.
741
- const defaultProps$c = {
611
+ const defaultProps$d = {
742
612
  size: 'scale',
743
613
  getParentSelector: getDefaultParentSelector,
744
614
  shouldDelayOnClose: true
@@ -817,85 +687,7 @@ const ModalPage = props => {
817
687
  };
818
688
  ModalPage.propTypes = {};
819
689
  ModalPage.displayName = 'ModalPage';
820
- ModalPage.defaultProps = defaultProps$c;
821
-
822
- const defaultProps$b = {
823
- size: 10,
824
- hideControls: false,
825
- onPrimaryButtonClick: () => {},
826
- onSecondaryButtonClick: () => {}
827
- };
828
- const ContentWrapper$1 = /*#__PURE__*/_styled__default["default"]("div", {
829
- target: "e18jo6y41"
830
- } )("height:100%;padding:", designSystem.designTokens.spacing50, ";" + ("" ));
831
- const HeaderWrapper = /*#__PURE__*/_styled__default["default"]("div", {
832
- target: "e18jo6y40"
833
- } )("padding:", designSystem.designTokens.spacing40, " 40px;border-bottom:1px solid ", designTokens.borderColorForModalPageHeaderDivider, ";" + ("" ));
834
- function Drawer(props) {
835
- const intl = reactIntl.useIntl();
836
- return jsxRuntime.jsxs(ModalPage, {
837
- isOpen: props.isOpen,
838
- hidePathLabel: true,
839
- hideTopBar: true,
840
- onClose: props.onClose,
841
- size: props.size,
842
- title: props.title,
843
- afterOpenStyles: props.afterOpenStyles,
844
- getParentSelector: props.getParentSelector,
845
- shouldDelayOnClose: props.shouldDelayOnClose,
846
- topBarColor: props.topBarColor,
847
- zIndex: props.zIndex,
848
- children: [jsxRuntime.jsx(HeaderWrapper, {
849
- children: jsxRuntime.jsxs(Spacings__default["default"].Stack, {
850
- children: [jsxRuntime.jsxs(Spacings__default["default"].Inline, {
851
- justifyContent: "space-between",
852
- children: [jsxRuntime.jsx(PageHeaderTitle, {
853
- title: props.title,
854
- titleSize: "medium",
855
- subtitle: props.subtitle && jsxRuntime.jsx(Text__default["default"].Detail, {
856
- children: props.subtitle
857
- })
858
- }), props.onClose && jsxRuntime.jsx(SecondaryIconButton__default["default"], {
859
- label: intl.formatMessage(messages$4.close),
860
- onClick: props.onClose,
861
- icon: jsxRuntime.jsx(LargeIconWrapper, {
862
- children: jsxRuntime.jsx(icons.CloseIcon, {})
863
- }),
864
- size: "big"
865
- })]
866
- }), jsxRuntime.jsxs(Spacings__default["default"].Inline, {
867
- justifyContent: "flex-end",
868
- children: [!props.hideControls && props.formControls && props.formControls, !props.hideControls && !props.formControls && jsxRuntime.jsxs(jsxRuntime.Fragment, {
869
- children: [jsxRuntime.jsx(FormSecondaryButton, {
870
- label: props.labelSecondaryButton,
871
- onClick: props.onSecondaryButtonClick,
872
- isDisabled: props.isSecondaryButtonDisabled,
873
- dataAttributes: props.dataAttributesSecondaryButton,
874
- iconLeft: props.iconLeftSecondaryButton
875
- }), jsxRuntime.jsx(FormPrimaryButton, {
876
- label: props.labelPrimaryButton,
877
- onClick: props.onPrimaryButtonClick,
878
- isDisabled: props.isPrimaryButtonDisabled,
879
- dataAttributes: props.dataAttributesPrimaryButton
880
- })]
881
- })]
882
- })]
883
- })
884
- }), jsxRuntime.jsx(ContentWrapper$1, {
885
- children: props.children
886
- })]
887
- });
888
- }
889
- Drawer.propTypes = {};
890
- Drawer.displayName = 'Drawer';
891
- Drawer.defaultProps = defaultProps$b;
892
- // Static export of pre-configured form control buttons to easily re-use
893
- // them in the custom controls.
894
- Drawer.FormPrimaryButton = FormPrimaryButton;
895
- Drawer.FormSecondaryButton = FormSecondaryButton;
896
- // This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
897
- // The Intl messages can be used for button labels.
898
- Drawer.Intl = i18n.sharedMessages;
690
+ ModalPage.defaultProps = defaultProps$d;
899
691
 
900
692
  const messages$3 = reactIntl.defineMessages({
901
693
  loadError: {
@@ -915,6 +707,9 @@ const isIframeReady = iFrameElementRef => {
915
707
  return false;
916
708
  }
917
709
  };
710
+ const ContentWrapper$2 = /*#__PURE__*/_styled__default["default"]("div", {
711
+ target: "ewwxuwo1"
712
+ } )("height:100%;padding:", designSystem.designTokens.spacing40, " 40px;" + ("" ));
918
713
  const CustomPanelIframe = /*#__PURE__*/_styled__default["default"]("iframe", {
919
714
  target: "ewwxuwo0"
920
715
  } )({
@@ -992,18 +787,21 @@ function CustomViewLoader(props) {
992
787
  }
993
788
  const panelSize = ((_props$customView$typ = props.customView.typeSettings) === null || _props$customView$typ === void 0 || (_props$customView$typ = _props$customView$typ.size) === null || _props$customView$typ === void 0 ? void 0 : _props$customView$typ.toLocaleLowerCase()) || 'large';
994
789
  const iFrameUrl = [window.location.origin, 'custom-views', props.customView.id, 'projects', projectKey].join('/');
995
- return jsxRuntime.jsx(Drawer, {
790
+ return jsxRuntime.jsx(ModalPage, {
996
791
  isOpen: true,
997
- title: "Custom View: ".concat(props.customView.defaultLabel),
998
792
  onClose: props.onClose,
999
793
  size: panelSize === 'small' ? 10 : 30,
1000
- children: jsxRuntime.jsx(CustomPanelIframe, {
1001
- id: "custom-view-".concat(props.customView.id),
1002
- title: "Custom View: ".concat(props.customView.defaultLabel),
1003
- ref: iFrameElementRef,
1004
- src: iFrameUrl,
1005
- onLoad: onLoadSuccessHandler
1006
- }, "custom-view-".concat(props.customView.id))
794
+ title: "Custom View: ".concat(props.customView.defaultLabel),
795
+ hidePathLabel: true,
796
+ children: jsxRuntime.jsx(ContentWrapper$2, {
797
+ children: jsxRuntime.jsx(CustomPanelIframe, {
798
+ id: "custom-view-".concat(props.customView.id),
799
+ title: "Custom View: ".concat(props.customView.defaultLabel),
800
+ ref: iFrameElementRef,
801
+ src: iFrameUrl,
802
+ onLoad: onLoadSuccessHandler
803
+ }, "custom-view-".concat(props.customView.id))
804
+ })
1007
805
  });
1008
806
  }
1009
807
  CustomViewLoader.propTypes = {};
@@ -1039,8 +837,8 @@ const useCustomViewsConnector = _ref => {
1039
837
  };
1040
838
  };
1041
839
 
1042
- 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; }
1043
- 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; }
840
+ 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; }
841
+ 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; }
1044
842
  const COMPONENT_HEIGHT = '52px';
1045
843
  const Wrapper = /*#__PURE__*/_styled__default["default"]("div", {
1046
844
  target: "e16cb3zv3"
@@ -1145,12 +943,85 @@ const CustomViewSelectorOrNothing = props => {
1145
943
  if (!props.customViewLocatorCode) {
1146
944
  return null;
1147
945
  }
1148
- return jsxRuntime.jsx(CustomViewSelector, _objectSpread$2(_objectSpread$2({}, props), {}, {
946
+ return jsxRuntime.jsx(CustomViewSelector, _objectSpread$3(_objectSpread$3({}, props), {}, {
1149
947
  customViewLocatorCode: props.customViewLocatorCode
1150
948
  }));
1151
949
  };
1152
950
  CustomViewSelectorOrNothing.propTypes = {};
1153
951
 
952
+ const defaultProps$c = {
953
+ titleSize: 'small',
954
+ truncate: false
955
+ };
956
+ const SubtitleWrapper = /*#__PURE__*/_styled__default["default"]("div", {
957
+ target: "epaiodd0"
958
+ } )("margin-top:", designTokens.marginTopForPageSubtitle, ";" + ("" ));
959
+ const Title = props => {
960
+ switch (props.titleSize) {
961
+ case 'big':
962
+ return jsxRuntime.jsx(Text__default["default"].Headline, {
963
+ as: "h1",
964
+ title: props.title,
965
+ truncate: props.truncate,
966
+ children: props.title
967
+ });
968
+ case 'medium':
969
+ return jsxRuntime.jsx(Text__default["default"].Headline, {
970
+ as: "h2",
971
+ title: props.title,
972
+ truncate: props.truncate,
973
+ children: props.title
974
+ });
975
+ default:
976
+ return jsxRuntime.jsx(Text__default["default"].Subheadline, {
977
+ as: "h4",
978
+ title: props.title,
979
+ truncate: props.truncate,
980
+ children: props.title
981
+ });
982
+ }
983
+ };
984
+ const Subtitle = props => {
985
+ if (!props.subtitle) {
986
+ return null;
987
+ }
988
+ if ( /*#__PURE__*/react$1.isValidElement(props.subtitle)) {
989
+ return jsxRuntime.jsx(SubtitleWrapper, {
990
+ children: props.subtitle
991
+ });
992
+ }
993
+ return jsxRuntime.jsx(SubtitleWrapper, {
994
+ children: jsxRuntime.jsx(Text__default["default"].Body, {
995
+ title: typeof props.subtitle === 'string' ? props.subtitle : undefined,
996
+ truncate: props.truncate,
997
+ tone: "secondary",
998
+ children: props.subtitle
999
+ })
1000
+ });
1001
+ };
1002
+ Subtitle.propTypes = {};
1003
+ Subtitle.defaultProps = {
1004
+ truncate: false
1005
+ };
1006
+ var _ref$3 = {
1007
+ name: "d3v9zr",
1008
+ styles: "overflow:hidden"
1009
+ } ;
1010
+ const PageHeaderTitle = props => jsxRuntime.jsxs("div", {
1011
+ css: _ref$3,
1012
+ children: [jsxRuntime.jsx(Title, {
1013
+ title: props.title,
1014
+ titleSize: props.titleSize,
1015
+ truncate: props.truncate
1016
+ }), jsxRuntime.jsx(Subtitle, {
1017
+ subtitle: props.subtitle,
1018
+ truncate: props.truncate
1019
+ })]
1020
+ });
1021
+ PageHeaderTitle.propTypes = {};
1022
+ PageHeaderTitle.displayName = 'PageHeaderTitle';
1023
+ PageHeaderTitle.defaultProps = defaultProps$c;
1024
+
1154
1025
  const PageHeader = props => {
1155
1026
  return jsxRuntime.jsxs("div", {
1156
1027
  css: /*#__PURE__*/react.css("margin:", designTokens.marginForModalPageHeader, ";padding:", designTokens.paddingForModalPageHeader, ";border-bottom:1px solid ", designTokens.borderColorForModalPageHeaderDivider, ";" + ("" ), "" ),
@@ -1171,7 +1042,7 @@ const PageHeader = props => {
1171
1042
  PageHeader.propTypes = {};
1172
1043
  PageHeader.displayName = 'PageHeader';
1173
1044
 
1174
- const ContentWrapper = /*#__PURE__*/_styled__default["default"]("div", {
1045
+ const ContentWrapper$1 = /*#__PURE__*/_styled__default["default"]("div", {
1175
1046
  target: "e1b7jwn01"
1176
1047
  } )("flex:1;flex-basis:0;margin:", designTokens.marginForPageContent, ";overflow:auto;" + ("" ));
1177
1048
  const PageWrapper = /*#__PURE__*/_styled__default["default"]("div", {
@@ -1195,13 +1066,70 @@ const InfoModalPage = props => jsxRuntime.jsxs(ModalPage, {
1195
1066
  title: props.title,
1196
1067
  subtitle: props.subtitle,
1197
1068
  customViewLocatorCode: props.customViewLocatorCode
1198
- }), jsxRuntime.jsx(ContentWrapper, {
1069
+ }), jsxRuntime.jsx(ContentWrapper$1, {
1199
1070
  children: props.children
1200
1071
  })]
1201
1072
  });
1202
1073
  InfoModalPage.propTypes = {};
1203
1074
  InfoModalPage.displayName = 'InfoModalPage';
1204
1075
 
1076
+ 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; }
1077
+ 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; }
1078
+ const primaryDefaultProps = {
1079
+ label: i18n.sharedMessages.confirm,
1080
+ isDisabled: false,
1081
+ dataAttributes: {}
1082
+ };
1083
+ const useFormattedLabel = label => {
1084
+ const intl = reactIntl.useIntl();
1085
+ return typeof label === 'string' ? label : intl.formatMessage(label);
1086
+ };
1087
+ const FormPrimaryButton = props => {
1088
+ const label = useFormattedLabel(props.label);
1089
+ return jsxRuntime.jsx(PrimaryButton__default["default"], _objectSpread$2({
1090
+ label: label,
1091
+ onClick: props.onClick,
1092
+ isDisabled: props.isDisabled
1093
+ }, filterDataAttributes(props.dataAttributes)));
1094
+ };
1095
+ FormPrimaryButton.propTypes = {};
1096
+ FormPrimaryButton.displayName = 'FormPrimaryButton';
1097
+ FormPrimaryButton.defaultProps = primaryDefaultProps;
1098
+ const secondaryDefaultProps = {
1099
+ label: i18n.sharedMessages.cancel,
1100
+ isDisabled: false,
1101
+ dataAttributes: {}
1102
+ };
1103
+ const FormSecondaryButton = props => {
1104
+ const label = useFormattedLabel(props.label);
1105
+ return jsxRuntime.jsx(SecondaryButton__default["default"], _objectSpread$2({
1106
+ label: label,
1107
+ onClick: props.onClick,
1108
+ isDisabled: props.isDisabled,
1109
+ iconLeft: props.iconLeft
1110
+ }, filterDataAttributes(props.dataAttributes)));
1111
+ };
1112
+ FormSecondaryButton.propTypes = {};
1113
+ FormSecondaryButton.displayName = 'FormSecondaryButton';
1114
+ FormSecondaryButton.defaultProps = secondaryDefaultProps;
1115
+ const deleteDefaultProps = {
1116
+ label: i18n.sharedMessages.delete,
1117
+ isDisabled: false,
1118
+ dataAttributes: {}
1119
+ };
1120
+ const FormDeleteButton = props => {
1121
+ const label = useFormattedLabel(props.label);
1122
+ return jsxRuntime.jsx(IconButton__default["default"], _objectSpread$2({
1123
+ icon: jsxRuntime.jsx(icons.BinLinearIcon, {}),
1124
+ label: label,
1125
+ onClick: props.onClick,
1126
+ isDisabled: props.isDisabled
1127
+ }, filterDataAttributes(props.dataAttributes)));
1128
+ };
1129
+ FormDeleteButton.propTypes = {};
1130
+ FormDeleteButton.displayName = 'FormDeleteButton';
1131
+ FormDeleteButton.defaultProps = deleteDefaultProps;
1132
+
1205
1133
  const CustomFormModalPage = props => jsxRuntime.jsxs(ModalPage, {
1206
1134
  title: props.title,
1207
1135
  isOpen: props.isOpen,
@@ -1220,7 +1148,7 @@ const CustomFormModalPage = props => jsxRuntime.jsxs(ModalPage, {
1220
1148
  alignItems: "flex-end",
1221
1149
  children: props.formControls
1222
1150
  })
1223
- }), jsxRuntime.jsx(ContentWrapper, {
1151
+ }), jsxRuntime.jsx(ContentWrapper$1, {
1224
1152
  children: props.children
1225
1153
  })]
1226
1154
  });
@@ -1235,7 +1163,7 @@ CustomFormModalPage.FormDeleteButton = FormDeleteButton;
1235
1163
  // The Intl messages can be used for button labels.
1236
1164
  CustomFormModalPage.Intl = i18n.sharedMessages;
1237
1165
 
1238
- const defaultProps$a = {
1166
+ const defaultProps$b = {
1239
1167
  hideControls: false
1240
1168
  };
1241
1169
  const FormModalPage = props => jsxRuntime.jsx(CustomFormModalPage, {
@@ -1269,7 +1197,7 @@ const FormModalPage = props => jsxRuntime.jsx(CustomFormModalPage, {
1269
1197
  });
1270
1198
  FormModalPage.propTypes = {};
1271
1199
  FormModalPage.displayName = 'FormModalPage';
1272
- FormModalPage.defaultProps = defaultProps$a;
1200
+ FormModalPage.defaultProps = defaultProps$b;
1273
1201
  // This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
1274
1202
  // The Intl messages can be used for button labels.
1275
1203
  FormModalPage.Intl = i18n.sharedMessages;
@@ -1312,10 +1240,10 @@ const TabularPageContainer = props => jsxRuntime.jsx("div", {
1312
1240
  });
1313
1241
  TabularPageContainer.propTypes = {};
1314
1242
  TabularPageContainer.displayName = 'TabularPageContainer';
1315
- const defaultProps$9 = {
1243
+ const defaultProps$a = {
1316
1244
  color: 'surface'
1317
1245
  };
1318
- TabularPageContainer.defaultProps = defaultProps$9;
1246
+ TabularPageContainer.defaultProps = defaultProps$a;
1319
1247
  const FormControlsContainer = /*#__PURE__*/_styled__default["default"]("div", {
1320
1248
  target: "elpldre1"
1321
1249
  } )("margin-bottom:", designSystem.designTokens.spacingM, ";" + ("" ));
@@ -1323,7 +1251,7 @@ const CustomViewsSelectorWrapper = /*#__PURE__*/_styled__default["default"]("div
1323
1251
  target: "elpldre0"
1324
1252
  } )("margin:", designTokens.marginForCustomViewsSelectorAsTabular, ";" + ("" ));
1325
1253
 
1326
- const defaultProps$8 = {
1254
+ const defaultProps$9 = {
1327
1255
  hideControls: false
1328
1256
  };
1329
1257
  const TabularModalPage = props => {
@@ -1361,14 +1289,14 @@ const TabularModalPage = props => {
1361
1289
  margin: "".concat(designSystem.designTokens.spacing30, " 0 0 0"),
1362
1290
  customViewLocatorCode: currentCustomViewLocatorCode
1363
1291
  })
1364
- }), jsxRuntime.jsx(ContentWrapper, {
1292
+ }), jsxRuntime.jsx(ContentWrapper$1, {
1365
1293
  children: props.children
1366
1294
  })]
1367
1295
  });
1368
1296
  };
1369
1297
  TabularModalPage.propTypes = {};
1370
1298
  TabularModalPage.displayName = 'TabularModalPage';
1371
- TabularModalPage.defaultProps = defaultProps$8;
1299
+ TabularModalPage.defaultProps = defaultProps$9;
1372
1300
  // Static export of pre-configured form control buttons to easily re-use
1373
1301
  // them in the custom controls.
1374
1302
  TabularModalPage.FormPrimaryButton = FormPrimaryButton;
@@ -1378,7 +1306,7 @@ TabularModalPage.FormDeleteButton = FormDeleteButton;
1378
1306
  // The Intl messages can be used for button labels.
1379
1307
  TabularModalPage.Intl = i18n.sharedMessages;
1380
1308
 
1381
- const defaultProps$7 = {
1309
+ const defaultProps$8 = {
1382
1310
  color: 'surface',
1383
1311
  previousPathLabel: messages$4.back
1384
1312
  };
@@ -1399,7 +1327,7 @@ const PageTopBar = props => {
1399
1327
  };
1400
1328
  PageTopBar.propTypes = {};
1401
1329
  PageTopBar.displayName = 'PageTopBar';
1402
- PageTopBar.defaultProps = defaultProps$7;
1330
+ PageTopBar.defaultProps = defaultProps$8;
1403
1331
 
1404
1332
  const DetailPageContainer = /*#__PURE__*/_styled__default["default"]("div", {
1405
1333
  target: "etkdonc1"
@@ -1415,7 +1343,7 @@ const getCustomViewsSelectorMargin = hasContentBelow => {
1415
1343
  // NOTE: the `MessageDescriptor` type is exposed by `react-intl`.
1416
1344
  // However, we need to explicitly define this otherwise the prop-types babel plugin
1417
1345
  // does not recognize the object shape.
1418
- const defaultProps$6 = {
1346
+ const defaultProps$7 = {
1419
1347
  hideControls: false
1420
1348
  };
1421
1349
  const CustomFormDetailPage = props => {
@@ -1439,14 +1367,14 @@ const CustomFormDetailPage = props => {
1439
1367
  children: props.formControls
1440
1368
  })
1441
1369
  })]
1442
- }), jsxRuntime.jsx(ContentWrapper, {
1370
+ }), jsxRuntime.jsx(ContentWrapper$1, {
1443
1371
  children: props.children
1444
1372
  })]
1445
1373
  });
1446
1374
  };
1447
1375
  CustomFormDetailPage.propTypes = {};
1448
1376
  CustomFormDetailPage.displayName = 'CustomFormDetailPage';
1449
- CustomFormDetailPage.defaultProps = defaultProps$6;
1377
+ CustomFormDetailPage.defaultProps = defaultProps$7;
1450
1378
  // Static export of pre-configured page header title component to easily
1451
1379
  // use as part of a custom title row
1452
1380
  CustomFormDetailPage.PageHeaderTitle = PageHeaderTitle;
@@ -1459,7 +1387,7 @@ CustomFormDetailPage.FormDeleteButton = FormDeleteButton;
1459
1387
  // The Intl messages can be used for button labels.
1460
1388
  CustomFormDetailPage.Intl = i18n.sharedMessages;
1461
1389
 
1462
- const defaultProps$5 = {
1390
+ const defaultProps$6 = {
1463
1391
  hideControls: false
1464
1392
  };
1465
1393
  const FormDetailPage = props => jsxRuntime.jsx(CustomFormDetailPage, {
@@ -1488,7 +1416,7 @@ const FormDetailPage = props => jsxRuntime.jsx(CustomFormDetailPage, {
1488
1416
  });
1489
1417
  FormDetailPage.propTypes = {};
1490
1418
  FormDetailPage.displayName = 'FormDetailPage';
1491
- FormDetailPage.defaultProps = defaultProps$5;
1419
+ FormDetailPage.defaultProps = defaultProps$6;
1492
1420
  // This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
1493
1421
  // The Intl messages can be used for button labels.
1494
1422
  // Static export of pre-configured page header title component to easily
@@ -1513,7 +1441,7 @@ InfoDetailPage.displayName = 'InfoDetailPage';
1513
1441
  // use as part of a custom title row
1514
1442
  InfoDetailPage.PageHeaderTitle = PageHeaderTitle;
1515
1443
 
1516
- const defaultProps$4 = {
1444
+ const defaultProps$5 = {
1517
1445
  hideControls: false
1518
1446
  };
1519
1447
  const TabularDetailPage = props => {
@@ -1545,14 +1473,14 @@ const TabularDetailPage = props => {
1545
1473
  margin: "".concat(designSystem.designTokens.spacing30, " 0 0 0"),
1546
1474
  customViewLocatorCode: currentCustomViewLocatorCode
1547
1475
  })
1548
- }), jsxRuntime.jsx(ContentWrapper, {
1476
+ }), jsxRuntime.jsx(ContentWrapper$1, {
1549
1477
  children: props.children
1550
1478
  })]
1551
1479
  });
1552
1480
  };
1553
1481
  TabularDetailPage.propTypes = {};
1554
1482
  TabularDetailPage.displayName = 'TabularDetailPage';
1555
- TabularDetailPage.defaultProps = defaultProps$4;
1483
+ TabularDetailPage.defaultProps = defaultProps$5;
1556
1484
  // Static export of pre-configured form control buttons to easily re-use
1557
1485
  // them in the custom controls.
1558
1486
  TabularDetailPage.FormPrimaryButton = FormPrimaryButton;
@@ -1564,7 +1492,7 @@ TabularDetailPage.PageHeaderTitle = PageHeaderTitle;
1564
1492
  // This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
1565
1493
  TabularDetailPage.Intl = i18n.sharedMessages;
1566
1494
 
1567
- const PublicPageLayout = /*#__PURE__*/react$1.lazy(() => Promise.resolve().then(function () { return require('./public-page-layout-609304bf.cjs.prod.js' /* webpackChunkName: "public-page-layout" */); }));
1495
+ const PublicPageLayout = /*#__PURE__*/react$1.lazy(() => Promise.resolve().then(function () { return require('./public-page-layout-f84502f6.cjs.prod.js' /* webpackChunkName: "public-page-layout" */); }));
1568
1496
 
1569
1497
  const MainPageContainer = /*#__PURE__*/_styled__default["default"]("div", {
1570
1498
  target: "ev8m2jf2"
@@ -1604,12 +1532,12 @@ const CustomFormMainPage = props => {
1604
1532
  });
1605
1533
  };
1606
1534
  CustomFormMainPage.propTypes = {};
1607
- const defaultProps$3 = {
1535
+ const defaultProps$4 = {
1608
1536
  hideControls: false,
1609
1537
  hideDivider: false
1610
1538
  };
1611
1539
  CustomFormMainPage.displayName = 'CustomFormMainPage';
1612
- CustomFormMainPage.defaultProps = defaultProps$3;
1540
+ CustomFormMainPage.defaultProps = defaultProps$4;
1613
1541
 
1614
1542
  // Static export of pre-configured page header title component to easily
1615
1543
  // use as part of a custom title row
@@ -1625,7 +1553,7 @@ CustomFormMainPage.FormDeleteButton = FormDeleteButton;
1625
1553
  // The Intl messages can be used for button labels.
1626
1554
  CustomFormMainPage.Intl = i18n.sharedMessages;
1627
1555
 
1628
- const defaultProps$2 = {
1556
+ const defaultProps$3 = {
1629
1557
  hideControls: false
1630
1558
  };
1631
1559
  const FormMainPage = props => {
@@ -1654,7 +1582,7 @@ const FormMainPage = props => {
1654
1582
  };
1655
1583
  FormMainPage.propTypes = {};
1656
1584
  FormMainPage.displayName = 'FormMainPage';
1657
- FormMainPage.defaultProps = defaultProps$2;
1585
+ FormMainPage.defaultProps = defaultProps$3;
1658
1586
 
1659
1587
  // Static export of pre-configured page header title component to easily
1660
1588
  // use as part of a custom title row
@@ -1680,7 +1608,7 @@ InfoMainPage.displayName = 'InfoMainPage';
1680
1608
  // use as part of a custom title row
1681
1609
  InfoMainPage.PageHeaderTitle = PageHeaderTitle;
1682
1610
 
1683
- const defaultProps$1 = {
1611
+ const defaultProps$2 = {
1684
1612
  hideControls: false
1685
1613
  };
1686
1614
  const TabularMainPage = props => {
@@ -1708,7 +1636,7 @@ const TabularMainPage = props => {
1708
1636
  margin: "".concat(designSystem.designTokens.spacing30, " 0 0 0"),
1709
1637
  customViewLocatorCode: currentCustomViewLocatorCode
1710
1638
  })
1711
- }), jsxRuntime.jsx(ContentWrapper, {
1639
+ }), jsxRuntime.jsx(ContentWrapper$1, {
1712
1640
  css: /*#__PURE__*/react.css("background-color:", designTokens.backgroundColorForTabularMainPageContent, ";" + ("" ), "" ),
1713
1641
  children: props.children
1714
1642
  })]
@@ -1716,7 +1644,7 @@ const TabularMainPage = props => {
1716
1644
  };
1717
1645
  TabularMainPage.propTypes = {};
1718
1646
  TabularMainPage.displayName = 'TabularMainPage';
1719
- TabularMainPage.defaultProps = defaultProps$1;
1647
+ TabularMainPage.defaultProps = defaultProps$2;
1720
1648
  // Static export of pre-configured form control buttons to easily re-use
1721
1649
  // them in the custom controls.
1722
1650
  TabularMainPage.FormPrimaryButton = FormPrimaryButton;
@@ -1924,11 +1852,11 @@ function PageContentWide(props) {
1924
1852
  });
1925
1853
  }
1926
1854
  PageContentWide.propTypes = {};
1927
- const defaultProps = {
1855
+ const defaultProps$1 = {
1928
1856
  columns: '1',
1929
1857
  gapSize: '20'
1930
1858
  };
1931
- PageContentWide.defaultProps = defaultProps;
1859
+ PageContentWide.defaultProps = defaultProps$1;
1932
1860
 
1933
1861
  var _ref$1 = {
1934
1862
  name: "1d3w5wq",
@@ -1944,6 +1872,84 @@ function PageContentFull(props) {
1944
1872
  }
1945
1873
  PageContentFull.propTypes = {};
1946
1874
 
1875
+ const defaultProps = {
1876
+ size: 10,
1877
+ hideControls: false,
1878
+ onPrimaryButtonClick: () => {},
1879
+ onSecondaryButtonClick: () => {}
1880
+ };
1881
+ const ContentWrapper = /*#__PURE__*/_styled__default["default"]("div", {
1882
+ target: "e18jo6y41"
1883
+ } )("height:100%;padding:", designSystem.designTokens.spacing50, ";" + ("" ));
1884
+ const HeaderWrapper = /*#__PURE__*/_styled__default["default"]("div", {
1885
+ target: "e18jo6y40"
1886
+ } )("padding:", designSystem.designTokens.spacing40, " 40px;border-bottom:1px solid ", designTokens.borderColorForModalPageHeaderDivider, ";" + ("" ));
1887
+ function Drawer(props) {
1888
+ const intl = reactIntl.useIntl();
1889
+ return jsxRuntime.jsxs(ModalPage, {
1890
+ isOpen: props.isOpen,
1891
+ hidePathLabel: true,
1892
+ hideTopBar: true,
1893
+ onClose: props.onClose,
1894
+ size: props.size,
1895
+ title: props.title,
1896
+ afterOpenStyles: props.afterOpenStyles,
1897
+ getParentSelector: props.getParentSelector,
1898
+ shouldDelayOnClose: props.shouldDelayOnClose,
1899
+ topBarColor: props.topBarColor,
1900
+ zIndex: props.zIndex,
1901
+ children: [jsxRuntime.jsx(HeaderWrapper, {
1902
+ children: jsxRuntime.jsxs(Spacings__default["default"].Stack, {
1903
+ children: [jsxRuntime.jsxs(Spacings__default["default"].Inline, {
1904
+ justifyContent: "space-between",
1905
+ children: [jsxRuntime.jsx(PageHeaderTitle, {
1906
+ title: props.title,
1907
+ titleSize: "medium",
1908
+ subtitle: props.subtitle && jsxRuntime.jsx(Text__default["default"].Detail, {
1909
+ children: props.subtitle
1910
+ })
1911
+ }), props.onClose && jsxRuntime.jsx(SecondaryIconButton__default["default"], {
1912
+ label: intl.formatMessage(messages$4.close),
1913
+ onClick: props.onClose,
1914
+ icon: jsxRuntime.jsx(LargeIconWrapper, {
1915
+ children: jsxRuntime.jsx(icons.CloseIcon, {})
1916
+ }),
1917
+ size: "big"
1918
+ })]
1919
+ }), jsxRuntime.jsxs(Spacings__default["default"].Inline, {
1920
+ justifyContent: "flex-end",
1921
+ children: [!props.hideControls && props.formControls && props.formControls, !props.hideControls && !props.formControls && jsxRuntime.jsxs(jsxRuntime.Fragment, {
1922
+ children: [jsxRuntime.jsx(FormSecondaryButton, {
1923
+ label: props.labelSecondaryButton,
1924
+ onClick: props.onSecondaryButtonClick,
1925
+ isDisabled: props.isSecondaryButtonDisabled,
1926
+ dataAttributes: props.dataAttributesSecondaryButton,
1927
+ iconLeft: props.iconLeftSecondaryButton
1928
+ }), jsxRuntime.jsx(FormPrimaryButton, {
1929
+ label: props.labelPrimaryButton,
1930
+ onClick: props.onPrimaryButtonClick,
1931
+ isDisabled: props.isPrimaryButtonDisabled,
1932
+ dataAttributes: props.dataAttributesPrimaryButton
1933
+ })]
1934
+ })]
1935
+ })]
1936
+ })
1937
+ }), jsxRuntime.jsx(ContentWrapper, {
1938
+ children: props.children
1939
+ })]
1940
+ });
1941
+ }
1942
+ Drawer.propTypes = {};
1943
+ Drawer.displayName = 'Drawer';
1944
+ Drawer.defaultProps = defaultProps;
1945
+ // Static export of pre-configured form control buttons to easily re-use
1946
+ // them in the custom controls.
1947
+ Drawer.FormPrimaryButton = FormPrimaryButton;
1948
+ Drawer.FormSecondaryButton = FormSecondaryButton;
1949
+ // This is a convenience proxy export to expose pre-defined Intl messages defined in the `@commercetools-frontend/i18n` package.
1950
+ // The Intl messages can be used for button labels.
1951
+ Drawer.Intl = i18n.sharedMessages;
1952
+
1947
1953
  // The width of each indentation level.
1948
1954
  const indentationSize = '48px';
1949
1955
  const useObserverElementDimensions = element => {