@@ -53,30 +53,30 @@ export function substituteRepoOpenWithUrl(tmpl: string, url: string): string {
5353function initCloneSchemeUrlSelection ( parent : Element ) {
5454 const elCloneUrlInput = parent . querySelector < HTMLInputElement > ( '.repo-clone-url' ) ;
5555
56- const tabHTTPS = parent . querySelector ( '.repo-clone-https' ) ;
57- const tabSSH = parent . querySelector ( '.repo-clone-ssh' ) ;
56+ const tabHttps = parent . querySelector ( '.repo-clone-https' ) ;
57+ const tabSsh = parent . querySelector ( '.repo-clone-ssh' ) ;
5858 const tabTea = parent . querySelector ( '.repo-clone-tea' ) ;
5959 const updateClonePanelUi = function ( ) {
6060 const scheme = localStorage . getItem ( 'repo-clone-protocol' ) || 'https' ;
61- const isHTTPS = scheme === 'https' && Boolean ( tabHTTPS ) || scheme !== 'https' && ! tabHTTPS ;
62- const isSSH = scheme === 'ssh' && Boolean ( tabSSH ) || scheme !== 'ssh' && ! tabSSH ;
61+ const isHttps = scheme === 'https' && Boolean ( tabHttps ) || scheme !== 'https' && ! tabHttps ;
62+ const isSsh = scheme === 'ssh' && Boolean ( tabSsh ) || scheme !== 'ssh' && ! tabSsh ;
6363 const isTea = scheme === 'tea' && Boolean ( tabTea ) || scheme !== 'tea' && ! tabTea ;
64- if ( tabHTTPS ) {
65- tabHTTPS . textContent = window . origin . split ( ':' ) [ 0 ] . toUpperCase ( ) ; // show "HTTP" or "HTTPS"
66- tabHTTPS . classList . toggle ( 'active' , isHTTPS ) ;
64+ if ( tabHttps ) {
65+ tabHttps . textContent = window . origin . split ( ':' ) [ 0 ] . toUpperCase ( ) ; // show "HTTP" or "HTTPS"
66+ tabHttps . classList . toggle ( 'active' , isHttps ) ;
6767 }
68- if ( tabSSH ) {
69- tabSSH . classList . toggle ( 'active' , isSSH ) ;
68+ if ( tabSsh ) {
69+ tabSsh . classList . toggle ( 'active' , isSsh ) ;
7070 }
7171 if ( tabTea ) {
7272 tabTea . classList . toggle ( 'active' , isTea ) ;
7373 }
7474
7575 let tab : Element ;
76- if ( isHTTPS ) {
77- tab = tabHTTPS ;
78- } else if ( isSSH ) {
79- tab = tabSSH ;
76+ if ( isHttps ) {
77+ tab = tabHttps ;
78+ } else if ( isSsh ) {
79+ tab = tabSsh ;
8080 } else if ( isTea ) {
8181 tab = tabTea ;
8282 }
@@ -97,12 +97,12 @@ function initCloneSchemeUrlSelection(parent: Element) {
9797 } ;
9898
9999 updateClonePanelUi ( ) ;
100- // tabSSH or tabHttps might not both exist, eg: guest view, or one is disabled by the server
101- tabHTTPS ?. addEventListener ( 'click' , ( ) => {
100+ // tabSsh or tabHttps might not both exist, eg: guest view, or one is disabled by the server
101+ tabHttps ?. addEventListener ( 'click' , ( ) => {
102102 localStorage . setItem ( 'repo-clone-protocol' , 'https' ) ;
103103 updateClonePanelUi ( ) ;
104104 } ) ;
105- tabSSH ?. addEventListener ( 'click' , ( ) => {
105+ tabSsh ?. addEventListener ( 'click' , ( ) => {
106106 localStorage . setItem ( 'repo-clone-protocol' , 'ssh' ) ;
107107 updateClonePanelUi ( ) ;
108108 } ) ;
0 commit comments