@patternfly/quickstarts 2.3.3 → 2.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ConsoleInternal/components/markdown-view.d.ts +1 -1
- package/dist/ConsoleShared/src/components/markdown-extensions/accordion-extension.d.ts +7 -0
- package/dist/ConsoleShared/src/components/markdown-extensions/accordion-render-extension.d.ts +6 -0
- package/dist/ConsoleShared/src/components/markdown-extensions/const.d.ts +2 -0
- package/dist/ConsoleShared/src/components/markdown-extensions/index.d.ts +2 -0
- package/dist/index.es.js +101 -28
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +99 -26
- package/dist/index.js.map +1 -1
- package/dist/patternfly-docs/quick-starts/design-guidelines/design-guidelines.md +1 -1
- package/dist/patternfly-docs/quick-starts/examples/about.md +28 -21
- package/dist/patternfly-docs/quick-starts/examples/basic.md +7 -5
- package/dist/patternfly-docs/quick-starts/examples/help-topics.md +8 -5
- package/dist/patternfly-nested.css +209 -1
- package/dist/quickstarts-base.css +49 -49
- package/dist/quickstarts-full.es.js +2928 -4373
- package/dist/quickstarts-full.es.js.map +1 -1
- package/dist/quickstarts-standalone.css +6 -0
- package/dist/quickstarts-standalone.min.css +2 -2
- package/dist/quickstarts.css +49 -49
- package/dist/quickstarts.min.css +1 -1
- package/package.json +8 -5
- package/src/ConsoleInternal/components/markdown-view.tsx +34 -50
- package/src/ConsoleShared/src/components/markdown-extensions/accordion-extension.tsx +52 -0
- package/src/ConsoleShared/src/components/markdown-extensions/accordion-render-extension.tsx +60 -0
- package/src/ConsoleShared/src/components/markdown-extensions/const.ts +2 -0
- package/src/ConsoleShared/src/components/markdown-extensions/index.ts +2 -0
- package/src/HelpTopicPanelContent.tsx +1 -1
- package/src/QuickStartMarkdownView.tsx +5 -0
- package/src/QuickStartPanelContent.tsx +11 -2
- package/src/controller/QuickStartTaskHeader.tsx +12 -1
- package/src/declaration.d.ts +1 -0
|
@@ -60,6 +60,7 @@ const QuickStartPanelContent: React.FC<QuickStartPanelContentProps> = ({
|
|
|
60
60
|
QuickStartContext,
|
|
61
61
|
);
|
|
62
62
|
const [contentRef, setContentRef] = React.useState<HTMLDivElement>();
|
|
63
|
+
const [displayName, setDisplayName] = React.useState<string>('');
|
|
63
64
|
const shadows = useScrollShadows(contentRef);
|
|
64
65
|
const quickStart = quickStarts.find((qs) => qs.metadata.name === activeQuickStartID);
|
|
65
66
|
const taskNumber = activeQuickStartState?.taskNumber;
|
|
@@ -96,6 +97,14 @@ const QuickStartPanelContent: React.FC<QuickStartPanelContentProps> = ({
|
|
|
96
97
|
}
|
|
97
98
|
}, [quickStart]);
|
|
98
99
|
|
|
100
|
+
React.useEffect(() => {
|
|
101
|
+
async function getDisplayName() {
|
|
102
|
+
const convertedMdDisplayName = await markdownConvert(quickStart?.spec.displayName);
|
|
103
|
+
setDisplayName(removeParagraphWrap(convertedMdDisplayName));
|
|
104
|
+
}
|
|
105
|
+
getDisplayName();
|
|
106
|
+
}, [quickStart]);
|
|
107
|
+
|
|
99
108
|
const content = quickStart ? (
|
|
100
109
|
<DrawerPanelContent
|
|
101
110
|
isResizable={isResizable}
|
|
@@ -109,14 +118,14 @@ const QuickStartPanelContent: React.FC<QuickStartPanelContentProps> = ({
|
|
|
109
118
|
<DrawerHead>
|
|
110
119
|
<div className="pfext-quick-start-panel-content__title" tabIndex={-1} ref={titleRef}>
|
|
111
120
|
<Title
|
|
112
|
-
headingLevel="
|
|
121
|
+
headingLevel="h2"
|
|
113
122
|
size="xl"
|
|
114
123
|
className="pfext-quick-start-panel-content__name"
|
|
115
124
|
style={{ marginRight: 'var(--pf-global--spacer--md)' }}
|
|
116
125
|
>
|
|
117
126
|
<span
|
|
118
127
|
dangerouslySetInnerHTML={{
|
|
119
|
-
__html:
|
|
128
|
+
__html: displayName,
|
|
120
129
|
}}
|
|
121
130
|
/>{' '}
|
|
122
131
|
<small className="pfext-quick-start-panel-content__duration">
|
|
@@ -64,12 +64,23 @@ const QuickStartTaskHeader: React.FC<QuickStartTaskHeaderProps> = ({
|
|
|
64
64
|
children,
|
|
65
65
|
}) => {
|
|
66
66
|
const titleRef = React.useRef(null);
|
|
67
|
+
const [parsedTitle, setParsedTitle] = React.useState<string>('');
|
|
68
|
+
|
|
67
69
|
React.useEffect(() => {
|
|
68
70
|
if (isActiveTask) {
|
|
69
71
|
// Focus the WizardNavItem button element that contains the title
|
|
70
72
|
titleRef.current.parentNode.focus();
|
|
71
73
|
}
|
|
72
74
|
}, [isActiveTask]);
|
|
75
|
+
|
|
76
|
+
React.useEffect(() => {
|
|
77
|
+
async function getParsedTitle() {
|
|
78
|
+
const convertedMdTitle = await markdownConvert(title);
|
|
79
|
+
setParsedTitle(removeParagraphWrap(convertedMdTitle));
|
|
80
|
+
}
|
|
81
|
+
getParsedTitle();
|
|
82
|
+
}, [title]);
|
|
83
|
+
|
|
73
84
|
const classNames = css('pfext-quick-start-task-header__title', {
|
|
74
85
|
'pfext-quick-start-task-header__title-success': taskStatus === QuickStartTaskStatus.SUCCESS,
|
|
75
86
|
'pfext-quick-start-task-header__title-failed':
|
|
@@ -92,7 +103,7 @@ const QuickStartTaskHeader: React.FC<QuickStartTaskHeaderProps> = ({
|
|
|
92
103
|
<div className="pfext-quick-start-task-header" ref={titleRef}>
|
|
93
104
|
<TaskIcon taskIndex={taskIndex} taskStatus={taskStatus} />
|
|
94
105
|
<Title headingLevel="h3" size={size} className={classNames}>
|
|
95
|
-
<span dangerouslySetInnerHTML={{ __html:
|
|
106
|
+
<span dangerouslySetInnerHTML={{ __html: parsedTitle }} />
|
|
96
107
|
{isActiveTask && subtitle && (
|
|
97
108
|
<span
|
|
98
109
|
className="pfext-quick-start-task-header__subtitle"
|
package/src/declaration.d.ts
CHANGED