diff --git a/docs/_config.yml b/docs/_config.yml index dc0c08e3723..c4114e407fc 100644 --- a/docs/_config.yml +++ b/docs/_config.yml @@ -12,4 +12,4 @@ repository: "AY2324S1-CS2103T-W10-1/tp" github_icon: "images/github-icon.png" plugins: - - jemoji \ No newline at end of file + - jemoji diff --git a/docs/_includes/toc.html b/docs/_includes/toc.html index 95daa2be2eb..81437a69869 100644 --- a/docs/_includes/toc.html +++ b/docs/_includes/toc.html @@ -180,4 +180,4 @@ {% capture jekyll_toc %}<{{ listModifier }}{{ rootAttributes }}>{{ nodes | shift | join: '>' }}>{% endcapture %} {% endif %} {% endif %} -{% endcapture %}{% assign tocWorkspace = '' %}{{ deprecation_warnings }}{{ jekyll_toc -}} \ No newline at end of file +{% endcapture %}{% assign tocWorkspace = '' %}{{ deprecation_warnings }}{{ jekyll_toc -}} diff --git a/docs/_includes/toc.md b/docs/_includes/toc.md index 5b62d4aae75..9bcff54e049 100644 --- a/docs/_includes/toc.md +++ b/docs/_includes/toc.md @@ -17,4 +17,4 @@ {% else %} * Table of contents {:toc} -{% endif %} \ No newline at end of file +{% endif %} diff --git a/docs/_sass/toc.scss b/docs/_sass/toc.scss index ca5bb10695f..bb98cd7d9e2 100644 --- a/docs/_sass/toc.scss +++ b/docs/_sass/toc.scss @@ -1,69 +1,69 @@ #markdown-toc { - //@@author ravern-reused - //Reused from https://github.com/AY2324S1-CS2103T-W10-3/tp/blob/master/docs/_sass/toc.scss - //with minor modifications - - //Adapted from https://stackoverflow.com/a/51007932/9311854 - ol { - counter-reset: item; - } - - > li, - ol > li { - counter-increment: item; - } - - ol > li { - display: block; - position: relative; - } - - ol > li:before { - content: counters(item, ".") ". "; - margin-left: -1em; - } + //@@author ravern-reused + //Reused from https://github.com/AY2324S1-CS2103T-W10-3/tp/blob/master/docs/_sass/toc.scss + //with minor modifications + + //Adapted from https://stackoverflow.com/a/51007932/9311854 + ol { + counter-reset: item; } - - - article.post { - counter-reset: section; - - h2:not(.no_toc) { - counter-reset: subsection; - } - - h3:not(.no_toc) { - counter-reset: subsubsection; - } - - h4:not(.no_toc) { - counter-increment: subsubsection; - } - - h2:not(.no_toc)::before { - color: inherit !important; - counter-increment: section; - content: counter(section) ". "; - } - - h3:not(.no_toc)::before { - color: inherit !important; - counter-increment: subsection; - content: counter(section) "." counter(subsection) ". "; - } - - h4:not(.no_toc)::before { - color: inherit !important; + + > li, + ol > li { + counter-increment: item; + } + + ol > li { + display: block; + position: relative; + } + + ol > li:before { + content: counters(item, ".") ". "; + margin-left: -1em; + } +} + + +article.post { + counter-reset: section; + + h2:not(.no_toc) { + counter-reset: subsection; + } + + h3:not(.no_toc) { + counter-reset: subsubsection; + } + + h4:not(.no_toc) { counter-increment: subsubsection; - content: counter(section) "." counter(subsection) "." counter(subsubsection) ". "; - } } - - - article.post { - h2:not(.no_toc)::before, - h3:not(.no_toc)::before, - h4:not(.no_toc)::before { - color: black; - } - } \ No newline at end of file + + h2:not(.no_toc)::before { + color: inherit !important; + counter-increment: section; + content: counter(section) ". "; + } + + h3:not(.no_toc)::before { + color: inherit !important; + counter-increment: subsection; + content: counter(section) "." counter(subsection) ". "; + } + + h4:not(.no_toc)::before { + color: inherit !important; + counter-increment: subsubsection; + content: counter(section) "." counter(subsection) "." counter(subsubsection) ". "; + } +} + + +article.post { + h2:not(.no_toc)::before, + h3:not(.no_toc)::before, + h4:not(.no_toc)::before { + color: black; + } +}