refactor: Cleanup git state - commit all staged changes

Major refactoring cleanup:
- Add new controller architecture (class-controller-*.php)
- Add new settings-v2 UI (views/settings-v2/)
- Add new CSS architecture (agentic-sidebar.css, tokens)
- Add esbuild build pipeline (scripts/build.js, package.json)
- Add composer dependencies (vendor/)
- Add frontend src directory (assets/js/src/index.jsx)
- Add documentation files
- Remove old/obsolete files (class-settings.php, old CSS)

This commits all pending changes from previous refactoring efforts.
This commit is contained in:
Dwindi Ramadhana
2026-06-17 05:27:58 +07:00
parent d3f142222c
commit 690991c526
7963 changed files with 941566 additions and 67372 deletions

View File

@@ -0,0 +1,6 @@
<div class="admonition {{ name }}{{ class ? (' '~class) }}{% if node.classes %} {{ node.classesString }}{% endif %}">
{% if title and isTitled %}<p class="admonition-title">{{ renderNode(title) }}</p>{% endif %}
{% if title and not isTitled %}<p>{{ renderNode(title) }}</p>{% endif %}
{{ renderNode(node) }}
</div>

View File

@@ -0,0 +1,3 @@
{% for child in node.value %}
{{ renderNode(child) }}
{% endfor %}

View File

@@ -0,0 +1,4 @@
<address itemprop="author" itemscope itemtype="http://schema.org/Person">
<p>Author: <span itemprop="name">{node.value}</span></p>
<p>Email: <a href="mailto:{node.email}"><span itemprop="email">{node.email}</span></a></p>
</address>

View File

@@ -0,0 +1,8 @@
<div class="citation {% if node.classes %} {{ node.classesString }}{% endif %}" id="{{ node.anchor }}">
<div class="citation-label">[{{ node.name }}]</div>
<div class="citation-content">
{%- for child in node.children -%}
{{ renderNode(child) }}
{%- endfor -%}
</div>
</div>

View File

@@ -0,0 +1,15 @@
{% if node.raw %}
{# see the RawDirective for where this is coming from; a refactor is desired to move this onto its own template / renderer #}
{{ node.value|raw }}
{%- else -%}
{% if node.caption %}
<div class="code-block-caption">
<span class="caption-text">{{ renderNode(node.caption) }}</span>
</div>
{%- endif -%}
<pre{% if node.classes %} class="{{ node.classesString }}"{% endif %}><code class="language-{{ node.language }}{{ node.startingLineNumber ? ' line-numbers' }}"
{%- if node.startingLineNumber %} data-start="{{ node.startingLineNumber }}"{% endif -%}
{%- if node.emphasizeLines %} data-emphasize-lines="{{ node.emphasizeLines }}"{% endif -%}>
{%- include "body/code/highlighted-code.html.twig" -%}
</code></pre>
{%~ endif -%}

View File

@@ -0,0 +1 @@
{{ node.value }}

View File

@@ -0,0 +1 @@
{{ renderNode(node) }}

View File

@@ -0,0 +1,17 @@
<div class="configuration-block">
<div role="tablist" aria-label="Configuration formats" class="configuration-tabs configuration-tabs-length-{{ node.tabs|length }}">
{% for tab in node.tabs %}
<button role="tab" type="button" data-language="{{ tab.slug }}"
aria-controls="{{ 'configuration-block-tabpanel-' ~ tab.hash }}" aria-selected="{{ loop.first ? 'true' : 'false' }}"
{{ loop.first ? 'data-active="true"' }} {{ not loop.first ? 'tabindex="-1"' }}>
<span>{{ tab.label }}</span>
</button>
{% endfor %}
</div>
{% for tab in node.tabs %}
<div role="tabpanel" id="{{ 'configuration-block-tabpanel-' ~ tab.hash }}" aria-label="{{ tab.label }}" class="configuration-codeblock" data-language="{{ tab.slug }}" style="{{ not loop.first ? 'display: none' }}">
{{ renderNode(tab.content) }}
</div>
{% endfor %}
</div>

View File

@@ -0,0 +1,4 @@
<div class="{{ class }}"{% if id is defined and id %} id="{{ id }}"{% endif %}>
{{ renderNode(node) }}
</div>
{# force a new line at the end of the file #}

View File

@@ -0,0 +1,22 @@
<dl{% if node.classes %} class="{{ node.classesString }}"{% endif %}>
{% for definitionListTerm in node.children %}
{% if definitionListTerm.classifiers is empty %}
<dt>{{ renderNode(definitionListTerm.term) }}</dt>
{% else %}
<dt>
{{- renderNode(definitionListTerm.term) -}}
{%- for classifier in definitionListTerm.classifiers %}
<span class="classifier-delimiter">:</span>
<span class="classifier">{{ renderNode(classifier) }}</span>
{%- endfor -%}
</dt>
{% endif %}
{% if definitionListTerm.children %}
{%- for definition in definitionListTerm.children -%}
<dd>{{ renderNode(definition) }}</dd>
{%- endfor ~%}
{% endif %}
{% endfor %}
</dl>

View File

@@ -0,0 +1,3 @@
{%- for child in node.children -%}
{{ renderNode(child) }}
{%- endfor -%}

View File

@@ -0,0 +1,8 @@
<iframe src="{{ node.url }}"
{%- if node.hasOption('width') %} width="{{ node.option('width') }}"{% endif -%}
{%- if node.hasOption('height') %} height="{{ node.option('height') }}"{% endif -%}
{%- if node.hasOption('title') %} title="{{ node.option('title') }}"{% endif -%}
{%- if node.hasOption('allow') %} allow="{{ node.option('allow') }}"{% endif -%}
{%- if node.hasOption('allowfullscreen') and node.option('allowfullscreen') %} allowfullscreen{% endif -%}
>
</iframe>

View File

@@ -0,0 +1,17 @@
<table{% if node.classes %} class="{{ node.classesString }}"{% endif %}>
{% for item in node.children %}
<tr>
<th>{{ item.term }}</th>
<td>
{% if item.children %}
{%- for definition in item.children -%}
{{ renderNode(definition) }}
{%- endfor -%}
{% else %}
&nbsp;
{% endif %}
</td>
</tr>
{% endfor %}
</table>

View File

@@ -0,0 +1,14 @@
<figure
{%- if node.hasOption('figclass') %} class="{{ node.option('figclass') }}"{% endif -%}
{%- if node.hasOption('figwidth') %} style="{% if node.hasOption('figwidth') %}width: {{ node.option('figwidth') }};{% endif %}"{% endif -%}
>
{{ renderNode(node.image) }}
{% if node.document %}
{% set caption = renderNode(node.document) %}
{% if caption|trim %}
<figcaption>{{ caption|raw }}</figcaption>
{% endif %}
{% endif %}
</figure>

View File

@@ -0,0 +1,8 @@
<div class="footnote {% if node.classes %} {{ node.classesString }}{% endif %}" id="{{ node.anchor }}">
<div class="footnote-label">[{{ node.number }}]</div>
<div class="footnote-content">
{%- for child in node.children -%}
{{ renderNode(child) }}
{%- endfor -%}
</div>
</div>

View File

@@ -0,0 +1,11 @@
{% if node.target %}<a href="{{ node.target.url }}">{% endif %}
<img
src="{%- if node.value is external_target -%} {{ node.value }} {%- else -%} {{ asset(node.value) }} {%- endif -%}"
{% if node.hasOption('width') %}width="{{ node.option('width') }}"{% endif%}
{% if node.hasOption('height') %}height="{{ node.option('height') }}"{% endif%}
{% if node.hasOption('align') %}align="{{ node.option('align') }}"{% endif%}
{% if node.hasOption('alt') %}alt="{{ node.option('alt') }}"{% endif%}
{% if node.hasOption('title') %}title="{{ node.option('title') }}"{% endif%}
{% if node.classesString %}class="{{ node.classesString }}"{% endif%}
/>
{% if node.target %}</a>{% endif %}

View File

@@ -0,0 +1,6 @@
<li{{- node.prefix == '-' ? ' class="dash"' : '' -}}
{%- if node.orderNumber %} value="{{ node.orderNumber }}"{% endif -%}>
{%- for child in node.children -%}
{{ renderNode(child) }}
{%- endfor -%}
</li>

View File

@@ -0,0 +1,14 @@
{% set keyword = 'ul' %}
{% if node.isOrdered %}
{% set keyword = 'ol' %}
{% endif %}
<{{ keyword }}{% if node.classes %} class="{{ node.classesString }}"{% endif %}
{%- if node.start %} start="{{ node.start }}"{% endif -%}
{%- if node.orderingType %} type="{{ renderOrderedListType(node.orderingType) }}"{% endif -%}>
{% for child in node.children %}
{{ renderNode(child) }}
{% endfor %}
</{{ keyword }}>
{# force a new line at the end of the file #}

View File

@@ -0,0 +1 @@
<pre>{{ node.value |raw }}</pre>

View File

@@ -0,0 +1 @@
<math{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value|raw }}</math>

View File

@@ -0,0 +1,10 @@
<nav aria-label="breadcrumb">
{% for entry in rootline -%}
{%- if entry.current %}
<span class="breadcrumb active level-{{ entry.level }}">{{ entry.value.toString }}</span>
{% else -%}
<a href="{{ renderLink(entry.url) }}"
class="breadcrumb level-{{ entry.level }}">{{ entry.value.toString }}</a> &gt;
{% endif -%}
{% endfor %}
</nav>

View File

@@ -0,0 +1,6 @@
<div class="contents">
{% if node.caption %}
<p class="topic-title">{{ renderNode(node.caption) }}</p>
{% endif %}
{% include "body/menu/menu-level.html.twig" %}
</div>

View File

@@ -0,0 +1 @@
<a href="{{ url }}">{{ renderNode(title) }}</a>

View File

@@ -0,0 +1,17 @@
<li class="toc-item {%- if node.isCurrent %} current{% endif -%} {%- if node.isInRootline %} active{% endif -%}">
<a href="{{ url }}">{{ node.value.toString }}</a>
{%~ if node.children|length %}
<ul class="menu-level-{{ node.level }}">
{% for child in node.children -%}
{{ renderNode(child) }}
{% endfor %}
</ul>
{%- endif ~%}
{%~ if node.sections|length %}
<ul class="section-level-{{ node.level }}">
{% for subsection in node.sections -%}
{{ renderNode(subsection) }}
{% endfor %}
</ul>
{%- endif ~%}
</li>

View File

@@ -0,0 +1,6 @@
<ul class="menu-level">
{% for entry in node.menuEntries -%}
{{ renderNode(entry) }}
{% endfor %}
</ul>
{# force a new line at the end of the file #}

View File

@@ -0,0 +1,3 @@
<div class="menu">
{% include "body/menu/menu-level.html.twig" %}
</div>

View File

@@ -0,0 +1,6 @@
<div class="toc">
{% if node.caption %}
<p class="caption">{{ renderNode(node.caption) }}</p>
{% endif -%}
{% include "body/menu/menu-level.html.twig" %}
</div>

View File

@@ -0,0 +1,5 @@
{% set text = renderNode(node.value) %}
{% if text %}
<p{% if node.classes %} class="{{ node.classesString }}"{% endif %}>{{ text|raw }}</p>
{% endif %}

View File

@@ -0,0 +1 @@
<blockquote{% if node.classes %} class="{{ node.classesString }}"{% endif %}>{{- renderNode(node.value) -}}</blockquote>

View File

@@ -0,0 +1 @@
<hr />

View File

@@ -0,0 +1,7 @@
<table {%- include "body/table/table-classes.html.twig" -%}
{%- include "body/table/table-inline-style.html.twig" -%}>
{% include "body/table/table-caption.html.twig" %}
{% include "body/table/table-colgroups.html.twig" %}
{% include "body/table/table-header.html.twig" %}
{% include "body/table/table-body.html.twig" %}
</table>

View File

@@ -0,0 +1,6 @@
<tbody>
{% for tableRow in tableRows %}
{% include "body/table/table-row.html.twig" %}
{% endfor %}
</tbody>
{# force a new line at the end of the file #}

View File

@@ -0,0 +1,3 @@
{% if tableNode.hasOption('caption') %}
<caption>{{ tableNode.option('caption') }}</caption>
{% endif %}

View File

@@ -0,0 +1,5 @@
<td{% if column.colSpan > 1 %} colspan="{{ column.colSpan }}"{% endif %}{% if column.rowSpan > 1 %} rowspan="{{ column.rowSpan }}"{% endif %}>
{%- for child in column.children -%}
{{- renderNode(child) -}}
{%- else %}&nbsp;{% endfor %}</td>
{# force a new line at the end of the file #}

View File

@@ -0,0 +1,17 @@
{%- set tableClasses = '' -%}
{# Check and add classes conditionally #}
{%- if tableNode.classes -%}
{%- set tableClasses = tableClasses ~ tableNode.classesString ~ ' ' -%}
{%- endif -%}
{%- if tableNode.hasOption('align') -%}
{%- set tableClasses = tableClasses ~ 'align-' ~ tableNode.option('align') ~ ' ' -%}
{%- endif -%}
{%- if tableNode.hasOption('widths') -%}
{%- set tableClasses = tableClasses ~ 'colwidths-' ~ tableNode.option('widths') ~ ' ' -%}
{%- endif -%}
{%- if tableNode.hasOption('grid') == 'grid' -%}
{%- set tableClasses = tableClasses ~ 'grid-' ~ tableNode.option('grid') ~ ' ' -%}
{%- endif -%}
{%- if tableClasses|trim %} class="{{ tableClasses|trim }}"{% endif -%}

View File

@@ -0,0 +1,11 @@
{% if tableNode.columnWidth %}
<colgroup>
{% for width in tableNode.columnWidth %}
{% if width<=0 %}
<col style="width: auto">
{% else %}
<col style="width: {{ width }}%">
{% endif %}
{% endfor %}
</colgroup>
{% endif %}

View File

@@ -0,0 +1,14 @@
{% if tableHeaderRows is not empty %}
<thead>
{% for tableHeaderRow in tableHeaderRows %}
<tr>
{% for column in tableHeaderRow.columns %}
<th{% if column.colspan > 1 %} colspan="{{ column.colspan }}"{% endif %}>
{%- for child in column.children -%}
{{- renderNode(child) -}}
{% endfor %}</th>
{% endfor %}
</tr>
{% endfor %}
</thead>
{% endif %}

View File

@@ -0,0 +1,5 @@
{%- set tableStyle = '' -%}
{%- if tableNode.hasOption('width') -%}
{%- set tableStyle = tableStyle ~ 'width: ' ~ tableNode.option('width') ~ '; ' -%}
{%- endif -%}
{%- if tableStyle|trim %} style="{{ tableStyle|trim }}"{% endif -%}

View File

@@ -0,0 +1,6 @@
<tr>
{% for column in tableRow.columns %}
{% include "body/table/table-cell.html.twig" %}
{% endfor %}
</tr>
{# force a new line at the end of the file #}

View File

@@ -0,0 +1,4 @@
<div class="topic">
<p class="topic-title">{{ name }}</p>
{{ renderNode(node) }}
</div>

View File

@@ -0,0 +1 @@
<a id="{{- node.value -}}"></a>

View File

@@ -0,0 +1,5 @@
{%- if node.internalTarget -%}
<sup>[<a href="{{- renderTarget(node.internalTarget) -}}">{{- node.value -}}</a>]</sup>
{%- else -%}
<sup>[{{- node.value -}}]</sup>
{%- endif -%}

View File

@@ -0,0 +1 @@
{{- include('inline/link.html.twig') -}}

View File

@@ -0,0 +1,5 @@
<em>
{%- for child in node.children -%}
{{- renderNode(child) -}}
{%- endfor -%}
</em>

View File

@@ -0,0 +1,5 @@
{%- if node.internalTarget -%}
<sup>[<a href="{{- renderTarget(node.internalTarget) -}}">{{- node.value -}}</a>]</sup>
{%- else -%}
<sup>[{{- node.value -}}]</sup>
{%- endif -%}

View File

@@ -0,0 +1,2 @@
<img src="{%- if node.value is external_target -%} {{ node.value }} {%- else -%} {{ asset(node.value) }} {%- endif -%}" alt="{{- node.altText -}}"
{%- if node.title %} title="{{- node.title -}}" {%- endif -%}/>

View File

@@ -0,0 +1,3 @@
{%- for child in node.children -%}
{{- renderNode(child) -}}
{%- endfor -%}

View File

@@ -0,0 +1,14 @@
{%- if node.url -%}
<a href="{{- node.url -}}"
{%- for key, value in attributes %} {{- key -}}="{{- value -}}"{% endfor -%}
{%- if node.classes %} class="{{ node.classesString }}"{% endif -%}
>
{%- for child in node.children -%}
{{- renderNode(child) -}}
{%- endfor -%}
</a>
{%- else -%}
{%- for child in node.children -%}
{{- renderNode(child) -}}
{%- endfor -%}
{%- endif -%}

View File

@@ -0,0 +1 @@
<code>{{- node.value -}}</code>

View File

@@ -0,0 +1 @@
&nbsp;

View File

@@ -0,0 +1 @@
<br>

View File

@@ -0,0 +1 @@
{{- node.value -}}

View File

@@ -0,0 +1 @@
{{- include('inline/link.html.twig') -}}

View File

@@ -0,0 +1,5 @@
<strong>
{%- for child in node.children -%}
{{- renderNode(child) -}}
{%- endfor -%}
</strong>

View File

@@ -0,0 +1 @@
<abbr title="{{ node.definition }}"{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.term }}</abbr>

View File

@@ -0,0 +1 @@
<em class="aspect{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</em>

View File

@@ -0,0 +1 @@
<br/>

View File

@@ -0,0 +1 @@
<code{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</code>

View File

@@ -0,0 +1 @@
<strong class="command{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</strong>

View File

@@ -0,0 +1 @@
<em class="dfn{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</em>

View File

@@ -0,0 +1 @@
<em{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</em>

View File

@@ -0,0 +1 @@
<span class="pre file{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</span>

View File

@@ -0,0 +1,4 @@
{%- include [
('inline/textroles/' ~ node.type ~ '.html.twig'),
'inline/textroles/unknown.html.twig'
] -%}

View File

@@ -0,0 +1 @@
<span class="guilabel{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</span>

View File

@@ -0,0 +1 @@
<kbd{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</kbd>

View File

@@ -0,0 +1 @@
<code{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</code>

View File

@@ -0,0 +1 @@
<em class="mailheader{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</em>

View File

@@ -0,0 +1 @@
<math{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</math>

View File

@@ -0,0 +1 @@
<span{%- if node.class %} class="{{ node.class }}"{% endif %}>{{- node.value -}}</span>

View File

@@ -0,0 +1 @@
<strong{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</strong>

View File

@@ -0,0 +1 @@
<sub{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</sub>

View File

@@ -0,0 +1 @@
<sub{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</sub>

View File

@@ -0,0 +1 @@
<sup{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</sup>

View File

@@ -0,0 +1 @@
<sup{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</sup>

View File

@@ -0,0 +1 @@
<cite{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</cite>

View File

@@ -0,0 +1 @@
<cite{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</cite>

View File

@@ -0,0 +1 @@
<cite{%- if node.class %} class="{{ node.class }}"{% endif %}>{{ node.value }}</cite>

View File

@@ -0,0 +1 @@
<code class="{{ node.type }}{%- if node.class %} {{ node.class }}{% endif %}">{{ node.value }}</code>

View File

@@ -0,0 +1 @@
{{- renderNode(node.child) -}}

View File

@@ -0,0 +1,14 @@
{% extends "structure/layout.html.twig" %}
{% block head %}
{%- for headerNode in node.headerNodes -%}
{{ renderNode(headerNode) }}
{%- endfor -%}
{{ parent() }}
{% endblock %}
{% block body %}
{% for child in node.children -%}
{{ renderNode(child) }}
{%~ endfor -%}
{% endblock %}

View File

@@ -0,0 +1,45 @@
<footer>
{#{% if (theme_prev_next_buttons_location == 'bottom' or theme_prev_next_buttons_location == 'both') and (next or prev) %}#}
{#<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">#}
{#{% if next %}#}
{#<a href="{{ next.link|e }}" class="btn btn-neutral float-right" title="{{ next.title|striptags|e }}" accesskey="n" rel="next">{{ _('Next') }} <span class="fa fa-arrow-circle-right"></span></a>#}
{#{% endif %}#}
{#{% if prev %}#}
{#<a href="{{ prev.link|e }}" class="btn btn-neutral" title="{{ prev.title|striptags|e }}" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> {{ _('Previous') }}</a>#}
{#{% endif %}#}
{#</div>#}
{#{% endif %}#}
<hr/>
<div role="contentinfo">
<p>
{#{%- if show_copyright %}#}
{#{%- if hasdoc('copyright') %}#}
{#{% trans path=pathto('copyright'), copyright=copyright|e %}&copy; <a href="{{ path }}">Copyright</a> {{ copyright }}.{% endtrans %}#}
{#{%- else %}#}
{#{% trans copyright=copyright|e %}&copy; Copyright {{ copyright }}.{% endtrans %}#}
{#{%- endif %}#}
{#{%- endif %}#}
{#{%- if build_id and build_url %}#}
{#{% trans build_url=build_url, build_id=build_id %}#}
{#<span class="build">#}
{#Build#}
{#<a href="{{ build_url }}">{{ build_id }}</a>.#}
{#</span>#}
{#{% endtrans %}#}
{#{%- elif commit %}#}
{#{% trans commit=commit %}#}
{#<span class="commit">#}
{#Revision <code>{{ commit }}</code>.#}
{#</span>#}
{#{% endtrans %}#}
{#{%- elif last_updated %}#}
{#{% trans last_updated=last_updated|e %}Last updated on {{ last_updated }}.{% endtrans %}#}
{#{%- endif %}#}
</p>
</div>
</footer>

View File

@@ -0,0 +1 @@
<h{{ node.level }}{% if node.classes %} class="{{ node.classesString }}"{% endif %}>{{ renderNode(node.value) }}</h{{ node.level }}>

View File

@@ -0,0 +1 @@
<meta name="author" content="{{ node.value }}" />

View File

@@ -0,0 +1 @@
<meta name="copyright" content="{{ node.value }}" />

View File

@@ -0,0 +1 @@
<meta name="date" content="{{ node.value }}" />

View File

@@ -0,0 +1 @@
<link rel="icon" type="image/x-icon" href="{{ url }}" />

View File

@@ -0,0 +1 @@
<script type="text/javascript" src="{{ js }}"></script>

View File

@@ -0,0 +1 @@
<meta name="{{ node.key }}" content="{{ node.value }}" />

View File

@@ -0,0 +1 @@
<meta name="robots" content="noindex">

View File

@@ -0,0 +1 @@
<link rel="stylesheet" type="text/css" href="{{ css }}" />

View File

@@ -0,0 +1,3 @@
{% if node.title == 'abstract' %}
<meta name="description" content="{{ node.value }}" />
{% endif %}

View File

@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>{{ title }}
{%- if title!=null and env.projectNode.title!=null %} - {% endif -%}
{%- if env.projectNode.title -%}{{ env.projectNode.title }}{%- endif -%}</title>
{%~ block head %}
{%~ endblock %}
</head>
<body>
<!-- content start -->
{%~ block body %}
{%~ endblock %}
<!-- content end -->
</body>
</html>

View File

@@ -0,0 +1,5 @@
<div class="section{% if node.classes %} {{ node.classesString }}{% endif %}" id="{{ node.title.id }}">
{% for childNode in node.children %}
{{ renderNode(childNode) }}
{% endfor %}
</div>

View File

@@ -0,0 +1,5 @@
<div class="admonition-wrapper">
<div class="admonition admonition-sidebar"><p class="sidebar-title">{{ renderNode(title) }}</p>
{{ renderNode(node) }}
</div>
</div>

View File

@@ -0,0 +1,118 @@
<?php
declare(strict_types=1);
use phpDocumentor\Guides\Nodes\AnchorNode;
use phpDocumentor\Guides\Nodes\AnnotationListNode;
use phpDocumentor\Guides\Nodes\CitationNode;
use phpDocumentor\Guides\Nodes\CodeNode;
use phpDocumentor\Guides\Nodes\Configuration\ConfigurationBlockNode;
use phpDocumentor\Guides\Nodes\DefinitionListNode;
use phpDocumentor\Guides\Nodes\DefinitionLists\DefinitionNode;
use phpDocumentor\Guides\Nodes\DocumentNode;
use phpDocumentor\Guides\Nodes\EmbeddedFrame;
use phpDocumentor\Guides\Nodes\FieldListNode;
use phpDocumentor\Guides\Nodes\FigureNode;
use phpDocumentor\Guides\Nodes\FootnoteNode;
use phpDocumentor\Guides\Nodes\ImageNode;
use phpDocumentor\Guides\Nodes\Inline\AbbreviationInlineNode;
use phpDocumentor\Guides\Nodes\Inline\CitationInlineNode;
use phpDocumentor\Guides\Nodes\Inline\DocReferenceNode;
use phpDocumentor\Guides\Nodes\Inline\EmphasisInlineNode;
use phpDocumentor\Guides\Nodes\Inline\FootnoteInlineNode;
use phpDocumentor\Guides\Nodes\Inline\GenericTextRoleInlineNode;
use phpDocumentor\Guides\Nodes\Inline\HyperLinkNode;
use phpDocumentor\Guides\Nodes\Inline\ImageInlineNode;
use phpDocumentor\Guides\Nodes\Inline\LiteralInlineNode;
use phpDocumentor\Guides\Nodes\Inline\NewlineInlineNode;
use phpDocumentor\Guides\Nodes\Inline\PlainTextInlineNode;
use phpDocumentor\Guides\Nodes\Inline\ReferenceNode;
use phpDocumentor\Guides\Nodes\Inline\StrongInlineNode;
use phpDocumentor\Guides\Nodes\Inline\VariableInlineNode;
use phpDocumentor\Guides\Nodes\Inline\WhitespaceInlineNode;
use phpDocumentor\Guides\Nodes\InlineCompoundNode;
use phpDocumentor\Guides\Nodes\ListItemNode;
use phpDocumentor\Guides\Nodes\ListNode;
use phpDocumentor\Guides\Nodes\LiteralBlockNode;
use phpDocumentor\Guides\Nodes\MathNode;
use phpDocumentor\Guides\Nodes\Metadata\AddressNode;
use phpDocumentor\Guides\Nodes\Metadata\AuthorNode;
use phpDocumentor\Guides\Nodes\Metadata\AuthorsNode;
use phpDocumentor\Guides\Nodes\Metadata\ContactNode;
use phpDocumentor\Guides\Nodes\Metadata\CopyrightNode;
use phpDocumentor\Guides\Nodes\Metadata\DateNode;
use phpDocumentor\Guides\Nodes\Metadata\MetaNode;
use phpDocumentor\Guides\Nodes\Metadata\NoCommentsNode;
use phpDocumentor\Guides\Nodes\Metadata\NoSearchNode;
use phpDocumentor\Guides\Nodes\Metadata\OrganizationNode;
use phpDocumentor\Guides\Nodes\Metadata\OrphanNode;
use phpDocumentor\Guides\Nodes\Metadata\RevisionNode;
use phpDocumentor\Guides\Nodes\Metadata\TocDepthNode;
use phpDocumentor\Guides\Nodes\Metadata\TopicNode;
use phpDocumentor\Guides\Nodes\Metadata\VersionNode;
use phpDocumentor\Guides\Nodes\ParagraphNode;
use phpDocumentor\Guides\Nodes\QuoteNode;
use phpDocumentor\Guides\Nodes\SectionNode;
use phpDocumentor\Guides\Nodes\SeparatorNode;
use phpDocumentor\Guides\Nodes\TitleNode;
return [
AnchorNode::class => 'inline/anchor.html.twig',
\phpDocumentor\Guides\Nodes\AuthorNode::class => 'body/author.html.twig',
FigureNode::class => 'body/figure.html.twig',
MetaNode::class => 'structure/header/meta.html.twig',
ParagraphNode::class => 'body/paragraph.html.twig',
QuoteNode::class => 'body/quote.html.twig',
SeparatorNode::class => 'body/separator.html.twig',
TitleNode::class => 'structure/header-title.html.twig',
SectionNode::class => 'structure/section.html.twig',
DocumentNode::class => 'structure/document.html.twig',
ImageNode::class => 'body/image.html.twig',
CodeNode::class => 'body/code.html.twig',
ConfigurationBlockNode::class => 'body/configuration-block.html.twig',
DefinitionListNode::class => 'body/definition-list.html.twig',
DefinitionNode::class => 'body/definition.html.twig',
FieldListNode::class => 'body/field-list.html.twig',
ListNode::class => 'body/list/list.html.twig',
ListItemNode::class => 'body/list/list-item.html.twig',
LiteralBlockNode::class => 'body/literal-block.html.twig',
MathNode::class => 'body/math.html.twig',
CitationNode::class => 'body/citation.html.twig',
FootnoteNode::class => 'body/footnote.html.twig',
AnnotationListNode::class => 'body/annotation-list.html.twig',
EmbeddedFrame::class => 'body/embedded-frame.html.twig',
// Inline
ImageInlineNode::class => 'inline/image.html.twig',
AbbreviationInlineNode::class => 'inline/textroles/abbreviation.html.twig',
CitationInlineNode::class => 'inline/citation.html.twig',
DocReferenceNode::class => 'inline/doc.html.twig',
EmphasisInlineNode::class => 'inline/emphasis.html.twig',
FootnoteInlineNode::class => 'inline/footnote.html.twig',
HyperLinkNode::class => 'inline/link.html.twig',
LiteralInlineNode::class => 'inline/literal.html.twig',
NewlineInlineNode::class => 'inline/newline.html.twig',
WhitespaceInlineNode::class => 'inline/nbsp.html.twig',
PlainTextInlineNode::class => 'inline/plain-text.html.twig',
ReferenceNode::class => 'inline/ref.html.twig',
StrongInlineNode::class => 'inline/strong.html.twig',
VariableInlineNode::class => 'inline/variable.html.twig',
GenericTextRoleInlineNode::class => 'inline/textroles/generic.html.twig',
InlineCompoundNode::class => 'inline/inline-node.html.twig',
// Output as Metatags
AuthorNode::class => 'structure/header/author.html.twig',
CopyrightNode::class => 'structure/header/copyright.html.twig',
DateNode::class => 'structure/header/date.html.twig',
NoSearchNode::class => 'structure/header/no-search.html.twig',
TopicNode::class => 'structure/header/topic.html.twig',
// No output in page header in HTML - might be output in i.e. LaTex
AddressNode::class => 'structure/header/blank.html.twig',
AuthorsNode::class => 'structure/header/blank.html.twig',
ContactNode::class => 'structure/header/blank.html.twig',
NoCommentsNode::class => 'structure/header/blank.html.twig',
OrganizationNode::class => 'structure/header/blank.html.twig',
OrphanNode::class => 'structure/header/blank.html.twig',
RevisionNode::class => 'structure/header/blank.html.twig',
TocDepthNode::class => 'structure/header/blank.html.twig',
VersionNode::class => 'structure/header/blank.html.twig',
];