forked from vcpkg/vcpkg.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
408fc22
commit 16e9a39
Showing
13 changed files
with
354 additions
and
315 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
{ | ||
"trailingComma": "es5", | ||
"tabWidth": 4, | ||
"semi": false, | ||
"singleQuote": true, | ||
|
||
"semi": true, | ||
"singleQuote": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,4 +2,4 @@ | |
"python.linting.pylintEnabled": false, | ||
"python.linting.flake8Enabled": true, | ||
"python.linting.enabled": true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,25 @@ | ||
function copyCodePanel(id) { | ||
let temp = document.getElementById(id) | ||
temp.value = temp.textContent | ||
temp.select() | ||
document.execCommand('copy') | ||
clearSelection() | ||
let temp = document.getElementById(id); | ||
temp.value = temp.textContent; | ||
temp.select(); | ||
document.execCommand('copy'); | ||
clearSelection(); | ||
} | ||
|
||
// remove the highlight from selected text | ||
function clearSelection() { | ||
if (window.getSelection) { | ||
window.getSelection().removeAllRanges() | ||
window.getSelection().removeAllRanges(); | ||
} else if (document.selection) { | ||
document.selection.empty() | ||
document.selection.empty(); | ||
} | ||
} | ||
|
||
// determine what OS the user is on, used to render corresponding package installation code | ||
// default to Unix unless the user is on a Windows device | ||
function detectOS() { | ||
if (/Win/.test(navigator.platform)) { | ||
return 'windows' | ||
return 'windows'; | ||
} | ||
return 'unix' | ||
return 'unix'; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,39 @@ | ||
let os = detectOS() | ||
let os = detectOS(); | ||
|
||
$(document).ready(function () { | ||
clickGetStartedTab(os) //initialized to user's current platform | ||
clickGetStartedTab(os); //initialized to user's current platform | ||
|
||
$('.gs-copy-btn').click(function () { | ||
var step = $(this).attr('id') | ||
var step = $(this).attr('id'); | ||
if (step === 'step5') { | ||
// the code for windows and unix is shared in this case | ||
copyCodePanel('all-' + step) | ||
} else if (os === 'windows') copyCodePanel('windows-' + step) | ||
else copyCodePanel('unix-' + step) | ||
}) | ||
copyCodePanel('all-' + step); | ||
} else if (os === 'windows') copyCodePanel('windows-' + step); | ||
else copyCodePanel('unix-' + step); | ||
}); | ||
|
||
$('.gs-tab-btn').click(function () { | ||
var id = $(this).attr('id') | ||
clickGetStartedTab(id.substring(7)) | ||
}) | ||
}) | ||
var id = $(this).attr('id'); | ||
clickGetStartedTab(id.substring(7)); | ||
}); | ||
}); | ||
|
||
function clickGetStartedTab(platform) { | ||
os = platform | ||
let elems = document.getElementsByClassName(os) | ||
os = platform; | ||
let elems = document.getElementsByClassName(os); | ||
|
||
$('.show').removeClass('show') | ||
$('.selected').removeClass('selected') | ||
$('.show').removeClass('show'); | ||
$('.selected').removeClass('selected'); | ||
|
||
document.getElementById('gs-btn-' + os).classList.add('selected') | ||
document.getElementById('gs-btn-' + os).classList.add('selected'); | ||
for (e of elems) { | ||
e.classList.add('show') | ||
e.classList.add('show'); | ||
} | ||
|
||
if (os === 'linux' || os === 'mac') { | ||
elems = document.getElementsByClassName('unix') | ||
elems = document.getElementsByClassName('unix'); | ||
for (e of elems) { | ||
e.classList.add('show') | ||
e.classList.add('show'); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,13 @@ | ||
function start_email() { | ||
window.location.href = 'mailto:[email protected]' | ||
window.location.href = 'mailto:[email protected]'; | ||
} | ||
|
||
function checkEnter(e) { | ||
if (e.keyCode === 13) { | ||
// redirect query to packages.html | ||
window.location.href = | ||
'packages.html?query=' + (<HTMLInputElement>document.getElementById('idx-search')).value | ||
'packages.html?query=' + | ||
(<HTMLInputElement>document.getElementById('idx-search')).value; | ||
} | ||
return false | ||
return false; | ||
} |
Oops, something went wrong.