Skip to content

Releases: pmndrs/leva

@leva-ui/[email protected]

15 Apr 15:02
2487e5e
Compare
Choose a tag to compare

Patch Changes

@leva-ui/[email protected]

15 Apr 15:02
2487e5e
Compare
Choose a tag to compare

Patch Changes

[email protected]

10 Apr 11:36
c9696b5
Compare
Choose a tag to compare

Patch Changes

  • 50e8096: fix: sanitize step should behave better.
    improvement: expand panel when filter changes.

  • 09a1a38: Allow specifying the explicit input type via the type option. This is handy when you want to prevent your string value being casted to a color or number.

    import { LevaInputs, useControls } from 'leva'
    
    useControls({
      color: {
        type: LevaInputs.STRING,
        value: '#f00',
      },
      number: {
        type: LevaInputs.STRING,
        value: '1',
      },
    })

[email protected]

06 Apr 09:56
d87f5b2
Compare
Choose a tag to compare

Patch Changes

  • 7edbb69: chore: update dependencies.

[email protected]

06 Apr 08:06
f46836d
Compare
Choose a tag to compare

Patch Changes

  • 34281d7: Add new value option transient. This allows opting out of the transient mode when having a onChange handler invoked.

    const data = useControls({
      color: {
        value: '#7c3d3d',
        onChange: value => {
          console.log(value)
        },
        transient: false,
      },
    })
    
    console.log(data) // { color: '#7c3d3d' }
    const data = useControls({
      color: {
        value: '#7c3d3d',
        onChange: value => {
          console.log(value)
        },
        transient: true,
      },
    })
    
    console.log(data) // {}

    This is handy if you want to use the onChange handler for triggering a save on a remote server, while still triggering a re-render with the value.

@leva-ui/[email protected]

06 Apr 09:56
d87f5b2
Compare
Choose a tag to compare

Patch Changes

[email protected]

03 Apr 15:51
57c5188
Compare
Choose a tag to compare

Patch Changes

  • 09ac7b1: chore: remove clipboard-polyfill dependency.

[email protected]

03 Apr 14:30
5e67844
Compare
Choose a tag to compare

Patch Changes

  • 50d850a: BREAKING CHANGE: Replace hideTitleBar with titleBar option.

    For hiding the title bar the usages of <Leva hideTitleBar /> must be replaced with <Leva titleBar={false} />.

    It is now possible to overwrite the six dots rendered as the title by default by providing a title option to the titleBar property.

    <Leva
      titleBar={{
        title: 'Some Title',
      }}
    />

    Its is now possible to disable dragging of the panel via the drag option to the titleBar property.

    <Leva
      titleBar={{
        drag: false,
      }}
    />

    It is now possible to enable or disable filtering of the panel values via the filter option on the titleBar property.

    <Leva
      titleBar={{
        filter: true,
      }}
    />

[email protected]

29 Mar 10:35
a63301d
Compare
Choose a tag to compare

Patch Changes

  • e0fdefc: types: fix beautifier union type.

[email protected]

28 Mar 20:40
3d0fbd5
Compare
Choose a tag to compare

Patch Changes

  • a7f9bf1: types: don't use union type when not using objects as plugin function args.