@patternfly/quickstarts 5.3.0 → 5.4.0-prerelease.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.
@@ -907,6 +907,18 @@
907
907
  --pf-v5-c-check__label--FontSize: 14px;
908
908
  }
909
909
 
910
+ .pfext-quick-start-footer {
911
+ background-color: var(--pf-v5-global--BackgroundColor--100);
912
+ flex: 0 0 auto;
913
+ padding: var(--pf-v5-global--spacer--md) var(--pf-v5-global--spacer--lg);
914
+ }
915
+ .pfext-quick-start-footer__actionbtn {
916
+ margin-right: var(--pf-v5-global--spacer--md);
917
+ }
918
+ .pfext-quick-start-footer__restartbtn {
919
+ float: right;
920
+ }
921
+
910
922
  .pfext-quick-start-content {
911
923
  flex: 1 1 0;
912
924
  overflow: auto;
@@ -917,16 +929,34 @@
917
929
  font-size: 13px;
918
930
  }
919
931
 
920
- .pfext-quick-start-footer {
921
- background-color: var(--pf-v5-global--BackgroundColor--100);
922
- flex: 0 0 auto;
923
- padding: var(--pf-v5-global--spacer--md) var(--pf-v5-global--spacer--lg);
932
+ .pfext-quick-start-intro__prereq {
933
+ margin-bottom: var(--pf-v5-global--spacer--md);
924
934
  }
925
- .pfext-quick-start-footer__actionbtn {
926
- margin-right: var(--pf-v5-global--spacer--md);
935
+ .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__content {
936
+ margin-top: var(--pf-v5-global--spacer--sm);
927
937
  }
928
- .pfext-quick-start-footer__restartbtn {
929
- float: right;
938
+ .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle {
939
+ padding-top: 0;
940
+ padding-bottom: 0;
941
+ }
942
+ .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-text {
943
+ margin-left: var(--pf-v5-global--spacer--sm);
944
+ }
945
+ .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-icon {
946
+ color: var(--pf-v5-c-expandable-section__toggle--Color);
947
+ }
948
+ .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-icon:focus, .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-icon:hover {
949
+ --pf-v5-c-expandable-section__toggle--Color: var(--pf-v5-c-expandable-section__toggle--focus--Color);
950
+ }
951
+ .pfext-quick-start-intro__prereq-list {
952
+ padding-left: 20px;
953
+ }
954
+ .pfext-quick-start-intro__prereq-list__item::marker {
955
+ font-size: 0.8rem;
956
+ }
957
+ .pfext-quick-start-intro__prereq-list__item-content {
958
+ position: relative;
959
+ left: 2px;
930
960
  }
931
961
 
932
962
  .pfext-quick-start-tasks__list button::before {
@@ -1000,36 +1030,6 @@
1000
1030
  font-size: 14px;
1001
1031
  }
1002
1032
 
1003
- .pfext-quick-start-intro__prereq {
1004
- margin-bottom: var(--pf-v5-global--spacer--md);
1005
- }
1006
- .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__content {
1007
- margin-top: var(--pf-v5-global--spacer--sm);
1008
- }
1009
- .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle {
1010
- padding-top: 0;
1011
- padding-bottom: 0;
1012
- }
1013
- .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-text {
1014
- margin-left: var(--pf-v5-global--spacer--sm);
1015
- }
1016
- .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-icon {
1017
- color: var(--pf-v5-c-expandable-section__toggle--Color);
1018
- }
1019
- .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-icon:focus, .pfext-quick-start-intro__prereq .pf-v5-c-expandable-section__toggle-icon:hover {
1020
- --pf-v5-c-expandable-section__toggle--Color: var(--pf-v5-c-expandable-section__toggle--focus--Color);
1021
- }
1022
- .pfext-quick-start-intro__prereq-list {
1023
- padding-left: 20px;
1024
- }
1025
- .pfext-quick-start-intro__prereq-list__item::marker {
1026
- font-size: 0.8rem;
1027
- }
1028
- .pfext-quick-start-intro__prereq-list__item-content {
1029
- position: relative;
1030
- left: 2px;
1031
- }
1032
-
1033
1033
  .pfext-quick-start-task-header__list {
1034
1034
  padding: 0 !important;
1035
1035
  }
@@ -1044,34 +1044,6 @@
1044
1044
  margin-bottom: var(--pf-v5-global--spacer--xs);
1045
1045
  }
1046
1046
 
1047
- .pfext-quick-start-task-review-alert {
1048
- margin: var(--pf-v5-global--spacer--lg) 0;
1049
- }
1050
-
1051
- .pfext-quick-start-task-review {
1052
- font-size: var(--pf-v5-global--FontSize--md);
1053
- line-height: var(--pf-v5-global--FontSize--xl);
1054
- font-family: var(--pf-v5-global--FontFamily--heading--sans-serif);
1055
- }
1056
- .pfext-quick-start-task-review__actions {
1057
- display: flex;
1058
- align-items: flex-start;
1059
- margin-bottom: var(--pf-v5-global--spacer--sm);
1060
- }
1061
- .pfext-quick-start-task-review__actions input[type=radio] {
1062
- margin-top: 0;
1063
- margin-right: 0;
1064
- }
1065
- .pfext-quick-start-task-review__radio {
1066
- margin-right: var(--pf-v5-global--spacer--xl) !important;
1067
- }
1068
- .pfext-quick-start-task-review--success {
1069
- color: var(--pf-v5-global--success-color--100) !important;
1070
- }
1071
- .pfext-quick-start-task-review--failed {
1072
- color: var(--pf-chart-global--danger--Color--100);
1073
- }
1074
-
1075
1047
  .pfext-quick-start-task-header {
1076
1048
  margin-bottom: var(--pf-v5-global--spacer--sm);
1077
1049
  display: grid;
@@ -1119,6 +1091,34 @@
1119
1091
  color: var(--pf-v5-global--danger-color--100) !important;
1120
1092
  }
1121
1093
 
1094
+ .pfext-quick-start-task-review-alert {
1095
+ margin: var(--pf-v5-global--spacer--lg) 0;
1096
+ }
1097
+
1098
+ .pfext-quick-start-task-review {
1099
+ font-size: var(--pf-v5-global--FontSize--md);
1100
+ line-height: var(--pf-v5-global--FontSize--xl);
1101
+ font-family: var(--pf-v5-global--FontFamily--heading--sans-serif);
1102
+ }
1103
+ .pfext-quick-start-task-review__actions {
1104
+ display: flex;
1105
+ align-items: flex-start;
1106
+ margin-bottom: var(--pf-v5-global--spacer--sm);
1107
+ }
1108
+ .pfext-quick-start-task-review__actions input[type=radio] {
1109
+ margin-top: 0;
1110
+ margin-right: 0;
1111
+ }
1112
+ .pfext-quick-start-task-review__radio {
1113
+ margin-right: var(--pf-v5-global--spacer--xl) !important;
1114
+ }
1115
+ .pfext-quick-start-task-review--success {
1116
+ color: var(--pf-v5-global--success-color--100) !important;
1117
+ }
1118
+ .pfext-quick-start-task-review--failed {
1119
+ color: var(--pf-chart-global--danger--Color--100);
1120
+ }
1121
+
1122
1122
  .pfext-modal {
1123
1123
  position: absolute !important;
1124
1124
  }
@@ -10209,6 +10209,7 @@ const QuickStartContextDefaults = {
10209
10209
  markdown: null,
10210
10210
  loading: false,
10211
10211
  alwaysShowTaskReview: true,
10212
+ focusOnQuickStart: true,
10212
10213
  };
10213
10214
  const QuickStartContext = createContext(QuickStartContextDefaults);
10214
10215
  const getResource = (resource, options, resourceBundle, lng) => {
@@ -31236,12 +31237,13 @@ const TaskIcon = ({ taskIndex, taskStatus }) => {
31236
31237
  };
31237
31238
  const QuickStartTaskHeader = ({ title, taskIndex, subtitle, taskStatus, size, isActiveTask, onTaskSelect, children, }) => {
31238
31239
  const titleRef = React.useRef(null);
31240
+ const { focusOnQuickStart } = React.useContext(QuickStartContext);
31239
31241
  React.useEffect(() => {
31240
- if (isActiveTask) {
31242
+ if (focusOnQuickStart && isActiveTask) {
31241
31243
  // Focus the WizardNavItem button element that contains the title
31242
31244
  titleRef.current.parentNode.focus();
31243
31245
  }
31244
- }, [isActiveTask]);
31246
+ }, [focusOnQuickStart, isActiveTask]);
31245
31247
  const classNames = css('pfext-quick-start-task-header__title', {
31246
31248
  'pfext-quick-start-task-header__title-success': taskStatus === QuickStartTaskStatus.SUCCESS,
31247
31249
  'pfext-quick-start-task-header__title-failed': taskStatus === (QuickStartTaskStatus.FAILED || QuickStartTaskStatus.VISITED),
@@ -31452,7 +31454,7 @@ const useScrollTopOnTaskNumberChange = (node, taskNumber) => {
31452
31454
  const QuickStartPanelContent = (_a) => {
31453
31455
  var { quickStarts = [], handleClose, activeQuickStartID, appendTo, isResizable = true, showClose = true, headerVariant = '' } = _a, props = __rest(_a, ["quickStarts", "handleClose", "activeQuickStartID", "appendTo", "isResizable", "showClose", "headerVariant"]);
31454
31456
  const titleRef = React.useRef(null);
31455
- const { getResource, activeQuickStartState } = React.useContext(QuickStartContext);
31457
+ const { getResource, activeQuickStartState, focusOnQuickStart } = React.useContext(QuickStartContext);
31456
31458
  const [contentRef, setContentRef] = React.useState();
31457
31459
  const shadows = useScrollShadows(contentRef);
31458
31460
  const quickStart = quickStarts.find((qs) => qs.metadata.name === activeQuickStartID);
@@ -31477,10 +31479,10 @@ const QuickStartPanelContent = (_a) => {
31477
31479
  return Number.parseInt(taskNumber) + 1;
31478
31480
  };
31479
31481
  React.useEffect(() => {
31480
- if (quickStart) {
31482
+ if (focusOnQuickStart && quickStart) {
31481
31483
  titleRef.current.focus();
31482
31484
  }
31483
- }, [quickStart]);
31485
+ }, [focusOnQuickStart, quickStart]);
31484
31486
  const content = quickStart ? (React.createElement(DrawerPanelContent, Object.assign({ isResizable: isResizable, className: "pfext-quick-start__base", "data-testid": `qs-drawer-${camelize(quickStart.spec.displayName)}`, "data-qs": `qs-step-${getStep()}`, "data-test": "quickstart drawer" }, props),
31485
31487
  React.createElement("div", { className: headerClasses },
31486
31488
  React.createElement(DrawerHead, null,