1import { Controller } from "@hotwired/stimulus" 2 3// Cuando el checkbox "DÃa operativo completo" está activo, deshabilita los 4// campos de hora/duración (el server calcula el rango usando operational_range_for). 5export default class extends Controller { 6 static targets = ["checkbox", "timeField", "timeFieldWrapper"] 7 8 connect() { 9 this._apply() 10 } 11 12 toggle() { 13 this._apply() 14 } 15 16 _apply() { 17 const on = this.checkboxTarget.checked 18 this.timeFieldTargets.forEach(el => { 19 el.disabled = on 20 el.required = !on 21 if (on) { 22 el.classList.add("opacity-50", "cursor-not-allowed") 23 } else { 24 el.classList.remove("opacity-50", "cursor-not-allowed") 25 } 26 }) 27 } 28}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.