Skip to content

Commit 52b336a

Browse files
anujsinglaanujsi
andauthored
docs: fix align component page header and css (#2471)
* docs: fix align component page header and css * docs: fix align component page header and css * docs: fix align component page header and css * docs: fix align component page header and css * docs: fix align component page header and css * docs: fix align component page header and css --------- Co-authored-by: Anuj Singla <[email protected]>
1 parent 1e21424 commit 52b336a

File tree

31 files changed

+60
-38
lines changed

31 files changed

+60
-38
lines changed

docs/components/components.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717

1818
<header class="band">
1919
<h1>{{element.title}}</h1>
20+
21+
{{ element.description | safe}}
22+
2023
</header>
2124

2225
{% renderFile element.docsTemplatePath, element %}

docs/main.css

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,7 @@ strong {
7878
}
7979

8080
header.band {
81-
background-color:
82-
var(
83-
--pf-c-page__main-section--BackgroundColor,
84-
var(
85-
--pf-c-page__main-section--m-light-100--BackgroundColor,
86-
var(--pf-global--BackgroundColor--150, #fafafa)));
81+
background-color: var(--pf-global--BackgroundColor--100, #fff);
8782
padding: var(--pf-global--spacer--md, 1rem) var(--pf-global--spacer--md, 1rem);
8883
box-shadow: var(--pf-c-page--section--m-sticky-top--BoxShadow, var(--pf-global--BoxShadow--sm-bottom, 0 0.125rem 0.25rem -0.0625rem rgba(3, 3, 3, 0.16)));
8984
}
@@ -278,11 +273,33 @@ header.band h1 {
278273
margin-top: 0;
279274
}
280275

276+
.example-preview {
277+
padding: var(--pf-global--spacer--md, 1rem);
278+
background-color: var(--pf-global--BackgroundColor--100, #fff);
279+
border-bottom: var(--pf-global--BorderWidth--sm, 1px) solid var(--pf-global--BorderColor--300, #f0f0f0);
280+
transition: width .2s ease-in-out;
281+
}
282+
283+
section.api.band.api-properties dl {
284+
padding: var(--pf-global--spacer--md, 1rem);
285+
background-color: var(--pf-global--BackgroundColor--100, #fff);
286+
}
287+
288+
section.api.band.api-properties table {
289+
background-color: var(--pf-global--BackgroundColor--100, #fff);
290+
}
291+
281292
main.basic,
282293
main.blog {
283294
margin-top: 6.5rem;
284295
margin-bottom: 3.75rem;
285296
flex-grow: 1;
297+
background-color:
298+
var(
299+
--pf-c-page__main-section--BackgroundColor,
300+
var(
301+
--pf-c-page__main-section--m-light-100--BackgroundColor,
302+
var(--pf-global--BackgroundColor--150, #fafafa)));
286303
}
287304

288305
#home-title img {
@@ -673,7 +690,6 @@ th, td {
673690
}
674691

675692
code:not([class*="language-"]) {
676-
background-color: rgba(27,31,35,.05);
677693
padding: .2em .4em;
678694
border-radius: 6px;
679695
font-family: "Overpass Mono", monospace;

elements/pf-accordion/docs/pf-accordion.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,4 +84,4 @@
8484

8585
{% renderCssCustomProperties %}{% endrenderCssCustomProperties %}
8686

87-
{% renderCssParts %}{% endrenderCssParts %}
87+
{% renderCssParts %}{% endrenderCssParts %}

elements/pf-accordion/pf-accordion.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export * from './pf-accordion-panel.js';
1111
import style from './pf-accordion.css';
1212

1313
/**
14-
* An accordion is an interactive container that expands and collapses to hide or reveal nested content. It takes advantage of progressive disclosure to help reduce page scrolling, by allowing users to choose whether they want to show or hide more detailed information as needed.
14+
* An **accordion** is an interactive container that expands and collapses to hide or reveal nested content. It takes advantage of progressive disclosure to help reduce page scrolling, by allowing users to choose whether they want to show or hide more detailed information as needed.
1515
*
1616
* @summary Toggle the visibility of sections of content
1717
*

elements/pf-avatar/pf-avatar.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { BaseAvatar } from './BaseAvatar.js';
66
import style from './pf-avatar.css';
77

88
/**
9-
* An avatar is a visual used to represent a user. It may contain an image or a placeholder graphic.
9+
* An **avatar** is a visual used to represent a user. It may contain an image or a placeholder graphic.
1010
*
1111
* @summary For displaying a user's avatar image
1212
*/

elements/pf-badge/pf-badge.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { BaseBadge } from './BaseBadge.js';
66
import styles from './pf-badge.css';
77

88
/**
9-
* A badge is used to annotate other information like a label or an object name.
9+
* A **badge** is used to annotate other information like a label or an object name.
1010
*
1111
* @cssprop {<length>} --pf-c-badge--BorderRadius {@default `180em`}
1212
*

elements/pf-button/pf-button.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export type ButtonVariant = (
1919
);
2020

2121
/**
22-
* A button is a box area or text that communicates and triggers user actions when
22+
* A **button** is a box area or text that communicates and triggers user actions when
2323
* clicked or selected. Buttons can be used to communicate and immediately trigger
2424
* actions a user can take in an application, like submitting a form, canceling a
2525
* process, or creating a new object. Buttons can also be used to take a user to a

elements/pf-card/pf-card.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import style from './pf-card.css';
55
import { BaseCard } from './BaseCard.js';
66

77
/**
8-
* A card is a square or rectangular container that can contain any kind of content.
8+
* A **card** is a square or rectangular container that can contain any kind of content.
99
* Cards symbolize units of information, and each one acts as an entry point for
1010
* users to access more details. For example, in dashboards and catalog views, cards
1111
* function as a preview of a detailed page. Cards may also be used in data displays

elements/pf-clipboard-copy/pf-clipboard-copy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import '@patternfly/elements/pf-tooltip/pf-tooltip.js';
1515
const sleep = (ms?: number) => new Promise(r => setTimeout(r, ms));
1616

1717
/**
18-
* The clipboard copy component allows users to quickly and easily copy content to their clipboard.
18+
* The **clipboard copy** component allows users to quickly and easily copy content to their clipboard.
1919
*
2020
* @slot - Place content to copy here, or use the `value` attribute
2121
* @slot actions - Place additional action buttons here

elements/pf-code-block/pf-code-block.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { BaseCodeBlock } from './BaseCodeBlock.js';
66
import styles from './pf-code-block.css';
77

88
/**
9-
* A code block is a component that contains 2 or more lines of read-only code. The code in a code block can be copied to the clipboard.
9+
* A **code block** is a component that contains 2 or more lines of read-only code. The code in a code block can be copied to the clipboard.
1010
*
1111
* @slot code
1212
* The slot to put the code in

0 commit comments

Comments
 (0)