From a26aee3543883faf9a5b83832b274604f4f69263 Mon Sep 17 00:00:00 2001 From: Maxim Devaev Date: Wed, 23 Oct 2024 19:27:24 +0300 Subject: partial streamer events --- web/share/js/tools.js | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'web/share/js/tools.js') diff --git a/web/share/js/tools.js b/web/share/js/tools.js index 604f9711..97eb0abf 100644 --- a/web/share/js/tools.js +++ b/web/share/js/tools.js @@ -309,6 +309,14 @@ export var tools = new function() { self.selector.addComment(el, "\u2500".repeat(repeat)); } }, + "hasValue": function(el, value) { + for (let el_op of el.options) { + if (el_op.value === value) { + return true; + } + } + return false; + }, "setValues": function(el, values, empty_title=null) { if (values.constructor == Object) { -- cgit v1.2.3