Reference
API
Everything @munsonlabs/splice and @munsonlabs/splice/vue export.
@munsonlabs/splice
| Export | Signature | Description |
|---|---|---|
createSplice | (options: SpliceOptions) => Promise<Blob> | Cuts a clip. See createSplice |
canSplice | (source, { crop?, audio? }) => Promise<CanSpliceResult> | Whether a source can be spliced here; never throws |
createThumbnails | (options: ThumbnailOptions) => Promise<void> | A filmstrip. See thumbnails |
createClipLink | (origin, start, end) => string | The deep link back to a moment |
planOutput | (request: PlanRequest) => Promise<OutputPlan | null> | What a clip of a given size and audio track would be |
CanSpliceResult is { ok: true, info, plan } or { ok: false, message }. info is the source's size, duration, codecs and what's actually read (resolved).
Types: SpliceOptions, SpliceSource, SpliceOrigin, CropOptions, CaptionCue, CaptionInput, CaptionPosition, CaptionStyle, EndCardOptions, EndCardTheme, StampOptions, StampPosition, WatermarkOptions, ImageSource, ThumbnailOptions, SourceInfo, PlanRequest, OutputPlan, CanSpliceOptions and CanSpliceResult.
@munsonlabs/splice/vue
| Export | Description |
|---|---|
SpliceEditor | The editor component. See the editor |
Types: EditorLabels, EditorState, EditorExportDetail and EditorErrorDetail.
@munsonlabs/splice/element
Registers <ml-splice-editor> on import (unless imported with ?defer) and puts its stylesheet on the page. See the web component.
| Export | Description |
|---|---|
defineSpliceEditor | (tag = 'ml-splice-editor') => void: registers the element under a tag |
SpliceEditorElement | The element's class, and its type |
It also re-exports everything from @munsonlabs/splice/vue.
@munsonlabs/splice/style
The editor's stylesheet.