-
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.
[android] Add variables 2.7.0 documents
- Loading branch information
Showing
100 changed files
with
5,129 additions
and
154 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<!DOCTYPE HTML> | ||
<html lang="en-US"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta http-equiv="refresh" content="0; url=variables/index.html"> | ||
<script type="text/javascript"> | ||
window.location.href = "variables/index.html" | ||
</script> | ||
<title>Documentation</title> | ||
</head> | ||
<body> | ||
If you are not redirected automatically, follow <a href="variables/index.html">this link</a>. | ||
</body> | ||
</html> |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<div class="sideMenuPart" id="nav-submenu" pageId="////PointingToDeclaration//1901061934"> | ||
<div class="overview"><a href="variables/index.html"><span>variables</span></a><span class="navButton pull-right" onclick="document.getElementById("nav-submenu").classList.toggle("hidden");"><span class="navButtonContent"></span></span></div> | ||
<div class="sideMenuPart" id="nav-submenu-0" pageId="io.karte.android.variables////PointingToDeclaration//-1508386440"> | ||
<div class="overview"><a href="variables/io.karte.android.variables/index.html"><span>io.</span><wbr></wbr><span>karte.</span><wbr></wbr><span>android.</span><wbr></wbr><span>variables</span></a><span class="navButton pull-right" onclick="document.getElementById("nav-submenu-0").classList.toggle("hidden");"><span class="navButtonContent"></span></span></div> | ||
<div class="sideMenuPart" id="nav-submenu-0-0" pageId="io.karte.android.variables/FetchCompletion///PointingToDeclaration//-1508386440"> | ||
<div class="overview"><a href="variables/io.karte.android.variables/-fetch-completion/index.html"><span>Fetch</span><wbr></wbr><span>Completion</span></a></div> | ||
</div> | ||
<div class="sideMenuPart" id="nav-submenu-0-1" pageId="io.karte.android.variables/Variable///PointingToDeclaration//-1508386440"> | ||
<div class="overview"><a href="variables/io.karte.android.variables/-variable/index.html"><span>Variable</span></a></div> | ||
</div> | ||
<div class="sideMenuPart" id="nav-submenu-0-2" pageId="io.karte.android.variables/Variables///PointingToDeclaration//-1508386440"> | ||
<div class="overview"><a href="variables/io.karte.android.variables/-variables/index.html"><span>Variables</span></a></div> | ||
</div> | ||
<div class="sideMenuPart" id="nav-submenu-0-3" pageId="io.karte.android.variables/VariablesPredicate///PointingToDeclaration//-1508386440"> | ||
<div class="overview"><a href="variables/io.karte.android.variables/-variables-predicate/index.html"><span>Variables</span><wbr></wbr><span>Predicate</span></a></div> | ||
</div> | ||
</div> | ||
</div> | ||
|
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 |
---|---|---|
@@ -0,0 +1,52 @@ | ||
window.addEventListener('load', () => { | ||
document.querySelectorAll('span.copy-icon').forEach(element => { | ||
element.addEventListener('click', (el) => copyElementsContentToClipboard(element)); | ||
}) | ||
|
||
document.querySelectorAll('span.anchor-icon').forEach(element => { | ||
element.addEventListener('click', (el) => { | ||
if(element.hasAttribute('pointing-to')){ | ||
const location = hrefWithoutCurrentlyUsedAnchor() + '#' + element.getAttribute('pointing-to') | ||
copyTextToClipboard(element, location) | ||
} | ||
}); | ||
}) | ||
}) | ||
|
||
const copyElementsContentToClipboard = (element) => { | ||
const selection = window.getSelection(); | ||
const range = document.createRange(); | ||
range.selectNodeContents(element.parentNode.parentNode); | ||
selection.removeAllRanges(); | ||
selection.addRange(range); | ||
|
||
copyAndShowPopup(element, () => selection.removeAllRanges()) | ||
} | ||
|
||
const copyTextToClipboard = (element, text) => { | ||
var textarea = document.createElement("textarea"); | ||
textarea.textContent = text; | ||
textarea.style.position = "fixed"; | ||
document.body.appendChild(textarea); | ||
textarea.select(); | ||
|
||
copyAndShowPopup(element, () => document.body.removeChild(textarea)) | ||
} | ||
|
||
const copyAndShowPopup = (element, after) => { | ||
try { | ||
document.execCommand('copy'); | ||
element.nextElementSibling.classList.add('active-popup'); | ||
setTimeout(() => { | ||
element.nextElementSibling.classList.remove('active-popup'); | ||
}, 1200); | ||
} catch (e) { | ||
console.error('Failed to write to clipboard:', e) | ||
} | ||
finally { | ||
if(after) after() | ||
} | ||
} | ||
|
||
const hrefWithoutCurrentlyUsedAnchor = () => window.location.href.split('#')[0] | ||
|
Large diffs are not rendered by default.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,64 @@ | ||
navigationPageText = fetch(pathToRoot + "navigation.html").then(response => response.text()) | ||
|
||
displayNavigationFromPage = () => { | ||
navigationPageText.then(data => { | ||
document.getElementById("sideMenu").innerHTML = data; | ||
}).then(() => { | ||
document.querySelectorAll(".overview > a").forEach(link => { | ||
link.setAttribute("href", pathToRoot + link.getAttribute("href")); | ||
}) | ||
}).then(() => { | ||
document.querySelectorAll(".sideMenuPart").forEach(nav => { | ||
if (!nav.classList.contains("hidden")) | ||
nav.classList.add("hidden") | ||
}) | ||
}).then(() => { | ||
revealNavigationForCurrentPage() | ||
}) | ||
document.querySelectorAll('.footer a[href^="#"]').forEach(anchor => { | ||
anchor.addEventListener('click', function (e) { | ||
e.preventDefault(); | ||
document.querySelector(this.getAttribute('href')).scrollIntoView({ | ||
behavior: 'smooth' | ||
}); | ||
}); | ||
}); | ||
} | ||
|
||
revealNavigationForCurrentPage = () => { | ||
let pageId = document.getElementById("content").attributes["pageIds"].value.toString(); | ||
let parts = document.querySelectorAll(".sideMenuPart"); | ||
let found = 0; | ||
do { | ||
parts.forEach(part => { | ||
if (part.attributes['pageId'].value.indexOf(pageId) !== -1 && found === 0) { | ||
found = 1; | ||
if (part.classList.contains("hidden")) { | ||
part.classList.remove("hidden"); | ||
part.setAttribute('data-active', ""); | ||
} | ||
revealParents(part) | ||
} | ||
}); | ||
pageId = pageId.substring(0, pageId.lastIndexOf("/")) | ||
} while (pageId.indexOf("/") !== -1 && found === 0) | ||
}; | ||
revealParents = (part) => { | ||
if (part.classList.contains("sideMenuPart")) { | ||
if (part.classList.contains("hidden")) | ||
part.classList.remove("hidden"); | ||
revealParents(part.parentNode) | ||
} | ||
}; | ||
|
||
/* | ||
This is a work-around for safari being IE of our times. | ||
It doesn't fire a DOMContentLoaded, presumabely because eventListener is added after it wants to do it | ||
*/ | ||
if (document.readyState == 'loading') { | ||
window.addEventListener('DOMContentLoaded', () => { | ||
displayNavigationFromPage() | ||
}) | ||
} else { | ||
displayNavigationFromPage() | ||
} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
[{"name":"variables","description":null,"location":"variables/index.html","searchKeys":["variables"]},{"name":"io.karte.android.variables","description":null,"location":"variables/io.karte.android.variables/index.html","searchKeys":["io.karte.android.variables"]},{"name":"FetchCompletion","description":null,"location":"variables/io.karte.android.variables/-fetch-completion/index.html","searchKeys":["FetchCompletion"]},{"name":"Variable","description":null,"location":"variables/io.karte.android.variables/-variable/index.html","searchKeys":["Variable"]},{"name":"Variables","description":null,"location":"variables/io.karte.android.variables/-variables/index.html","searchKeys":["Variables"]},{"name":"VariablesPredicate","description":null,"location":"variables/io.karte.android.variables/-variables-predicate/index.html","searchKeys":["VariablesPredicate"]}] |
Oops, something went wrong.