@@ -285,34 +285,34 @@ <h3>Advanced Users</h3>
285
285
</ div >
286
286
< script >
287
287
document . querySelectorAll ( 'div.radios input' ) . forEach ( ( radio ) =>
288
- radio . addEventListener ( "change" , ( ) => {
289
- const button = document . querySelector ( "esp-web-install-button" ) ;
290
- var protocol = document . querySelector ( 'input[name="protocol"]:checked' ) . value ;
291
- var hardware = document . querySelector ( 'input[name="hardware"]:checked' ) . value ;
292
-
293
- if ( protocol === "dry_contact" ) {
294
- alert ( "Dry contact support is coming soon." ) ;
295
- document . querySelector ( 'input[name="protocol"][value="secplusv2"]' ) . checked = true ;
296
- return ;
297
- document . querySelector ( "#wiring_diagram" ) . src = "wiring_diagrams/dry_contact_diagram.png" ;
298
- } else {
299
- document . querySelector ( "#wiring_diagram" ) . src = "wiring_diagrams/secplus_diagram.png" ;
300
- }
301
-
302
- if ( protocol !== "sec2" && hardware === "v2.0" ) {
303
- alert ( "ratgdo version 2.0 only works with Security + 2.0" ) ;
304
- document . querySelector ( 'input[name="protocol"][value="secplusv2"]' ) . checked = true ;
305
- return ;
306
- }
307
-
308
- if ( protocol === "secplusv2" ) {
309
- protocol = "" ;
310
- } else {
311
- protocol = `_${ protocol } ` ;
312
- }
313
-
314
- button . manifest = `${ hardware } ${ protocol } -manifest.json` ;
315
- } )
288
+ radio . addEventListener ( "change" , ( ) => {
289
+ const button = document . querySelector ( "esp-web-install-button" ) ;
290
+ var protocol = document . querySelector ( 'input[name="protocol"]:checked' ) . value ;
291
+ var hardware = document . querySelector ( 'input[name="hardware"]:checked' ) . value ;
292
+
293
+ if ( protocol === "dry_contact" ) {
294
+ alert ( "Dry contact support is coming soon." ) ;
295
+ document . querySelector ( 'input[name="protocol"][value="secplusv2"]' ) . checked = true ;
296
+ return ;
297
+ document . querySelector ( "#wiring_diagram" ) . src = "wiring_diagrams/dry_contact_diagram.png" ;
298
+ } else {
299
+ document . querySelector ( "#wiring_diagram" ) . src = "wiring_diagrams/secplus_diagram.png" ;
300
+ }
301
+
302
+ if ( protocol !== "sec2" && hardware === "v2.0" ) {
303
+ alert ( "ratgdo version 2.0 only works with Security + 2.0" ) ;
304
+ document . querySelector ( 'input[name="protocol"][value="secplusv2"]' ) . checked = true ;
305
+ return ;
306
+ }
307
+
308
+ if ( protocol === "secplusv2" ) {
309
+ protocol = "" ;
310
+ } else {
311
+ protocol = `_${ protocol } ` ;
312
+ }
313
+
314
+ button . manifest = `${ hardware } ${ protocol } -manifest.json` ;
315
+ } )
316
316
) ;
317
317
318
318
document
0 commit comments