diff --git a/packages/documentation-framework/components/example/example.css b/packages/documentation-framework/components/example/example.css
index a9750d46c4..6af274e328 100644
--- a/packages/documentation-framework/components/example/example.css
+++ b/packages/documentation-framework/components/example/example.css
@@ -2,6 +2,10 @@
--ws-code-editor--tooltip--MaxWidth: 16ch;
}
+.ws-heading.ws-example-heading {
+ margin-block-end: -0.5rem;
+}
+
.ws-code-editor:not(.ws-example-code-expanded) > .pf-v6-c-code-editor__header::before {
--pf-v6-c-code-editor__header--before--BorderBottomWidth: 0;
}
diff --git a/packages/documentation-framework/components/example/example.js b/packages/documentation-framework/components/example/example.js
index 8ee8de60fb..d62748e509 100644
--- a/packages/documentation-framework/components/example/example.js
+++ b/packages/documentation-framework/components/example/example.js
@@ -9,8 +9,7 @@ import {
Label,
Switch,
Tooltip,
- Stack,
- StackItem,
+ Stack
} from '@patternfly/react-core';
import * as reactCoreModule from '@patternfly/react-core';
import * as reactCoreNextModule from '@patternfly/react-core/next';
@@ -117,8 +116,6 @@ export const Example = ({
// absolute url to hosted file
sourceLink = ''
}) => {
-
-
if (isFullscreenPreview) {
isFullscreen = false;
}
@@ -284,7 +281,9 @@ export const Example = ({
className={css('ws-full-page-utils-position-btn', utilsProps.className)}
isClicked={fullPageUtilsPosition === utilsProps.className}
onClick={() => setFullPageUtilsPosition(utilsProps.className)}
- aria-label={`${utilsProps.label}${fullPageUtilsPosition === utilsProps.className ? ', selected' : ''}`}
+ aria-label={`${utilsProps.label}${
+ fullPageUtilsPosition === utilsProps.className ? ', selected' : ''
+ }`}
icon={fullPageUtilsPosition === utilsProps.className ? utilsProps.iconClicked : utilsProps.icon}
/>
@@ -303,7 +302,7 @@ export const Example = ({
const fullscreenLink = (() => {
const cleanPathname = loc.pathname.replace(/\/$/, '');
const sourcePath = `/${source}`;
-
+
// Check if the source is already at the end of the pathname to avoid duplication
// Using endsWith instead of includes to prevent false positives (e.g., /react-console matching /react)
if (cleanPathname.endsWith(sourcePath)) {
@@ -348,19 +347,19 @@ export const Example = ({
const metaText = hasMetaText && tooltips;
const thumbnailDimensions = {
- width: "800",
- height: "450"
- }
+ width: '800',
+ height: '450'
+ };
return (