mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-03 03:42:17 +00:00
commit
1e4cf52fd4
4 changed files with 38 additions and 4 deletions
|
@ -468,6 +468,12 @@ pre {
|
||||||
line-height: 15px;
|
line-height: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.builtins-tip {
|
||||||
|
padding: 1em;
|
||||||
|
font-style: italic;
|
||||||
|
line-height: 1.3em;
|
||||||
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
:root {
|
:root {
|
||||||
--body-bg-color: var(--purple-8);
|
--body-bg-color: var(--purple-8);
|
||||||
|
|
|
@ -275,7 +275,7 @@ pub const ANSI_STYLE_CODES: StyleCodes = StyleCodes {
|
||||||
|
|
||||||
macro_rules! html_color {
|
macro_rules! html_color {
|
||||||
($name: expr) => {
|
($name: expr) => {
|
||||||
concat!("<span style='color: ", $name, "'>")
|
concat!("<span class='color-", $name, "'>")
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -287,8 +287,8 @@ pub const HTML_STYLE_CODES: StyleCodes = StyleCodes {
|
||||||
magenta: html_color!("magenta"),
|
magenta: html_color!("magenta"),
|
||||||
cyan: html_color!("cyan"),
|
cyan: html_color!("cyan"),
|
||||||
white: html_color!("white"),
|
white: html_color!("white"),
|
||||||
bold: "<span style='font-weight: bold'>",
|
bold: "<span class='bold'>",
|
||||||
underline: "<span style='text-decoration: underline'>",
|
underline: "<span class='underline'>",
|
||||||
reset: "</span>",
|
reset: "</span>",
|
||||||
color_reset: "</span>",
|
color_reset: "</span>",
|
||||||
};
|
};
|
||||||
|
|
|
@ -56,7 +56,7 @@ mv generated-docs/*.* www/build # move all the .js, .css, etc. files to build/
|
||||||
mv generated-docs/ www/build/builtins # move all the folders to build/builtins/
|
mv generated-docs/ www/build/builtins # move all the folders to build/builtins/
|
||||||
|
|
||||||
# Manually add this tip to all the builtin docs.
|
# Manually add this tip to all the builtin docs.
|
||||||
find www/build/builtins -type f -name 'index.html' -exec sed -i 's!</nav>!<div style="padding: 1em;font-style: italic;line-height: 1.3em;"><strong>Tip:</strong> <a href="/different-names">Some names</a> differ from other languages.</div></nav>!' {} \;
|
find www/build/builtins -type f -name 'index.html' -exec sed -i 's!</nav>!<div class="builtins-tip"><b>Tip:</b> <a href="/different-names">Some names</a> differ from other languages.</div></nav>!' {} \;
|
||||||
|
|
||||||
echo 'Generating CLI example platform docs...'
|
echo 'Generating CLI example platform docs...'
|
||||||
# Change ROC_DOCS_ROOT_DIR=builtins so that links will be generated relative to
|
# Change ROC_DOCS_ROOT_DIR=builtins so that links will be generated relative to
|
||||||
|
|
|
@ -75,3 +75,31 @@ section.source textarea {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
margin-bottom: 16px;
|
margin-bottom: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.color-red {
|
||||||
|
color: red;
|
||||||
|
}
|
||||||
|
.color-green {
|
||||||
|
color: green;
|
||||||
|
}
|
||||||
|
.color-yellow {
|
||||||
|
color: yellow;
|
||||||
|
}
|
||||||
|
.color-blue {
|
||||||
|
color: blue;
|
||||||
|
}
|
||||||
|
.color-magenta {
|
||||||
|
color: magenta;
|
||||||
|
}
|
||||||
|
.color-cyan {
|
||||||
|
color: cyan;
|
||||||
|
}
|
||||||
|
.color-white {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.bold {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
.underline {
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue