All Downloads are FREE. Search and download functionalities are using the official Maven repository.

package.docs.utilities.Text.examples.Text.md Maven / Gradle / Ivy

The newest version!
---
id: Text
section: utility-classes
---## Examples

### Font family

```html
Text
Heading
Monospace
``` ### Font size ```html
Extra small text
Small text
Medium text
Large text
Extra large text
2xl text
3xl text
4xl text
``` ### Font weight ```html
Normal
Bold
``` ### Standard text colors ```html
Regular text color
Brand font color
Placeholder text color
Required text color
Subtle text color
``` ### Inverse colors These colors are best used with the ["inverse" background colors](/utility-classes/background-color#inverse-background-colors). ```html
Inverse text color
``` ### Link colors ```html ``` ### Status and state text colors ```html
Success status text color
Warning status text color
Danger status text color
Info status text color
Custom status text color
``` ### Disabled text colors ```html
Disabled text color
Disabled text color on disabled background
``` ### Icon colors ```html

``` ### Controlling text ```html

Breakword

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus pretium est a porttitor vehicula. Quisque vel commodo urna. Morbi mattis rutrum ante, id vehicula ex accumsan ut.


No Wrap

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus pretium est a porttitor vehicula.


Wrap

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus pretium est a porttitor vehicula. Quisque vel commodo urna. Morbi mattis rutrum ante, id vehicula ex accumsan ut.


Truncate

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus pretium est a porttitor vehicula. Quisque vel commodo urna. Morbi mattis rutrum ante, id vehicula ex accumsan ut.

``` ## Documentation ### Overview These text utilities can be used to modify text within the PatternFly framework. In most cases, using the components with available modifiers should be sufficient to implement most designs, and should be preferred over customizations using these utilities. Care should be taken especially when applying text colors, as this can have a negative effect on the readability and accessibility of text. Refer to the information on [contrast ratios](/guidelines/colors/#contrast-ratios) for more information. [Breakpoint](/developer-resources/global-css-variables#breakpoint-variables-and-class-suffixes) is optional. Breakpoints: base (no breakpoint value), `-on-sm`, `-on-md`, `-on-lg`, and `-on-xl`. **Example .pf-v6-u-font-size-xl-on-lg** ### Usage | Class | Applied to | Outcome | | - | - | - | | `.pf-v6-u-font-size-{xs, sm, md, lg, xl, 2xl, 3xl, 4xl}{-on-[breakpoint]}`| `*` | Sets font-size to xs, sm, md, lg, xl, 2xl, 3xl, or 4xl | | `.pf-v6-u-font-family-{text, heading, monospace}` | `*` | Sets font-family to text, heading, or monospace | | `.pf-v6-u-font-weight-{normal, bold}{-on-[breakpoint]}` | `*` | Sets font-weight to light, normal, or bold | | `.pf-v6-u-text-color-{regular, brand, placeholder, requried, subtle}{-on-[breakpoint]}` | `*` | Sets font-color | | `.pf-v6-u-text-color-link{-on-[breakpoint]}` | `*` | Sets font-color to link color | | `.pf-v6-u-text-color-link-hover{-on-[breakpoint]}` | `*` | Sets font-color to hover link color | | `.pf-v6-u-text-color-link-visited{-on-[breakpoint]}` | `*` | Sets font-color to visited link color | | `.pf-v6-u-text-color-status-{success, warning, danger, info, custom}{-on-[breakpoint]}` | `*` | Sets font-color to status color | | `.pf-v6-u-text-color-disabled{-on-[breakpoint]}` | `*` | Sets font-color to disabled text color | | `.pf-v6-u-text-color-on-disabled{-on-[breakpoint]}` | `*` | Sets font-color to text color on disabled background | | `.pf-v6-u-icon-color-{regular, brand, placeholder, requried, subtle}{-on-[breakpoint]}` | `*` | Sets font-color for icons | | `.pf-v6-u-icon-color-status-{success, warning, danger, info, custom}{-on-[breakpoint]}` | `*` | Sets font-color to icon status color | | `.pf-v6-u-text-break-word{-on-[breakpoint]}` | `*` | Sets word-break to break-word | | `.pf-v6-u-text-nowrap{-on-[breakpoint]}` | `*` | Sets white-space to nowrap | | `.pf-v6-u-text-wrap{-on-[breakpoint]}` | `*` | Sets white-space to normal | | `.pf-v6-u-text-truncate` | `*` | Truncates text field |




© 2015 - 2025 Weber Informatics LLC | Privacy Policy