@vivliostyle/core 2.15.8 → 2.17.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/vivliostyle/assets.d.ts +1 -1
- package/lib/vivliostyle/base.d.ts +5 -14
- package/lib/vivliostyle/break-position.d.ts +1 -10
- package/lib/vivliostyle/cfi.d.ts +4 -12
- package/lib/vivliostyle/columns.d.ts +0 -21
- package/lib/vivliostyle/css-cascade.d.ts +74 -372
- package/lib/vivliostyle/css-page.d.ts +3 -141
- package/lib/vivliostyle/css-parser.d.ts +0 -173
- package/lib/vivliostyle/css-prop.d.ts +0 -25
- package/lib/vivliostyle/css-styler.d.ts +4 -11
- package/lib/vivliostyle/css-tokenizer.d.ts +9 -3
- package/lib/vivliostyle/css-validator.d.ts +11 -184
- package/lib/vivliostyle/css.d.ts +34 -183
- package/lib/vivliostyle/diff.d.ts +2 -8
- package/lib/vivliostyle/epub.d.ts +1 -6
- package/lib/vivliostyle/exprs.d.ts +1 -225
- package/lib/vivliostyle/footnotes.d.ts +7 -30
- package/lib/vivliostyle/layout-processor.d.ts +8 -24
- package/lib/vivliostyle/layout-util.d.ts +0 -9
- package/lib/vivliostyle/layout.d.ts +4 -37
- package/lib/vivliostyle/net.d.ts +2 -8
- package/lib/vivliostyle/ops.d.ts +5 -52
- package/lib/vivliostyle/page-floats.d.ts +7 -21
- package/lib/vivliostyle/page-master.d.ts +3 -54
- package/lib/vivliostyle/pseudo-element.d.ts +3 -7
- package/lib/vivliostyle/repetitive-element.d.ts +9 -54
- package/lib/vivliostyle/table.d.ts +11 -92
- package/lib/vivliostyle/task.d.ts +16 -49
- package/lib/vivliostyle/toc.d.ts +1 -3
- package/lib/vivliostyle/types.d.ts +5 -4
- package/lib/vivliostyle/vgen.d.ts +14 -43
- package/lib/vivliostyle/vtree.d.ts +0 -4
- package/lib/vivliostyle.js +1 -1
- package/lib/vivliostyle.js.map +1 -1
- package/package.json +2 -2
|
@@ -38,7 +38,6 @@ export interface Timer {
|
|
|
38
38
|
/**
|
|
39
39
|
* Calls function after a given timeout.
|
|
40
40
|
* @param token timeout token.
|
|
41
|
-
* @return.
|
|
42
41
|
*/
|
|
43
42
|
clearTimeout(token: number): void;
|
|
44
43
|
}
|
|
@@ -113,17 +112,11 @@ export declare enum FrameState {
|
|
|
113
112
|
DEAD = 3
|
|
114
113
|
}
|
|
115
114
|
export declare class TimerImpl implements Timer {
|
|
116
|
-
/**
|
|
117
|
-
* @override
|
|
118
|
-
*/
|
|
115
|
+
/** @override */
|
|
119
116
|
currentTime(): number;
|
|
120
|
-
/**
|
|
121
|
-
* @override
|
|
122
|
-
*/
|
|
117
|
+
/** @override */
|
|
123
118
|
setTimeout(fn: () => void, delay: number): number;
|
|
124
|
-
/**
|
|
125
|
-
* @override
|
|
126
|
-
*/
|
|
119
|
+
/** @override */
|
|
127
120
|
clearTimeout(token: number): void;
|
|
128
121
|
}
|
|
129
122
|
/**
|
|
@@ -170,9 +163,7 @@ export declare class Continuation<T> implements Base.Comparable {
|
|
|
170
163
|
result: T;
|
|
171
164
|
canceled: boolean;
|
|
172
165
|
constructor(task: Task);
|
|
173
|
-
/**
|
|
174
|
-
* @override
|
|
175
|
-
*/
|
|
166
|
+
/** @override */
|
|
176
167
|
compare(otherComp: Base.Comparable): number;
|
|
177
168
|
/**
|
|
178
169
|
* Continuation's task
|
|
@@ -247,29 +238,17 @@ export declare class Task {
|
|
|
247
238
|
export declare class SyncResultImpl<T> implements Result<T> {
|
|
248
239
|
value: T;
|
|
249
240
|
constructor(value: T);
|
|
250
|
-
/**
|
|
251
|
-
* @override
|
|
252
|
-
*/
|
|
241
|
+
/** @override */
|
|
253
242
|
then(callback: (T: any) => void): void;
|
|
254
|
-
/**
|
|
255
|
-
* @override
|
|
256
|
-
*/
|
|
243
|
+
/** @override */
|
|
257
244
|
thenAsync<T1>(callback: (p1: T) => Result<T1>): Result<T1>;
|
|
258
|
-
/**
|
|
259
|
-
* @override
|
|
260
|
-
*/
|
|
245
|
+
/** @override */
|
|
261
246
|
thenReturn<T1>(result: T1): SyncResultImpl<T1>;
|
|
262
|
-
/**
|
|
263
|
-
* @override
|
|
264
|
-
*/
|
|
247
|
+
/** @override */
|
|
265
248
|
thenFinish(frame: Frame<T>): void;
|
|
266
|
-
/**
|
|
267
|
-
* @override
|
|
268
|
-
*/
|
|
249
|
+
/** @override */
|
|
269
250
|
isPending(): boolean;
|
|
270
|
-
/**
|
|
271
|
-
* @override
|
|
272
|
-
*/
|
|
251
|
+
/** @override */
|
|
273
252
|
get(): T | null;
|
|
274
253
|
}
|
|
275
254
|
/**
|
|
@@ -278,29 +257,17 @@ export declare class SyncResultImpl<T> implements Result<T> {
|
|
|
278
257
|
export declare class ResultImpl<T> implements Result<T> {
|
|
279
258
|
readonly frame: Frame<T>;
|
|
280
259
|
constructor(frame: Frame<T>);
|
|
281
|
-
/**
|
|
282
|
-
* @override
|
|
283
|
-
*/
|
|
260
|
+
/** @override */
|
|
284
261
|
then(callback: (p1: T) => void): void;
|
|
285
|
-
/**
|
|
286
|
-
* @override
|
|
287
|
-
*/
|
|
262
|
+
/** @override */
|
|
288
263
|
thenAsync<T1>(callback: (p1: T) => Result<T1>): Result<T1>;
|
|
289
|
-
/**
|
|
290
|
-
* @override
|
|
291
|
-
*/
|
|
264
|
+
/** @override */
|
|
292
265
|
thenReturn<T1>(result: T1): Result<any> | SyncResultImpl<T1>;
|
|
293
|
-
/**
|
|
294
|
-
* @override
|
|
295
|
-
*/
|
|
266
|
+
/** @override */
|
|
296
267
|
thenFinish(frame: Frame<T>): void;
|
|
297
|
-
/**
|
|
298
|
-
* @override
|
|
299
|
-
*/
|
|
268
|
+
/** @override */
|
|
300
269
|
isPending(): boolean;
|
|
301
|
-
/**
|
|
302
|
-
* @override
|
|
303
|
-
*/
|
|
270
|
+
/** @override */
|
|
304
271
|
get(): T | null;
|
|
305
272
|
}
|
|
306
273
|
/**
|
package/lib/vivliostyle/toc.d.ts
CHANGED
|
@@ -54,9 +54,7 @@ export declare class TOCView implements Vgen.CustomRendererFactory {
|
|
|
54
54
|
[key: string]: string;
|
|
55
55
|
}, documentURLTransformer: Base.DocumentURLTransformer, counterStore: Counters.CounterStore);
|
|
56
56
|
setAutoHeight(elem: Element, depth: number): void;
|
|
57
|
-
/**
|
|
58
|
-
* @override
|
|
59
|
-
*/
|
|
57
|
+
/** @override */
|
|
60
58
|
makeCustomRenderer(xmldoc: XmlDoc.XMLDocHolder): Vgen.CustomRenderer;
|
|
61
59
|
showTOC(elem: HTMLElement, viewport: Vgen.Viewport, width: number, height: number, fontSize: number): Task.Result<Vtree.Page>;
|
|
62
60
|
hideTOC(): void;
|
|
@@ -26,15 +26,16 @@ import * as TaskUtil from "./task-util";
|
|
|
26
26
|
export declare type FormattingContextType = "Block" | "RepetitiveElementsOwner" | "Table";
|
|
27
27
|
export declare type FragmentLayoutConstraintType = "AfterIfContinue" | "EntireTable" | "RepetitiveElementsOwner" | "TableRow";
|
|
28
28
|
export declare namespace CssCascade {
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
type ElementStyle = {
|
|
30
|
+
[key: string]: any;
|
|
31
|
+
};
|
|
31
32
|
}
|
|
32
33
|
export declare namespace CssStyler {
|
|
33
34
|
interface AbstractStyler {
|
|
34
35
|
getStyle(element: Element, deep: boolean): CssCascade.ElementStyle;
|
|
35
36
|
processContent(element: Element, styles: {
|
|
36
37
|
[key: string]: Css.Val;
|
|
37
|
-
}): any;
|
|
38
|
+
}, viewNode: Node): any;
|
|
38
39
|
}
|
|
39
40
|
}
|
|
40
41
|
export declare namespace Layout {
|
|
@@ -840,7 +841,7 @@ export declare namespace Vtree {
|
|
|
840
841
|
readonly parentShadow: ShadowContext;
|
|
841
842
|
subShadow: ShadowContext;
|
|
842
843
|
readonly type: Vtree.ShadowType;
|
|
843
|
-
readonly styler:
|
|
844
|
+
readonly styler: CssStyler.AbstractStyler;
|
|
844
845
|
equals(other: ShadowContext): boolean;
|
|
845
846
|
}
|
|
846
847
|
/**
|
|
@@ -62,21 +62,17 @@ export declare class ViewFactory extends Base.SimpleEventTarget implements Vtree
|
|
|
62
62
|
constructor(flowName: string, context: Exprs.Context, viewport: Viewport, styler: CssStyler.Styler, regionIds: string[], xmldoc: XmlDoc.XMLDocHolder, docFaces: Font.DocumentFaces, footnoteStyle: CssCascade.ElementStyle, stylerProducer: StylerProducer, page: Vtree.Page, customRenderer: CustomRenderer, fallbackMap: {
|
|
63
63
|
[key: string]: string;
|
|
64
64
|
}, documentURLTransformer: Base.DocumentURLTransformer);
|
|
65
|
-
/**
|
|
66
|
-
* @override
|
|
67
|
-
*/
|
|
65
|
+
/** @override */
|
|
68
66
|
clone(): Vtree.LayoutContext;
|
|
69
67
|
createPseudoelementShadow(element: Element, isRoot: boolean, cascStyle: CssCascade.ElementStyle, computedStyle: {
|
|
70
68
|
[key: string]: Css.Val;
|
|
71
69
|
}, styler: CssStyler.AbstractStyler, context: Exprs.Context, parentShadow: Vtree.ShadowContext, subShadow: Vtree.ShadowContext): Vtree.ShadowContext;
|
|
72
|
-
getPseudoMap(cascStyle: CssCascade.ElementStyle, regionIds: string[], isFootnote: boolean, nodeContext: Vtree.NodeContext, context: Exprs.Context):
|
|
70
|
+
getPseudoMap(cascStyle: CssCascade.ElementStyle, regionIds: string[], isFootnote: boolean, nodeContext: Vtree.NodeContext, context: Exprs.Context): CssCascade.ElementStyleMap;
|
|
73
71
|
createRefShadow(href: string, type: Vtree.ShadowType, element: Element, parentShadow: Vtree.ShadowContext, subShadow: Vtree.ShadowContext): Task.Result<Vtree.ShadowContext>;
|
|
74
72
|
createShadows(element: Element, isRoot: any, cascStyle: CssCascade.ElementStyle, computedStyle: {
|
|
75
73
|
[key: string]: Css.Val;
|
|
76
74
|
}, styler: CssStyler.AbstractStyler, context: Exprs.Context, shadowContext: Vtree.ShadowContext): Task.Result<Vtree.ShadowContext>;
|
|
77
|
-
/**
|
|
78
|
-
* @override
|
|
79
|
-
*/
|
|
75
|
+
/** @override */
|
|
80
76
|
setViewRoot(viewRoot: Element, isFootnote: boolean): void;
|
|
81
77
|
/**
|
|
82
78
|
* @return vertical
|
|
@@ -102,9 +98,6 @@ export declare class ViewFactory extends Base.SimpleEventTarget implements Vtree
|
|
|
102
98
|
*/
|
|
103
99
|
private isAtForcedBreak;
|
|
104
100
|
private processAfterIfcontinues;
|
|
105
|
-
/**
|
|
106
|
-
* @return isSVGUrlAttribute
|
|
107
|
-
*/
|
|
108
101
|
isSVGUrlAttribute(attributeName: string): boolean;
|
|
109
102
|
modifyElemDimensionWithImageResolution(images: {
|
|
110
103
|
image: HTMLElement;
|
|
@@ -122,16 +115,12 @@ export declare class ViewFactory extends Base.SimpleEventTarget implements Vtree
|
|
|
122
115
|
* @return holding true if children should be processed
|
|
123
116
|
*/
|
|
124
117
|
createNodeView(firstTime: boolean, atUnforcedBreak: boolean): Task.Result<boolean>;
|
|
125
|
-
/**
|
|
126
|
-
* @override
|
|
127
|
-
*/
|
|
118
|
+
/** @override */
|
|
128
119
|
setCurrent(nodeContext: Vtree.NodeContext, firstTime: boolean, atUnforcedBreak?: boolean): Task.Result<boolean>;
|
|
129
120
|
processShadowContent(pos: Vtree.NodeContext): Vtree.NodeContext;
|
|
130
121
|
private nextPositionInTree;
|
|
131
122
|
isTransclusion(element: Element, elementStyle: CssCascade.ElementStyle, transclusionType: string | null): boolean;
|
|
132
|
-
/**
|
|
133
|
-
* @override
|
|
134
|
-
*/
|
|
123
|
+
/** @override */
|
|
135
124
|
nextInTree(position: Vtree.NodeContext, atUnforcedBreak?: boolean): Task.Result<Vtree.NodeContext>;
|
|
136
125
|
addImageFetchers(bg: Css.Val): void;
|
|
137
126
|
applyComputedStyles(target: Element, computedStyle: {
|
|
@@ -145,34 +134,22 @@ export declare class ViewFactory extends Base.SimpleEventTarget implements Vtree
|
|
|
145
134
|
* @returns true if the font-size fix is done
|
|
146
135
|
*/
|
|
147
136
|
fixRubyTextFontSize(target: Element, value: Css.Val): boolean;
|
|
148
|
-
/**
|
|
149
|
-
* @override
|
|
150
|
-
*/
|
|
137
|
+
/** @override */
|
|
151
138
|
applyPseudoelementStyle(nodeContext: Vtree.NodeContext, pseudoName: string, target: Element): void;
|
|
152
|
-
/**
|
|
153
|
-
* @override
|
|
154
|
-
*/
|
|
139
|
+
/** @override */
|
|
155
140
|
peelOff(nodeContext: Vtree.NodeContext, nodeOffset: number): Task.Result<Vtree.NodeContext>;
|
|
156
141
|
createElement(ns: string, tag: string): Element;
|
|
157
|
-
/**
|
|
158
|
-
* @override
|
|
159
|
-
*/
|
|
142
|
+
/** @override */
|
|
160
143
|
applyFootnoteStyle(vertical: boolean, rtl: boolean, target: Element): boolean;
|
|
161
|
-
/**
|
|
162
|
-
* @override
|
|
163
|
-
*/
|
|
144
|
+
/** @override */
|
|
164
145
|
processFragmentedBlockEdge(nodeContext: Vtree.NodeContext): void;
|
|
165
|
-
/**
|
|
166
|
-
* @override
|
|
167
|
-
*/
|
|
146
|
+
/** @override */
|
|
168
147
|
convertLengthToPx(numeric: Css.Numeric, viewNode: Node, clientLayout: Vtree.ClientLayout): number | Css.Numeric;
|
|
169
148
|
/**
|
|
170
149
|
* Returns if two NodePositionStep are equivalent.
|
|
171
150
|
*/
|
|
172
151
|
isSameNodePositionStep(step1: Vtree.NodePositionStep, step2: Vtree.NodePositionStep): boolean;
|
|
173
|
-
/**
|
|
174
|
-
* @override
|
|
175
|
-
*/
|
|
152
|
+
/** @override */
|
|
176
153
|
isSameNodePosition(nodePosition1: Vtree.NodePosition, nodePosition2: Vtree.NodePosition): boolean;
|
|
177
154
|
isPseudoelement(elem: any): boolean;
|
|
178
155
|
}
|
|
@@ -192,17 +169,11 @@ export declare class DefaultClientLayout implements Vtree.ClientLayout {
|
|
|
192
169
|
window: Window;
|
|
193
170
|
constructor(viewport: Viewport);
|
|
194
171
|
private subtractOffsets;
|
|
195
|
-
/**
|
|
196
|
-
* @override
|
|
197
|
-
*/
|
|
172
|
+
/** @override */
|
|
198
173
|
getRangeClientRects(range: Range): Vtree.ClientRect[];
|
|
199
|
-
/**
|
|
200
|
-
* @override
|
|
201
|
-
*/
|
|
174
|
+
/** @override */
|
|
202
175
|
getElementClientRect(element: Element): Vtree.ClientRect;
|
|
203
|
-
/**
|
|
204
|
-
* @override
|
|
205
|
-
*/
|
|
176
|
+
/** @override */
|
|
206
177
|
getElementComputedStyle(element: Element): CSSStyleDeclaration;
|
|
207
178
|
}
|
|
208
179
|
export declare class Viewport {
|
|
@@ -396,13 +396,9 @@ export declare class ContentPropertyHandler extends Css.Visitor {
|
|
|
396
396
|
readonly exprContentListener: ExprContentListener;
|
|
397
397
|
constructor(elem: Element, context: Exprs.Context, rootContentValue: Css.Val, exprContentListener: ExprContentListener);
|
|
398
398
|
private visitStrInner;
|
|
399
|
-
/** @override */
|
|
400
399
|
visitStr(str: Css.Str): Css.Val;
|
|
401
|
-
/** @override */
|
|
402
400
|
visitURL(url: Css.URL): Css.Val;
|
|
403
|
-
/** @override */
|
|
404
401
|
visitSpaceList(list: Css.SpaceList): Css.Val;
|
|
405
|
-
/** @override */
|
|
406
402
|
visitExpr(expr: Css.Expr): Css.Val;
|
|
407
403
|
}
|
|
408
404
|
export declare function nonTrivialContent(val: Css.Val): boolean;
|