Skip to content

Commit

Permalink
Cross-out deprecated modules
Browse files Browse the repository at this point in the history
  • Loading branch information
moisseev committed Apr 13, 2024
1 parent f07150d commit 3cc4c94
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 11 deletions.
35 changes: 24 additions & 11 deletions _includes/directory-tree.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,24 +3,30 @@

Page Front Matter directory-tree hash parameters:

emphasize Emphasize the page in the tree.
Default: false.
emphasize Emphasize the page in the tree.
Default: false.

de-emphasize De-emphasize the page in the tree.
Default: false.

Tree include parameters:

dir The top-level directory of the tree.
If the path ends with a slash, the directory itself will be excluded from the tree.
Default: The root directory.
dir The top-level directory of the tree.
If the path ends with a slash, the directory itself will be excluded from the tree.
Default: The root directory.

Tree parameters that can be passed as include hash, Front Matter directory-tree hash or Liquid variables with directory-tree- prefix:

li The generated tree is a list item. Do not wrap an <ul> tag around it.
li The generated tree is a list item. Do not wrap an <ul> tag around it.

dir_class Add a class attribute with the specified classes to <li> tags of all directories.
If not set, wrap a <strong> tag around titles of all directories.

dir_class Add a class attribute with the specified classes to <li> tags of all directories.
If not set, wrap a <strong> tag around titles of all directories.
strong Wrap a <strong> tag around titles of the pages that have set `emphasize: true` in the Front Matter.
Default: false.

strong Wrap a <strong> tag around titles of the pages that have `emphasize: true` in the Front Matter.
Default: false.
del Wrap a <del> tag around titles of the pages that have set `de-emphasize: true` in the Front Matter.
Default: false.
{%- endcomment -%}
{%- unless include.li or page.directory-tree.li or directory-tree-li %}<ul>{%- endunless %}
{%- assign dir_class = include.dir_class | default: directory-tree-dir_class | default: page.directory-tree.dir_class -%}
Expand Down Expand Up @@ -103,8 +109,15 @@
{%- else -%}
{%- assign strong = "" -%}
{%- assign strong_closing = "" -%}
{%- endif -%}
{%- if pg.directory-tree.de-emphasize and include.del or page.directory-tree.del or directory-tree-del -%}
{%- assign del = "<del>" -%}
{%- assign del_closing = "</del>" -%}
{%- else -%}
{%- assign del = "" -%}
{%- assign del_closing = "" -%}
{%- endif %}
<li><a href="{{ site.baseurl }}{{ pg.url }}">{{ strong }}{{ pg.title }}{{ strong_closing }}</a></li>
<li><a href="{{ site.baseurl }}{{ pg.url }}">{{ strong }}{{ del }}{{ pg.title }}{{ del_closing }}{{ strong_closing }}</a></li>
{%- endunless -%}
{% endfor -%}
{%- assign offset = include.dir | split: "/" | size -%}
Expand Down
2 changes: 2 additions & 0 deletions _layouts/doc.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

{%- assign directory-tree-li = true -%}
{%- assign directory-tree-strong = true -%}
{%- assign directory-tree-del = true -%}
{%- assign directory-tree-dir_class = "r-docs-subnav list-group-item" %}

<style>
Expand All @@ -22,6 +23,7 @@
font-weight: bold;
color: #de4700;
}
.r-docs-nav a:not(.active-link) > del { opacity: 0.4; }

.r-docs-subnav ul {
list-style: none;
Expand Down
2 changes: 2 additions & 0 deletions doc/modules/emails.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
layout: doc
title: Emails module
directory-tree:
de-emphasize: true
---

# Emails module
Expand Down
2 changes: 2 additions & 0 deletions doc/modules/ip_score.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
layout: doc
title: IP Score module
directory-tree:
de-emphasize: true
---

# IP Score
Expand Down
2 changes: 2 additions & 0 deletions doc/modules/surbl.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
layout: doc
title: SURBL module
directory-tree:
de-emphasize: true
---

# SURBL module
Expand Down
2 changes: 2 additions & 0 deletions doc/modules/trie.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---
layout: doc
title: Trie module
directory-tree:
de-emphasize: true
---

# Trie plugin
Expand Down

0 comments on commit 3cc4c94

Please sign in to comment.