diff options
| author | Andrew Dolgov <fox@fakecake.org> | 2026-05-24 20:34:28 +0300 |
|---|---|---|
| committer | Andrew Dolgov <fox@fakecake.org> | 2026-05-24 20:34:28 +0300 |
| commit | ec163996772bb0239ebc1beeffe79deb83a17140 (patch) | |
| tree | e859eafdfb0a19622a2908997df2be42b1bb9813 /lib | |
| parent | a578fa50b2fc2d11ff5a0d45c2cd4d390409739a (diff) | |
| download | the-epube-ec163996772bb0239ebc1beeffe79deb83a17140.tar.gz the-epube-ec163996772bb0239ebc1beeffe79deb83a17140.tar.xz | |
add missing interface for objects returned by find() and fix related problems
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/epub.js/types/section.d.ts | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/epub.js/types/section.d.ts b/lib/epub.js/types/section.d.ts index 075bef5..9678629 100644 --- a/lib/epub.js/types/section.d.ts +++ b/lib/epub.js/types/section.d.ts @@ -24,6 +24,11 @@ export interface SpineItem { prev: () => SpineItem, } +export interface Match { + cfi: string, + excerpt: string +} + export default class Section { constructor(item: SpineItem, hooks: HooksObject); @@ -48,7 +53,7 @@ export default class Section { render(_request?: Function): string; - find(_query: string): Array<Element>; + find(_query: string): Array<Match>; reconcileLayoutSettings(globalLayout: GlobalLayout): LayoutSettings; |
