How to call dat.GUI function to instead the default UI?


If I have a UI control like the image above, it is not friendly on mobile. Therefore, how can I call the related function on the other method? I want to create a slide button to call it.


1 Like

My problem also.

Can you please explain this sentence in more detail? I’m not sure it’s clear what you are looking for.

I mean, I mean how can I do this style

In this case I would not use dat.gui at all and develop a custom UI. The idea of using something like dat.gui is to use it out-of-the-box without performing modifications.

1 Like

It’s possible to apply styles to its elements though: Styling Dat.GUI (Layer Example).
But I perfectly agree with @Mugen87

1 Like

Such as:

	gui.add( params, 'maxScale', 1, 30 ).name( 'Decal Size' ).onChange( updateDecalSize );


It is friendly on PC to use mousemove(slide) to change the size. However, it is not friendly on Mobile. Mobile cannot use mousemove(slide), only can be changed by click.

By using CSS is just change the UI style. What I want to do is for mobile-friendly usage.