123 lines
4.8 KiB
HTML
123 lines
4.8 KiB
HTML
![]() |
<!DOCTYPE html>
|
||
|
<html lang="en">
|
||
|
|
||
|
<head>
|
||
|
<meta charset="UTF-8">
|
||
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||
|
<title>SPT-AKI</title>
|
||
|
<link rel="stylesheet" href="./assets/css/style.css">
|
||
|
<link rel="stylesheet" href="./assets/css/prism.css">
|
||
|
</head>
|
||
|
|
||
|
<body>
|
||
|
<header aki-toolbar>
|
||
|
<a class="left" href="../../index.html">
|
||
|
<img class="logo" src="./assets/img/logo.png">
|
||
|
<span class="title text2">
|
||
|
<span>SPT-AKI - Docs</span>
|
||
|
</span>
|
||
|
</a>
|
||
|
|
||
|
<nav class="text2 right dropdown">
|
||
|
<div class="dropdown-button">...</div>
|
||
|
<div class="dropdown-content">
|
||
|
<a href="https://www.sp-tarkov.com">Website</a>
|
||
|
<a href="https://mods.sp-tarkov.com">Workshop</a>
|
||
|
<a href="https://dev.sp-tarkov.com">Gitea</a>
|
||
|
<!--<a href="#">Development</a>-->
|
||
|
</div>
|
||
|
</nav>
|
||
|
</header>
|
||
|
|
||
|
<main>
|
||
|
<aside></aside>
|
||
|
<div id="router-outlet" class="doc-typography">
|
||
|
<div class="text2" style="align-items:center;display:flex;height:100%;justify-content: center;">
|
||
|
<div aki-card>
|
||
|
Select a guide on the left to get started.
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
</main>
|
||
|
|
||
|
<script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"></script>
|
||
|
<script src="./assets/js/prism.js"></script>
|
||
|
<script src="./assets/js/akiNavigatorRouter.js"></script>
|
||
|
<script>
|
||
|
const routes = {
|
||
|
"SPT-AKI": {
|
||
|
"FAQ": "faq.md",
|
||
|
"Installing a release": "sp-tarkov/install_sp-tarkov.md",
|
||
|
"About":"about.md"
|
||
|
},
|
||
|
"Tutorials":{
|
||
|
"Create a mod on SP-Tarkov": "tutorials/create_a_mod.md",
|
||
|
"How to report a bug": "tutorials/bug-report.md",
|
||
|
"Editing differents things in my player profile": "tutorials/edit_the_player_profile.md",
|
||
|
"Change some traders behaviour": "tutorials/edit_traders_values.md",
|
||
|
"How to customize maps values": "tutorials/edit_location_values.md",
|
||
|
"Change global values of the server": "tutorials/edit_globals_values.md",
|
||
|
"Edit weapons textures": "tutorials/edit_weapons_textures.md",
|
||
|
"Edit weapons textures with photoshop": "tutorials/photoshop_texture_editing.md",
|
||
|
"Customize weather presets": "tutorials/create_weather.md",
|
||
|
"Add new bundles to the game": "tutorials/add_new_bundles.md"
|
||
|
},
|
||
|
"Modding":{
|
||
|
"All items stats resources":"resources/itemsStats_resources.md",
|
||
|
"All locations resources":"resources/locations_resources.md",
|
||
|
"All player profile resources":"resources/playerProfile_resources.md",
|
||
|
"All quest resources":"resources/quests_resources.md",
|
||
|
"All other resources":"resources/other_resources.md"
|
||
|
},
|
||
|
"DEBUG": {
|
||
|
"** Markdown Demo": "demo.md",
|
||
|
},
|
||
|
};
|
||
|
|
||
|
/**
|
||
|
* Populates the <aside> element in the page
|
||
|
* based on the `routes` object content.
|
||
|
*/
|
||
|
function populateNav() {
|
||
|
Object.entries(routes).forEach(([key, node]) => {
|
||
|
const sectionTitle = document.createElement('div');
|
||
|
sectionTitle.classList.add('subheader');
|
||
|
sectionTitle.innerText = key;
|
||
|
|
||
|
const sectionList = document.createElement('ul');
|
||
|
// sectionTitle.appendChild(sectionList);
|
||
|
|
||
|
Object.entries(node).forEach(([k, v]) => {
|
||
|
const listItem = document.createElement('li');
|
||
|
const link = document.createElement('a');
|
||
|
link.innerText = k;
|
||
|
link.href = `#${v}`;
|
||
|
|
||
|
listItem.appendChild(link);
|
||
|
// listItem.setAttribute('link', v);
|
||
|
// listItem.innerText = k;
|
||
|
|
||
|
// The nav binding
|
||
|
listItem.addEventListener('click', e => {
|
||
|
if (e.target && e.target.hasAttribute('link')) {
|
||
|
window.location.hash = e.target.getAttribute('link');
|
||
|
}
|
||
|
});
|
||
|
|
||
|
sectionList.appendChild(listItem);
|
||
|
});
|
||
|
|
||
|
const divider = document.createElement('hr');
|
||
|
divider.setAttribute('aki-divider', '');
|
||
|
|
||
|
const nav = document.querySelector('aside');
|
||
|
nav.appendChild(sectionTitle);
|
||
|
nav.appendChild(sectionList);
|
||
|
nav.appendChild(divider);
|
||
|
});
|
||
|
}
|
||
|
|
||
|
populateNav();
|
||
|
const akiNavigatorRouter = new AkiNavigatorRouter(routes);
|
||
|
</script>
|
||
|
</body>
|