init
This commit is contained in:
		
						commit
						d013ece0f3
					
				
					 363 changed files with 20823 additions and 0 deletions
				
			
		
							
								
								
									
										33
									
								
								themes/duckquill/templates/partials/toc.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								themes/duckquill/templates/partials/toc.html
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,33 @@
 | 
			
		|||
{%- if page.extra.toc_ordered or section.extra.toc_ordered or config.extra.toc_ordered -%}
 | 
			
		||||
	{%- set list_element = "ol" -%}
 | 
			
		||||
{%- else -%}
 | 
			
		||||
	{%- set list_element = "ul" -%}
 | 
			
		||||
{%- endif -%}
 | 
			
		||||
 | 
			
		||||
{%- if page.toc -%}
 | 
			
		||||
    {%- set toc = page.toc -%}
 | 
			
		||||
{%- elif section.toc -%}
 | 
			
		||||
    {%- set toc = section.toc -%}
 | 
			
		||||
{%- endif -%}
 | 
			
		||||
 | 
			
		||||
{%- if page.extra.toc or section.extra.toc -%}
 | 
			
		||||
	{%- if toc | length > 0 -%}
 | 
			
		||||
		<h2>{{ macros_translate::translate(key="table_of_contents", default="Table of Contents", language_strings=language_strings) }}</h2>
 | 
			
		||||
		<{{ list_element }}>
 | 
			
		||||
			{%- for h1 in toc -%}
 | 
			
		||||
				<li>
 | 
			
		||||
					<a href="{{ h1.permalink | safe }}">{{ h1.title }}</a>
 | 
			
		||||
					{%- if h1.children -%}
 | 
			
		||||
						<{{ list_element }}>
 | 
			
		||||
							{%- for h2 in h1.children -%}
 | 
			
		||||
								<li>
 | 
			
		||||
									<a href="{{ h2.permalink | safe }}">{{ h2.title }}</a>
 | 
			
		||||
								</li>
 | 
			
		||||
							{%- endfor -%}
 | 
			
		||||
						</{{ list_element }}>
 | 
			
		||||
					{%- endif -%}
 | 
			
		||||
				</li>
 | 
			
		||||
			{%- endfor -%}
 | 
			
		||||
		</{{ list_element }}>
 | 
			
		||||
	{%- endif -%}
 | 
			
		||||
{%- endif -%}
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue