diff --git a/CHANGELOG.md b/CHANGELOG.md index b725c50..5cf9b47 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## [Unreleased] +### Fixed + +- Update type definition to add `cssNesting` constructor option ([#401](https://github.com/marp-team/marpit/pull/401)) + ## v3.1.0 - 2024-08-30 ### Added diff --git a/index.d.ts b/index.d.ts index f5898db..03bc242 100644 --- a/index.d.ts +++ b/index.d.ts @@ -10,6 +10,7 @@ declare namespace Marpit { anchor?: boolean | AnchorCallback container?: false | Element | Element[] cssContainerQuery?: boolean | string | string[] + cssNesting?: boolean headingDivider?: false | HeadingDivider | HeadingDivider[] lang?: string looseYAML?: boolean @@ -47,15 +48,20 @@ declare namespace Marpit { ...params: P ) => void + type ThemeMetaType = { + [key: string]: StringConstructor | ArrayConstructor + } + type ThemeReservedMeta = { theme: string } - type ThemeMetaType = { - [key: string]: StringConstructor | ArrayConstructor + interface ThemeSetOptions { + cssNesting?: boolean } type ThemeOptions = { + cssNesting?: boolean metaType?: ThemeMetaType } @@ -126,8 +132,9 @@ declare namespace Marpit { } export class ThemeSet { - constructor() + constructor(opts?: ThemeSetOptions) + cssNesting: boolean default: Theme | undefined metaType: ThemeMetaType