Soundor 0.17.0
Release notes for Soundor 0.17.0.
19 changes — 14 features, 3 fixes, 2 breaking changes
Minor Changes
-
#252
3275981Thanks @dm-balakin! - Double clicks:soundor:uideclares thedblclickevent andPointerEvent.detail(which click of a series aclickis, as the platform counts them), and@soundor/reactnodes takeonDoubleClickandonDoubleClickCapture. The test runtime counts a press as itsdetailsays (1 by default) and firesdblclickafter a second click; Testing Library addsuser.dblClick()andfireEvent.dblClick(), anduser.pointerpresses take adetail. Soundor Driver addslocator.dblclick(),pointer.dblclick()and aclickCountoption forpointer.down()andpointer.click()(Input.dispatchPointer'sclickCount), andsoundor driver dblclick.Packages:
@soundor/devtools-protocol,@soundor/devtools-server,@soundor/driver,@soundor/environment,@soundor/react,@soundor/test-runtime,@soundor/testing-library,soundor. -
#256
d5b9b16Thanks @dm-balakin! - Breaking: runtimes and the CLI agree on a runtime API version.RUNTIME_API_VERSION(now 1) in@soundor/configis the version of what a runtime depends on of its host (theRuntimeinterface,LifecycleContext, the config it receives, the error protocol), independent of the package versions.defineRuntime()gives a runtime the version of the@soundor/configit is built with (runtime.apiVersion; a runtime without one implements 1), andresolveRuntime()refuses, with exit code 4 (INCOMPATIBLE_RUNTIME), one outsideMIN_RUNTIME_API_VERSIONtoRUNTIME_API_VERSION, or one older than a config setting the project uses (CONFIG_FEATURES), naming its path.soundor init,gen,dev,buildanddoctorresolve every runtime they run before generating or bundling anything.packages/config/runtime-api.jsonrecords 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, andparseConfig()refuses a project whose own@soundor/configis of another release line than the CLI's (ConfigErrorof kindcompatibility).Errors are recognized across copies of the packages:
isSoundorError(value, code?)checks a protocol everySoundorErrorcarries (the brandSymbol.for('soundor.error.v1'), a stringcode,issues), andisConfigError()aConfigError's.runPhase()passes through, andexitCodeFor()classifies, an error a runtime threw from its own@soundor/core, whereinstanceofsaid no: a runtime'sConfigErrororEnvErrorwas wrapped as aRuntimeErrorwith exit code 5. New:RuntimeCompatibilityErrorin core;CONFIG_VERSION,RUNTIME_API_VERSION,MIN_RUNTIME_API_VERSION,CONFIG_FEATURES,HOST_RUNTIME_API,checkRuntimeCompatibility(),runtimeApiVersion(),checkProjectConfigVersion(),projectConfigVersion()andsameReleaseLine()in config.@soundor/runtime-sdkre-exports all of@soundor/configand@soundor/core, and is the one Soundor package a runtime depends on; its new@soundor/runtime-sdk/cliententry has what a runtime's client code needs without Node (core's springs).defineSoundorConfig()returns aSoundorConfiginstead of the literal type of what it is given, so a project's config type names only@soundor/config, not its runtimes' packages (which acompositeproject, ascreate-soundor-appmakes, could not name). Parameter types for the UI come fromsoundor gen, as before.soundorand@soundor/runtime-sdkdepend on@soundor/configinstead of declaring it a peer: both run its code.soundor gen,initanddoctorexit 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
67ffaacThanks @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
258c891Thanks @dm-balakin! - Runtime packages now declare supported Soundor CLI versions through a requiredsoundorpeer dependency. Both first-party runtimes use a caret range matching their regular@soundor/runtime-sdkdependency; 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.apiVersionandResolvedRuntime.apiVersion, runtime API version constants and contract record, config-feature version gates, compatibility helpers, andRuntimeCompatibilityErrorwith 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 inpeerDependencies.soundor. The existing project config release-line check and cross-copy error protocol remain.Packages:
@soundor/config,@soundor/core,@soundor/runtime-sdk,soundor. -
#289
a54e1daThanks @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
496fe62Thanks @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
0354f73Thanks @dm-balakin! - Native channels:native.channelsdeclares 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 tomaxLengthnumbers (spectrum: { type: 'buffer<float32>', maxLength: 512 }).soundor:nativeexports them aschannels:get()is the latest value received (undefined before the first, the value published last when a UI opens), andsubscribe((value, sequence) => …)hears of each newer one, at most once a frame,sequencecounting the publications so a gap is how many were skipped.getandsubscribework unbound, souseSyncExternalStore(channels.peak.subscribe, channels.peak.get)works. A method can no longer be calledchannels. In tests,publishChannel(name, value)from@soundor/testing-librarypublishes a value.Packages:
@soundor/config,@soundor/core,@soundor/test-runtime,@soundor/testing-library,@soundor/vitest. -
#258
553d8c4Thanks @dm-balakin! - Parameters with Soundor's own semantics.parametersis a record keyed by each parameter's stable id, with the typesfloat32,int8…uint32,booleanandchoice(options{ value, label }, their values inferred withoutas const, defaults and repeated options type errors);int64,uint64andfloat64are refused, as hosts carry parameters as 32-bit floats. A parameter declares itsaccess(automatable,manual,readOnly), itsmapping(linear,log,power,symmetricPower, or a custom pair of expressions), astep, aunit, andformatandparsewritten with the new@soundor/expressionbuilder. Validation resolves each one into typed expressions (ParameterSemantics) that runtimes compile, and checks defaults, steps, custom mappings and format/parse round trips.soundor:parametersaddsformat(),parse(),toNormalized()andfromNormalized(), and refuses writes to read-only parameters.@soundor/expressionis 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, andtestParameters.setsets 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
14b7be0Thanks @dm-balakin! - Add typed persistent application state throughsoundor:state, reusing native type declarations and validated defaults, with field subscriptions and ReactuseStateValue().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
553076dThanks @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
27a3303Thanks @dm-balakin! - Native events:native.eventsdeclares 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:nativeexports them asevents: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 calledevents. In tests,emitNative(name, value)from@soundor/testing-librarypublishes one to the UI's subscribers.Packages:
@soundor/core,@soundor/test-runtime,@soundor/testing-library,@soundor/vitest. -
#255
13da21dThanks @dm-balakin! - Breaking: the native API's types are language-neutral and sized.numberis gone: useint8,uint8,int16,uint16,int32,uint32,int64,uint64(bigintin TypeScript, so the whole range is exact),float32orfloat64. The JavaScript binary types (ArrayBuffer,Uint8Array,Int32Array,Float32Array,Float64Array) are replaced bybuffer<T>, contiguous numbers of any sized type (buffer<float32>is aFloat32Array,buffer<int64>aBigInt64Array), 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, neverundefined; 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
61798d1Thanks @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
6cfc628Thanks @dm-balakin! - Narrow the@soundor/vst3-hostpeer 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
0ada0c5Thanks @dm-balakin! - Box shadows:soundor:ui'sStyledeclaresboxShadow, a list ofBoxShadow(offsetX,offsetY,blur,spread,color,inset), as CSS'sbox-shadow.@soundor/reactnodes take it instyleand 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
02d06a8Thanks @dm-balakin! - Add booleansoundor:uiisVisible()/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
3a778e2Thanks @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
d5b9b16Thanks @dm-balakin! -isDriverError()recognizes aDriverErrorof any copy of the Driver (such as@soundor/vitest-e2e's), by the brandSymbol.for('soundor.driver-error.v1')and itscode, not byinstanceof.Packages:
@soundor/driver. -
#261
ca998c9Thanks @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.