From 86c6cd3cc099d2480932ede03c12cea01e625c94 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Sun, 26 Apr 2026 21:56:28 +0000
Subject: [PATCH] =Requiring files based on Site class settings

---
 assets/js/concise/UtilityFunctions.js |   19 +++++++++++++++++--
 1 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/assets/js/concise/UtilityFunctions.js b/assets/js/concise/UtilityFunctions.js
index 6772ebf..efbf22f 100644
--- a/assets/js/concise/UtilityFunctions.js
+++ b/assets/js/concise/UtilityFunctions.js
@@ -413,7 +413,7 @@
 	}
 }
 
-window.prefixInput = function(input, prefix, wrapper = null, replace = false) {
+window.prefixInput = function(input, prefix, wrapper = null, replace = false, name = false) {
 	if (!input) {
 		console.warn('prefixInput called with null/undefined input');
 		return;
@@ -444,7 +444,9 @@
 	}
 
 	input.id = newId;
-	input.name = newId;
+	if (name) {
+		input.name = newId;
+	}
 }
 
 /**
@@ -893,6 +895,9 @@
 	return ui;
 }
 
+window.sleep = async function (ms = 50) {
+	return new Promise(resolve => setTimeout(resolve, ms));
+};
 
 class DebouncedActions {
 	constructor() {
@@ -995,3 +1000,13 @@
 updateMaxScroll();
 updateScrollProgress(lastY);
 
+
+
+window.decodeHTMLEntities = function(text) {
+	if (!window.decodeHelper) {
+		window.decodeHelper = document.createElement('textarea');
+	}
+
+	window.decodeHelper.innerHTML = text;
+	return window.decodeHelper.value;
+}

--
Gitblit v1.10.0