@@ -149,7 +149,7 @@ case "CHANGE_PIN":
149149 <label class="absolute left-5 top-2.5 text-gray-500 dark:text-gray-400 text-xs font-semibold uppercase tracking-wider transition-all peer-placeholder-shown:top-4 peer-placeholder-shown:text-sm peer-placeholder-shown:normal-case peer-placeholder-shown:tracking-normal peer-focus:top-2.5 peer-focus:text-xs peer-focus:uppercase peer-focus:tracking-wider peer-focus:text-cyan-500">New PIN</label>
150150 <button type="button" id="toggleIcon" onclick="togglePin()" class="absolute right-5 top-1/2 -translate-y-1/2 text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 text-xl">👁️</button>
151151 ` ;
152- button . addEventListener ( onclick , submitRequest ( ' CHANGE_PIN' ) ) ;
152+ button . addEventListener ( "click" , ( ) => submitRequest ( " CHANGE_PIN" ) ) ;
153153
154154 break ;
155155
@@ -158,8 +158,8 @@ case "CHANGE_ACCOUNT_NAME":
158158 <input type="text" id="new_name" class="peer w-full bg-gray-50 dark:bg-gray-800 text-gray-900 dark:text-white border border-gray-300 dark:border-gray-600 rounded-2xl px-5 pt-7 pb-3 focus:ring-2 focus:ring-cyan-500 focus:border-transparent outline-none transition-all font-medium">
159159 <label class="absolute left-5 top-2.5 text-gray-500 dark:text-gray-400 text-xs font-semibold uppercase tracking-wider transition-all peer-placeholder-shown:top-4 peer-placeholder-shown:text-sm peer-placeholder-shown:normal-case peer-placeholder-shown:tracking-normal peer-focus:top-2.5 peer-focus:text-xs peer-focus:uppercase peer-focus:tracking-wider peer-focus:text-cyan-500">New Account Name</label>
160160 ` ;
161- button . addEventListener ( onclick , submitRequest ( ' CHANGE_ACCOUNT_NAME' ) ) ;
162-
161+ button . addEventListener ( "click" , ( ) => submitRequest ( " CHANGE_ACCOUNT_NAME" ) ) ;
162+
163163 break ;
164164
165165//NOTE : //h future request query implementation :
@@ -224,9 +224,9 @@ case "CHANGE_ACCOUNT_NAME":
224224}
225225
226226async function submitRequest ( query_type ) {
227- // document.getElementById("dynamic_submit_button").disabled = true;
228- // document.getElementById("btnText").textContent = "Logging in...";
229- // document.getElementById("spinner").classList.remove("hidden");
227+ document . getElementById ( "dynamic_submit_button" ) . disabled = true ;
228+ document . getElementById ( "btnText" ) . textContent = "Logging in..." ;
229+ document . getElementById ( "spinner" ) . classList . remove ( "hidden" ) ;
230230const fields = document . querySelectorAll ( "#dynamic_form_fields input, #dynamic_form_fields textarea" ) ;
231231
232232const payload = { } ;
0 commit comments