Soundor
Soundor

Soundor 0.17.0 Contains breaking changes

Release notes for Soundor 0.17.0.

All Soundor releases

19 changes — 14 features, 3 fixes, 2 breaking changes

Minor Changes

  • #252 3275981 Thanks @dm-balakin! - Double clicks: soundor:ui declares the dblclick event and PointerEvent.detail (which click of a series a click is, as the platform counts them), and @soundor/react nodes take onDoubleClick and onDoubleClickCapture. The test runtime counts a press as its detail says (1 by default) and fires dblclick after a second click; Testing Library adds user.dblClick() and fireEvent.dblClick(), and user.pointer presses take a detail. Soundor Driver adds locator.dblclick(), pointer.dblclick() and a clickCount option for pointer.down() and pointer.click() (Input.dispatchPointer's clickCount), and soundor driver dblclick.

    Packages: @soundor/devtools-protocol, @soundor/devtools-server, @soundor/driver, @soundor/environment, @soundor/react, @soundor/test-runtime, @soundor/testing-library, soundor.

  • #256 d5b9b16 Thanks @dm-balakin! - Breaking: runtimes and the CLI agree on a runtime API version. RUNTIME_API_VERSION (now 1) in @soundor/config is the version of what a runtime depends on of its host (the Runtime interface, LifecycleContext, the config it receives, the error protocol), independent of the package versions. defineRuntime() gives a runtime the version of the @soundor/config it is built with (runtime.apiVersion; a runtime without one implements 1), and resolveRuntime() refuses, with exit code 4 (INCOMPATIBLE_RUNTIME), one outside MIN_RUNTIME_API_VERSION to RUNTIME_API_VERSION, or one older than a config setting the project uses (CONFIG_FEATURES), naming its path. soundor init, gen, dev, build and doctor resolve every runtime they run before generating or bundling anything. packages/config/runtime-api.json records the contract, and a test fails when it changes, for the version to be raised if runtimes could notice.

    The config schema rejects properties it does not have (unknown property 'mapping' in @soundor/config 0.17.0) instead of dropping them, and parseConfig() refuses a project whose own @soundor/config is of another release line than the CLI's (ConfigError of kind compatibility).

    Errors are recognized across copies of the packages: isSoundorError(value, code?) checks a protocol every SoundorError carries (the brand Symbol.for('soundor.error.v1'), a string code, issues), and isConfigError() a ConfigError's. runPhase() passes through, and exitCodeFor() classifies, an error a runtime threw from its own @soundor/core, where instanceof said no: a runtime's ConfigError or EnvError was wrapped as a RuntimeError with exit code 5. New: RuntimeCompatibilityError in core; CONFIG_VERSION, RUNTIME_API_VERSION, MIN_RUNTIME_API_VERSION, CONFIG_FEATURES, HOST_RUNTIME_API, checkRuntimeCompatibility(), runtimeApiVersion(), checkProjectConfigVersion(), projectConfigVersion() and sameReleaseLine() in config.

    @soundor/runtime-sdk re-exports all of @soundor/config and @soundor/core, and is the one Soundor package a runtime depends on; its new @soundor/runtime-sdk/client entry has what a runtime's client code needs without Node (core's springs). defineSoundorConfig() returns a SoundorConfig instead of the literal type of what it is given, so a project's config type names only @soundor/config, not its runtimes' packages (which a composite project, as create-soundor-app makes, could not name). Parameter types for the UI come from soundor gen, as before. soundor and @soundor/runtime-sdk depend on @soundor/config instead of declaring it a peer: both run its code.

    soundor gen, init and doctor exit when they fail: their progress spinner kept the process running after the error was printed.

    Packages: @soundor/config, @soundor/core, @soundor/runtime-sdk, soundor.

  • #289 67ffaac Thanks @dm-balakin! - Add soundor:env with explicit, typed, readonly public configuration values and DEV/PROD/MODE built-ins. Embed values in the shared UI bundle, resolve the same module for web host code, and support isolated configuration in the test runtime. No process environment is exposed implicitly.

    Packages: @soundor/config, @soundor/core, @soundor/environment, @soundor/test-runtime, @soundor/vitest, soundor.

  • #275 258c891 Thanks @dm-balakin! - Runtime packages now declare supported Soundor CLI versions through a required soundor peer dependency. Both first-party runtimes use a caret range matching their regular @soundor/runtime-sdk dependency; the SDK and CLI share the fixed package version. Before 1.0, this supports the current minor and its patches. Runtime providers own the supported range, and package managers handle peer mismatches without an additional CLI compatibility check.

    Remove the numeric Runtime.apiVersion and ResolvedRuntime.apiVersion, runtime API version constants and contract record, config-feature version gates, compatibility helpers, and RuntimeCompatibilityError with its dedicated error codes. Third-party runtimes should remove those imports and fields, keep the SDK as a regular dependency, and declare the supported CLI range in peerDependencies.soundor. The existing project config release-line check and cross-copy error protocol remain.

    Packages: @soundor/config, @soundor/core, @soundor/runtime-sdk, soundor.

  • #289 a54e1da Thanks @dm-balakin! - Expose plugin version and runtime environment in soundor:host, and extend host state with processing mode, sample precision, optional track metadata, loop boundaries and timecode. Rename snapshot/subscribe to getHostState/subscribeHostState. Configure plugin.version (default 0.1.0) consistently across formats.

    Packages: @soundor/config, @soundor/environment, @soundor/test-runtime, @soundor/vitest.

  • #266 496fe62 Thanks @dm-balakin! - Accept synchronous functional updaters on parameter and persistent state fields. Resolve once against the latest immutable store value, validate before publishing, and reject asynchronous results. Automatically bracket changed automatable parameter writes in a host gesture when no explicit gesture is active, preserving nested gestures and keeping state gestures explicit.

    Raise the runtime API version to 4 for the compatible setter addition; older runtime API versions remain supported.

    Packages: @soundor/config, @soundor/core, @soundor/test-runtime.

  • #281 0354f73 Thanks @dm-balakin! - Native channels: native.channels declares values the plugin's native code keeps publishing and the UI shows the latest of, each one number (peak: { type: 'float32' }) or a buffer of up to maxLength numbers (spectrum: { type: 'buffer<float32>', maxLength: 512 }). soundor:native exports them as channels: get() is the latest value received (undefined before the first, the value published last when a UI opens), and subscribe((value, sequence) => …) hears of each newer one, at most once a frame, sequence counting the publications so a gap is how many were skipped. get and subscribe work unbound, so useSyncExternalStore(channels.peak.subscribe, channels.peak.get) works. A method can no longer be called channels. In tests, publishChannel(name, value) from @soundor/testing-library publishes a value.

    Packages: @soundor/config, @soundor/core, @soundor/test-runtime, @soundor/testing-library, @soundor/vitest.

  • #258 553d8c4 Thanks @dm-balakin! - Parameters with Soundor's own semantics. parameters is a record keyed by each parameter's stable id, with the types float32, int8…uint32, boolean and choice (options { value, label }, their values inferred without as const, defaults and repeated options type errors); int64, uint64 and float64 are refused, as hosts carry parameters as 32-bit floats. A parameter declares its access (automatable, manual, readOnly), its mapping (linear, log, power, symmetricPower, or a custom pair of expressions), a step, a unit, and format and parse written with the new @soundor/expression builder. Validation resolves each one into typed expressions (ParameterSemantics) that runtimes compile, and checks defaults, steps, custom mappings and format/parse round trips. soundor:parameters adds format(), parse(), toNormalized() and fromNormalized(), and refuses writes to read-only parameters. @soundor/expression is a typed, JSON-serializable expression language with C++ and JavaScript compilers of identical semantics; the SDK re-exports it as @soundor/runtime-sdk/expression. The test runtime and Testing Library run the same compiled behavior, and testParameters.set sets read-only parameters as the processing does.

    Packages: @soundor/config, @soundor/core, @soundor/expression, @soundor/runtime-sdk, @soundor/test-runtime, @soundor/testing-library, @soundor/vitest, create-soundor-app.

  • #263 14b7be0 Thanks @dm-balakin! - Add typed persistent application state through soundor:state, reusing native type declarations and validated defaults, with field subscriptions and React useStateValue().

    JUCE owns state per processor, saves parameters and state together, accepts legacy APVTS projects, and calls the protected stateRestored() hook on the message thread after each complete restoration. Off-thread host restorations queue to that thread. Web hydrates before application startup and automatically saves snapshots to application-namespaced IndexedDB. Runtime API 2 gates state configuration for older runtimes.

    Packages: @soundor/config, @soundor/core, @soundor/react, @soundor/runtime-sdk, @soundor/test-runtime, @soundor/vitest.

  • #267 553076d Thanks @dm-balakin! - Add processor-owned StateHistory with opt-in discrete edits, History-enabled parameter/state gestures, synchronous buffered transactions, undo/redo, subscriptions, and useStateHistory(). JavaScript and native C++ share one manager in JUCE; Web and simulated runtimes implement the same contract. History survives editor recreation and clears on project restoration. Runtime API 5 is now required so older runtimes cannot silently ignore History options.

    Packages: @soundor/config, @soundor/core, @soundor/environment, @soundor/react, @soundor/test-runtime, @soundor/vitest.

  • #280 27a3303 Thanks @dm-balakin! - Native events: native.events declares what the plugin's native code tells its UI, each event with the fields of its value (presetLoaded: { path: 'string', preset: 'Preset?' }, ready: {}), of the same types as arguments. soundor:native exports them as events: events.presetLoaded.subscribe(({ path, preset }) => …) returns a function that unsubscribes. Subscribers run on the UI thread after the publishing call returns, in the order published, and receive only events published after they subscribed; a UI holds at most 1024 undelivered events and drops newer ones. A method can no longer be called events. In tests, emitNative(name, value) from @soundor/testing-library publishes one to the UI's subscribers.

    Packages: @soundor/core, @soundor/test-runtime, @soundor/testing-library, @soundor/vitest.

  • #255 13da21d Thanks @dm-balakin! - Breaking: the native API's types are language-neutral and sized. number is gone: use int8, uint8, int16, uint16, int32, uint32, int64, uint64 (bigint in TypeScript, so the whole range is exact), float32 or float64. The JavaScript binary types (ArrayBuffer, Uint8Array, Int32Array, Float32Array, Float64Array) are replaced by buffer<T>, contiguous numbers of any sized type (buffer<float32> is a Float32Array, buffer<int64> a BigInt64Array), now also allowed in structs. 'handle' types are removed: declare a struct of the values the UI needs, or pass an ID or path. New: T?, nullable (null, never undefined; an argument is still required) for any type, including structs, arrays and buffers. T[] stays a list of values: primitives, enums or structs. Config validation names the replacement of a former type ('Float32Array' is not a native type; use 'buffer<float32>'). nativeTsType() renders a native type as TypeScript, the same for every runtime.

    Packages: @soundor/core.

  • #264 61798d1 Thanks @dm-balakin! - Add optional beginGesture() and endGesture() methods to persistent state fields in JavaScript and native JUCE code. Gestures nest per field, leave writes immediate, reset on restoration, and clean up unfinished UI interactions without host automation or History recording.

    Raise the runtime API version to 3 for the additional state field methods; older runtimes remain accepted.

    Packages: @soundor/core, @soundor/test-runtime, @soundor/vitest.

  • #275 6cfc628 Thanks @dm-balakin! - Narrow the @soundor/vst3-host peer dependency to a caret range matching the host release used for development, instead of accepting every pre-1.0 minor. This supports patches in the current minor without claiming compatibility with future breaking host API changes. The host remains optional for the Driver and JUCE runtime and required for Vitest E2E.

    Packages: @soundor/driver, @soundor/vitest-e2e.

  • #254 0ada0c5 Thanks @dm-balakin! - Box shadows: soundor:ui's Style declares boxShadow, a list of BoxShadow (offsetX, offsetY, blur, spread, color, inset), as CSS's box-shadow. @soundor/react nodes take it in style and compare it by value, so re-rendering the same shadows in a new array sets no style; the test runtime keeps it.

    Packages: @soundor/environment, @soundor/react, @soundor/test-runtime.

  • #288 02d06a8 Thanks @dm-balakin! - Add boolean soundor:ui isVisible()/subscribeVisibility() and isFocused()/subscribeFocus() APIs so plugins can react to editor visibility and keyboard focus across runtimes. Add test runtime setters and Testing Library editor helpers. The analyzer example pauses its UI subscriptions while hidden.

    Packages: @soundor/environment, @soundor/test-runtime, @soundor/testing-library.

Patch Changes

  • #285 3a778e2 Thanks @dm-balakin! - Stop Windows UI rebuild loops by ignoring filesystem events without filenames and normalizing Windows separators and directory casing before filtering generated output.

    Packages: soundor.

  • #256 d5b9b16 Thanks @dm-balakin! - isDriverError() recognizes a DriverError of any copy of the Driver (such as @soundor/vitest-e2e's), by the brand Symbol.for('soundor.driver-error.v1') and its code, not by instanceof.

    Packages: @soundor/driver.

  • #261 ca998c9 Thanks @dm-balakin! - Default E2E polling assertions to five seconds so native host and UI reads have time to complete. Preserve explicit project and per-assertion timeouts.

    Packages: @soundor/vitest-e2e.

On this page