Skip to content

Rule.io SDK


Rule.io SDK / rcml/src / EmailThemePatch

Interface: EmailThemePatch

Defined in: rcml/src/email/theme-types.ts:205

A partial-theme shape used by two call sites:

  • createEmailTheme — seed values applied on top of the defaults when constructing a fresh theme.
  • applyTheme — a patch written into an existing rcml document; only the buckets present in the patch are touched.

Each bucket uses arrays (not the full EmailTheme map shape) so a caller can write { colors: [{ type: Primary, hex: '#F00' }] } without restating the slot key. fontStyles accepts entry-level partials so { type: H1, color: '#F00' } changes just the colour and keeps the rest of the slot at its default.

Properties

brandStyleId?

optional brandStyleId?: number

Defined in: rcml/src/email/theme-types.ts:207

Numeric brand-style id to set on <rc-brand-style>.


colors?

optional colors?: EmailThemeColor[]

Defined in: rcml/src/email/theme-types.ts:209

Colour entries keyed by slot type; unspecified slots fall back to defaults.


fonts?

optional fonts?: EmailThemeFont[]

Defined in: rcml/src/email/theme-types.ts:215

Ordered fonts list; an empty array clears every font registration.


fontStyles?

optional fontStyles?: Partial<EmailThemeFontStyle>[]

Defined in: rcml/src/email/theme-types.ts:221

Per-slot partial font-style overrides. Missing fields on an override fall back to the slot's default, so { type: H1, color: '#F00' } changes only the colour and keeps size/weight/family at defaults.


images?

optional images?: EmailThemeImage[]

Defined in: rcml/src/email/theme-types.ts:213

Image entries keyed by slot type; an empty array clears all images.


optional links?: EmailThemeSocialLink[]

Defined in: rcml/src/email/theme-types.ts:211

Social-link entries keyed by slot type; unspecified slots fall back to defaults.