mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 02:44:02 +00:00
style(ui): format shortcut and parameter components
This commit is contained in:
1 parent
7a5f615d55
commit
c9be877f9c
5 files changed
+262
-72
No files matched your search
@@ -7,12 +7,16 @@
|
||||
* @param {Document} [options.documentRef] Document used to construct rows.
|
||||
* @returns {{render: Function, clear: Function, destroy: Function}}
|
||||
*/
|
||||
export function createStyleParameters({ container, documentRef = container.ownerDocument }) {
|
||||
export function createStyleParameters({
|
||||
container,
|
||||
documentRef = container.ownerDocument,
|
||||
}) {
|
||||
let listeners = [];
|
||||
let destroyed = false;
|
||||
const clear = () => {
|
||||
if (destroyed) return;
|
||||
for (const [slider, listener] of listeners) slider.removeEventListener('input', listener);
|
||||
for (const [slider, listener] of listeners)
|
||||
slider.removeEventListener('input', listener);
|
||||
listeners = [];
|
||||
container.replaceChildren();
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user