fix changeSyndicate button hight logic
This commit is contained in:
		
							parent
							
								
									108333e8d5
								
							
						
					
					
						commit
						46fe26a8ff
					
				@ -1078,7 +1078,7 @@
 | 
				
			|||||||
                                    <label class="form-label" for="changeSyndicate" data-loc="cheats_changeSupportedSyndicate"></label>
 | 
					                                    <label class="form-label" for="changeSyndicate" data-loc="cheats_changeSupportedSyndicate"></label>
 | 
				
			||||||
                                    <div class="input-group">
 | 
					                                    <div class="input-group">
 | 
				
			||||||
                                        <select class="form-control" id="changeSyndicate"></select>
 | 
					                                        <select class="form-control" id="changeSyndicate"></select>
 | 
				
			||||||
                                        <button class="btn btn-primary" type="submit" data-loc="cheats_changeButton"></button>
 | 
					                                        <button class="btn btn-secondary" type="submit" data-loc="cheats_changeButton"></button>
 | 
				
			||||||
                                    </div>
 | 
					                                    </div>
 | 
				
			||||||
                                </form>
 | 
					                                </form>
 | 
				
			||||||
                            </div>
 | 
					                            </div>
 | 
				
			||||||
 | 
				
			|||||||
@ -3213,12 +3213,20 @@ document.querySelectorAll("#account-cheats input[type=checkbox]").forEach(elm =>
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
document.querySelectorAll("#account-cheats .input-group").forEach(grp => {
 | 
					document.querySelectorAll("#account-cheats .input-group").forEach(grp => {
 | 
				
			||||||
    const input = grp.querySelector("input");
 | 
					    const input = grp.querySelector("input");
 | 
				
			||||||
 | 
					    const select = grp.querySelector("select");
 | 
				
			||||||
    const btn = grp.querySelector("button");
 | 
					    const btn = grp.querySelector("button");
 | 
				
			||||||
    if (!input || !btn) return;
 | 
					    if (input) {
 | 
				
			||||||
    input.oninput = input.onchange = function () {
 | 
					        input.oninput = input.onchange = function () {
 | 
				
			||||||
        btn.classList.remove("btn-secondary");
 | 
					            btn.classList.remove("btn-secondary");
 | 
				
			||||||
        btn.classList.add("btn-primary");
 | 
					            btn.classList.add("btn-primary");
 | 
				
			||||||
    };
 | 
					        };
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    if (select) {
 | 
				
			||||||
 | 
					        select.oninput = select.onchange = function () {
 | 
				
			||||||
 | 
					            btn.classList.remove("btn-secondary");
 | 
				
			||||||
 | 
					            btn.classList.add("btn-primary");
 | 
				
			||||||
 | 
					        };
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    btn.onclick = function () {
 | 
					    btn.onclick = function () {
 | 
				
			||||||
        btn.classList.remove("btn-primary");
 | 
					        btn.classList.remove("btn-primary");
 | 
				
			||||||
        btn.classList.add("btn-secondary");
 | 
					        btn.classList.add("btn-secondary");
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user