dotquilt 0.0.0-stage → 0.1.0
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/LICENSE +21 -0
- package/README.md +64 -2
- package/dist/animations.d.ts +105 -0
- package/dist/animations.js +107 -0
- package/dist/catalog-styles.d.ts +4 -0
- package/dist/catalog-styles.js +12 -0
- package/dist/chart-animations.d.ts +36 -0
- package/dist/chart-animations.js +25 -0
- package/dist/chart-styles.d.ts +3 -0
- package/dist/chart-styles.js +23 -0
- package/dist/chart.css +4 -0
- package/dist/chart.d.ts +73 -0
- package/dist/chart.js +80 -0
- package/dist/circle.css +5 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +9 -0
- package/dist/internal/binding.d.ts +13 -0
- package/dist/internal/binding.js +21 -0
- package/dist/internal/capture.d.ts +4 -0
- package/dist/internal/capture.js +13 -0
- package/dist/internal/chart-appearance.d.ts +12 -0
- package/dist/internal/chart-appearance.js +2 -0
- package/dist/internal/chart-definitions.d.ts +19 -0
- package/dist/internal/chart-definitions.js +149 -0
- package/dist/internal/chart-factory.d.ts +12 -0
- package/dist/internal/chart-factory.js +31 -0
- package/dist/internal/chart-field.d.ts +22 -0
- package/dist/internal/chart-field.js +74 -0
- package/dist/internal/chart-idle.d.ts +3 -0
- package/dist/internal/chart-idle.js +96 -0
- package/dist/internal/chart-math.d.ts +8 -0
- package/dist/internal/chart-math.js +19 -0
- package/dist/internal/chart-participant.d.ts +8 -0
- package/dist/internal/chart-participant.js +4 -0
- package/dist/internal/chart-projection.d.ts +11 -0
- package/dist/internal/chart-projection.js +69 -0
- package/dist/internal/content-box.d.ts +11 -0
- package/dist/internal/content-box.js +36 -0
- package/dist/internal/coordinated-handoff.d.ts +4 -0
- package/dist/internal/coordinated-handoff.js +158 -0
- package/dist/internal/count.d.ts +3 -0
- package/dist/internal/count.js +20 -0
- package/dist/internal/defaults.d.ts +11 -0
- package/dist/internal/defaults.js +11 -0
- package/dist/internal/dense/managed-painter.d.ts +4 -0
- package/dist/internal/dense/managed-painter.js +361 -0
- package/dist/internal/dense/runner.d.ts +2 -0
- package/dist/internal/dense/runner.js +5 -0
- package/dist/internal/dense-loader.d.ts +83 -0
- package/dist/internal/dense-loader.js +331 -0
- package/dist/internal/dissolve.d.ts +27 -0
- package/dist/internal/dissolve.js +216 -0
- package/dist/internal/dom.d.ts +23 -0
- package/dist/internal/dom.js +104 -0
- package/dist/internal/effect.d.ts +2 -0
- package/dist/internal/effect.js +17 -0
- package/dist/internal/element.d.ts +89 -0
- package/dist/internal/element.js +384 -0
- package/dist/internal/event-element.d.ts +8 -0
- package/dist/internal/event-element.js +20 -0
- package/dist/internal/frames.d.ts +1 -0
- package/dist/internal/frames.js +51 -0
- package/dist/internal/handoff.d.ts +56 -0
- package/dist/internal/handoff.js +102 -0
- package/dist/internal/ledger.d.ts +13 -0
- package/dist/internal/ledger.js +78 -0
- package/dist/internal/loading-controller.d.ts +62 -0
- package/dist/internal/loading-controller.js +694 -0
- package/dist/internal/marks.d.ts +153 -0
- package/dist/internal/marks.js +227 -0
- package/dist/internal/math.d.ts +2 -0
- package/dist/internal/math.js +2 -0
- package/dist/internal/morph-marks.d.ts +62 -0
- package/dist/internal/morph-marks.js +205 -0
- package/dist/internal/morph.d.ts +35 -0
- package/dist/internal/morph.js +488 -0
- package/dist/internal/paint.d.ts +29 -0
- package/dist/internal/paint.js +1 -0
- package/dist/internal/painter.d.ts +20 -0
- package/dist/internal/painter.js +155 -0
- package/dist/internal/preset-data.d.ts +12 -0
- package/dist/internal/preset-data.js +31 -0
- package/dist/internal/preset.d.ts +22 -0
- package/dist/internal/preset.js +86 -0
- package/dist/internal/pulse.d.ts +7 -0
- package/dist/internal/pulse.js +74 -0
- package/dist/internal/reveal-effect.d.ts +7 -0
- package/dist/internal/reveal-effect.js +24 -0
- package/dist/internal/reveal.d.ts +5 -0
- package/dist/internal/reveal.js +11 -0
- package/dist/internal/runner.d.ts +9 -0
- package/dist/internal/runner.js +70 -0
- package/dist/internal/services.d.ts +12 -0
- package/dist/internal/services.js +159 -0
- package/dist/internal/skeleton-handoff.d.ts +26 -0
- package/dist/internal/skeleton-handoff.js +6 -0
- package/dist/internal/skeleton-source.d.ts +5 -0
- package/dist/internal/skeleton-source.js +106 -0
- package/dist/internal/surface.d.ts +4 -0
- package/dist/internal/surface.js +21 -0
- package/dist/internal/table-definitions.d.ts +27 -0
- package/dist/internal/table-definitions.js +139 -0
- package/dist/internal/table-factory.d.ts +12 -0
- package/dist/internal/table-factory.js +44 -0
- package/dist/internal/table-field.d.ts +12 -0
- package/dist/internal/table-field.js +75 -0
- package/dist/internal/table-model.d.ts +21 -0
- package/dist/internal/table-model.js +117 -0
- package/dist/internal/table-projection.d.ts +7 -0
- package/dist/internal/table-projection.js +110 -0
- package/dist/internal/target-changes.d.ts +3 -0
- package/dist/internal/target-changes.js +2 -0
- package/dist/internal/target-tracker.d.ts +18 -0
- package/dist/internal/target-tracker.js +33 -0
- package/dist/internal/targets.d.ts +3 -0
- package/dist/internal/targets.js +15 -0
- package/dist/internal/text-definitions.d.ts +141 -0
- package/dist/internal/text-definitions.js +228 -0
- package/dist/internal/text-glyphs.d.ts +4 -0
- package/dist/internal/text-glyphs.js +32 -0
- package/dist/internal/text-morph.d.ts +32 -0
- package/dist/internal/text-morph.js +113 -0
- package/dist/internal/text-playback.d.ts +4 -0
- package/dist/internal/text-playback.js +119 -0
- package/dist/internal/text-scramble.d.ts +18 -0
- package/dist/internal/text-scramble.js +47 -0
- package/dist/internal/time.d.ts +9 -0
- package/dist/internal/time.js +13 -0
- package/dist/internal/unstyled.d.ts +8 -0
- package/dist/internal/unstyled.js +8 -0
- package/dist/line.css +5 -0
- package/dist/region-css.d.ts +1 -0
- package/dist/region-css.js +6 -0
- package/dist/region-styles.d.ts +3 -0
- package/dist/region-styles.js +15 -0
- package/dist/region.css +1 -0
- package/dist/region.d.ts +31 -0
- package/dist/region.js +100 -0
- package/dist/register-all.d.ts +2 -0
- package/dist/register-all.js +33 -0
- package/dist/server.d.ts +63 -0
- package/dist/server.js +141 -0
- package/dist/skeleton-animations.d.ts +10 -0
- package/dist/skeleton-animations.js +35 -0
- package/dist/skeleton-block.d.ts +50 -0
- package/dist/skeleton-block.js +260 -0
- package/dist/skeleton-circle.d.ts +5 -0
- package/dist/skeleton-circle.js +11 -0
- package/dist/skeleton-family.css +13 -0
- package/dist/skeleton-line.d.ts +5 -0
- package/dist/skeleton-line.js +11 -0
- package/dist/skeleton-text.css +5 -0
- package/dist/skeleton-text.d.ts +22 -0
- package/dist/skeleton-text.js +115 -0
- package/dist/skeleton.css +4 -0
- package/dist/skeleton.d.ts +5 -0
- package/dist/skeleton.js +4 -0
- package/dist/static-catalog-styles.d.ts +8 -0
- package/dist/static-catalog-styles.js +44 -0
- package/dist/styles.d.ts +4 -0
- package/dist/styles.js +18 -0
- package/dist/table-animations.d.ts +11 -0
- package/dist/table-animations.js +4 -0
- package/dist/table-styles.d.ts +2 -0
- package/dist/table-styles.js +12 -0
- package/dist/table.css +3 -0
- package/dist/table.d.ts +88 -0
- package/dist/table.js +126 -0
- package/dist/text-animations.d.ts +31 -0
- package/dist/text-animations.js +40 -0
- package/dist/text-styles.d.ts +3 -0
- package/dist/text-styles.js +24 -0
- package/dist/text.css +3 -0
- package/dist/text.d.ts +42 -0
- package/dist/text.js +402 -0
- package/dist/types.d.ts +56 -0
- package/dist/types.js +18 -0
- package/dist/typing-styles.d.ts +1 -0
- package/dist/typing-styles.js +7 -0
- package/dist/typing.css +4 -0
- package/dist/typing.d.ts +35 -0
- package/dist/typing.js +164 -0
- package/package.json +100 -4
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type { AnimationBinding, AnimationFamily, RevealFrame, RevealTarget } from '../animations.js';
|
|
2
|
+
import type { TargetTracker } from './target-tracker.js';
|
|
3
|
+
/** Private shared-wrapper output capability; never exposed to authored callbacks. */
|
|
4
|
+
export interface HandoffScope {
|
|
5
|
+
readonly targets: TargetTracker;
|
|
6
|
+
duration(): number;
|
|
7
|
+
reveal(frame: RevealFrame): void;
|
|
8
|
+
target(id: string, frame: RevealFrame): void;
|
|
9
|
+
}
|
|
10
|
+
/** A running handoff, as the loading controller drives it frame by frame. */
|
|
11
|
+
export interface HandoffDriver {
|
|
12
|
+
duration: number;
|
|
13
|
+
restricted?: (() => boolean) | undefined;
|
|
14
|
+
targetsChanged?: ((next: readonly RevealTarget[]) => boolean) | undefined;
|
|
15
|
+
draw?: ((linear: number, eased?: number) => void) | undefined;
|
|
16
|
+
/** Set when the driver paints both layers itself, so the controller only keeps time. */
|
|
17
|
+
readonly paints?: boolean | undefined;
|
|
18
|
+
/** Hands a painting driver the layers' clock animations, to style per frame. */
|
|
19
|
+
attach?: ((outgoing: Animation, incoming: Animation) => void) | undefined;
|
|
20
|
+
activate(callback: () => void): void;
|
|
21
|
+
dispose(): void;
|
|
22
|
+
}
|
|
23
|
+
export type HandoffBinding = AnimationBinding<AnimationFamily, 'handoff'>;
|
|
24
|
+
/** What the loading controller gives a handoff when the region becomes ready. */
|
|
25
|
+
export interface HandoffRequest {
|
|
26
|
+
/** The element whose surface the handoff draws on. */
|
|
27
|
+
readonly host: HTMLElement;
|
|
28
|
+
/** The region's content layer, which the handoff reveals. */
|
|
29
|
+
readonly content: HTMLElement;
|
|
30
|
+
/** The region's placeholder layer, which the handoff hides. */
|
|
31
|
+
readonly placeholder?: HTMLElement | undefined;
|
|
32
|
+
readonly targets: readonly RevealTarget[];
|
|
33
|
+
/** The caller's `timing.duration`; undefined lets the definition decide. */
|
|
34
|
+
readonly duration: number | undefined;
|
|
35
|
+
/** False once this handoff has been superseded or cancelled. */
|
|
36
|
+
readonly current: () => boolean;
|
|
37
|
+
/** Registers a Web Animation so it is cancelled with the handoff. */
|
|
38
|
+
readonly own: (animation: Animation) => void;
|
|
39
|
+
readonly report: (code: string) => void;
|
|
40
|
+
/** Set when a coordinated handoff merges several sources' output. */
|
|
41
|
+
readonly scope?: HandoffScope | undefined;
|
|
42
|
+
}
|
|
43
|
+
export type HandoffFactory = (binding: HandoffBinding, request: HandoffRequest) => HandoffDriver;
|
|
44
|
+
/** Where a region's handoff comes from: a placeholder, or the region itself. */
|
|
45
|
+
export interface HandoffSource {
|
|
46
|
+
/** Used when neither the region nor its preset picks a handoff. */
|
|
47
|
+
readonly binding: HandoffBinding | undefined;
|
|
48
|
+
readonly host: HTMLElement;
|
|
49
|
+
/** Reported in handoff events when no binding is in use. */
|
|
50
|
+
readonly animation: string;
|
|
51
|
+
/** Replaces the binding's own factory (rich, skeleton and coordinated sources). */
|
|
52
|
+
readonly prepare?: (binding: HandoffBinding | undefined, request: HandoffRequest) => HandoffDriver;
|
|
53
|
+
}
|
|
54
|
+
/** Starts a source's handoff; throws when no factory can run it. */
|
|
55
|
+
export declare function runHandoff(prepare: HandoffSource['prepare'], binding: HandoffBinding | undefined, request: HandoffRequest): HandoffDriver;
|
|
56
|
+
export declare const createHandoff: HandoffFactory;
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import { definitionOf } from './binding.js';
|
|
2
|
+
import { frames } from './frames.js';
|
|
3
|
+
import { createPainter } from './painter.js';
|
|
4
|
+
/** Starts a source's handoff; throws when no factory can run it. */
|
|
5
|
+
export function runHandoff(prepare, binding, request) {
|
|
6
|
+
if (prepare)
|
|
7
|
+
return prepare(binding, request);
|
|
8
|
+
const factory = binding && definitionOf(binding).handoff;
|
|
9
|
+
if (!binding || !factory)
|
|
10
|
+
throw new TypeError();
|
|
11
|
+
return factory(binding, request);
|
|
12
|
+
}
|
|
13
|
+
export const createHandoff = (binding, { host, content, targets, duration: requestedDuration, current, own, report, scope, }) => {
|
|
14
|
+
const definition = definitionOf(binding);
|
|
15
|
+
const surface = definition.snapshot(host, binding.family, targets.map((t) => t.id));
|
|
16
|
+
const duration = requestedDuration ?? definition.duration(surface, binding.options);
|
|
17
|
+
const prepared = definition.prepare(surface, binding.options);
|
|
18
|
+
const targetMap = scope?.targets ?? definition.targets(content, targets, own);
|
|
19
|
+
const reveal = scope ?? definition.reveal(content, own, true);
|
|
20
|
+
let painter;
|
|
21
|
+
let release;
|
|
22
|
+
let resize;
|
|
23
|
+
let invalidated = false;
|
|
24
|
+
const dispose = () => {
|
|
25
|
+
release?.();
|
|
26
|
+
release = undefined;
|
|
27
|
+
resize?.disconnect();
|
|
28
|
+
painter?.dispose();
|
|
29
|
+
};
|
|
30
|
+
let lastProgress = 0;
|
|
31
|
+
const draw = (p, eased = p) => {
|
|
32
|
+
if (invalidated || !current())
|
|
33
|
+
throw new TypeError();
|
|
34
|
+
targetMap.check();
|
|
35
|
+
painter ??= (definition.painter ?? createPainter)(host, report, binding.family === 'chart' || binding.family === 'table'
|
|
36
|
+
? 'surface'
|
|
37
|
+
: undefined);
|
|
38
|
+
const total = scope?.duration() ?? duration;
|
|
39
|
+
const deltaMs = (p - lastProgress) * total;
|
|
40
|
+
lastProgress = p;
|
|
41
|
+
painter.draw((dot) => definition.draw({
|
|
42
|
+
surface,
|
|
43
|
+
options: binding.options,
|
|
44
|
+
prepared,
|
|
45
|
+
linear: p,
|
|
46
|
+
progress: eased,
|
|
47
|
+
duration: total,
|
|
48
|
+
deltaMs,
|
|
49
|
+
dot,
|
|
50
|
+
reveal(frame) {
|
|
51
|
+
if (current()) {
|
|
52
|
+
if (scope)
|
|
53
|
+
scope.reveal(frame);
|
|
54
|
+
else
|
|
55
|
+
reveal.draw(frame);
|
|
56
|
+
}
|
|
57
|
+
},
|
|
58
|
+
revealTarget(id, frame) {
|
|
59
|
+
if (current()) {
|
|
60
|
+
if (scope)
|
|
61
|
+
return scope.target(id, frame);
|
|
62
|
+
if (!targetMap.draw)
|
|
63
|
+
throw new TypeError();
|
|
64
|
+
targetMap.draw(id, frame);
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
}));
|
|
68
|
+
};
|
|
69
|
+
return {
|
|
70
|
+
duration,
|
|
71
|
+
targetsChanged: targetMap.changed,
|
|
72
|
+
draw,
|
|
73
|
+
dispose,
|
|
74
|
+
activate(callback) {
|
|
75
|
+
if (scope)
|
|
76
|
+
return;
|
|
77
|
+
release ??= frames(host, callback);
|
|
78
|
+
const bounds = new Map();
|
|
79
|
+
for (const element of [host, content, ...targets.map((t) => t.element)])
|
|
80
|
+
bounds.set(element, element.getBoundingClientRect());
|
|
81
|
+
resize = new ResizeObserver((entries) => {
|
|
82
|
+
if (!current())
|
|
83
|
+
return;
|
|
84
|
+
for (const { target } of entries) {
|
|
85
|
+
const before = bounds.get(target);
|
|
86
|
+
const after = target.getBoundingClientRect();
|
|
87
|
+
// Translation can perturb floating-point rect subtraction in WebKit.
|
|
88
|
+
// A layout unit still invalidates; numerical noise does not.
|
|
89
|
+
if (before &&
|
|
90
|
+
(Math.abs(before.width - after.width) >= 1 / 64 ||
|
|
91
|
+
Math.abs(before.height - after.height) >= 1 / 64)) {
|
|
92
|
+
invalidated = true;
|
|
93
|
+
callback();
|
|
94
|
+
return;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
});
|
|
98
|
+
for (const element of bounds.keys())
|
|
99
|
+
resize.observe(element);
|
|
100
|
+
},
|
|
101
|
+
};
|
|
102
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
type Kind = 'dots' | 'pixels' | 'bytes';
|
|
2
|
+
/** Dots currently drawn in the document. */
|
|
3
|
+
export declare function documentDots(doc: Document): number;
|
|
4
|
+
export declare function lease(doc: Document, report: (code: string) => void): {
|
|
5
|
+
issue: (code: string) => void;
|
|
6
|
+
/** Sets this lease's share of `kind`; false (and a report) past a limit. */
|
|
7
|
+
set(kind: Kind, count: number): boolean;
|
|
8
|
+
get(kind: Kind): number;
|
|
9
|
+
close(): void;
|
|
10
|
+
};
|
|
11
|
+
/** Whether `count` more of `kind` would fit, crediting what a lease already holds. */
|
|
12
|
+
export declare function available(doc: Document, kind: Kind, count: number, credit?: number): boolean;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
const key = Symbol.for('dotquilt.v1.dot-ledger');
|
|
2
|
+
/** [per surface, per document] */
|
|
3
|
+
const limits = {
|
|
4
|
+
dots: [4096, 16384],
|
|
5
|
+
pixels: [1048576, 4194304],
|
|
6
|
+
bytes: [262144, 2097152],
|
|
7
|
+
};
|
|
8
|
+
function read(doc) {
|
|
9
|
+
return doc[key];
|
|
10
|
+
}
|
|
11
|
+
/** Dots currently drawn in the document. */
|
|
12
|
+
export function documentDots(doc) {
|
|
13
|
+
return read(doc)?.dots ?? 0;
|
|
14
|
+
}
|
|
15
|
+
export function lease(doc, report) {
|
|
16
|
+
let ledger = read(doc);
|
|
17
|
+
if (!ledger) {
|
|
18
|
+
ledger = { dots: 0, users: 0 };
|
|
19
|
+
doc[key] = ledger;
|
|
20
|
+
}
|
|
21
|
+
const shared = ledger;
|
|
22
|
+
shared.users++;
|
|
23
|
+
const owned = { dots: 0, pixels: 0, bytes: 0 };
|
|
24
|
+
let closed = false;
|
|
25
|
+
const codes = new Set();
|
|
26
|
+
const issue = (code) => {
|
|
27
|
+
if (!codes.has(code)) {
|
|
28
|
+
codes.add(code);
|
|
29
|
+
report(code);
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
return {
|
|
33
|
+
issue,
|
|
34
|
+
/** Sets this lease's share of `kind`; false (and a report) past a limit. */
|
|
35
|
+
set(kind, count) {
|
|
36
|
+
if (closed)
|
|
37
|
+
return false;
|
|
38
|
+
const [surface, document] = limits[kind];
|
|
39
|
+
const total = (shared[kind] ?? 0) - owned[kind] + count;
|
|
40
|
+
if (!Number.isSafeInteger(count) ||
|
|
41
|
+
count < 0 ||
|
|
42
|
+
count > surface ||
|
|
43
|
+
total > document) {
|
|
44
|
+
issue(`${kind}-limit`);
|
|
45
|
+
return false;
|
|
46
|
+
}
|
|
47
|
+
shared[kind] = total;
|
|
48
|
+
owned[kind] = count;
|
|
49
|
+
return true;
|
|
50
|
+
},
|
|
51
|
+
get(kind) {
|
|
52
|
+
return owned[kind];
|
|
53
|
+
},
|
|
54
|
+
close() {
|
|
55
|
+
if (closed)
|
|
56
|
+
return;
|
|
57
|
+
closed = true;
|
|
58
|
+
for (const kind of ['dots', 'pixels', 'bytes'])
|
|
59
|
+
if (owned[kind])
|
|
60
|
+
shared[kind] = (shared[kind] ?? 0) - owned[kind];
|
|
61
|
+
if (--shared.users === 0)
|
|
62
|
+
delete doc[key];
|
|
63
|
+
},
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
/** Whether `count` more of `kind` would fit, crediting what a lease already holds. */
|
|
67
|
+
export function available(doc, kind, count, credit = 0) {
|
|
68
|
+
const total = read(doc)?.[kind] ?? 0;
|
|
69
|
+
const [surface, document] = limits[kind];
|
|
70
|
+
return (Number.isSafeInteger(count) &&
|
|
71
|
+
Number.isSafeInteger(credit) &&
|
|
72
|
+
count >= 0 &&
|
|
73
|
+
count <= surface &&
|
|
74
|
+
credit >= 0 &&
|
|
75
|
+
credit <= surface &&
|
|
76
|
+
credit <= total &&
|
|
77
|
+
total - credit + count <= document);
|
|
78
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import type { Animations, RevealTarget } from '../animations.js';
|
|
2
|
+
import type { LoadingState, Motion, StylePolicy, Timing } from '../types.js';
|
|
3
|
+
import { EventElement } from './event-element.js';
|
|
4
|
+
import { type HandoffSource } from './handoff.js';
|
|
5
|
+
import type { Preset } from './preset.js';
|
|
6
|
+
type OwnerAnimations<F extends 'region' | 'text'> = F extends 'region' ? Pick<Animations<F>, 'handoff'> : Animations<F>;
|
|
7
|
+
export declare abstract class LoadingController<F extends 'region' | 'text' = 'region'> extends EventElement<F> {
|
|
8
|
+
#private;
|
|
9
|
+
protected upgrade(): void;
|
|
10
|
+
protected abstract get family(): F;
|
|
11
|
+
protected abstract get styles(): readonly string[];
|
|
12
|
+
protected placeholderChanged(_placeholder: HTMLSlotElement, _state: LoadingState): void;
|
|
13
|
+
protected abstract contentChanged(): void;
|
|
14
|
+
protected abstract settled(): void;
|
|
15
|
+
/** A built-in cue shown while refreshing, when the app gives none. */
|
|
16
|
+
protected refreshCue(): Element | undefined;
|
|
17
|
+
/** Called once each time refreshing starts with the built-in cue. */
|
|
18
|
+
protected refreshStarted(_cue: Element): void;
|
|
19
|
+
protected capturePreset(value: Preset<F>): Preset<F>;
|
|
20
|
+
static observedAttributes: string[];
|
|
21
|
+
get activity(): import("./element.js").Activity;
|
|
22
|
+
get presentation(): string;
|
|
23
|
+
get state(): LoadingState;
|
|
24
|
+
set state(value: LoadingState | undefined);
|
|
25
|
+
get cycle(): string | undefined;
|
|
26
|
+
/** Milliseconds to wait before showing the placeholder (0–10000). */
|
|
27
|
+
get delay(): number;
|
|
28
|
+
set delay(value: number | undefined);
|
|
29
|
+
/** Milliseconds a placeholder stays once shown (0–10000). */
|
|
30
|
+
get minDisplay(): number;
|
|
31
|
+
set minDisplay(value: number | undefined);
|
|
32
|
+
set cycle(value: string | undefined);
|
|
33
|
+
get timing(): Timing;
|
|
34
|
+
set timing(value: Timing | undefined);
|
|
35
|
+
get animations(): OwnerAnimations<F>;
|
|
36
|
+
set animations(value: OwnerAnimations<F> | undefined);
|
|
37
|
+
get revealTargets(): readonly RevealTarget[];
|
|
38
|
+
set revealTargets(value: readonly RevealTarget[]);
|
|
39
|
+
update(patch: {
|
|
40
|
+
readonly state?: LoadingState;
|
|
41
|
+
readonly cycle?: string | undefined;
|
|
42
|
+
readonly timing?: Timing | undefined;
|
|
43
|
+
readonly animations?: OwnerAnimations<F> | undefined;
|
|
44
|
+
readonly revealTargets?: readonly RevealTarget[];
|
|
45
|
+
readonly motion?: Motion | undefined;
|
|
46
|
+
readonly stylePolicy?: StylePolicy;
|
|
47
|
+
readonly preset?: import('./preset.js').Preset<F> | undefined;
|
|
48
|
+
readonly delay?: number | undefined;
|
|
49
|
+
readonly minDisplay?: number | undefined;
|
|
50
|
+
}): void;
|
|
51
|
+
protected get optionNames(): readonly string[];
|
|
52
|
+
attributeChangedCallback(name: string, old: string | null, value: string | null): void;
|
|
53
|
+
connectedCallback(): void;
|
|
54
|
+
disconnectedCallback(): void;
|
|
55
|
+
refresh(): void;
|
|
56
|
+
protected refreshParticipants(): void;
|
|
57
|
+
/** Where the handoff comes from when this element becomes ready. */
|
|
58
|
+
protected abstract handoffSource(): HandoffSource;
|
|
59
|
+
protected render(): void;
|
|
60
|
+
protected frame(): void;
|
|
61
|
+
}
|
|
62
|
+
export {};
|