-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated the Particles Snow example with depth softening (#7106)
Co-authored-by: Martin Valigursky <mvaligursky@snapchat.com>
- Loading branch information
1 parent
fb5962c
commit 00e2f02
Showing
2 changed files
with
73 additions
and
11 deletions.
There are no files selected for viewing
23 changes: 23 additions & 0 deletions
23
examples/src/examples/graphics/particles-snow.controls.mjs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/** | ||
* @param {import('../../app/components/Example.mjs').ControlOptions} options - The options. | ||
* @returns {JSX.Element} The returned JSX Element. | ||
*/ | ||
export const controls = ({ observer, ReactPCUI, React, jsx, fragment }) => { | ||
const { BindingTwoWay, LabelGroup, Panel, BooleanInput } = ReactPCUI; | ||
return fragment( | ||
jsx( | ||
Panel, | ||
{ headerText: 'Options' }, | ||
jsx( | ||
LabelGroup, | ||
{ text: 'Soft' }, | ||
jsx(BooleanInput, { | ||
type: 'toggle', | ||
binding: new BindingTwoWay(), | ||
link: { observer, path: 'data.soft' }, | ||
value: observer.get('data.soft') | ||
}) | ||
) | ||
) | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters