@pixerate/editor-react 0.114.2 → 0.115.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.
Files changed (42) hide show
  1. package/dist/animation-editor/index.cjs +361 -216
  2. package/dist/animation-editor/index.js +2 -2
  3. package/dist/canvas/index.cjs +539 -394
  4. package/dist/canvas/index.js +2 -2
  5. package/dist/{chunk-2INOKIJN.js → chunk-2KXZLZAS.js} +381 -364
  6. package/dist/{chunk-5LFQ2UQZ.js → chunk-5RPB4WGT.js} +240 -102
  7. package/dist/{chunk-BWEARAWR.js → chunk-6BWTJ3EE.js} +40 -18
  8. package/dist/effects/EffectParameters.d.cts +4 -1
  9. package/dist/effects/EffectParameters.d.ts +4 -1
  10. package/dist/effects/index.cjs +367 -222
  11. package/dist/effects/index.js +2 -2
  12. package/dist/image-editor/ImageEffectControls.d.cts +4 -1
  13. package/dist/image-editor/ImageEffectControls.d.ts +4 -1
  14. package/dist/image-editor/ImageProviderEffectsPanel.d.cts +4 -1
  15. package/dist/image-editor/ImageProviderEffectsPanel.d.ts +4 -1
  16. package/dist/image-editor/controls/controls.d.cts +19 -0
  17. package/dist/image-editor/controls/controls.d.ts +19 -0
  18. package/dist/image-editor/controls/parameterControls.d.cts +4 -0
  19. package/dist/image-editor/controls/parameterControls.d.ts +4 -0
  20. package/dist/image-editor/index.cjs +924 -765
  21. package/dist/image-editor/index.d.cts +1 -1
  22. package/dist/image-editor/index.d.ts +1 -1
  23. package/dist/image-editor/index.js +5 -3
  24. package/dist/index.cjs +1444 -1285
  25. package/dist/index.js +5 -3
  26. package/dist/paint-editor/index.cjs +354 -209
  27. package/dist/paint-editor/index.js +2 -2
  28. package/dist/parameters/ParametersPanel.d.cts +4 -1
  29. package/dist/parameters/ParametersPanel.d.ts +4 -1
  30. package/dist/parameters/controls.d.cts +92 -0
  31. package/dist/parameters/controls.d.ts +92 -0
  32. package/dist/parameters/fields.d.cts +20 -7
  33. package/dist/parameters/fields.d.ts +20 -7
  34. package/dist/parameters/index.cjs +369 -184
  35. package/dist/parameters/index.d.cts +1 -0
  36. package/dist/parameters/index.d.ts +1 -0
  37. package/dist/parameters/index.js +70 -14
  38. package/dist/vector/index.cjs +340 -195
  39. package/dist/vector/index.js +2 -2
  40. package/dist/video-editor/index.cjs +437 -292
  41. package/dist/video-editor/index.js +2 -2
  42. package/package.json +3 -3
@@ -5,8 +5,8 @@ import {
5
5
  EffectParameters,
6
6
  EffectsBrowser,
7
7
  useEffectDescription
8
- } from "../chunk-BWEARAWR.js";
9
- import "../chunk-5LFQ2UQZ.js";
8
+ } from "../chunk-6BWTJ3EE.js";
9
+ import "../chunk-5RPB4WGT.js";
10
10
  import "../chunk-KIRIU53A.js";
11
11
  import "../chunk-3I7FOSLF.js";
12
12
  import {
@@ -2,6 +2,7 @@ import React from 'react';
2
2
  import type { AgentPlayback } from '@pixerate/editor/tools';
3
3
  import { type ParametersController } from '@pixerate/editor/parameters';
4
4
  import { type ParameterImageProps } from './fields.cjs';
5
+ import { type ParameterComponents } from './controls.cjs';
5
6
  export interface ParametersPanelProps {
6
7
  controller: ParametersController;
7
8
  /** Heading (default: the schema's title). Pass `null` for none. */
@@ -19,6 +20,8 @@ export interface ParametersPanelProps {
19
20
  /** Shown when the schema has no fields. */
20
21
  emptyMessage?: React.ReactNode;
21
22
  className?: string;
23
+ /** Custom host controls (input, slider, select). */
24
+ components?: ParameterComponents;
22
25
  /**
23
26
  * Agent playback: act out `parameters.*` commands here with the agent's cursor (default: the
24
27
  * nearest `AgentPlaybackProvider`; `null` turns it off).
@@ -34,4 +37,4 @@ export interface ParametersPanelProps {
34
37
  * keyframe diamonds, per-field reset, presets, and undo / redo / reset / randomize. Slider
35
38
  * drags and colour picks are one undo step each.
36
39
  */
37
- export declare function ParametersPanel({ controller, title, showToolbar, showPresets, showKeyframes, showFieldReset, resolveFile, emptyMessage, className, playback, playbackId, onPlaybackReveal, }: ParametersPanelProps): React.JSX.Element;
40
+ export declare function ParametersPanel({ controller, title, showToolbar, showPresets, showKeyframes, showFieldReset, resolveFile, emptyMessage, className, components, playback, playbackId, onPlaybackReveal, }: ParametersPanelProps): React.JSX.Element;
@@ -2,6 +2,7 @@ import React from 'react';
2
2
  import type { AgentPlayback } from '@pixerate/editor/tools';
3
3
  import { type ParametersController } from '@pixerate/editor/parameters';
4
4
  import { type ParameterImageProps } from './fields.js';
5
+ import { type ParameterComponents } from './controls.js';
5
6
  export interface ParametersPanelProps {
6
7
  controller: ParametersController;
7
8
  /** Heading (default: the schema's title). Pass `null` for none. */
@@ -19,6 +20,8 @@ export interface ParametersPanelProps {
19
20
  /** Shown when the schema has no fields. */
20
21
  emptyMessage?: React.ReactNode;
21
22
  className?: string;
23
+ /** Custom host controls (input, slider, select). */
24
+ components?: ParameterComponents;
22
25
  /**
23
26
  * Agent playback: act out `parameters.*` commands here with the agent's cursor (default: the
24
27
  * nearest `AgentPlaybackProvider`; `null` turns it off).
@@ -34,4 +37,4 @@ export interface ParametersPanelProps {
34
37
  * keyframe diamonds, per-field reset, presets, and undo / redo / reset / randomize. Slider
35
38
  * drags and colour picks are one undo step each.
36
39
  */
37
- export declare function ParametersPanel({ controller, title, showToolbar, showPresets, showKeyframes, showFieldReset, resolveFile, emptyMessage, className, playback, playbackId, onPlaybackReveal, }: ParametersPanelProps): React.JSX.Element;
40
+ export declare function ParametersPanel({ controller, title, showToolbar, showPresets, showKeyframes, showFieldReset, resolveFile, emptyMessage, className, components, playback, playbackId, onPlaybackReveal, }: ParametersPanelProps): React.JSX.Element;
@@ -0,0 +1,92 @@
1
+ import React, { type ComponentType, type ReactNode } from 'react';
2
+ /** Props for a custom number input in parameter panels. Call `onCommit` when an edit is done (blur, Enter, Tab). */
3
+ export interface ParameterInputProps {
4
+ id?: string;
5
+ /** The stored value as text, without the unit. */
6
+ value: string;
7
+ disabled?: boolean;
8
+ 'aria-label'?: string;
9
+ /** The field's label. */
10
+ label: string;
11
+ inputMode?: React.HTMLAttributes<HTMLInputElement>['inputMode'];
12
+ className?: string;
13
+ style?: React.CSSProperties;
14
+ /** Commits typed text. Pass the element to have a refused edit show the stored value again. */
15
+ onCommit: (value: string, input?: HTMLInputElement | HTMLTextAreaElement) => void;
16
+ /** Arrow keys step the value (Shift ×10). */
17
+ onKeyDown?: React.KeyboardEventHandler;
18
+ }
19
+ /** Props for a custom slider in parameter panels. */
20
+ export interface ParameterSliderProps {
21
+ id?: string;
22
+ value: number;
23
+ min: number;
24
+ max: number;
25
+ step: number;
26
+ disabled?: boolean;
27
+ 'aria-label'?: string;
28
+ /** The field's label. */
29
+ label: string;
30
+ 'aria-valuetext'?: string;
31
+ className?: string;
32
+ style?: React.CSSProperties;
33
+ /** Every change while the value moves. */
34
+ onChange: (value: number) => void;
35
+ /** A drag (or key press) starts: changes until `onGestureEnd` merge into one undo step. */
36
+ onGestureStart?: () => void;
37
+ onGestureEnd?: () => void;
38
+ }
39
+ /** One option in a dropdown parameter control. */
40
+ export interface ParameterSelectOption {
41
+ value: string | number;
42
+ label: string;
43
+ description?: string;
44
+ }
45
+ /** Props for a custom select in parameter panels. `onChange` takes an option's `value` (or its string form). */
46
+ export interface ParameterSelectProps {
47
+ id?: string;
48
+ value: string | number;
49
+ options: readonly ParameterSelectOption[];
50
+ disabled?: boolean;
51
+ 'aria-label'?: string;
52
+ /** The control's label. */
53
+ label: string;
54
+ className?: string;
55
+ style?: React.CSSProperties;
56
+ onChange: (value: string | number) => void;
57
+ }
58
+ /** Host form controls for parameter panels. Any left out fall back to the default controls. */
59
+ /** Props for a custom colour control in parameter panels. */
60
+ export interface ParameterColorProps {
61
+ id?: string;
62
+ /** `#rrggbb`, or `#rrggbbaa` with `alpha`. */
63
+ value: string;
64
+ /** Whether the field has an alpha channel. */
65
+ alpha?: boolean;
66
+ /** Suggested colours for the field, if it has any. */
67
+ swatches?: readonly string[];
68
+ disabled?: boolean;
69
+ /** The field's label. */
70
+ label: string;
71
+ className?: string;
72
+ style?: React.CSSProperties;
73
+ onChange: (value: string) => void;
74
+ /** A pick starts: changes until `onGestureEnd` merge into one undo step. */
75
+ onGestureStart?: () => void;
76
+ onGestureEnd?: () => void;
77
+ }
78
+ export interface ParameterComponents {
79
+ input?: ComponentType<ParameterInputProps>;
80
+ slider?: ComponentType<ParameterSliderProps>;
81
+ select?: ComponentType<ParameterSelectProps>;
82
+ color?: ComponentType<ParameterColorProps>;
83
+ }
84
+ /** Makes the parameter panels inside it use the host's controls. */
85
+ export declare function ParameterComponentsProvider({ components, children }: {
86
+ components: ParameterComponents;
87
+ children?: ReactNode;
88
+ }): React.JSX.Element;
89
+ /** The controls set by an enclosing {@link ParameterComponentsProvider}, or none. */
90
+ export declare function useParameterComponents(): ParameterComponents;
91
+ /** The controls to use: each one from `explicit`, else from `context`. */
92
+ export declare function resolveParameterComponents(explicit?: ParameterComponents, context?: ParameterComponents): ParameterComponents;
@@ -0,0 +1,92 @@
1
+ import React, { type ComponentType, type ReactNode } from 'react';
2
+ /** Props for a custom number input in parameter panels. Call `onCommit` when an edit is done (blur, Enter, Tab). */
3
+ export interface ParameterInputProps {
4
+ id?: string;
5
+ /** The stored value as text, without the unit. */
6
+ value: string;
7
+ disabled?: boolean;
8
+ 'aria-label'?: string;
9
+ /** The field's label. */
10
+ label: string;
11
+ inputMode?: React.HTMLAttributes<HTMLInputElement>['inputMode'];
12
+ className?: string;
13
+ style?: React.CSSProperties;
14
+ /** Commits typed text. Pass the element to have a refused edit show the stored value again. */
15
+ onCommit: (value: string, input?: HTMLInputElement | HTMLTextAreaElement) => void;
16
+ /** Arrow keys step the value (Shift ×10). */
17
+ onKeyDown?: React.KeyboardEventHandler;
18
+ }
19
+ /** Props for a custom slider in parameter panels. */
20
+ export interface ParameterSliderProps {
21
+ id?: string;
22
+ value: number;
23
+ min: number;
24
+ max: number;
25
+ step: number;
26
+ disabled?: boolean;
27
+ 'aria-label'?: string;
28
+ /** The field's label. */
29
+ label: string;
30
+ 'aria-valuetext'?: string;
31
+ className?: string;
32
+ style?: React.CSSProperties;
33
+ /** Every change while the value moves. */
34
+ onChange: (value: number) => void;
35
+ /** A drag (or key press) starts: changes until `onGestureEnd` merge into one undo step. */
36
+ onGestureStart?: () => void;
37
+ onGestureEnd?: () => void;
38
+ }
39
+ /** One option in a dropdown parameter control. */
40
+ export interface ParameterSelectOption {
41
+ value: string | number;
42
+ label: string;
43
+ description?: string;
44
+ }
45
+ /** Props for a custom select in parameter panels. `onChange` takes an option's `value` (or its string form). */
46
+ export interface ParameterSelectProps {
47
+ id?: string;
48
+ value: string | number;
49
+ options: readonly ParameterSelectOption[];
50
+ disabled?: boolean;
51
+ 'aria-label'?: string;
52
+ /** The control's label. */
53
+ label: string;
54
+ className?: string;
55
+ style?: React.CSSProperties;
56
+ onChange: (value: string | number) => void;
57
+ }
58
+ /** Host form controls for parameter panels. Any left out fall back to the default controls. */
59
+ /** Props for a custom colour control in parameter panels. */
60
+ export interface ParameterColorProps {
61
+ id?: string;
62
+ /** `#rrggbb`, or `#rrggbbaa` with `alpha`. */
63
+ value: string;
64
+ /** Whether the field has an alpha channel. */
65
+ alpha?: boolean;
66
+ /** Suggested colours for the field, if it has any. */
67
+ swatches?: readonly string[];
68
+ disabled?: boolean;
69
+ /** The field's label. */
70
+ label: string;
71
+ className?: string;
72
+ style?: React.CSSProperties;
73
+ onChange: (value: string) => void;
74
+ /** A pick starts: changes until `onGestureEnd` merge into one undo step. */
75
+ onGestureStart?: () => void;
76
+ onGestureEnd?: () => void;
77
+ }
78
+ export interface ParameterComponents {
79
+ input?: ComponentType<ParameterInputProps>;
80
+ slider?: ComponentType<ParameterSliderProps>;
81
+ select?: ComponentType<ParameterSelectProps>;
82
+ color?: ComponentType<ParameterColorProps>;
83
+ }
84
+ /** Makes the parameter panels inside it use the host's controls. */
85
+ export declare function ParameterComponentsProvider({ components, children }: {
86
+ components: ParameterComponents;
87
+ children?: ReactNode;
88
+ }): React.JSX.Element;
89
+ /** The controls set by an enclosing {@link ParameterComponentsProvider}, or none. */
90
+ export declare function useParameterComponents(): ParameterComponents;
91
+ /** The controls to use: each one from `explicit`, else from `context`. */
92
+ export declare function resolveParameterComponents(explicit?: ParameterComponents, context?: ParameterComponents): ParameterComponents;
@@ -1,5 +1,12 @@
1
1
  import React from 'react';
2
2
  import { type BooleanParameterField, type ChoiceParameterField, type ColorParameterField, type ImageParameterField, type NumberParameterField, type ParameterField, type ParameterKeyState, type ParameterValue, type TextParameterField, type VectorParameterField } from '@pixerate/editor/parameters';
3
+ import { type ParameterComponents } from './controls.cjs';
4
+ /** Inline theme styles (`--pixerate-parameter-*` tokens with host fallbacks), shared with Svelte through core. */
5
+ export declare const parameterInputStyle: React.CSSProperties;
6
+ export declare const parameterSelectStyle: React.CSSProperties;
7
+ /** Text and border only, so the button classes' `hover:` background still applies. */
8
+ export declare const parameterButtonStyle: React.CSSProperties;
9
+ export declare const parameterRangeStyle: React.CSSProperties;
3
10
  /** Props every field control takes. Controls are controller-free: wire them to anything. */
4
11
  export interface ParameterControlProps<F extends ParameterField, V extends ParameterValue> {
5
12
  field: F;
@@ -11,6 +18,8 @@ export interface ParameterControlProps<F extends ParameterField, V extends Param
11
18
  disabled?: boolean;
12
19
  /** DOM id of the main input (for a `<label htmlFor>`). */
13
20
  id?: string;
21
+ /** Custom host controls (input, slider, select). */
22
+ components?: ParameterComponents;
14
23
  }
15
24
  export declare const parameterInputClass = "h-7 w-full min-w-0 rounded-md border border-input bg-background px-2 text-xs text-foreground tabular-nums focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-primary disabled:cursor-not-allowed disabled:opacity-50";
16
25
  export declare const parameterButtonClass = "inline-flex h-7 items-center justify-center gap-1 rounded-md border border-input bg-background px-2 text-xs text-foreground hover:bg-muted focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-primary disabled:pointer-events-none disabled:opacity-50";
@@ -20,10 +29,14 @@ type CommitInputProps = {
20
29
  onCommit: (value: string, input: HTMLInputElement | HTMLTextAreaElement) => void;
21
30
  multiline?: boolean;
22
31
  } & Omit<React.InputHTMLAttributes<HTMLInputElement> & React.TextareaHTMLAttributes<HTMLTextAreaElement>, 'value' | 'onChange' | 'defaultValue'>;
23
- /** A text box that commits on blur or Enter (Mod+Enter when multiline) and resets on Escape. */
24
- export declare function ParameterCommitInput({ value, onCommit, multiline, className, onKeyDown, ...rest }: CommitInputProps): React.JSX.Element;
32
+ /**
33
+ * A text box that commits on blur, Tab, a native `change` or Enter (Mod+Enter when multiline) and
34
+ * resets on Escape. Text that was already committed (or refused) is not committed again, so the
35
+ * blur that follows Tab or `change` is a no-op.
36
+ */
37
+ export declare function ParameterCommitInput({ value, onCommit, multiline, className, onKeyDown, style, ...rest }: CommitInputProps): React.JSX.Element;
25
38
  /** A number box: type a value (units allowed), or step with the arrow keys (Shift ×10). */
26
- export declare function ParameterNumberInput({ field, value, onChange, disabled, id, 'aria-label': ariaLabel, }: ParameterControlProps<NumberParameterField, number> & {
39
+ export declare function ParameterNumberInput(props: ParameterControlProps<NumberParameterField, number> & {
27
40
  'aria-label'?: string;
28
41
  }): React.JSX.Element;
29
42
  /** A slider plus number box for `number` / `int` fields (number box only for `control: 'input'` or unbounded fields). */
@@ -31,18 +44,18 @@ export declare function ParameterSlider(props: ParameterControlProps<NumberParam
31
44
  /** An on/off switch for `boolean` fields. */
32
45
  export declare function ParameterToggle({ field, value, onChange, disabled, id }: ParameterControlProps<BooleanParameterField, boolean>): React.JSX.Element;
33
46
  /** A dropdown (or segmented buttons with `control: 'segmented'`) for `choice` fields. */
34
- export declare function ParameterSelect({ field, value, onChange, disabled, id }: ParameterControlProps<ChoiceParameterField, string | number>): React.JSX.Element;
47
+ export declare function ParameterSelect(props: ParameterControlProps<ChoiceParameterField, string | number>): React.JSX.Element;
35
48
  /** A colour picker with a hex box and a popup ColorPicker. */
36
- export declare function ParameterColor({ field, value, onChange, onGestureStart, onGestureEnd, disabled, id }: ParameterControlProps<ColorParameterField, string>): React.JSX.Element;
49
+ export declare function ParameterColor({ field, value, onChange, onGestureStart, onGestureEnd, disabled, id, components }: ParameterControlProps<ColorParameterField, string>): React.JSX.Element;
37
50
  /** One number box per component for `vector` fields. */
38
- export declare function ParameterVector({ field, value, onChange, disabled, id }: ParameterControlProps<VectorParameterField, number[]>): React.JSX.Element;
51
+ export declare function ParameterVector({ field, value, onChange, disabled, id, components }: ParameterControlProps<VectorParameterField, number[]>): React.JSX.Element;
39
52
  export interface ParameterImageProps extends ParameterControlProps<ImageParameterField, string> {
40
53
  /** Turns a picked file into a URL (upload it, or `URL.createObjectURL`). Without it there is no file button. */
41
54
  resolveFile?: (file: File) => string | Promise<string>;
42
55
  }
43
56
  /** An image picker: suggested thumbnails, a URL box, an optional file button and a clear button. */
44
57
  export declare function ParameterImage({ field, value, onChange, disabled, id, resolveFile }: ParameterImageProps): React.JSX.Element;
45
- /** A text box (or textarea with `multiline`) that commits on blur or Enter. */
58
+ /** A text box (or textarea with `multiline`) that commits on blur, Tab, or Enter. */
46
59
  export declare function ParameterText({ field, value, onChange, disabled, id }: ParameterControlProps<TextParameterField, string>): React.JSX.Element;
47
60
  export interface KeyframeDiamondProps {
48
61
  state: ParameterKeyState;
@@ -1,5 +1,12 @@
1
1
  import React from 'react';
2
2
  import { type BooleanParameterField, type ChoiceParameterField, type ColorParameterField, type ImageParameterField, type NumberParameterField, type ParameterField, type ParameterKeyState, type ParameterValue, type TextParameterField, type VectorParameterField } from '@pixerate/editor/parameters';
3
+ import { type ParameterComponents } from './controls.js';
4
+ /** Inline theme styles (`--pixerate-parameter-*` tokens with host fallbacks), shared with Svelte through core. */
5
+ export declare const parameterInputStyle: React.CSSProperties;
6
+ export declare const parameterSelectStyle: React.CSSProperties;
7
+ /** Text and border only, so the button classes' `hover:` background still applies. */
8
+ export declare const parameterButtonStyle: React.CSSProperties;
9
+ export declare const parameterRangeStyle: React.CSSProperties;
3
10
  /** Props every field control takes. Controls are controller-free: wire them to anything. */
4
11
  export interface ParameterControlProps<F extends ParameterField, V extends ParameterValue> {
5
12
  field: F;
@@ -11,6 +18,8 @@ export interface ParameterControlProps<F extends ParameterField, V extends Param
11
18
  disabled?: boolean;
12
19
  /** DOM id of the main input (for a `<label htmlFor>`). */
13
20
  id?: string;
21
+ /** Custom host controls (input, slider, select). */
22
+ components?: ParameterComponents;
14
23
  }
15
24
  export declare const parameterInputClass = "h-7 w-full min-w-0 rounded-md border border-input bg-background px-2 text-xs text-foreground tabular-nums focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-primary disabled:cursor-not-allowed disabled:opacity-50";
16
25
  export declare const parameterButtonClass = "inline-flex h-7 items-center justify-center gap-1 rounded-md border border-input bg-background px-2 text-xs text-foreground hover:bg-muted focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-primary disabled:pointer-events-none disabled:opacity-50";
@@ -20,10 +29,14 @@ type CommitInputProps = {
20
29
  onCommit: (value: string, input: HTMLInputElement | HTMLTextAreaElement) => void;
21
30
  multiline?: boolean;
22
31
  } & Omit<React.InputHTMLAttributes<HTMLInputElement> & React.TextareaHTMLAttributes<HTMLTextAreaElement>, 'value' | 'onChange' | 'defaultValue'>;
23
- /** A text box that commits on blur or Enter (Mod+Enter when multiline) and resets on Escape. */
24
- export declare function ParameterCommitInput({ value, onCommit, multiline, className, onKeyDown, ...rest }: CommitInputProps): React.JSX.Element;
32
+ /**
33
+ * A text box that commits on blur, Tab, a native `change` or Enter (Mod+Enter when multiline) and
34
+ * resets on Escape. Text that was already committed (or refused) is not committed again, so the
35
+ * blur that follows Tab or `change` is a no-op.
36
+ */
37
+ export declare function ParameterCommitInput({ value, onCommit, multiline, className, onKeyDown, style, ...rest }: CommitInputProps): React.JSX.Element;
25
38
  /** A number box: type a value (units allowed), or step with the arrow keys (Shift ×10). */
26
- export declare function ParameterNumberInput({ field, value, onChange, disabled, id, 'aria-label': ariaLabel, }: ParameterControlProps<NumberParameterField, number> & {
39
+ export declare function ParameterNumberInput(props: ParameterControlProps<NumberParameterField, number> & {
27
40
  'aria-label'?: string;
28
41
  }): React.JSX.Element;
29
42
  /** A slider plus number box for `number` / `int` fields (number box only for `control: 'input'` or unbounded fields). */
@@ -31,18 +44,18 @@ export declare function ParameterSlider(props: ParameterControlProps<NumberParam
31
44
  /** An on/off switch for `boolean` fields. */
32
45
  export declare function ParameterToggle({ field, value, onChange, disabled, id }: ParameterControlProps<BooleanParameterField, boolean>): React.JSX.Element;
33
46
  /** A dropdown (or segmented buttons with `control: 'segmented'`) for `choice` fields. */
34
- export declare function ParameterSelect({ field, value, onChange, disabled, id }: ParameterControlProps<ChoiceParameterField, string | number>): React.JSX.Element;
47
+ export declare function ParameterSelect(props: ParameterControlProps<ChoiceParameterField, string | number>): React.JSX.Element;
35
48
  /** A colour picker with a hex box and a popup ColorPicker. */
36
- export declare function ParameterColor({ field, value, onChange, onGestureStart, onGestureEnd, disabled, id }: ParameterControlProps<ColorParameterField, string>): React.JSX.Element;
49
+ export declare function ParameterColor({ field, value, onChange, onGestureStart, onGestureEnd, disabled, id, components }: ParameterControlProps<ColorParameterField, string>): React.JSX.Element;
37
50
  /** One number box per component for `vector` fields. */
38
- export declare function ParameterVector({ field, value, onChange, disabled, id }: ParameterControlProps<VectorParameterField, number[]>): React.JSX.Element;
51
+ export declare function ParameterVector({ field, value, onChange, disabled, id, components }: ParameterControlProps<VectorParameterField, number[]>): React.JSX.Element;
39
52
  export interface ParameterImageProps extends ParameterControlProps<ImageParameterField, string> {
40
53
  /** Turns a picked file into a URL (upload it, or `URL.createObjectURL`). Without it there is no file button. */
41
54
  resolveFile?: (file: File) => string | Promise<string>;
42
55
  }
43
56
  /** An image picker: suggested thumbnails, a URL box, an optional file button and a clear button. */
44
57
  export declare function ParameterImage({ field, value, onChange, disabled, id, resolveFile }: ParameterImageProps): React.JSX.Element;
45
- /** A text box (or textarea with `multiline`) that commits on blur or Enter. */
58
+ /** A text box (or textarea with `multiline`) that commits on blur, Tab, or Enter. */
46
59
  export declare function ParameterText({ field, value, onChange, disabled, id }: ParameterControlProps<TextParameterField, string>): React.JSX.Element;
47
60
  export interface KeyframeDiamondProps {
48
61
  state: ParameterKeyState;