Styling: Text
Oracle® JavaScript Extension Toolkit (JET)
16.0.0
F83701-01
Description
Style classes handling the Text display
-
.oj-text-disabled-color
-
Class to show disabled text.
Deprecated:
Since Description 9.0.0Use oj-text-color-disabled instead -
.oj-text-primary-color
-
Class to show primary text. In some themes this class may have no effect.
Deprecated:
Since Description 9.0.0Use oj-text-color-primary instead -
.oj-text-secondary-color
-
Class to show secondary text. In some themes this class may have no effect.
Deprecated:
Since Description 9.0.0Use oj-text-color-secondary instead -
.oj-text-tertiary-color
-
Class to show tertiary text. In some themes this class may have no effect.
Deprecated:
Since Description 9.0.0Use oj-text-color-secondary instead -
Category: Line Clamp
-
Line clamp utility classes can be used to truncate text with an ellipsis after a certain number of lines. These classes rely on the -webkit-line-clamp property (see caniuse.com for browser support) and in addition set overflow to hidden.
Class template:
-
.oj-line-clamp-
[line-clamp-level]Note: Square brackets signify required token substitutions whereas parentheses signify optional token substitutions.
-
Values for
[line-clamp-level]Value (required) Name Description 11 line Line Clamp at 1 line 22 lines Line Clamp at 2 lines 33 lines Line Clamp at 3 lines 44 lines Line Clamp at 4 lines
Example
<div class="oj-line-clamp-2">This could be some very long text that requires line clamping</div> -
-
Category: Text Colors
-
Sets the text color. In Redwood these classes use the !important rule.
Class template:
-
.oj-text-color-
[text-color]Note: Square brackets signify required token substitutions whereas parentheses signify optional token substitutions.
-
Values for
[text-color]Value (required) Name Description primaryPrimary text color Primary text color secondarySecondary text color Secondary text color disabledDisabled text color Disabled text color dangerDanger text color Danger text color warningWarning text color Warning text color successSuccess text color Success text color
Example
<div class="oj-text-color-secondary">Secondary text</div> -
-
Category: Typography
-
Sets the font weight, font size, and line height. In Redwood these classes use the !important rule.
In Redwood headers and subheaders are smaller when the screen size is in the small range, see the ResponsivePrefixes doc for more information about screen ranges.
NOTE: oj-typography classes set line-height which doesn't work reliably on inline elements, therefore these classes should be set on block (e.g. div) or inline block elements.
Class template:
-
.oj-typography-
[typography-level]Note: Square brackets signify required token substitutions whereas parentheses signify optional token substitutions.
-
Values for
[typography-level]Value (required) Name Description heading-2xlHeading 2xl Extra Extra Large Heading heading-xlHeading xl Extra Large Heading heading-lgHeading lg Large Heading heading-mdHeading md Medium Heading heading-smHeading sm Smaller Heading heading-xsHeading xs Extra Small Heading subheading-2xlSubheading 2xl Extra Extra Large Subheading subheading-xlSubheading xl Extra Large subheading subheading-lgSubheading lg Large subheading subheading-mdSubheading md Medium subheading subheading-smSubheading sm Smaller subheading subheading-xsSubheading xs Extra Small subheading body-xlBody xl Extra Large Body body-lgBody lg Large Body body-mdBody md Medium Body body-smBody sm Small Body body-xsBody xs Extra Small Body body-2xsBody 2xs Extra Extra Small Body
Example
<div class="oj-typography-body-xs">body text</div> -
-
Category: Typography Weight
-
Sets the font weight to semi bold or bold, meant to be used in conjunction with oj-typography-body-*. In Redwood these classes use the !important rule.
Class template:
-
.oj-typography-
[typography-weight]Note: Square brackets signify required token substitutions whereas parentheses signify optional token substitutions.
-
Values for
[typography-weight]Value (required) Name Description semi-boldSemi Bold Set the font weight to semi bold boldBold Set the font weight to bold
Example
<div class="oj-typography-body-xs oj-typography-semi-bold">Caption text</div> -
-
Category: Text Size
-
Classes for small or xs text.
Classes:
-
.oj-text-sm
-
Deprecated:
Since Description 9.0.0Use oj-typography-body-sm instead -
.oj-text-xs
-
Deprecated:
Since Description 9.0.0Use oj-typography-body-xs instead
Deprecated:
Since Description 9.0.0Replace oj-text-sm with oj-typography-body-sm. Replace oj-text-xs with oj-typography-body-xs -