ClipInfo.exclusiveWith ​Contract 2.0.0 · package sha256
a857eca95b35921109faf997094bb4192f12527d9d0fcd4be7e97f06425bad6e· generated fromconfigurator-runtime.d.tsbyservices/onsite-scripter/scripts/build-contract-docs.mjs; edit the source, not this file.
Property of ClipInfo · stable · since 2.0.0 · called as session.animations.list(target).exclusiveWith
readonly exclusiveWith: readonly string[];
The same model's clips that animate a node or joint this one does, in glTF order: a play of
one of them returns this clip to frame 0 first (see Animations), firing no event when it is
held at its end. Clips it doesn't name play beside it.
Default: [] (it shares no node with another clip)
Imports: values (has, validate, the Holo*Error classes, the pure helpers) from @holostep-configurators/runtime-client, types from @holostep-configurators/runtime-client/contract, /math and /testing names from those entries; boot from the runtime module the root's loadRuntimeAtFloor resolves to. A type your page defines is your app's: declare it there, never import it from the package.
Compiled under the contract's strict settings (examples/declaration/14-ClipInfo.exclusiveWith.ts):
import type { Session } from '@holostep-configurators/runtime-client/contract';
declare const session: Session;
declare const signal: AbortSignal;
// A door button keeps its own state; a play of a clip that shares the door's nodes closes it.
let doorOpen = false;
session.on('animation:finished', ({ clip }) => void (clip === 'DoorOpen' && (doorOpen = true)), {
signal,
});
export async function playClip(clip: string): Promise<void> {
const door = session.animations.list('cabinet').find((c) => c.clip === 'DoorOpen');
if (door?.exclusiveWith.includes(clip)) doorOpen = false; // back at frame 0
await session.animations.play('cabinet', clip);
}
export const isDoorOpen = (): boolean => doorOpen;
| Rule | Result |
|---|---|
| 1. Neutral name | pass: exclusiveWith names no product |
| 2. A precedent | not recorded: no ledger row (coverage.json) names this member or its owner |
| 3. Two apps, or labs | pass: 21 apps (fleet cross-check: app-04c2774145, app-0c773a4ee3, app-37356bf09f, app-4762caacdc, app-4fd23bc869, app-822bb9d6aa, app-8675b3225c, app-b362a81c85 and 13 more) |
| 4. The cheaper fix first | not recorded per member (Appendix B decides it per need) |