Skip to main content
Foundation mark for applying multiple text formatting attributes. Enables combining font, color, and other text properties while maintaining Word compatibility.

OOXML Structure

Use case

  • Style Foundation - Base layer for combining multiple text properties
  • Clean Markup - Prevents empty span elements in your HTML
  • Style References - Apply predefined Word styles via styleId
  • Extension Bridge - Enables font, color, and size extensions to work together
  • Word Compatibility - Maps directly to Word’s character styles

Options

Configure the extension behavior:
Object
default:"{}"
Custom HTML attributes to apply to text style spans

Attributes

Mark attributes that can be set and retrieved:
string
Vertical alignment for superscript and subscript. Values: 'superscript', 'subscript', 'baseline'
string
Custom vertical position offset in points (e.g., '2pt', '-1.5pt'). Takes precedence over vertAlign when both are present.

Commands

removeEmptyTextStyle

Remove empty text style marks
Automatically checks if any style attributes exist before removal
Example:

Source code