File tree Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Original file line number Diff line number Diff line change 1616 < header class ="flex-row ">
1717 < h1 class ="flex-child-grow "> ILR File Creator</ h1 >
1818 <!-- TODO: read version number from schemafile -->
19- < p class ="flex-child-static "> 2526.1.38.0</ p >
19+ < p id =" version-number " class ="flex-child-static "> 2526.1.38.0</ p >
2020 </ header >
2121
2222 < main >
Original file line number Diff line number Diff line change @@ -8,6 +8,24 @@ function logToMain(message) {
88const form = document . getElementById ( "uploadForm" ) ;
99const output = document . getElementById ( "output" ) ;
1010
11+ /* Current Schema Version
12+ Change this when the government updates its schema.
13+ It should then update the UI
14+ */
15+ const schemaVersion = "2526.1.38.0" ;
16+
17+ function setDefaultReleaseVersion ( ) {
18+ const versionElement = document . getElementById ( "version-number" ) ;
19+ const releaseVersionInput = document . getElementById ( "releaseVersion" ) ;
20+
21+ if ( versionElement && releaseVersionInput ) {
22+ versionElement . value = schemaVersion . trim ( ) ;
23+ releaseVersionInput . value = schemaVersion . trim ( ) ;
24+ }
25+ }
26+
27+ document . addEventListener ( "DOMContentLoaded" , setDefaultReleaseVersion ) ;
28+
1129ipcRenderer . on ( "show-alert" , ( event , message ) => {
1230 alert ( message ) ;
1331} ) ;
You can’t perform that action at this time.
0 commit comments