@zinejs/core 0.7.3 → 0.7.4
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/dist/engine/emitter.d.ts +4 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +200 -157
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +58 -4
- package/dist/index.umd.js.map +1 -1
- package/dist/loading/loading.d.ts +18 -0
- package/dist/loading-C0qbANt2.js +45 -0
- package/dist/loading-C0qbANt2.js.map +1 -0
- package/dist/source/types.d.ts +13 -0
- package/dist/{webglRenderer-D_XGumQT.js → webglRenderer-nGRruZk2.js} +5 -4
- package/dist/webglRenderer-nGRruZk2.js.map +1 -0
- package/dist/zine.d.ts +8 -0
- package/package.json +7 -1
- package/dist/webglRenderer-D_XGumQT.js.map +0 -1
package/dist/engine/emitter.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { SpreadMode } from './spread.js';
|
|
2
|
+
import type { LoadProgress } from '../source/types.js';
|
|
2
3
|
export type Listener<T> = (payload: T) => void;
|
|
3
4
|
/** Events typed as `void` are emitted with no payload argument. */
|
|
4
5
|
type PayloadArgs<T> = [T] extends [void] ? [] : [payload: T];
|
|
@@ -35,6 +36,9 @@ export interface ZineEventMap {
|
|
|
35
36
|
zoomChanged: {
|
|
36
37
|
scale: number;
|
|
37
38
|
};
|
|
39
|
+
/** The document is downloading. Fires only for sources that report byte progress (a PDF from a
|
|
40
|
+
* URL); use it to drive a custom loading indicator, and hide it on `ready`. */
|
|
41
|
+
progress: LoadProgress;
|
|
38
42
|
sourceError: {
|
|
39
43
|
index: number;
|
|
40
44
|
error: unknown;
|
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ export { defineControl, getControl, DEFAULT_ITEMS } from './controls/registry';
|
|
|
4
4
|
export type { ControlContext, ControlDef, ControlItem, ControlsOptions, ControlsPosition, } from './controls/types';
|
|
5
5
|
export { ImageSource } from './source/imageSource';
|
|
6
6
|
export type { ImageSourceOptions, ImageFit } from './source/imageSource';
|
|
7
|
-
export type { Source, DownloadInfo, OutlineItem, PageRequest } from './source/types';
|
|
7
|
+
export type { Source, DownloadInfo, LoadProgress, OutlineItem, PageRequest } from './source/types';
|
|
8
8
|
export type { RendererOption, RendererKind } from './renderer/select';
|
|
9
9
|
export type { Renderer, SpreadContent, PageContent, FlipDirection, LayoutMetrics, RenderOptions } from './renderer/types';
|
|
10
10
|
export type { ZineEventMap } from './engine/emitter';
|