Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
bananaturtlesandwich committed Aug 27, 2023
1 parent 156a78e commit e8d3fbf
Show file tree
Hide file tree
Showing 62 changed files with 5,907 additions and 507 deletions.
84 changes: 64 additions & 20 deletions 404.html

Large diffs are not rendered by default.

90 changes: 67 additions & 23 deletions Concepts/Cooking.html

Large diffs are not rendered by default.

90 changes: 67 additions & 23 deletions Concepts/Dummying.html

Large diffs are not rendered by default.

90 changes: 67 additions & 23 deletions Concepts/Files.html

Large diffs are not rendered by default.

90 changes: 67 additions & 23 deletions Concepts/Loading.html

Large diffs are not rendered by default.

94 changes: 69 additions & 25 deletions Concepts/Paks.html

Large diffs are not rendered by default.

86 changes: 65 additions & 21 deletions Home.html

Large diffs are not rendered by default.

90 changes: 67 additions & 23 deletions Resources/Discords.html

Large diffs are not rendered by default.

90 changes: 67 additions & 23 deletions Resources/Resources.html

Large diffs are not rendered by default.

232 changes: 232 additions & 0 deletions Resources/guides.html

Large diffs are not rendered by default.

239 changes: 239 additions & 0 deletions Tools/explorers.html

Large diffs are not rendered by default.

239 changes: 239 additions & 0 deletions Tools/locres.html

Large diffs are not rendered by default.

245 changes: 245 additions & 0 deletions Tools/packers.html

Large diffs are not rendered by default.

245 changes: 245 additions & 0 deletions Tools/uasset.html

Large diffs are not rendered by default.

248 changes: 248 additions & 0 deletions basics/basics.html

Large diffs are not rendered by default.

Binary file added basics/engine/content.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
245 changes: 245 additions & 0 deletions basics/engine/creation.html

Large diffs are not rendered by default.

Binary file added basics/engine/fara.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added basics/engine/settings.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
241 changes: 241 additions & 0 deletions basics/engine/setup.html

Large diffs are not rendered by default.

Binary file added basics/engine/template.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added basics/engine/type.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
239 changes: 239 additions & 0 deletions basics/packing/cooking.html

Large diffs are not rendered by default.

Binary file added basics/packing/drip.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
257 changes: 257 additions & 0 deletions basics/packing/packaging.html

Large diffs are not rendered by default.

Binary file added basics/packing/packaging.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added basics/projectname.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
251 changes: 251 additions & 0 deletions basics/unpacking/fmodel.html

Large diffs are not rendered by default.

Binary file added basics/unpacking/fmodel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
249 changes: 249 additions & 0 deletions basics/unpacking/options.html

Large diffs are not rendered by default.

Binary file added basics/unpacking/umodel-browse.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added basics/unpacking/umodel-popup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added basics/unpacking/umodel-startup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
263 changes: 263 additions & 0 deletions basics/unpacking/umodel.html

Large diffs are not rendered by default.

Binary file added basics/version.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 20 additions & 17 deletions book.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,16 @@
window.onunload = function () { };

// Global variable, shared between modules
function playground_text(playground) {
function playground_text(playground, hidden = true) {
let code_block = playground.querySelector("code");

if (window.ace && code_block.classList.contains("editable")) {
let editor = window.ace.edit(code_block);
return editor.getValue();
} else {
} else if (hidden) {
return code_block.textContent;
} else {
return code_block.innerText;
}
}

Expand Down Expand Up @@ -66,7 +68,7 @@ function playground_text(playground) {
}

// updates the visibility of play button based on `no_run` class and
// used crates vs ones available on http://play.rust-lang.org
// used crates vs ones available on https://play.rust-lang.org
function update_play_button(pre_block, playground_crates) {
var play_button = pre_block.querySelector(".play-button");

Expand Down Expand Up @@ -166,7 +168,6 @@ function playground_text(playground) {
.filter(function (node) {return node.classList.contains("editable"); })
.forEach(function (block) { block.classList.remove('language-rust'); });

Array
code_nodes
.filter(function (node) {return !node.classList.contains("editable"); })
.forEach(function (block) { hljs.highlightBlock(block); });
Expand All @@ -178,7 +179,7 @@ function playground_text(playground) {
// even if highlighting doesn't apply
code_nodes.forEach(function (block) { block.classList.add('hljs'); });

Array.from(document.querySelectorAll("code.language-rust")).forEach(function (block) {
Array.from(document.querySelectorAll("code.hljs")).forEach(function (block) {

var lines = Array.from(block.querySelectorAll('.boring'));
// If no lines were hidden, return
Expand Down Expand Up @@ -300,6 +301,13 @@ function playground_text(playground) {
themePopup.querySelector("button#" + get_theme()).focus();
}

function updateThemeSelected() {
themePopup.querySelectorAll('.theme-selected').forEach(function (el) {
el.classList.remove('theme-selected');
});
themePopup.querySelector("button#" + get_theme()).classList.add('theme-selected');
}

function hideThemes() {
themePopup.style.display = 'none';
themeToggleButton.setAttribute('aria-expanded', false);
Expand Down Expand Up @@ -338,7 +346,7 @@ function playground_text(playground) {
}

setTimeout(function () {
themeColorMetaTag.content = getComputedStyle(document.body).backgroundColor;
themeColorMetaTag.content = getComputedStyle(document.documentElement).backgroundColor;
}, 1);

if (window.ace && window.editors) {
Expand All @@ -355,6 +363,7 @@ function playground_text(playground) {

html.classList.remove(previousTheme);
html.classList.add(theme);
updateThemeSelected();
}

// Set theme
Expand Down Expand Up @@ -542,13 +551,6 @@ function playground_text(playground) {
firstContact = null;
}
}, { passive: true });

// Scroll sidebar to current active section
var activeSection = document.getElementById("sidebar").querySelector(".active");
if (activeSection) {
// https://developer.mozilla.org/en-US/docs/Web/API/Element/scrollIntoView
activeSection.scrollIntoView({ block: 'center' });
}
})();

(function chapterNavigation() {
Expand Down Expand Up @@ -592,7 +594,7 @@ function playground_text(playground) {
text: function (trigger) {
hideTooltip(trigger);
let playground = trigger.closest("pre");
return playground_text(playground);
return playground_text(playground, false);
}
});

Expand Down Expand Up @@ -667,13 +669,14 @@ function playground_text(playground) {
}, { passive: true });
})();
(function controllBorder() {
menu.classList.remove('bordered');
document.addEventListener('scroll', function () {
function updateBorder() {
if (menu.offsetTop === 0) {
menu.classList.remove('bordered');
} else {
menu.classList.add('bordered');
}
}, { passive: true });
}
updateBorder();
document.addEventListener('scroll', updateBorder, { passive: true });
})();
})();
33 changes: 22 additions & 11 deletions css/chrome.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,6 @@

@import 'variables.css';

::-webkit-scrollbar {
background: var(--bg);
}
::-webkit-scrollbar-thumb {
background: var(--scrollbar);
}
html {
scrollbar-color: var(--scrollbar) var(--bg);
}
Expand All @@ -18,6 +12,19 @@ a > .hljs {
color: var(--links);
}

/*
body-container is necessary because mobile browsers don't seem to like
overflow-x on the body tag when there is a <meta name="viewport"> tag.
*/
#body-container {
/*
This is used when the sidebar pushes the body content off the side of
the screen on small screens. Without it, dragging on mobile Safari
will want to reposition the viewport in a weird way.
*/
overflow-x: clip;
}

/* Menu Bar */

#menu-bar,
Expand Down Expand Up @@ -507,6 +514,8 @@ ul#searchresults span.teaser em {
padding: 0;
list-style: none;
display: none;
/* Don't let the children's background extend past the rounded corners. */
overflow: hidden;
}
.theme-popup .default {
color: var(--icons);
Expand All @@ -515,7 +524,7 @@ ul#searchresults span.teaser em {
width: 100%;
border: 0;
margin: 0;
padding: 2px 10px;
padding: 2px 20px;
line-height: 25px;
white-space: nowrap;
text-align: left;
Expand All @@ -527,8 +536,10 @@ ul#searchresults span.teaser em {
.theme-popup .theme:hover {
background-color: var(--theme-hover);
}
.theme-popup .theme:hover:first-child,
.theme-popup .theme:hover:last-child {
border-top-left-radius: inherit;
border-top-right-radius: inherit;

.theme-selected::before {
display: inline-block;
content: "✓";
margin-left: -14px;
width: 14px;
}
17 changes: 15 additions & 2 deletions css/general.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
:root {
/* Browser default font-size is 16px, this way 1 rem = 10px */
font-size: 62.5%;
color-scheme: var(--color-scheme);
}

html {
Expand All @@ -22,8 +23,8 @@ body {
}

code {
font-family: "Source Code Pro", Consolas, "Ubuntu Mono", Menlo, "DejaVu Sans Mono", monospace, monospace !important;
font-size: 0.875em; /* please adjust the ace font size accordingly in editor.js */
font-family: var(--mono-font) !important;
font-size: var(--code-font-size);
}

/* make long words/inline code not x overflow */
Expand Down Expand Up @@ -148,6 +149,18 @@ blockquote {
border-bottom: .1em solid var(--quote-border);
}

kbd {
background-color: var(--table-border-color);
border-radius: 4px;
border: solid 1px var(--theme-popup-border);
box-shadow: inset 0 -1px 0 var(--theme-hover);
display: inline-block;
font-size: var(--code-font-size);
font-family: var(--mono-font);
line-height: 10px;
padding: 4px 5px;
vertical-align: middle;
}

:not(.footnote-definition) + .footnote-definition,
.footnote-definition + :not(.footnote-definition) {
Expand Down
8 changes: 0 additions & 8 deletions css/print.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,6 @@
overflow-y: initial;
}

code {
background-color: #666666;
border-radius: 5px;

/* Force background to be printed in Chrome */
-webkit-print-color-adjust: exact;
}

pre > .buttons {
z-index: 2;
}
Expand Down
12 changes: 12 additions & 0 deletions css/variables.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
--page-padding: 15px;
--content-max-width: 750px;
--menu-bar-height: 50px;
--mono-font: "Source Code Pro", Consolas, "Ubuntu Mono", Menlo, "DejaVu Sans Mono", monospace, monospace;
--code-font-size: 0.875em /* please adjust the ace font size accordingly in editor.js */
}

/* Themes */
Expand Down Expand Up @@ -48,6 +50,8 @@
--searchresults-border-color: #888;
--searchresults-li-bg: #252932;
--search-mark-bg: #e3b171;

--color-scheme: dark;
}

.coal {
Expand Down Expand Up @@ -88,6 +92,8 @@
--searchresults-border-color: #98a3ad;
--searchresults-li-bg: #2b2b2f;
--search-mark-bg: #355c7d;

--color-scheme: dark;
}

.light {
Expand Down Expand Up @@ -128,6 +134,8 @@
--searchresults-border-color: #888;
--searchresults-li-bg: #e4f2fe;
--search-mark-bg: #a2cff5;

--color-scheme: light;
}

.navy {
Expand Down Expand Up @@ -168,6 +176,8 @@
--searchresults-border-color: #5c5c68;
--searchresults-li-bg: #242430;
--search-mark-bg: #a2cff5;

--color-scheme: dark;
}

.rust {
Expand Down Expand Up @@ -208,6 +218,8 @@
--searchresults-border-color: #888;
--searchresults-li-bg: #dec2a2;
--search-mark-bg: #e69f67;

--color-scheme: light;
}

@media (prefers-color-scheme: dark) {
Expand Down
Loading

0 comments on commit e8d3fbf

Please sign in to comment.