Change how customizer params are applied (#529)
* Only send customizer params when it's open * Add customizer reset button and have two modes of customizer vs not depending of if the customizer is open. * Remove re-render on customizer open/close in project profile
This commit was merged in pull request #529.
This commit is contained in:
@@ -3,7 +3,7 @@ import { useIdeContext } from 'src/helpers/hooks/useIdeContext'
|
||||
|
||||
export const useRender = () => {
|
||||
const { state, thunkDispatch } = useIdeContext()
|
||||
return () => {
|
||||
return (disableParams = false) => {
|
||||
thunkDispatch((dispatch, getState) => {
|
||||
const state = getState()
|
||||
dispatch({ type: 'setLoading' })
|
||||
@@ -13,7 +13,7 @@ export const useRender = () => {
|
||||
code: state.code,
|
||||
viewerSize: state.viewerSize,
|
||||
camera: state.camera,
|
||||
parameters: state.currentParameters,
|
||||
parameters: disableParams ? {} : state.currentParameters,
|
||||
})
|
||||
})
|
||||
localStorage.setItem(makeCodeStoreKey(state.ideType), state.code)
|
||||
|
||||
Reference in New Issue
Block a user