|
50 | 50 | } |
51 | 51 |
|
52 | 52 | const htmlString = divElement.join(''); |
53 | | - document.getElementById('contributorinfomation').innerHTML = htmlString; |
| 53 | + document.getElementById('contributor-information').innerHTML = htmlString; |
54 | 54 | } |
55 | 55 |
|
56 | 56 | // Load the Repository information into section1 div element. |
|
95 | 95 | } |
96 | 96 | } |
97 | 97 | const htmlString = templateElement.join(''); |
98 | | - document.getElementById('repodetails').innerHTML = htmlString; |
| 98 | + document.getElementById('repo-details').innerHTML = htmlString; |
99 | 99 | } |
100 | 100 |
|
101 | 101 | // Create options under 'SELECT' element which should have HYF Repositories. |
102 | 102 |
|
103 | 103 | function loadSelectionValues(userRepo) { |
104 | 104 | const sortRepoName = []; |
105 | 105 |
|
106 | | - const selectRepo = document.getElementById('selectrepo'); |
| 106 | + const selectRepo = document.getElementById('select-repo'); |
107 | 107 |
|
108 | 108 | // push all the HYP repo names to sort array. |
109 | 109 |
|
|
127 | 127 | selectRepo.appendChild(option); |
128 | 128 | } |
129 | 129 |
|
130 | | - const selectBox = document.getElementById('selectrepo'); |
| 130 | + const selectBox = document.getElementById('select-repo'); |
131 | 131 | const selectedValue = selectBox.options[selectBox.selectedIndex].value; |
132 | 132 |
|
133 | 133 | // Load Repository information for the choose repository name in the select box. |
|
147 | 147 | } else { |
148 | 148 | // Create div element 'select' in document body to hold the label element and list box. |
149 | 149 |
|
150 | | - createAndAppend('div', BodyEl, { id: 'seletcontainer' }); |
151 | | - const select = document.getElementById('seletcontainer'); |
| 150 | + createAndAppend('div', BodyEl, { id: 'select-container' }); |
| 151 | + const select = document.getElementById('select-container'); |
152 | 152 | createAndAppend('LABEL', select, { |
153 | 153 | text: 'HYF Repositories: ', |
154 | 154 | id: 'label', |
155 | 155 | for: 'repo', |
156 | 156 | }); |
157 | | - createAndAppend('select', select, { id: 'selectrepo' }); |
| 157 | + createAndAppend('select', select, { id: 'select-repo' }); |
158 | 158 |
|
159 | 159 | // Create two div elements section1 and section2 under 'Root' div to have |
160 | 160 | // section1 - Repository Information. |
161 | 161 | // section2 - Contributions. |
162 | 162 |
|
163 | | - createAndAppend('div', root, { id: 'repodetails' }); |
164 | | - createAndAppend('div', root, { id: 'contributorinfomation' }); |
| 163 | + createAndAppend('div', root, { id: 'repo-details' }); |
| 164 | + createAndAppend('div', root, { id: 'contributor-information' }); |
165 | 165 |
|
166 | 166 | // Insert section1 before section2 div element under 'root' div. |
167 | | - const newNode = document.getElementById('contributorinfomation'); |
168 | | - const referenceNode = document.querySelector('repodetails'); |
| 167 | + const newNode = document.getElementById('contributor-information'); |
| 168 | + const referenceNode = document.querySelector('repo-details'); |
169 | 169 | root.insertBefore(newNode, referenceNode); |
170 | 170 |
|
171 | 171 | // Insert Select div first in the body before root div. |
|
0 commit comments