mirror of
				https://github.com/BBaoVanC/bobatheme.git
				synced 2025-10-28 16:53:30 -05:00 
			
		
		
		
	Compare commits
	
		
			176 Commits
		
	
	
		
			1127795717
			...
			remove-sha
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| b1cdf7c318 | |||
| 14475c13f4 | |||
| 6b729c6acf | |||
| f751c4b104 | |||
| de20387b5a | |||
| 84004d3ac0 | |||
| 52a6440011 | |||
| 322928ed7a | |||
| 4e753395ba | |||
| 5d335647d0 | |||
| 22fff1a9c5 | |||
| b79c956c07 | |||
| b15ca73977 | |||
| ccb5170d2b | |||
| 433dd125e2 | |||
| d50a4dc6bd | |||
| bbe76a44bb | |||
| 8845272d4d | |||
| 5afaf2ce3e | |||
| 486fa65ad6 | |||
| f371afe529 | |||
| 8f79d2af3a | |||
| d6cb2c12c8 | |||
| 2fa53d1f2c | |||
| e0d2c536e4 | |||
| 8fafc843ef | |||
| 1f82ad4f0b | |||
| 7e016547ec | |||
| b4bff1e36d | |||
| 1f9477759d | |||
| cc7cec07df | |||
| be12afb50d | |||
| 9d761b2f81 | |||
| ba9c106a88 | |||
| 150ee40fd5 | |||
| ca0f8d390c | |||
| 62f0d42140 | |||
| 16f08dce7f | |||
| c06e7eb938 | |||
| 5a957bc745 | |||
| 67ac36e9e2 | |||
| 6ff0ffb80b | |||
| ff4998f31b | |||
| 1aa2f8ea5c | |||
| 6e7160efbb | |||
| 04c3c007a8 | |||
| ad7432155f | |||
| 0aaf865b75 | |||
| c9095e948b | |||
| ddb57e0120 | |||
| 9b851ce0e4 | |||
| f34cffb849 | |||
| 91994df910 | |||
| e84f334591 | |||
| ebf39263a6 | |||
| 77afe66aa6 | |||
| 788583ea23 | |||
| 4216b9ed6f | |||
| 54e639ecc3 | |||
| c980ced2fb | |||
| 9ca15a198f | |||
| 5c87c2b069 | |||
| 6c42ae9518 | |||
| f33492ef8e | |||
| ffcae79156 | |||
| a59a87374b | |||
| 88adfbdf89 | |||
| 0f717e81c0 | |||
| ede5958a46 | |||
| 0b3b160e87 | |||
| 12c6efc0fe | |||
| 0e930f7ae1 | |||
| 289f55dc19 | |||
| 0ddf0bdf42 | |||
| 03d826f1c4 | |||
| f94307cdbf | |||
| fde24f7438 | |||
| c0426f191a | |||
| e8a34ae4a4 | |||
| 18731498e8 | |||
| ad5c40b02b | |||
| e6b5997dff | |||
| 960d1d24be | |||
| 17047babc0 | |||
| 7bc8a4cb57 | |||
| d34b2a56d7 | |||
| 50a207b8ee | |||
| 6f140f096b | |||
| 316c62ebe8 | |||
| 1caa7acdc9 | |||
| f2f9e78559 | |||
| dd65d55389 | |||
| c7acf8ce38 | |||
| d7647a0b6f | |||
| ebaa1de00b | |||
| 0744af717d | |||
| 23f86d5982 | |||
| b854ae48e6 | |||
| 36a19a48b7 | |||
| 1f8a82228e | |||
| 60ed1c0264 | |||
| 3fae019148 | |||
| 8ef1e3840a | |||
| 629b3758b9 | |||
| 9412906b4f | |||
| f8cfad647f | |||
| b200623dca | |||
| 80f5994d96 | |||
| 342710a755 | |||
| 8eb642dbc8 | |||
| a4be8b395b | |||
| 47d6d02186 | |||
| a26ea62b60 | |||
| 7cff045cb3 | |||
| 9f080377e7 | |||
| fb40c8a4c3 | |||
| 0c248a4ca5 | |||
| 56d8a07893 | |||
| 8aab2ca693 | |||
| e46288dc45 | |||
| 637ffc12f5 | |||
| 2a40664bb6 | |||
| e34d2109ec | |||
| 54f89dad51 | |||
| 04b5017279 | |||
| a65a435b1d | |||
| 73dc916d5a | |||
| e8be3ae45b | |||
| 73ef9cc7a6 | |||
| 4adb754ae3 | |||
| 81709bb47e | |||
| 9c3a076e96 | |||
| 833edacc1f | |||
| 121a67a1fc | |||
| 8e3fb4038a | |||
| e9266cdead | |||
| 3a4cb538f7 | |||
| de84bc5ddf | |||
| 466c91a980 | |||
| 8d81f5e37c | |||
| 7dd01894da | |||
| 9665133ba4 | |||
| b272ed6181 | |||
| 17918a5617 | |||
| 493ee2da96 | |||
| 3d83e9fbdf | |||
| 684769df5a | |||
| 9bee463a3c | |||
| 805dc65ccb | |||
| a9d1c25ee4 | |||
| fe08bdc93c | |||
| 026d5ab2c3 | |||
| 311d846cb8 | |||
| 0888356292 | |||
| bcf0b68df9 | |||
| 034ef462a2 | |||
| 56610009e9 | |||
| 76b0383c2c | |||
| 0877a9d400 | |||
| 2731d9795f | |||
| 87a6da5c41 | |||
| e450f3fbc7 | |||
| cba6dd0a2f | |||
| fa5c014a1b | |||
| a172b1ea21 | |||
| 93d9164c6a | |||
| 72ebcf134a | |||
| effd3a265b | |||
| d41f3facd7 | |||
| c82d5602bb | |||
| 219f97bc00 | |||
| 2f6d67a03f | |||
| e97d4f921d | |||
| 5ffca36b84 | |||
| f4c056b99c | |||
| 3713fdae5b | 
							
								
								
									
										2
									
								
								.gitmodules
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.gitmodules
									
									
									
									
										vendored
									
									
								
							| @@ -1,4 +1,4 @@ | ||||
| [submodule "assets/jam"] | ||||
| 	path = assets/jam | ||||
| 	url = https://github.com/michaelampr/jam.git | ||||
| 	url = https://github.com/BBaoVanC/jam.git | ||||
| 	branch = master | ||||
|   | ||||
| @@ -1,2 +1,4 @@ | ||||
| # bobatheme | ||||
| Simple Hugo theme | ||||
|  | ||||
| The (boba) best Hugo theme. Contains everything I need for bbaovanc.com and | ||||
| boba.best. | ||||
|   | ||||
| @@ -8,13 +8,16 @@ comments: true | ||||
| draft: true | ||||
|  | ||||
| authors: | ||||
|   - {{ with .Site.Author.name }}{{ . }}{{ else }}John Doe{{ end }} | ||||
|   - {{ with .Site.Params.author.name }}{{ . }}{{ else }}John Doe{{ end }} | ||||
|  | ||||
| categories: | ||||
|   - archetype-stuff | ||||
|  | ||||
| tags: | ||||
|   - awesome | ||||
|  | ||||
| series: | ||||
|   - Archetype | ||||
|   - archetype | ||||
|  | ||||
| # this will be shown for the article in list pages and in the page metadata | ||||
| # it can be either an image or video (this might change in the future, however) | ||||
|   | ||||
							
								
								
									
										15
									
								
								archetypes/categories/_index.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								archetypes/categories/_index.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| --- | ||||
|  | ||||
| title: {{ replace .Name "-" " " | title }} | ||||
|  | ||||
| --- | ||||
|  | ||||
| A short summary of what the category is about. | ||||
|  | ||||
| <!--more--> | ||||
|  | ||||
| Optionally provide more information about the category here. This part will only | ||||
| show on the category page, not on the category list page. | ||||
|  | ||||
| If you delete this section, DO NOT delete the summary separator (`<!--more-->`) | ||||
| or else the summary won't be shown. | ||||
| @@ -6,7 +6,7 @@ toc: true | ||||
| comments: false | ||||
|  | ||||
| authors: | ||||
|   - {{ with .Site.Author.name }}{{ . }}{{ else }}John Doe{{ end }} | ||||
|   - {{ with .Site.params.author.name }}{{ . }}{{ else }}John Doe{{ end }} | ||||
|  | ||||
| --- | ||||
|  | ||||
|   | ||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							
							
								
								
									
										121
									
								
								assets/css/comments.css
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										121
									
								
								assets/css/comments.css
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,121 @@ | ||||
| /* Isso styling */ | ||||
| h4.isso-thread-heading { | ||||
|     color: var(--text-0); | ||||
|     margin-bottom: 8px; | ||||
| } | ||||
|  | ||||
| .isso-comment:not(:first-of-type), | ||||
| .isso-follow-up .isso-comment { | ||||
|     border-color: var(--background-3); | ||||
| } | ||||
|  | ||||
| .isso-author, | ||||
| .isso-page-author-suffix, | ||||
| .isso-comment-footer, | ||||
| .isso-comment-footer .isso-votes { | ||||
|     color: var(--text-gray-0); | ||||
| } | ||||
|  | ||||
| .isso-comment-header .isso-spacer, | ||||
| .isso-spacer:hover, | ||||
| .isso-permalink, | ||||
| .isso-permalink:hover { | ||||
|     color: var(--text-gray-1) !important; | ||||
| } | ||||
| a.isso-author:hover, | ||||
| .isso-permalink:hover { | ||||
|     text-decoration: underline !important; | ||||
| } | ||||
|  | ||||
| .isso-comment.isso-is-page-author > .isso-text-wrapper { | ||||
|     background-color: var(--background-accent-1); | ||||
| } | ||||
|  | ||||
| .isso-feedlink:hover, | ||||
| .isso-reply { | ||||
|     color: var(--link-0) !important; | ||||
|     text-shadow: unset !important; | ||||
| } | ||||
| .isso-reply:hover { | ||||
|     text-decoration: underline; | ||||
| } | ||||
|  | ||||
| .isso-text pre, | ||||
| .isso-text :not(pre) > code { | ||||
|     background-color: var(--background-2); | ||||
|     border: none; | ||||
|     padding: 2px 4px; | ||||
|     border-radius: 5px; | ||||
|     /* thanks isso.css for setting this to 85% for whatever reason */ | ||||
|     font-size: 0.75em; | ||||
| } | ||||
|  | ||||
| .isso-input-wrapper input, | ||||
| .isso-post-action > input, | ||||
| .isso-textarea, | ||||
| .isso-preview { | ||||
|     color: var(--text-1); | ||||
|     background-color: var(--background-1); | ||||
|     border-color: var(--background-2) !important; | ||||
| } | ||||
|  | ||||
| .isso-input-wrapper input:focus, | ||||
| .isso-textarea:focus { | ||||
|     border-color: var(--background-3) !important; | ||||
| } | ||||
|  | ||||
| .isso-post-action > input:hover { | ||||
|     background-color: var(--background-2); | ||||
| } | ||||
| .isso-post-action > input:focus, | ||||
| .isso-post-action > input:active { | ||||
|     background-color: var(--background-3); | ||||
| } | ||||
|  | ||||
| .isso-textarea { | ||||
|     margin-bottom: 4px; | ||||
| } | ||||
| .isso-input-wrapper { | ||||
|     display: inline-flex; | ||||
|     flex-direction: column; | ||||
|     margin-right: 4px; | ||||
|     max-width: 25%; | ||||
| } | ||||
| .isso-input-wrapper input { | ||||
|     order: 1; | ||||
| } | ||||
| .isso-input-wrapper label { | ||||
|     order: 2; | ||||
|     font-size: small; | ||||
| } | ||||
| .isso-post-action { | ||||
|     margin-left: 4px; | ||||
|     margin-top: 0; | ||||
| } | ||||
| @media screen and (max-width: 600px) { | ||||
|     .isso-input-wrapper { | ||||
|         display: block; | ||||
|         max-width: 100%; | ||||
|     } | ||||
| } | ||||
|  | ||||
| @media print { | ||||
|     .comments { | ||||
|         break-before: always; | ||||
|     } | ||||
|     .isso-comment { | ||||
|         max-width: unset; | ||||
|     } | ||||
|     .isso-text-wrapper { | ||||
|         break-inside: avoid; | ||||
|     } | ||||
|  | ||||
|     .isso-postbox, | ||||
|     .isso-feedlink { | ||||
|         display: none; | ||||
|     } | ||||
| } | ||||
|  | ||||
| .isso-target { | ||||
|     animation: target-fade 10s ease-out; /* defined in bobatheme */ | ||||
| } | ||||
							
								
								
									
										9
									
								
								assets/css/search.css
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								assets/css/search.css
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| /* put on body so it overrides the defaults set in :root by pagefind.css */ | ||||
| body { | ||||
|     /* https://pagefind.app/docs/ui-usage/#customising-the-styles */ | ||||
|     --pagefind-ui-background: var(--background-1); | ||||
|     --pagefind-ui-border: var(--background-2); | ||||
|     --pagefind-ui-primary: var(--link-0); | ||||
|     --pagefind-ui-tag: var(--background-1); | ||||
|     --pagefind-ui-text: var(--text-1); | ||||
| } | ||||
| @@ -1,14 +1,22 @@ | ||||
| /* tango style */ | ||||
|  | ||||
| @media print, (prefers-color-scheme: light) { | ||||
|   .chroma { | ||||
|     color: black; | ||||
|   } | ||||
|  | ||||
| /* Background */ .bg { background-color: #f8f8f8; } | ||||
| /* PreWrapper */ .chroma { background-color: #f8f8f8; } | ||||
| /* Other */ .chroma .x { color: #000000 } | ||||
| /* Error */ .chroma .err { color: #a40000 } | ||||
| /* CodeLine */ .chroma .cl {  } | ||||
| /* LineLink */ .chroma .lnlinks { outline: none; text-decoration: none; color: inherit } | ||||
| /* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; } | ||||
| /* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; width: auto; overflow: auto; display: block; } | ||||
| /* LineHighlight */ .chroma .hl { display: block; width: 100%;background-color: #ffffcc } | ||||
| /* LineNumbersTable */ .chroma .lnt { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } | ||||
| /* LineNumbers */ .chroma .ln { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } | ||||
| /* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; } | ||||
| /* LineHighlight */ .chroma .hl { background-color: #dfdfdf } | ||||
| /* LineNumbersTable */ .chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } | ||||
| /* LineNumbers */ .chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } | ||||
| /* Line */ .chroma .line { display: flex; } | ||||
| /* Keyword */ .chroma .k { color: #204a87; font-weight: bold } | ||||
| /* KeywordConstant */ .chroma .kc { color: #204a87; font-weight: bold } | ||||
| /* KeywordDeclaration */ .chroma .kd { color: #204a87; font-weight: bold } | ||||
| @@ -83,6 +91,7 @@ | ||||
| /* GenericTraceback */ .chroma .gt { color: #a40000; font-weight: bold } | ||||
| /* GenericUnderline */ .chroma .gl { color: #000000; text-decoration: underline } | ||||
| /* TextWhitespace */ .chroma .w { color: #f8f8f8; text-decoration: underline } | ||||
|  | ||||
| } | ||||
|  | ||||
| @media (prefers-color-scheme: light) { | ||||
|   | ||||
| @@ -1,11 +1,17 @@ | ||||
| /* Background */ .chroma { color: #d0d0d0; background-color: #202020 } | ||||
| /* native style */ | ||||
|  | ||||
| /* Background */ .bg { color: #d0d0d0; background-color: #202020; } | ||||
| /* PreWrapper */ .chroma { color: #d0d0d0; background-color: #202020; } | ||||
| /* Other */ .chroma .x {  } | ||||
| /* Error */ .chroma .err { color: #a61717; background-color: #e3d2d2 } | ||||
| /* CodeLine */ .chroma .cl {  } | ||||
| /* LineLink */ .chroma .lnlinks { outline: none; text-decoration: none; color: inherit } | ||||
| /* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; } | ||||
| /* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; width: auto; overflow: auto; display: block; } | ||||
| /* LineHighlight */ .chroma .hl { display: block; width: 100%;background-color: #363636 } | ||||
| /* LineNumbersTable */ .chroma .lnt { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #686868 } | ||||
| /* LineNumbers */ .chroma .ln { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #686868 } | ||||
| /* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; } | ||||
| /* LineHighlight */ .chroma .hl { background-color: #363636 } | ||||
| /* LineNumbersTable */ .chroma .lnt { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #686868 } | ||||
| /* LineNumbers */ .chroma .ln { white-space: pre; -webkit-user-select: none; user-select: none; margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #686868 } | ||||
| /* Line */ .chroma .line { display: flex; } | ||||
| /* Keyword */ .chroma .k { color: #6ab825; font-weight: bold } | ||||
| /* KeywordConstant */ .chroma .kc { color: #6ab825; font-weight: bold } | ||||
| /* KeywordDeclaration */ .chroma .kd { color: #6ab825; font-weight: bold } | ||||
|   | ||||
| @@ -1,8 +0,0 @@ | ||||
| const backToTop = document.getElementById("back-to-top"); | ||||
| window.onscroll = function() { | ||||
|     if (document.body.scrollTop > 100 || document.documentElement.scrollTop > 100) { | ||||
|         backToTop.style.display = "block"; | ||||
|     } else { | ||||
|         backToTop.style.display = "none"; | ||||
|     } | ||||
| } | ||||
							
								
								
									
										25
									
								
								assets/js/bobatheme.js
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								assets/js/bobatheme.js
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,25 @@ | ||||
| // code block copy to clipboard | ||||
| window.onload = () => { | ||||
|     document.querySelectorAll(".code-block").forEach(codeBlock => { | ||||
|         const button = codeBlock.querySelector(".code-header > .code-copy-button"); | ||||
|  | ||||
|         // lang will not be unset because we default it to text | ||||
|         // clone it so it doesn't change the actual DOM element | ||||
|         const codeElem = codeBlock.querySelector("code[data-lang]").cloneNode(true); | ||||
|         // bashsession: remove command output lines | ||||
|         codeElem.querySelectorAll(".go").forEach(e => e.parentNode.removeChild(e)); | ||||
|         // bashsession: remove prompt symbol | ||||
|         codeElem.querySelectorAll(".gp").forEach(e => e.parentNode.removeChild(e)); | ||||
|         const rawCode = codeElem.innerText; | ||||
|  | ||||
|         const originalCopyText = button.innerHTML; | ||||
|         button.onclick = event => { | ||||
|             navigator.clipboard.writeText(rawCode); | ||||
|             // TODO: maybe we could add a fancier indicator, like a flash or something | ||||
|             event.target.innerHTML = "Copied!"; | ||||
|             setTimeout(() => { | ||||
|                 event.target.innerHTML = originalCopyText; | ||||
|             }, 3000); | ||||
|         } | ||||
|     }); | ||||
| } | ||||
| @@ -1,12 +0,0 @@ | ||||
| 1: "enero" | ||||
| 2: "febrero" | ||||
| 3: "marzo" | ||||
| 4: "abril" | ||||
| 5: "mayo" | ||||
| 6: "julio" | ||||
| 7: "junio" | ||||
| 8: "agosto" | ||||
| 9: "septiembre" | ||||
| 10: "octubre" | ||||
| 11: "noviembre" | ||||
| 12: "diciembre" | ||||
| @@ -1,50 +0,0 @@ | ||||
| baseURL: https://example.com | ||||
| theme: bobatheme | ||||
| defaultContentLanguage: en | ||||
| copyright: '© 2021 bbaovanc <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/">CC BY-SA 4.0</a>' | ||||
| sectionPagesMenu: main | ||||
| enableRobotsTXT: true | ||||
| paginate: 5 | ||||
| enableGitInfo: true | ||||
|  | ||||
| taxonomies: | ||||
|   _merge: deep | ||||
|  | ||||
| author: | ||||
|   name: bbaovanc | ||||
|  | ||||
| markup: # this just keeps the bobatheme markup styling | ||||
|   _merge: deep | ||||
|  | ||||
| params: | ||||
|   # these are for the OpenGraph/Twitter embeds in Hugo | ||||
|   description: Example website for bobatheme | ||||
|  | ||||
|   # these are for favicons in bobatheme (defaults are shown here) | ||||
|   # faviconICO: favicon.ico | ||||
|   # faviconPNG: favicon.png | ||||
|  | ||||
|   # show reading time (enabled by default) | ||||
|   # readingtime: true | ||||
|  | ||||
|   # used for "View source" (unset by default) | ||||
|   # gitFileURL: https://github.com/BBaoVanC/bobatheme/blob/master | ||||
|   # gitFileIcon: github-circle | ||||
|  | ||||
| # see https://gohugo.io/about/hugo-and-gdpr/#all-privacy-settings | ||||
| # you probably want to keep this default | ||||
| privacy: | ||||
|   _merge: deep | ||||
|  | ||||
| languages: | ||||
|   en: | ||||
|     languageName: English | ||||
|     title: Example Website | ||||
|     weight: 1 | ||||
|  | ||||
|   es: | ||||
|     languageName: Español | ||||
|     title: Sitio web ejemplo | ||||
|     weight: 2 | ||||
|     params: | ||||
|       description: Sitio web ejemplo para bobatheme | ||||
| @@ -2,22 +2,36 @@ markup: | ||||
|   highlight: | ||||
|     noClasses: false | ||||
|     lineNos: true | ||||
|   goldmark: | ||||
|     parser: | ||||
|       attribute: | ||||
|         block: true | ||||
|         # this is enabled by default already | ||||
|         #title: true | ||||
| 
 | ||||
| params: | ||||
|   faviconICO: favicon.ico | ||||
|   faviconPNG: favicon.png | ||||
|   readingtime: true | ||||
| 
 | ||||
| taxonomies: | ||||
|   category: categories | ||||
|   tag: tags | ||||
|   author: authors | ||||
|   series: series | ||||
| 
 | ||||
| outputs: | ||||
|   page: | ||||
|     - html | ||||
|     - markdown | ||||
| 
 | ||||
| outputFormats: | ||||
|   markdown: | ||||
|     ugly: true | ||||
| 
 | ||||
| privacy: | ||||
|   googleAnalytics: | ||||
|     disable: true | ||||
| 
 | ||||
|   twitter: | ||||
|   x: | ||||
|     enableDNT: true | ||||
| 
 | ||||
|   vimeo: | ||||
							
								
								
									
										49
									
								
								i18n/en.yaml
									
									
									
									
									
								
							
							
						
						
									
										49
									
								
								i18n/en.yaml
									
									
									
									
									
								
							| @@ -7,12 +7,20 @@ table_of_contents: | ||||
|  | ||||
| browser_no_video_support: | ||||
|   other: "Your browser does not support video." | ||||
| browser_no_video_support_link: | ||||
|   other: "Click here to download it instead." | ||||
|  | ||||
| latest_posts: | ||||
|   other: "Latest Posts" | ||||
|  | ||||
| see_also: | ||||
|   other: "SEE ALSO:" | ||||
|  | ||||
| copy_to_clipboard: | ||||
|   other: "Copy" | ||||
|  | ||||
|  | ||||
| # Meta items | ||||
| long_date: | ||||
|   other: "{{ .Date.Format `January 2, 2006` }}" | ||||
|  | ||||
| wordcount: | ||||
|   one: "{{ . }} word" | ||||
|   other: "{{ . }} words" | ||||
| @@ -21,6 +29,12 @@ readingtime: | ||||
|   one: "{{ . }} min" | ||||
|   other: "{{ . }} mins" | ||||
|  | ||||
| edit_history: | ||||
|   other: "Edit history" | ||||
|  | ||||
| view_markdown: | ||||
|   other: "View raw" | ||||
|  | ||||
|  | ||||
| # Post count | ||||
| no_posts: | ||||
| @@ -36,7 +50,7 @@ read_more: | ||||
|   other: "Read more" | ||||
|  | ||||
| related_posts: | ||||
|   other: "Related posts" | ||||
|   other: "Related Posts" | ||||
|  | ||||
| older_post: | ||||
|   other: "Older" | ||||
| @@ -46,8 +60,8 @@ newer_post: | ||||
|  | ||||
|  | ||||
| # ARIA labels | ||||
| aria_header_link: | ||||
|   other: "header link" | ||||
| aria_heading_link: | ||||
|   other: "heading link" | ||||
|  | ||||
| aria_back_to_top_button: | ||||
|   other: "back to top button" | ||||
| @@ -55,11 +69,14 @@ aria_back_to_top_button: | ||||
| aria_rss_link: | ||||
|   other: "RSS feed link" | ||||
|  | ||||
| aria_post_meta_view_source: | ||||
|   other: "link to page source" | ||||
| aria_post_meta_edit_history: | ||||
|   other: "link to page edit history" | ||||
|  | ||||
| aria_post_meta_translations: | ||||
|   other: "translations" | ||||
| aria_post_meta_view_markdown: | ||||
|   other: "link to view raw markdown code of page" | ||||
|  | ||||
| aria_post_meta_categories: | ||||
|   other: "categories" | ||||
|  | ||||
| aria_post_meta_tags: | ||||
|   other: "tags" | ||||
| @@ -82,6 +99,9 @@ aria_post_metadata: | ||||
| aria_author_metadata: | ||||
|   other: "author metadata" | ||||
|  | ||||
| aria_taxonomy_metadata: | ||||
|   other: "taxonomy metadata" | ||||
|  | ||||
| aria_post_meta_date: | ||||
|   other: "date" | ||||
|  | ||||
| @@ -94,17 +114,14 @@ aria_author_post_count: | ||||
| aria_author_word_count: | ||||
|   other: "word count" | ||||
|  | ||||
| aria_taxonomy_post_count: | ||||
|   other: "post count" | ||||
|  | ||||
| aria_series_metadata: | ||||
|   other: "series metadata" | ||||
|  | ||||
| aria_navbar: | ||||
|   other: "navigation bar" | ||||
|  | ||||
| aria_langpicker: | ||||
|   other: "language picker" | ||||
|  | ||||
| aria_langpicker_list: | ||||
|   other: "language list" | ||||
|  | ||||
| aria_table_of_contents: | ||||
|   other: "table of contents" | ||||
|   | ||||
							
								
								
									
										110
									
								
								i18n/es.yaml
									
									
									
									
									
								
							
							
						
						
									
										110
									
								
								i18n/es.yaml
									
									
									
									
									
								
							| @@ -1,110 +0,0 @@ | ||||
| # Misc | ||||
| credit_comment: | ||||
|   other: "<!-- bobatheme está disponible en GitHub basado en la licensia MIT: https://github.com/BBaoVanC/bobatheme. -->" | ||||
|  | ||||
| table_of_contents: | ||||
|   other: "Índice" | ||||
|  | ||||
| browser_no_video_support: | ||||
|   other: "Tu navegador de internet no admite video." | ||||
|  | ||||
|  | ||||
| # Meta items | ||||
| long_date: | ||||
|   other: "{{ .Date.Day }} de {{ index .Data.meses (printf `%d` .Date.Month) }} de {{ .Date.Year }}" | ||||
|  | ||||
| wordcount: | ||||
|   one: "{{ . }} palabra" | ||||
|   other: "{{ . }} palabras" | ||||
|  | ||||
| readingtime: | ||||
|   one: "{{ . }} min" | ||||
|   other: "{{ . }} mins" | ||||
|  | ||||
|  | ||||
| # Post count | ||||
| no_posts: | ||||
|   other: "¡No hay contenido para mostrar!" | ||||
|  | ||||
| # post_count: | ||||
| #   one: "{{ . }} post" | ||||
| #   other: "{{ . }} posts" | ||||
|  | ||||
|  | ||||
| # Navigation | ||||
| read_more: | ||||
|   other: "Leer más" | ||||
|  | ||||
| related_posts: | ||||
|   other: "Publicaciones similares" | ||||
|  | ||||
| older_post: | ||||
|   other: "Más antiguo" | ||||
|  | ||||
| newer_post: | ||||
|   other: "Más nuevo" | ||||
|  | ||||
|  | ||||
| # ARIA labels | ||||
| # aria_header_link: | ||||
| #   other: "header link" | ||||
|  | ||||
| # aria_back_to_top_button: | ||||
| #   other: "back to top button" | ||||
|  | ||||
| # aria_rss_link: | ||||
| #   other: "RSS feed link" | ||||
|  | ||||
| # aria_post_meta_view_source: | ||||
| #   other: "link to page source" | ||||
|  | ||||
| # aria_post_meta_translations: | ||||
| #   other: "translations" | ||||
|  | ||||
| # aria_post_meta_tags: | ||||
| #   other: "tags" | ||||
|  | ||||
| # aria_post_meta_reading_time: | ||||
| #   other: "reading time" | ||||
|  | ||||
| # aria_post_meta_authors: | ||||
| #   other: "authors" | ||||
|  | ||||
| # aria_post_meta_series: | ||||
| #   other: "series" | ||||
|  | ||||
| # aria_breadcrumbnav: | ||||
| #   other: "breadcrumb navigation bar" | ||||
|  | ||||
| # aria_post_metadata: | ||||
| #   other: "post metadata" | ||||
|  | ||||
| # aria_author_metadata: | ||||
| #   other: "author metadata" | ||||
|  | ||||
| # aria_post_meta_date: | ||||
| #   other: "date" | ||||
|  | ||||
| # aria_post_meta_modified_date: | ||||
| #   other: "last modified date" | ||||
|  | ||||
| # aria_author_post_count: | ||||
| #   other: "post count" | ||||
|  | ||||
| # aria_author_word_count: | ||||
| #   other: "word count" | ||||
|  | ||||
| # aria_series_metadata: | ||||
| #   other: "series metadata" | ||||
|  | ||||
| # aria_navbar: | ||||
| #   other: "navigation bar" | ||||
|  | ||||
| # aria_langpicker: | ||||
| #   other: "language picker" | ||||
|  | ||||
| # aria_langpicker_list: | ||||
| #   other: "language list" | ||||
|  | ||||
| # aria_table_of_contents: | ||||
| #   other: "table of contents" | ||||
| @@ -1,8 +0,0 @@ | ||||
| <h{{ .Level }} id="{{ .Anchor | safeURL }}" class="section-header"> | ||||
|     {{ .Text | safeHTML }} | ||||
|     <a href="#{{ .Anchor | safeURL }}"> | ||||
|         <span class="section-header-link" aria-label="{{ i18n "aria_header_link" }}"> | ||||
|             {{ partial "icon.html" "link" }} | ||||
|         </span> | ||||
|     </a> | ||||
| </h{{ .Level }}> | ||||
| @@ -1,50 +0,0 @@ | ||||
| {{ partial "credit.html" }} | ||||
| <!DOCTYPE html> | ||||
| <html lang="{{ .Language.Lang }}"> | ||||
|     {{ partial "head.html" . }} | ||||
|  | ||||
|     <body> | ||||
|         <a id="top" name="top" aria-hidden="true"></a> | ||||
|  | ||||
|         <div class="top"> | ||||
|             {{ partial "top.html" . }} | ||||
|         </div> | ||||
|  | ||||
|         {{ if not .IsHome }} | ||||
|             {{ partial "breadcrumb.html" . }} | ||||
|         {{ end }} | ||||
|  | ||||
|         <main> | ||||
|             {{ block "main" . }} | ||||
|                 {{ .Content }} | ||||
|             {{ end }} | ||||
|         </main> | ||||
|  | ||||
|         {{ if or .Site.Copyright .Site.Params.footer }} | ||||
|             <hr> | ||||
|             <footer> | ||||
|                 <small> | ||||
|                     {{ with .Site.Copyright }} | ||||
|                         <p>{{ . | safeHTML }}</p> | ||||
|                     {{ end }} | ||||
|  | ||||
|                     {{ with .Site.Params.footer }} | ||||
|                         {{ . | $.RenderString (dict "display" "block") }} | ||||
|                     {{ end }} | ||||
|                 </small> | ||||
|             </footer> | ||||
|         {{ end }} | ||||
|  | ||||
|         <a id="back-to-top" href="#top" aria-label="{{ i18n "aria_back_to_top_button" }}"> | ||||
|             {{ partial "icon.html" "chevron-up" }} | ||||
|         </a> | ||||
|         <noscript> | ||||
|             <style> | ||||
|                 #back-to-top { | ||||
|                     display: block; | ||||
|                 } | ||||
|             </style> | ||||
|         </noscript> | ||||
|     </body> | ||||
|  | ||||
| </html> | ||||
| @@ -1,33 +0,0 @@ | ||||
| {{ define "main" }} | ||||
|     <h1> | ||||
|         {{ with .Params.icon }}{{ partial "icon.html" . }}{{ end }} | ||||
|         {{ .Title | markdownify }} | ||||
|         {{ partial "rss-link.html" . }} | ||||
|     </h1> | ||||
|  | ||||
|     <div class="list-page-content"> | ||||
|         {{ with .Sections }} | ||||
|             <div class="sections"> | ||||
|                 {{ range . }} | ||||
|                     {{ .Render "summary/section" }} | ||||
|                 {{ end }} | ||||
|             </div> | ||||
|         {{ end }} | ||||
|  | ||||
|         <div class="page-list"> | ||||
|             {{ with .Paginator.Pages }} | ||||
|                 <ul> | ||||
|                     {{ range . }} | ||||
|                         <li>{{ .Render "summary/post" }}</li> | ||||
|                     {{ end }} | ||||
|                 </ul> | ||||
|             {{ else }} | ||||
|                 <div> | ||||
|                     {{ i18n "no_posts" }} | ||||
|                 </div> | ||||
|             {{ end }} | ||||
|         </div> | ||||
|     </div> | ||||
|  | ||||
|     {{ partial "pagination.html" . }} | ||||
| {{ end }} | ||||
| @@ -1,16 +0,0 @@ | ||||
| <div class="author"> | ||||
|     <h2 class="author-name"> | ||||
|         <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a> | ||||
|         {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
|     </h2> | ||||
|  | ||||
|     {{ partial "post-metadata/author.html" . }} | ||||
|  | ||||
|     <div class="author-description"> | ||||
|         {{ partial "description-or-summary.html" . }} | ||||
|     </div> | ||||
|  | ||||
|     <div class="readmore"> | ||||
|         <a href="{{ .Permalink }}">{{ i18n "read_more" }} →</a> | ||||
|     </div> | ||||
| </div> | ||||
| @@ -1,23 +0,0 @@ | ||||
| <div class="post"> | ||||
|     <h2 class="post-title"> | ||||
|         {{ with .Parent.Params.icon }}{{ partial "icon.html" . }}{{ end }} | ||||
|         <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a> | ||||
|         {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
|     </h2> | ||||
|  | ||||
|     {{ partial "post-metadata/short.html" . }} | ||||
|  | ||||
|     {{ with .Resources.GetMatch "feature" }} | ||||
|         <div class="post-media"> | ||||
|             {{ partial "figure.html" (dict "src" . "border" true) }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="post-description"> | ||||
|         {{ partial "description-or-summary.html" . }} | ||||
|     </div> | ||||
|  | ||||
|     <div class="readmore"> | ||||
|         <a href="{{ .Permalink }}">{{ i18n "read_more" }} →</a> | ||||
|     </div> | ||||
| </div> | ||||
| @@ -1,26 +0,0 @@ | ||||
| <div class="post"> | ||||
|     <h2 class="post-title"> | ||||
|         {{ with .Parent.Params.icon }}{{ partial "icon.html" . }}{{ end }} | ||||
|         <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a> | ||||
|         {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
|     </h2> | ||||
|  | ||||
|     {{ partial "post-metadata/series.html" . }} | ||||
|  | ||||
|     <div class="post-description"> | ||||
|         {{ partial "description-or-summary.html" . }} | ||||
|     </div> | ||||
|  | ||||
|     <div class="series-pages"> | ||||
|         <ul> | ||||
|             {{ $i := 0 }} | ||||
|             {{ $total := len .Data.Pages }} | ||||
|             {{ range .Data.Pages.Reverse }} | ||||
|                 {{ $i = add 1 $i }} | ||||
|                 {{ .Scratch.Set "series_position" $i }} | ||||
|                 {{ .Scratch.Set "series_total" $total }} | ||||
|                 <li>{{ .Render "summary/series_post" }}</li> | ||||
|             {{ end }} | ||||
|         </ul> | ||||
|     </div> | ||||
| </div> | ||||
| @@ -1,29 +0,0 @@ | ||||
| <div class="post"> | ||||
|     <div class="post-series-position"> | ||||
|         {{ if .Scratch.Get "series_position" }} | ||||
|             ({{ .Scratch.Get "series_position" }}/{{ .Scratch.Get "series_total" }}) | ||||
|         {{ end }} | ||||
|     </div> | ||||
|  | ||||
|     <h2 class="post-title"> | ||||
|         {{ with .Parent.Params.icon }}{{ partial "icon.html" . }}{{ end }} | ||||
|         <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a> | ||||
|         {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
|     </h2> | ||||
|  | ||||
|     {{ partial "post-metadata/short.html" . }} | ||||
|  | ||||
|     {{ with .Resources.GetMatch "feature" }} | ||||
|         <div class="post-media"> | ||||
|             {{ partial "figure.html" (dict "src" . "border" true) }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="post-description"> | ||||
|         {{ partial "description-or-summary.html" . }} | ||||
|     </div> | ||||
|  | ||||
|     <div class="readmore"> | ||||
|         <a href="{{ .Permalink }}">{{ i18n "read_more" }} →</a> | ||||
|     </div> | ||||
| </div> | ||||
							
								
								
									
										15
									
								
								layouts/_markup/render-codeblock.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								layouts/_markup/render-codeblock.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| {{ $type := "text" }} | ||||
| {{ with .Type }} | ||||
|     {{ $type = . }} | ||||
| {{ end }} | ||||
| <div class="code-block"> | ||||
|     <div class="code-header"> | ||||
|         <pre class="code-type">{{ $type }}</pre> | ||||
|         <a href="javascript:void(0)" class="code-copy-button"> | ||||
|             {{ i18n "copy_to_clipboard" }} | ||||
|         </a> | ||||
|     </div> | ||||
|  | ||||
|     {{/* a div.highlight is already created by highlight function */}} | ||||
|     {{ highlight .Inner $type }} | ||||
| </div> | ||||
							
								
								
									
										8
									
								
								layouts/_markup/render-heading.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								layouts/_markup/render-heading.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| <h{{ .Level }} id="{{ .Anchor | safeURL }}" class="section-heading"> | ||||
|     {{ .Text | safeHTML }} | ||||
|     <a class="content-heading-link" href="#{{ .Anchor | safeURL }}"> | ||||
|         <span aria-label="{{ i18n "aria_heading_link" }}"> | ||||
|             {{ partial "icon.html" "link" }} | ||||
|         </span> | ||||
|     </a> | ||||
| </h{{ .Level }}> | ||||
							
								
								
									
										15
									
								
								layouts/_partials/comments.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								layouts/_partials/comments.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,15 @@ | ||||
| {{ with resources.Get "css/comments.css" | fingerprint "sha512" }} | ||||
|     <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"> | ||||
| {{ end }} | ||||
|  | ||||
| <h2 style="margin-bottom: 0;">Comments</h2> | ||||
| <p style="margin: 0; font-size: smaller;"> | ||||
|     If you provide an email address, you can enable notifications for | ||||
|     replies to your comment. It will not be shown publicly. | ||||
| </p> | ||||
|  | ||||
| <noscript> | ||||
|     <i>Enable JavaScript to see the comment section.</i> | ||||
| </noscript> | ||||
|  | ||||
| <section id="isso-thread" data-title="{{ .Title }}"></section> | ||||
							
								
								
									
										23
									
								
								layouts/_partials/embed-resource.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								layouts/_partials/embed-resource.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,23 @@ | ||||
| {{ if eq .ResourceType "image" }} | ||||
|     {{/* TODO: figure out whether loading="lazy" should be set because MDN | ||||
|        *       claims that images won't work with JS disabled since it would | ||||
|        *       make tracking possible, but my experience says otherwise | ||||
|        */}} | ||||
|     <img class="figure-media" src="{{ .Permalink }}" {{ with .Params.alt }}alt="{{ . }}"{{ end }} /> | ||||
| {{ else if eq .ResourceType "video" }} | ||||
|     <video class="figure-media" controls preload="metadata"> | ||||
|         {{ with .Params.alt }} | ||||
|             {{ warnf "video does not support alt text, '%s'" . }} | ||||
|         {{ end }} | ||||
|         <source src="{{ .Permalink }}" /> | ||||
|         {{ i18n "browser_no_video_support" }} | ||||
|         <a href="{{ .Permalink }}" target="_blank" rel="noopener"> | ||||
|             {{ i18n "browser_no_video_support_link" }} | ||||
|         </a> | ||||
|     </video> | ||||
| {{ else }} | ||||
|     {{/* TODO: could consider implementing more types, listed at: | ||||
|        * https://www.iana.org/assignments/media-types/media-types.xhtml | ||||
|        */}} | ||||
|     {{ errorf "Handling %q resource not supported" .ResourceType }} | ||||
| {{ end }} | ||||
							
								
								
									
										10
									
								
								layouts/_partials/feature-figure.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								layouts/_partials/feature-figure.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | ||||
| {{ with .Resources.Get "feature" }} | ||||
|     <div class="post-media"> | ||||
|         <figure> | ||||
|             {{ partial "embed-resource.html" . }} | ||||
|             {{ with .Title }} | ||||
|                 <figcaption>{{ . | markdownify }}</figcaption> | ||||
|             {{ end }} | ||||
|         </figure> | ||||
|     </div> | ||||
| {{ end }} | ||||
							
								
								
									
										97
									
								
								layouts/_partials/head.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										97
									
								
								layouts/_partials/head.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,97 @@ | ||||
| <head> | ||||
|     <meta charset="UTF-8"> | ||||
|     <meta name="viewport" content="width=device-width, initial-scale=1"> | ||||
|     {{ hugo.Generator }} | ||||
|  | ||||
|     {{ with resources.Get "css/bobastyle.css" | fingerprint "sha512" }} | ||||
|         <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"> | ||||
|     {{ end }} | ||||
|     {{ with resources.Get "css/syntax.css" | fingerprint "sha512" }} | ||||
|         <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous" media="print" onload="this.media='all'"> | ||||
|     {{ end }} | ||||
|     {{ with resources.Get "css/syntax-light.css" | fingerprint "sha512" }} | ||||
|         <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous" media="print" onload="this.media='all'"> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ with resources.Get "js/bobatheme.js" | fingerprint "sha512" }} | ||||
|         <script defer src="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"></script> | ||||
|     {{ end }} | ||||
|     {{ if not hugo.IsServer }} | ||||
|         <script defer data-domain="bbaovanc.com" src="https://plausible.bbaovanc.com/js/bobalytics.outbound-links.js"></script> | ||||
|         <script>window.plausible = window.plausible || function() { (window.plausible.q = window.plausible.q || []).push(arguments) }</script> | ||||
|     {{ end }} | ||||
|     {{ $isso_url := .Permalink }} | ||||
|     {{ if .IsTranslated }} | ||||
|         {{ with index .AllTranslations 0 }} | ||||
|             {{ $isso_url = .Permalink }} | ||||
|         {{ end }} | ||||
|     {{ end }} | ||||
|     <script defer src="https://isso.bbaovanc.com/js/embed.min.js" | ||||
|             data-isso-id="{{ $isso_url }}" | ||||
|             data-isso-default-lang="{{ .Language.Lang }}" | ||||
|             data-isso-css="true" | ||||
|             data-isso-max-comments-top="inf" | ||||
|             data-isso-max-comments-nested="inf" | ||||
|             data-isso-reveal-on-click="5" | ||||
|             {{/* | ||||
|             data-isso-avatar-bg="#111" | ||||
|             data-isso-avatar-fg="#9abf88 #5698c4 #e279a3 #9163b6 ..." | ||||
|             */}} | ||||
|             data-isso-vote="true" | ||||
|             {{/* | ||||
|             data-isso-vote-levels="" | ||||
|             */}} | ||||
|             data-isso-feed="true" | ||||
|             data-isso-require-email="false" | ||||
|             data-isso-reply-notifications="true" | ||||
|             data-isso-reply-notifications-default-enabled="true" | ||||
|  | ||||
|             {{ with (.GetTerms "authors") }} | ||||
|                 {{ $authorHashes := slice }} | ||||
|                 {{ range . }} | ||||
|                     {{ with .Params.issoUserID }} | ||||
|                         {{ $authorHashes = $authorHashes | append . }} | ||||
|                     {{ end }} | ||||
|                 {{ end }} | ||||
|  | ||||
|                 data-isso-page-author-hashes="{{ delimit $authorHashes "," }}" | ||||
|             {{ end }} | ||||
|             > | ||||
|     </script> | ||||
|  | ||||
|     {{ if eq .Layout "search" }} | ||||
|         {{ with resources.Get "css/search.css" | fingerprint "sha512" }} | ||||
|             <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"> | ||||
|         {{ end }} | ||||
|  | ||||
|         <link rel="stylesheet" type="text/css" href="{{ absURL "pagefind/pagefind-ui.css" }}" crossorigin="anonymous"> | ||||
|         <script src="{{ absURL "pagefind/pagefind-ui.js" }}" crossorigin="anonymous"></script> | ||||
|         <script> | ||||
|             window.addEventListener('DOMContentLoaded', (event) => { | ||||
|                 new PagefindUI({ element: "#search-box", showSubResults: true }); | ||||
|             }); | ||||
|         </script> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ with .Site.Params.faviconSVG }} | ||||
|         <link rel="icon" href="{{ . | absURL }}" /> | ||||
|     {{ end }} | ||||
|     {{ with .Site.Params.appleTouchPNG }} | ||||
|         <link rel="apple-touch-icon" href="{{ . | absURL }}" /> | ||||
|     {{ end }} | ||||
|  | ||||
|     <title>{{ .Render "head_title" }}</title> | ||||
|  | ||||
|     {{ range .Site.Params.rel_me }} | ||||
|         <link rel="me" href="{{ . }}" /> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ partial "seo-tags/opengraph.html" . }} | ||||
|     {{ partial "seo-tags/twitter-cards.html" . }} | ||||
|     {{ partial "seo-tags/schema.html" . }} | ||||
|     {{ partial "seo-tags/link.html" . }} | ||||
|     {{ partial "seo-tags/author.html" . }} | ||||
|  | ||||
|     <meta name="language" content="{{ .Language.Lang }}"> | ||||
|     <meta name="description" content="{{ (partial "seo-description.html" .) | plainify }}"> | ||||
| </head> | ||||
							
								
								
									
										1
									
								
								layouts/_partials/icon.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								layouts/_partials/icon.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | ||||
| {{ partialCached "icon_code.html" . . }} | ||||
| @@ -1,5 +1,6 @@ | ||||
| {{- $icon_resource := resources.Get (printf "jam/icons/%s.svg" .) -}} | ||||
| {{- $icon := $icon_resource.Content -}} | ||||
| {{- $icon = replaceRE `<svg` `<svg class="icon"` $icon -}} | ||||
| {{- $icon = replaceRE `<svg` (printf `<svg class="icon icon-%s"` .) $icon -}} | ||||
| {{- $icon = replaceRE `</svg>` (printf `<title>%s icon</title></svg>` .) $icon -}} | ||||
| {{- $icon = replaceRE `(width|height)="[0-9]*"` "" $icon -}} | ||||
| {{- $icon | safeHTML -}} | ||||
							
								
								
									
										13
									
								
								layouts/_partials/page-list.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								layouts/_partials/page-list.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,13 @@ | ||||
| <div class="page-list"> | ||||
|     {{ with . }} | ||||
|         {{ range . }} | ||||
|             <article class="page"> | ||||
|                 {{ .Render "summary" }} | ||||
|             </article> | ||||
|         {{ end }} | ||||
|     {{ else }} | ||||
|         <div> | ||||
|             {{ i18n "no_posts" }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
| </div> | ||||
| @@ -1,16 +1,16 @@ | ||||
| <div class="author-metadata" aria-label="{{ i18n "aria_author_metadata" }}"> | ||||
| <div class="page-metadata" aria-label="{{ i18n "aria_author_metadata" }}"> | ||||
|     {{/* Calculate the total word count */}} | ||||
|     {{ $total_words := 0 }} | ||||
|     {{ range .Data.Pages }} | ||||
|         {{ $total_words = add $total_words .WordCount }} | ||||
|     {{ end }} | ||||
| 
 | ||||
|     <span class="author-meta-item" aria-label="{{ i18n "aria_author_post_count" }}"> | ||||
|     <span class="page-metadata-item" aria-label="{{ i18n "aria_author_post_count" }}"> | ||||
|         {{ partial "icon.html" "newspaper" }} | ||||
|         {{ i18n "post_count" (len .Data.Pages) }} | ||||
|     </span> | ||||
| 
 | ||||
|     <span class="author-meta-item" aria-label="{{ i18n "aria_author_word_count" }}"> | ||||
|     <span class="page-metadata-item" aria-label="{{ i18n "aria_author_word_count" }}"> | ||||
|         {{ partial "icon.html" "align-left" }} | ||||
|         {{ i18n "wordcount" $total_words }} | ||||
|     </span> | ||||
| @@ -1,14 +1,14 @@ | ||||
| {{ with .Params.authors }} | ||||
|     <span class="post-meta-item" aria-label="{{ i18n "aria_post_meta_authors" }}"> | ||||
|     <span class="page-metadata-item" data-pagefind-meta="authors" aria-label="{{ i18n "aria_post_meta_authors" }}"> | ||||
|         {{ partial "icon.html" "user-circle" }} | ||||
| 
 | ||||
|         {{ if index $.Site.Taxonomies "authors" }} | ||||
|             {{ $authors := slice }} | ||||
|             {{ range . }} | ||||
|                 {{ $url := (printf "authors/%s" (. | anchorize)) | absLangURL }} | ||||
|                 {{ $authors = $authors | append (printf `<a href="%s">%s</a>` $url . | safeHTML) }} | ||||
|                 {{ $authors = $authors | append (printf `<a href="%s">%s</a>` $url .) }} | ||||
|             {{ end }} | ||||
|             {{ delimit $authors ", " }} | ||||
|             {{ delimit $authors ", " | safeHTML }} | ||||
|         {{ else }} | ||||
|             {{ delimit . ", " }} | ||||
|         {{ end }} | ||||
							
								
								
									
										11
									
								
								layouts/_partials/page-metadata/item/categories.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								layouts/_partials/page-metadata/item/categories.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,11 @@ | ||||
| {{ with (.GetTerms "categories") }} | ||||
|     {{ $categories := slice }} | ||||
|     {{ range . }} | ||||
|         {{ $categories = $categories | append (printf `<a href="%s">%s</a>` .Permalink .LinkTitle) }} | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="page-metadata-section categories" data-pagefind-meta="categories" aria-label="{{ i18n "aria_post_meta_categories" }}"> | ||||
|         {{ partial "icon.html" "folder" }} | ||||
|         {{ delimit $categories ", " | safeHTML }} | ||||
|     </div> | ||||
| {{ end }} | ||||
| @@ -0,0 +1,8 @@ | ||||
| <span class="page-metadata-item" aria-label="comments counter"> | ||||
|     {{ partial "icon.html" "message" }} | ||||
|     {{/* TODO: figure out if there's a nicer way to generate this URL | ||||
|        * the current issue is that we can't use RelRef, since content view means that we don't | ||||
|        * have access to the original page context | ||||
|        */}} | ||||
|     <a href="{{ .RelPermalink }}#isso-thread">comments</a> | ||||
| </span> | ||||
							
								
								
									
										8
									
								
								layouts/_partials/page-metadata/item/edithistory.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								layouts/_partials/page-metadata/item/edithistory.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| {{ if and .Site.Params.gitHistoryURL .File.Path }} | ||||
|     <span class="page-metadata-item post-meta-edit-history" aria-label="{{ i18n "aria_post_meta_edit_history" }}"> | ||||
|         {{ partial "icon.html" "history" }} | ||||
|         <a href="{{ printf "%s/content/%s" .Site.Params.gitHistoryURL .File.Path }}" target="_blank" rel="noopener"> | ||||
|             {{- i18n "edit_history" -}} | ||||
|         </a> | ||||
|     </span> | ||||
| {{ end }} | ||||
| @@ -1,5 +1,5 @@ | ||||
| {{ if ne .Site.Params.readingtime false }} | ||||
|     <span class="post-meta-item" aria-label="{{ i18n "aria_post_meta_reading_time" }}"> | ||||
|     <span class="page-metadata-item" aria-label="{{ i18n "aria_post_meta_reading_time" }}"> | ||||
|         {{ partial "icon.html" "clock" }} | ||||
|         {{ i18n "readingtime" .ReadingTime }} | ||||
|     </span> | ||||
| @@ -4,8 +4,8 @@ | ||||
|         {{ $series = $series | append (printf `<a href="%s">%s</a>` .Permalink .LinkTitle) }} | ||||
|     {{ end }} | ||||
| 
 | ||||
|     <div class="series" aria-label="{{ i18n "aria_post_meta_series" }}"> | ||||
|     <div class="page-metadata-section series" data-pagefind-meta="series" aria-label="{{ i18n "aria_post_meta_series" }}"> | ||||
|         {{ partial "icon.html" "files" }} | ||||
|         {{ delimit $series ", " }} | ||||
|         {{ delimit $series ", " | safeHTML }} | ||||
|     </div> | ||||
| {{ end }} | ||||
| @@ -4,8 +4,8 @@ | ||||
|         {{ $tags = $tags | append (printf `<a href="%s">%s</a>` .Permalink .LinkTitle) }} | ||||
|     {{ end }} | ||||
| 
 | ||||
|     <div class="tags" aria-label="{{ i18n "aria_post_meta_tags" }}"> | ||||
|     <div class="page-metadata-section tags" data-pagefind-meta="tags" aria-label="{{ i18n "aria_post_meta_tags" }}"> | ||||
|         {{ partial "icon.html" "tag" }} | ||||
|         {{ delimit $tags ", " }} | ||||
|         {{ delimit $tags ", " | safeHTML }} | ||||
|     </div> | ||||
| {{ end }} | ||||
							
								
								
									
										8
									
								
								layouts/_partials/page-metadata/item/viewraw.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								layouts/_partials/page-metadata/item/viewraw.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| {{ with .OutputFormats.Get "markdown" }} | ||||
|     <span class="page-metadata-item post-meta-view-markdown" aria-label="{{ i18n "aria_post_meta_view_markdown" }}"> | ||||
|         {{ partial "icon.html" "code" }} | ||||
|         <a href="{{ .Permalink }}" target="_blank"> | ||||
|             {{- i18n "view_markdown" -}} | ||||
|         </a> | ||||
|     </span> | ||||
| {{ end }} | ||||
							
								
								
									
										30
									
								
								layouts/_partials/page-metadata/post-full.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										30
									
								
								layouts/_partials/page-metadata/post-full.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,30 @@ | ||||
| {{ if or .Date .Params.authors .Site.Params.readingtime .Site.Params.gitFileURL }} | ||||
|     <div class="page-metadata" aria-label="{{ i18n "aria_post_metadata" }}"> | ||||
|         {{ if .Date }} | ||||
|             <span class="page-metadata-item" aria-label="{{ i18n "aria_post_meta_date" }}"> | ||||
|                 {{ partial "icon.html" "calendar" }} | ||||
|                 {{ partial "time-element.html" .Date }} | ||||
|             </span> | ||||
|  | ||||
|             {{/* TODO: make this be a tooltip */}} | ||||
|             {{/* DISABLED | ||||
|             {{ if ne (time.Format "2006-01-02" .Lastmod) (time.Format "2006-01-02" .Date) }} | ||||
|                 <span class="page-metadata-item" aria-label="{{ i18n "aria_post_meta_modified_date" }}"> | ||||
|                     {{ partial "icon.html" "pencil" }} | ||||
|                     {{ partial "time-element.html" .Lastmod }} | ||||
|                     {{ end }} | ||||
|                 </span> | ||||
|             */}} | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ partial "page-metadata/item/authors.html" . }} | ||||
|         {{ partial "page-metadata/item/readingtime.html" . }} | ||||
|         {{ partial "page-metadata/item/edithistory.html" . }} | ||||
|         {{ partial "page-metadata/item/viewraw.html" . }} | ||||
|         {{ partial "page-metadata/item/comments-counter.html" . }} | ||||
|  | ||||
|         {{ partial "page-metadata/item/categories.html" . }} | ||||
|  | ||||
|         {{ partial "page-metadata/item/tags.html" . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
							
								
								
									
										18
									
								
								layouts/_partials/page-metadata/post-short.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								layouts/_partials/page-metadata/post-short.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,18 @@ | ||||
| {{ if or .Date .Params.authors .Site.Params.readingtime }} | ||||
|     <div class="page-metadata" aria-label="{{ i18n "aria_post_metadata" }}"> | ||||
|         {{ if .Date }} | ||||
|             <span class="page-metadata-item" aria-label="date"> | ||||
|                 {{ partial "icon.html" "calendar" }} | ||||
|                 {{ partial "time-element.html" .Date }} | ||||
|             </span> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ partial "page-metadata/item/authors.html" . }} | ||||
|         {{ partial "page-metadata/item/readingtime.html" . }} | ||||
|         {{ partial "page-metadata/item/comments-counter.html" . }} | ||||
|  | ||||
|         {{ partial "page-metadata/item/series.html" . }} | ||||
|         {{ partial "page-metadata/item/categories.html" . }} | ||||
|         {{ partial "page-metadata/item/tags.html" . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
| @@ -1,11 +1,11 @@ | ||||
| <div class="post-metadata" aria-label="{{ i18n "aria_series_metadata" }}"> | ||||
|     <span class="post-meta-item"> | ||||
| <div class="page-metadata" aria-label="{{ i18n "aria_series_metadata" }}"> | ||||
|     <span class="page-metadata-item"> | ||||
|         {{ partial "icon.html" "newspaper" }} | ||||
|         {{ i18n "post_count" (len .Data.Pages) }} | ||||
|     </span> | ||||
| 
 | ||||
|     {{ if ne .Site.Params.readingtime false }} | ||||
|         <span class="post-meta-item"> | ||||
|         <span class="page-metadata-item"> | ||||
|             {{ partial "icon.html" "clock" }} | ||||
|             {{ $readingtime := 0 }} | ||||
|             {{ range .Data.Pages }} | ||||
| @@ -14,9 +14,4 @@ | ||||
|             {{ i18n "readingtime" $readingtime }} | ||||
|         </span> | ||||
|     {{ end }} | ||||
| 
 | ||||
|     {{ partial "post-meta-item/translations.html" . }} | ||||
|     {{ if .File }} | ||||
|         {{ partial "post-meta-item/viewsource.html" . }} | ||||
|     {{ end }} | ||||
| </div> | ||||
							
								
								
									
										6
									
								
								layouts/_partials/page-metadata/taxonomy.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								layouts/_partials/page-metadata/taxonomy.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | ||||
| <div class="taxonomy-metadata" aria-label="{{ i18n "aria_taxonomy_metadata" }}"> | ||||
|     <span class="taxonomy-meta-item" aria-label="{{ i18n "aria_taxonomy_post_count" }}"> | ||||
|         {{ partial "icon.html" "newspaper" }} | ||||
|         {{ i18n "post_count" (len .Data.Pages) }} | ||||
|     </span> | ||||
| </div> | ||||
							
								
								
									
										154
									
								
								layouts/_partials/pagination-hugo.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										154
									
								
								layouts/_partials/pagination-hugo.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,154 @@ | ||||
| {{- $validFormats := slice "default" "terse" }} | ||||
|  | ||||
| {{- $msg1 := "When passing a map to the internal pagination template, one of the elements must be named 'page', and it must be set to the context of the current page." }} | ||||
| {{- $msg2 := "The 'format' specified in the map passed to the internal pagination template is invalid. Valid choices are: %s." }} | ||||
|  | ||||
| {{- $page := . }} | ||||
| {{- $format := "default" }} | ||||
|  | ||||
| {{- if reflect.IsMap . }} | ||||
|   {{- with .page }} | ||||
|     {{- $page = . }} | ||||
|   {{- else }} | ||||
|     {{- errorf $msg1 }} | ||||
|   {{- end }} | ||||
|   {{- with .format }} | ||||
|     {{- $format = lower . }} | ||||
|   {{- end }} | ||||
| {{- end }} | ||||
|  | ||||
| {{- if in $validFormats $format }} | ||||
|   {{- if gt $page.Paginator.TotalPages 1 }} | ||||
|     <ul class="pagination pagination-{{ $format }}"> | ||||
|       {{- partial (printf "inline/pagination/%s.html" $format) $page }} | ||||
|     </ul> | ||||
|   {{- end }} | ||||
| {{- else }} | ||||
|   {{- errorf $msg2 (delimit $validFormats ", ") }} | ||||
| {{- end -}} | ||||
|  | ||||
| {{/* Format: default | ||||
| {{/* --------------------------------------------------------------------- */}} | ||||
| {{- define "_partials/inline/pagination/default.html" }} | ||||
|   {{- with .Paginator }} | ||||
|     {{- $currentPageNumber := .PageNumber }} | ||||
|  | ||||
|     {{- with .First }} | ||||
|       {{- if ne $currentPageNumber .PageNumber }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="First" class="page-link" role="button"><span aria-hidden="true">««</span></a> | ||||
|       </li> | ||||
|       {{- else }} | ||||
|       <li class="page-item disabled"> | ||||
|         <a aria-disabled="true" aria-label="First" class="page-link" role="button" tabindex="-1"><span aria-hidden="true">««</span></a> | ||||
|       </li> | ||||
|       {{- end }} | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- with .Prev }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="Previous" class="page-link" role="button"><span aria-hidden="true">«</span></a> | ||||
|       </li> | ||||
|     {{- else }} | ||||
|       <li class="page-item disabled"> | ||||
|         <a aria-disabled="true" aria-label="Previous" class="page-link" role="button" tabindex="-1"><span aria-hidden="true">«</span></a> | ||||
|       </li> | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- $slots := 5 }} | ||||
|     {{- $start := math.Max 1 (sub .PageNumber (math.Floor (div $slots 2))) }} | ||||
|     {{- $end := math.Min .TotalPages (sub (add $start $slots) 1) }} | ||||
|     {{- if lt (add (sub $end $start) 1) $slots }} | ||||
|       {{- $start = math.Max 1 (add (sub $end $slots) 1) }} | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- range $k := seq $start $end }} | ||||
|       {{- if eq $.Paginator.PageNumber $k }} | ||||
|       <li class="page-item active"> | ||||
|         <a aria-current="page" aria-label="Page {{ $k }}" class="page-link" role="button">{{ $k }}</a> | ||||
|       </li> | ||||
|       {{- else }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ (index $.Paginator.Pagers (sub $k 1)).URL }}" aria-label="Page {{ $k }}" class="page-link" role="button">{{ $k }}</a> | ||||
|       </li> | ||||
|       {{- end }} | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- with .Next }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="Next" class="page-link" role="button"><span aria-hidden="true">»</span></a> | ||||
|       </li> | ||||
|     {{- else }} | ||||
|       <li class="page-item disabled"> | ||||
|         <a aria-disabled="true" aria-label="Next" class="page-link" role="button" tabindex="-1"><span aria-hidden="true">»</span></a> | ||||
|       </li> | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- with .Last }} | ||||
|       {{- if ne $currentPageNumber .PageNumber }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="Last" class="page-link" role="button"><span aria-hidden="true">»»</span></a> | ||||
|       </li> | ||||
|       {{- else }} | ||||
|       <li class="page-item disabled"> | ||||
|         <a aria-disabled="true" aria-label="Last" class="page-link" role="button" tabindex="-1"><span aria-hidden="true">»»</span></a> | ||||
|       </li> | ||||
|       {{- end }} | ||||
|     {{- end }} | ||||
|   {{- end }} | ||||
| {{- end -}} | ||||
|  | ||||
| {{/* Format: terse | ||||
| {{/* --------------------------------------------------------------------- */}} | ||||
| {{- define "_partials/inline/pagination/terse.html" }} | ||||
|   {{- with .Paginator }} | ||||
|     {{- $currentPageNumber := .PageNumber }} | ||||
|  | ||||
|     {{- with .First }} | ||||
|       {{- if ne $currentPageNumber .PageNumber }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="First" class="page-link" role="button"><span aria-hidden="true">««</span></a> | ||||
|       </li> | ||||
|       {{- end }} | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- with .Prev }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="Previous" class="page-link" role="button"><span aria-hidden="true">«</span></a> | ||||
|       </li> | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- $slots := 3 }} | ||||
|     {{- $start := math.Max 1 (sub .PageNumber (math.Floor (div $slots 2))) }} | ||||
|     {{- $end := math.Min .TotalPages (sub (add $start $slots) 1) }} | ||||
|     {{- if lt (add (sub $end $start) 1) $slots }} | ||||
|       {{- $start = math.Max 1 (add (sub $end $slots) 1) }} | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- range $k := seq $start $end }} | ||||
|       {{- if eq $.Paginator.PageNumber $k }} | ||||
|       <li class="page-item active"> | ||||
|         <a aria-current="page" aria-label="Page {{ $k }}" class="page-link" role="button">{{ $k }}</a> | ||||
|       </li> | ||||
|       {{- else }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ (index $.Paginator.Pagers (sub $k 1)).URL }}" aria-label="Page {{ $k }}" class="page-link" role="button">{{ $k }}</a> | ||||
|       </li> | ||||
|       {{- end }} | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- with .Next }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="Next" class="page-link" role="button"><span aria-hidden="true">»</span></a> | ||||
|       </li> | ||||
|     {{- end }} | ||||
|  | ||||
|     {{- with .Last }} | ||||
|       {{- if ne $currentPageNumber .PageNumber }} | ||||
|       <li class="page-item"> | ||||
|         <a href="{{ .URL }}" aria-label="Last" class="page-link" role="button"><span aria-hidden="true">»»</span></a> | ||||
|       </li> | ||||
|       {{- end }} | ||||
|     {{- end }} | ||||
|   {{- end }} | ||||
| {{- end -}} | ||||
							
								
								
									
										6
									
								
								layouts/_partials/pagination.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								layouts/_partials/pagination.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,6 @@ | ||||
| {{ if gt .Paginator.TotalPages 1 }} | ||||
|     <nav class="pagination"> | ||||
|         {{/* https://github.com/gohugoio/hugo/blob/a88b488181279befd50e1d127f9f67604f2f9854/tpl/tplimpl/embedded/templates/_partials/pagination.html */}} | ||||
|         {{ partial "pagination-hugo.html" . }} | ||||
|     </nav> | ||||
| {{ end }} | ||||
| @@ -1,5 +1,5 @@ | ||||
| <meta property="og:title" content="{{ .Title | plainify }}"> | ||||
| <meta property="og:description" content="{{ (partial "seo-tags/description.html" .) | plainify }}"> | ||||
| <meta property="og:description" content="{{ (partial "seo-description.html" .) | plainify }}"> | ||||
| <meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}"> | ||||
| <meta property="og:url" content="{{ .Permalink }}"> | ||||
| 
 | ||||
| @@ -33,7 +33,7 @@ | ||||
|     <meta property="og:locale" content="{{ . }}"> | ||||
| {{ end }} | ||||
| 
 | ||||
| {{ with .Site.Params.title }} | ||||
| {{ with .Site.Title }} | ||||
|     <meta property="og:site_name" content="{{ . }}"> | ||||
| {{ end }} | ||||
| 
 | ||||
| @@ -1,5 +1,5 @@ | ||||
| <meta itemprop="name" content="{{ .Title | plainify }}"> | ||||
| <meta itemprop="description" content="{{ (partial "seo-tags/description.html" .) | plainify }}"> | ||||
| <meta itemprop="description" content="{{ (partial "seo-description.html" .) | plainify }}"> | ||||
| 
 | ||||
| {{ $format := "2006-01-02T15:04:05-07:00" }} | ||||
| {{ with .Date }} | ||||
| @@ -21,6 +21,14 @@ | ||||
|     <meta itemprop="image" content="{{ $featured.Permalink }}"> | ||||
| {{ end }} | ||||
| 
 | ||||
| {{ with .Params.tags }} | ||||
| {{ with .Keywords }} | ||||
|     <meta itemprop="keywords" content="{{ delimit . ", " }}"> | ||||
| {{ else }} | ||||
|     {{ with (.GetTerms "tags") }} | ||||
|         {{ $tags := slice }} | ||||
|         {{ range . }} | ||||
|             {{ $tags = $tags | append .LinkTitle }} | ||||
|         {{ end }} | ||||
|         <meta itemprop="keywords" content="{{ delimit $tags ", " }}"> | ||||
|     {{ end }} | ||||
| {{ end }} | ||||
							
								
								
									
										41
									
								
								layouts/_partials/seo-tags/twitter-cards.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										41
									
								
								layouts/_partials/seo-tags/twitter-cards.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,41 @@ | ||||
| {{/* we do not need to duplicate what's already covered by OpenGraph tags | ||||
|    * see: https://demo.bbaovanc.com/test/remove-twitter-tags/blog/swapfile-guide/ | ||||
|    * so, no twitter:image/title/description | ||||
|    */}} | ||||
| {{ $images := $.Resources.ByType "image" }} | ||||
| {{ $featured := $images.GetMatch "*feature*" }} | ||||
| {{ if not $featured }} | ||||
|     {{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" }} | ||||
| {{ end }} | ||||
|  | ||||
| {{ with $featured }} | ||||
|     {{ $ratio := 0 }} | ||||
|     {{ if gt .Width .Height }} | ||||
|         {{ $ratio = div (float .Width) .Height }} | ||||
|     {{ else }} | ||||
|         {{ $ratio = div (float .Height) .Width }} | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ if lt $ratio 1.75 }} | ||||
|         <meta name="twitter:card" content="summary_large_image"> | ||||
|     {{ else }} | ||||
|         <meta name="twitter:card" content="summary"> | ||||
|     {{ end }} | ||||
| {{ else }} | ||||
|     <meta name="twitter:card" content="summary"> | ||||
| {{ end }} | ||||
|  | ||||
| {{/* twitter:site is the site author; twitter:creator is page author | ||||
|    * https://developer.x.com/en/docs/x-for-websites/cards/guides/getting-started | ||||
|    * "Card and Content Attribution" | ||||
|    */}} | ||||
| {{ with .Site.Params.social.twitter }} | ||||
|     <meta name="twitter:site" content="@{{ . }}"> | ||||
| {{ end }} | ||||
| {{ with .GetTerms "authors" }} | ||||
|     {{ range . }} | ||||
|         {{ with .Params.twitter }} | ||||
|             <meta name="twitter:creator" content="@{{ . }}"> | ||||
|         {{ end }} | ||||
|     {{ end }} | ||||
| {{ end }} | ||||
| @@ -12,6 +12,6 @@ | ||||
|             This post is part of a series: | ||||
|         {{ end }} | ||||
| 
 | ||||
|         {{ delimit $series ", " }} | ||||
|         {{ delimit $series ", " | safeHTML }} | ||||
|     </div> | ||||
| {{ end }} | ||||
							
								
								
									
										3
									
								
								layouts/_partials/time-element.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								layouts/_partials/time-element.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,3 @@ | ||||
| <time datetime="{{ .Format "2006-01-02T15:04:05Z07:00" }}" title="{{ . }}"> | ||||
|     {{ .Format "January 2, 2006" }} | ||||
| </time> | ||||
							
								
								
									
										24
									
								
								layouts/_partials/top.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								layouts/_partials/top.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,24 @@ | ||||
| <div class="top"> | ||||
|     <header class="header"> | ||||
|         <a href="{{ .Site.Home.Permalink | absLangURL }}"> | ||||
|             {{ .Site.Title | markdownify }} | ||||
|         </a> | ||||
|     </header> | ||||
|  | ||||
|     <nav class="navbar" aria-label="{{ i18n "aria_navbar" }}"> | ||||
|         {{ with .Site.Home }} | ||||
|             <a class="navbar-item{{ if $.IsHome }} active{{ end }}" href="{{ .Permalink | absLangURL }}">{{ .Title | markdownify }}</a> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ range .Site.Menus.main }} | ||||
|             {{ $isActive := false }} | ||||
|             {{/* https://discourse.gohugo.io/t/ismenucurrent-not-working-with-using-sectionpagesmenu/46687/2?u=bbaovanc */}} | ||||
|             {{ if or ($.HasMenuCurrent .Menu .) (eq .Page $) }} | ||||
|                 {{ $isActive = true }} | ||||
|             {{ end }} | ||||
|             <a class="navbar-item{{ if $isActive }} active{{ end }}" | ||||
|                {{ if strings.HasPrefix .URL "http" }}target="_blank" rel="noopener"{{ end }} | ||||
|                href="{{ .URL }}">{{ .Name }}</a> | ||||
|         {{ end }} | ||||
|     </nav> | ||||
| </div> | ||||
							
								
								
									
										5
									
								
								layouts/_shortcodes/abbr.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								layouts/_shortcodes/abbr.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | ||||
| {{ if .IsNamedParams }} | ||||
|     <abbr title="{{ .Get "title" }}">{{ .Inner }}</abbr> | ||||
| {{ else }} | ||||
|     <abbr title="{{ .Get 0 }}">{{ .Inner }}</abbr> | ||||
| {{ end }} | ||||
							
								
								
									
										28
									
								
								layouts/_shortcodes/aside.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								layouts/_shortcodes/aside.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,28 @@ | ||||
| {{ $type := "" }} | ||||
| {{ if .IsNamedParams }} | ||||
|     {{ $type = .Get "type" | default "note" }} | ||||
| {{ else }} | ||||
|     {{ $type = .Get 0 | default "note" }} | ||||
| {{ end }} | ||||
|  | ||||
| {{/* This idea comes from the LoveIt theme: | ||||
|      https://github.com/dillonzq/LoveIt/blob/aa834e89af8349f6c18d4c7ad50a73fd5f1e40e0/layouts/shortcodes/admonition.html#L3-L14 | ||||
| */}} | ||||
|  | ||||
| {{ $icons := dict "note" "pencil" }} | ||||
| {{ $icons  = dict "info" "info" | merge $icons }} | ||||
| {{ $icons  = dict "tip" "lightbulb" | merge $icons }} | ||||
| {{ $icons  = dict "warning" "info" | merge $icons }} | ||||
| {{ $icons  = dict "example" "flask" | merge $icons }} | ||||
| {{ $icons  = dict "quote" "quote" | merge $icons }} | ||||
|  | ||||
| <aside class="{{ $type }}"> | ||||
|     <div class="aside-title"> | ||||
|         {{ partial "icon.html" (index $icons $type) }} | ||||
|         {{ title $type }} | ||||
|     </div> | ||||
|  | ||||
|     <div class="aside-content"> | ||||
|         {{ .Inner | .Page.RenderString (dict "display" "block") }} | ||||
|     </div> | ||||
| </aside> | ||||
							
								
								
									
										17
									
								
								layouts/_shortcodes/figure.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								layouts/_shortcodes/figure.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,17 @@ | ||||
| <figure> | ||||
|     {{ $resource_title := "" }} | ||||
|     {{ with .Get "src" }} | ||||
|         {{ with $.Page.Resources.Get . }} | ||||
|             {{ $resource_title = .Title }} | ||||
|             {{ partial "embed-resource.html" . }} | ||||
|         {{ else }} | ||||
|             {{ errorf "resource %q not found" . }} | ||||
|         {{ end }} | ||||
|     {{ else }} | ||||
|         {{ .Inner }} | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ with or (.Get "caption") (.Get 0) $resource_title }} | ||||
|         <figcaption>{{ (replace . "\\bt" "`") | markdownify }}</figcaption> | ||||
|     {{ end }} | ||||
| </figure> | ||||
							
								
								
									
										14
									
								
								layouts/_shortcodes/include.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								layouts/_shortcodes/include.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,14 @@ | ||||
| {{/* https://github.com/gohugoio/hugo/issues/13823#issuecomment-3015270202 */}} | ||||
| {{ with .Get 0 -}} | ||||
|     {{ with $.Page.GetPage . -}} | ||||
|         {{ .RenderShortcodes -}} | ||||
|     {{ else with $.Page.Resources.Get . -}} | ||||
|         {{ .RenderShortcodes -}} | ||||
|     {{ else with resources.Get . -}} | ||||
|         {{ .Content -}} | ||||
|     {{ else -}} | ||||
|         {{ errorf "The %q shortcode was unable to find %q. See %s" $.Name . $.Position -}} | ||||
|     {{ end -}} | ||||
| {{ else -}} | ||||
|     {{ errorf "The %q shortcode requires a positional parameter indicating the logical path of the file to include. See %s" .Name .Position -}} | ||||
| {{ end -}} | ||||
							
								
								
									
										9
									
								
								layouts/_shortcodes/resource.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								layouts/_shortcodes/resource.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| {{ with .Get 0 }} | ||||
|     {{ with $.Page.Resources.Get . }} | ||||
|         {{ partial "embed-resource.html" . }} | ||||
|     {{ else }} | ||||
|         {{ errorf "resource %q not found" . }} | ||||
|     {{ end }} | ||||
| {{ else }} | ||||
|     {{ errorf "resource name not provided as first parameter" }} | ||||
| {{ end }} | ||||
							
								
								
									
										7
									
								
								layouts/_shortcodes/see-also.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								layouts/_shortcodes/see-also.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,7 @@ | ||||
| <div class="see-also"> | ||||
|     {{ with .Site.GetPage (.Get 0) }} | ||||
|         <p>{{ i18n "see_also" }} <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a></p> | ||||
|     {{ else }} | ||||
|         {{ errorf "Page could not be found for see-also shortcode: %s" .Position }} | ||||
|     {{ end }} | ||||
| </div> | ||||
| @@ -4,13 +4,17 @@ | ||||
|         {{ .Title | markdownify }} | ||||
|     </h1> | ||||
|  | ||||
|     {{ with .Content }} | ||||
|         {{ . }} | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="page-list"> | ||||
|         {{ with .Paginator.Pages }} | ||||
|             <ul> | ||||
|             {{ range . }} | ||||
|                     <li>{{ .Render "summary/author" }}</li> | ||||
|                 <article class="page"> | ||||
|                     {{ .Render "summary" }} | ||||
|                 </article> | ||||
|             {{ end }} | ||||
|             </ul> | ||||
|         {{ else }} | ||||
|             <div> | ||||
|                 {{ i18n "no_posts" }} | ||||
|   | ||||
							
								
								
									
										16
									
								
								layouts/authors/summary.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								layouts/authors/summary.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,16 @@ | ||||
| <h2 class="page-title"> | ||||
|     <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a> | ||||
|     {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
| </h2> | ||||
|  | ||||
| {{ partial "page-metadata/author.html" . }} | ||||
|  | ||||
| {{ with .Summary }} | ||||
|     <div class="page-description"> | ||||
|         {{ . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
|  | ||||
| <div class="readmore"> | ||||
|     <a href="{{ .Permalink }}">{{ i18n "read_more" }} →</a> | ||||
| </div> | ||||
							
								
								
									
										1
									
								
								layouts/authors/term.head_title.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								layouts/authors/term.head_title.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | ||||
| {{ (print .Title "'s Posts | " .Site.Title) | plainify }} | ||||
| @@ -1,27 +1,19 @@ | ||||
| {{ define "main" }} | ||||
|     <div class="page-title"> | ||||
|         <h1> | ||||
|             {{ partial "icon.html" "user-circle" }} | ||||
|             {{ .Title | markdownify }} | ||||
|             {{ partial "rss-link.html" . }} | ||||
|         </h1> | ||||
|  | ||||
|     {{ partial "post-metadata/author.html" . }} | ||||
|  | ||||
|     {{ .Content }} | ||||
|  | ||||
|     <div class="page-list"> | ||||
|         {{ with .Paginator.Pages }} | ||||
|             <ul> | ||||
|                 {{ range . }} | ||||
|                     <li>{{ .Render "summary/post" }}</li> | ||||
|                 {{ end }} | ||||
|             </ul> | ||||
|         {{ else }} | ||||
|             <div> | ||||
|                 {{ i18n "no_posts" }} | ||||
|     </div> | ||||
|  | ||||
|     {{ partial "page-metadata/author.html" . }} | ||||
|  | ||||
|     {{ with .Content }} | ||||
|         {{ . }} | ||||
|     {{ end }} | ||||
|     </div> | ||||
|  | ||||
|     {{ partial "page-list.html" .Paginator.Pages }} | ||||
|  | ||||
|     {{ partial "pagination.html" . }} | ||||
| {{ end }} | ||||
|   | ||||
							
								
								
									
										40
									
								
								layouts/baseof.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										40
									
								
								layouts/baseof.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,40 @@ | ||||
| {{ i18n "credit_comment" | safeHTML }} | ||||
| <!DOCTYPE html> | ||||
| <html lang="{{ .Language.Lang }}"> | ||||
|     {{ partial "head.html" . }} | ||||
|  | ||||
|     <body> | ||||
|         <a id="skip-to-main" href="#main-content">Skip to main content</a> | ||||
|  | ||||
|         {{ partial "top.html" . }} | ||||
|  | ||||
|         <div class="main-container"> | ||||
|             {{ if not .IsHome }} | ||||
|                 {{ partial "breadcrumb.html" . }} | ||||
|             {{ end }} | ||||
|  | ||||
|             <main id="main-content"> | ||||
|                 {{ block "main" . }} | ||||
|                     THIS TEXT SHOULD NOT SHOW. YUZSIQGHE (that string is so I can grep for it) | ||||
|                 {{ end }} | ||||
|             </main> | ||||
|  | ||||
|             {{ if or .Site.Copyright .Site.Params.footer }} | ||||
|                 <footer> | ||||
|                     {{ with .Site.Copyright }} | ||||
|                         {{ . | safeHTML }} | ||||
|                     {{ end }} | ||||
|  | ||||
|                     {{ with .Site.Params.footer }} | ||||
|                         {{ . | $.RenderString (dict "display" "block") }} | ||||
|                     {{ end }} | ||||
|                 </footer> | ||||
|             {{ end }} | ||||
|         </div> | ||||
|  | ||||
|         {{ block "post-body" . }} | ||||
|             {{/* currently this is only used for related posts */}} | ||||
|         {{ end }} | ||||
|     </body> | ||||
|  | ||||
| </html> | ||||
							
								
								
									
										1
									
								
								layouts/head_title.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								layouts/head_title.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | ||||
| {{ (print .Title " | " .Site.Title) | plainify }} | ||||
							
								
								
									
										1
									
								
								layouts/home.head_title.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								layouts/home.head_title.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1 @@ | ||||
| {{ .Site.Title | plainify }} | ||||
							
								
								
									
										21
									
								
								layouts/home.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								layouts/home.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,21 @@ | ||||
| {{ define "main" }} | ||||
|     {{ with .Content }} | ||||
|         <article class="homepage-content"> | ||||
|             {{ . }} | ||||
|         </article> | ||||
|         <hr> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ if .Site.Params.homepageLatestPosts }} | ||||
|         <div class="homepage-latest-posts"> | ||||
|             <h1> | ||||
|                 {{ i18n "latest_posts" }} | ||||
|                 {{ partial "rss-link.html" . }} | ||||
|             </h1> | ||||
|  | ||||
|             {{ partial "page-list.html" (.Paginate .Site.RegularPages).Pages }} | ||||
|  | ||||
|             {{ partial "pagination.html" . }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
| {{ end }} | ||||
| @@ -1,2 +0,0 @@ | ||||
| {{ define "main" }} | ||||
| {{ end }} | ||||
| @@ -1,12 +1,12 @@ | ||||
| {{ define "main" }} | ||||
|     <div class="post-title"> | ||||
|     <div class="page-title"> | ||||
|         <h1> | ||||
|             {{ .Title | markdownify }} | ||||
|             {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
|         </h1> | ||||
|     </div> | ||||
| 
 | ||||
|     {{ partial "post-metadata/full.html" . }} | ||||
|     {{ partial "page-metadata/post-full.html" . }} | ||||
|     {{ partial "series-box.html" . }} | ||||
| 
 | ||||
|     {{ if .Params.Toc }} | ||||
| @@ -22,15 +22,13 @@ | ||||
|         </div> | ||||
|     {{ end }} | ||||
| 
 | ||||
|     {{ with .Resources.GetMatch "feature" }} | ||||
|         <div class="post-media"> | ||||
|             {{ partial "figure.html" (dict "src" . "border" true) }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
|     {{ partial "feature-figure.html" . }} | ||||
| 
 | ||||
|     <div class="post-content"> | ||||
|     <article class="post-content" data-pagefind-body> | ||||
|         {{ .Content }} | ||||
|     </div> | ||||
|     </article> | ||||
| 
 | ||||
|     {{ partial "series-box.html" . }} | ||||
| 
 | ||||
|     {{ if or .NextInSection .PrevInSection }} | ||||
|         <div class="prevnext"> | ||||
| @@ -62,25 +60,21 @@ | ||||
|         </div> | ||||
|     {{ end }} | ||||
| 
 | ||||
|     {{ partial "series-box.html" . }} | ||||
| 
 | ||||
|     {{ $related := .Site.RegularPages.Related . | first 10 }} | ||||
|     {{ with $related }} | ||||
|         <div class="related"> | ||||
|             <hr> | ||||
|             <h2>{{ i18n "related_posts" }}</h2> | ||||
|             <div class="related-posts"> | ||||
|                 {{ range . }} | ||||
|                     {{ .Render "summary/post" }} | ||||
|                 {{ end }} | ||||
|             </div> | ||||
|             <hr> | ||||
|         </div> | ||||
|     {{ end }} | ||||
| 
 | ||||
|     {{ if .Params.comments }} | ||||
|         <div class="comments"> | ||||
|             {{ partial "comments.html" . }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
| {{ end }} | ||||
| 
 | ||||
| 
 | ||||
| {{ define "post-body" }} | ||||
|     {{ $related := .Site.RegularPages.Related . | first 10 }} | ||||
|     {{ with $related }} | ||||
|         <div class="related-posts"> | ||||
|             <hr> | ||||
|             <h1>{{ i18n "related_posts" }}</h1> | ||||
|             {{ partial "page-list.html" . }} | ||||
|         </div> | ||||
|     {{ end }} | ||||
| {{ end }} | ||||
							
								
								
									
										9
									
								
								layouts/page.markdown.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								layouts/page.markdown.md
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| {{ with .File -}} | ||||
|   {{ with (.Path | readFile) -}} | ||||
|     {{ . -}} | ||||
|   {{ else -}} | ||||
|     {{ errorf "file not found: %s" .Path -}} | ||||
|   {{ end -}} | ||||
| {{ else -}} | ||||
|   {{ errorf "no file available for markdown template?" -}} | ||||
| {{ end -}} | ||||
| @@ -1,4 +0,0 @@ | ||||
| {{/* | ||||
|     Create a file named `layouts/partials/comments.html` at your site root to | ||||
|     add a comment system. Page variables are passed. | ||||
| */}} | ||||
| @@ -1 +0,0 @@ | ||||
| {{ i18n "credit_comment" | safeHTML }} | ||||
| @@ -1,7 +0,0 @@ | ||||
| {{ with .Description }} | ||||
|     <p>{{ . | markdownify }}</p> | ||||
| {{ else }} | ||||
|     {{ with .Summary }} | ||||
|         {{ . }} | ||||
|     {{ end }} | ||||
| {{ end }} | ||||
| @@ -1,28 +0,0 @@ | ||||
| {{ $hidecaption := index . "hidecaption" }} | ||||
|  | ||||
| {{ if index . "noborder" }} | ||||
|     <figure> | ||||
| {{ else }} | ||||
|     <figure class="border"> | ||||
| {{ end }} | ||||
|  | ||||
|     {{ with index . "src" }} | ||||
|         {{ $media := . }} | ||||
|         {{ if eq .MediaType.MainType "image" }} | ||||
|             <img src="{{ $media.Permalink }}" alt="{{ $media.Title }}" /> | ||||
|         {{ else if eq .MediaType.MainType "video" }} | ||||
|             <video controls preload="metadata"> | ||||
|                 <source src="{{ $media.Permalink }}" alt="{{ $media.Title }}"> | ||||
|                 {{ i18n "browser_no_video_support" }} | ||||
|             </video> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ if not $hidecaption }} | ||||
|             {{ with $media.Title }} | ||||
|                 <figcaption> | ||||
|                     {{ . | markdownify }} | ||||
|                 </figcaption> | ||||
|             {{ end }} | ||||
|         {{ end }} | ||||
|     {{ end }} | ||||
| </figure> | ||||
| @@ -1,42 +0,0 @@ | ||||
| <head> | ||||
|     <meta charset="UTF-8"> | ||||
|     <meta name="viewport" content="width=device-width, initial-scale=1"> | ||||
|     {{ hugo.Generator }} | ||||
|  | ||||
|     {{ with resources.Get "css/bobastyle.css" | fingerprint "sha512" }} | ||||
|         <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"> | ||||
|     {{ end }} | ||||
|     {{ with resources.Get "css/syntax.css" | fingerprint "sha512" }} | ||||
|         <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"> | ||||
|     {{ end }} | ||||
|     {{ with resources.Get "css/syntax-light.css" | fingerprint "sha512" }} | ||||
|         <link rel="stylesheet" type="text/css" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"> | ||||
|     {{ end }} | ||||
|     {{ with resources.Get "js/back-to-top.js" | fingerprint "sha512" }} | ||||
|         <script defer src="{{ .Permalink }}" type="text/javascript" integrity="{{ .Data.Integrity }}" crossorigin="anonymous"></script> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ with .Site.Params.faviconICO }} | ||||
|         <link rel="icon" type="image/x-icon" href="{{ . | absURL }}" /> | ||||
|     {{ end }} | ||||
|     {{ with .Site.Params.faviconPNG }} | ||||
|         <link rel="icon" type="image/png" href="{{ . | absURL }}" /> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ if .IsHome }} | ||||
|         <title>{{ .Site.Title | plainify }}</title> | ||||
|     {{ else }} | ||||
|         <title>{{ (print .Title " | " .Site.Title) | plainify }}</title> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ partial "seo-tags/opengraph.html" . }} | ||||
|     {{ partial "seo-tags/twitter-cards.html" . }} | ||||
|     {{ partial "seo-tags/schema.html" . }} | ||||
|     {{ partial "seo-tags/link.html" . }} | ||||
|     {{ partial "seo-tags/author.html" . }} | ||||
|  | ||||
|     <meta name="language" content="{{ .Language.Lang }}"> | ||||
|     <meta name="description" content="{{ (partial "seo-tags/description.html" .) | plainify }}"> | ||||
|  | ||||
|     {{ partial "additional-head.html" . }} | ||||
| </head> | ||||
| @@ -1,5 +0,0 @@ | ||||
| {{ if gt .Paginator.TotalPages 1 }} | ||||
|     <div class="pagination"> | ||||
|         {{ template "_internal/pagination.html" . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
| @@ -1,8 +0,0 @@ | ||||
| {{ if .IsTranslated }} | ||||
|     <span class="post-meta-item" aria-label="{{ i18n "aria_post_meta_translations" }}"> | ||||
|         {{ partial "icon.html" "world" }} | ||||
|         {{ range .Translations }} | ||||
|             <a href="{{ .Permalink }}">{{ .Language }}</a> | ||||
|         {{ end }} | ||||
|     </span> | ||||
| {{ end }} | ||||
| @@ -1,13 +0,0 @@ | ||||
| {{ if and .Site.Params.gitFileURL .File.Path }} | ||||
|     <span class="post-meta-item" aria-label="{{ i18n "aria_post_meta_view_source" }}"> | ||||
|         {{ with .Site.Params.gitFileIcon }} | ||||
|             {{ partial "icon.html" . }} | ||||
|         {{ else }} | ||||
|             {{ partial "icon.html" "file" }} | ||||
|         {{ end }} | ||||
|  | ||||
|         <a href="{{ printf "%s/content/%s" .Site.Params.gitFileURL .File.Path }}" target="_blank" rel="noopener"> | ||||
|             View source | ||||
|         </a> | ||||
|     </span> | ||||
| {{ end }} | ||||
| @@ -1,28 +0,0 @@ | ||||
| {{ if or .Date .Params.authors .IsTranslated .Site.Params.readingtime .Site.Params.gitFileURL }} | ||||
|     <div class="post-metadata" aria-label="{{ i18n "aria_post_metadata" }}"> | ||||
|         {{ if .Date }} | ||||
|             <span class="post-meta-item" aria-label="{{ i18n "aria_post_meta_date" }}"> | ||||
|                 {{ partial "icon.html" "calendar" }} | ||||
|                 <time datetime="{{ .Date.Format "2006-01-02" }}" pubdate> | ||||
|                     {{ i18n "long_date" (dict "Date" .Date "Data" .Site.Data) }} | ||||
|                 </time> | ||||
|             </span> | ||||
|  | ||||
|             {{/* TODO: make this be a tooltip */}} | ||||
|             {{ if ne (time.Format "2006-01-02" .Lastmod) (time.Format "2006-01-02" .Date) }} | ||||
|                 <span class="post-meta-item" aria-label="{{ i18n "aria_post_meta_modified_date" }}"> | ||||
|                     {{ partial "icon.html" "pencil" }} | ||||
|                     <time datetime="{{ .Lastmod.Format "2006-01-02" }}" pubdate> | ||||
|                         {{ i18n "long_date" (dict "Date" .Lastmod "Data" .Site.Data) }} | ||||
|                     </time> | ||||
|                     {{ end }} | ||||
|                 </span> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ partial "post-meta-item/authors.html" . }} | ||||
|         {{ partial "post-meta-item/translations.html" . }} | ||||
|         {{ partial "post-meta-item/readingtime.html" . }} | ||||
|         {{ partial "post-meta-item/viewsource.html" . }} | ||||
|         {{ partial "post-meta-item/tags.html" . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
| @@ -1,18 +0,0 @@ | ||||
| {{ if or .Date .Params.authors .IsTranslated .Site.Params.readingtime }} | ||||
|     <div class="post-metadata" aria-label="{{ i18n "aria_post_metadata" }}"> | ||||
|         {{ if .Date }} | ||||
|             <span class="post-meta-item" aria-label="date"> | ||||
|                 {{ partial "icon.html" "calendar" }} | ||||
|                 <time datetime="{{ .Date.Format "2006-01-02" }}" pubdate> | ||||
|                     {{ i18n "long_date" (dict "Date" .Date "Data" .Site.Data) }} | ||||
|                 </time> | ||||
|             </span> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ partial "post-meta-item/authors.html" . }} | ||||
|         {{ partial "post-meta-item/translations.html" . }} | ||||
|         {{ partial "post-meta-item/readingtime.html" . }} | ||||
|         {{ partial "post-meta-item/series.html" . }} | ||||
|         {{ partial "post-meta-item/tags.html" . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
| @@ -1,28 +0,0 @@ | ||||
| {{ $hidecaption := index . "hidecaption" }} | ||||
| {{ $type := index . "type" }} | ||||
| {{ $src := index . "src" }} | ||||
| {{ $alt := index . "alt" }} | ||||
|  | ||||
| {{ if index . "border" }} | ||||
|     <figure class="border"> | ||||
| {{ else }} | ||||
|     <figure> | ||||
| {{ end }} | ||||
|  | ||||
|     {{ if eq $type "image" }} | ||||
|         <img src="{{ $src }}" alt="{{ $alt }}" /> | ||||
|     {{ else if eq $type "video" }} | ||||
|         <video controls preload="metadata"> | ||||
|             <source src="{{ $src }}" alt="{{ $alt }}"> | ||||
|             {{ i18n "browser_no_video_support" }} | ||||
|         </video> | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ if not $hidecaption }} | ||||
|         {{ with $alt }} | ||||
|             <figcaption> | ||||
|                 {{ . | markdownify }} | ||||
|             </figcaption> | ||||
|         {{ end }} | ||||
|     {{ end }} | ||||
| </figure> | ||||
| @@ -1,29 +0,0 @@ | ||||
| {{ $images := $.Resources.ByType "image" }} | ||||
| {{ $featured := $images.GetMatch "*feature*" }} | ||||
| {{ if not $featured }} | ||||
|     {{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" }} | ||||
| {{ end }} | ||||
|  | ||||
| {{ with $featured }} | ||||
|     {{ $ratio := 0 }} | ||||
|     {{ if gt .Width .Height }} | ||||
|         {{ $ratio = div (float .Width) .Height }} | ||||
|     {{ else }} | ||||
|         {{ $ratio = div (float .Height) .Width }} | ||||
|     {{ end }} | ||||
|  | ||||
|     {{ if lt $ratio 1.75 }} | ||||
|         <meta name="twitter:card" content="summary_large_image"> | ||||
|     {{ else }} | ||||
|         <meta name="twitter:card" content="summary"> | ||||
|     {{ end }} | ||||
|  | ||||
|     <meta name="twitter:image" content="{{ $featured.Permalink }}"> | ||||
| {{ end }} | ||||
|  | ||||
| <meta name="twitter:title" content="{{ .Title | plainify }}"> | ||||
| <meta name="twitter:description" content="{{ (partial "seo-tags/description.html" .) | plainify }}"> | ||||
|  | ||||
| {{ with .Site.Social.twitter }} | ||||
|     <meta name="twitter:site" content="@{{ . }}"> | ||||
| {{ end }} | ||||
| @@ -1,50 +0,0 @@ | ||||
| <h2 class="header"> | ||||
|     <a href="{{ .Site.Home.Permalink | absLangURL }}">{{ .Site.Title | markdownify }}</a> | ||||
| </h2> | ||||
|  | ||||
| <div class="topbar"> | ||||
|     <nav class="navbar" aria-label="{{ i18n "aria_navbar" }}"> | ||||
|         {{ with .Site.Home }} | ||||
|             <a class="navbar-item{{ if $.IsHome }} active{{ end }}" href="{{ .Permalink | absLangURL }}">{{ .Title | markdownify }}</a> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ range .Site.Menus.main }} | ||||
|             {{ $isActive := false }} | ||||
|             {{ if or ($.HasMenuCurrent .Menu .) ($.IsMenuCurrent .Menu .) }} | ||||
|                 {{ $isActive = true }} | ||||
|             {{ end }} | ||||
|             <a class="navbar-item{{ if $isActive }} active{{ end }}" href="{{ .URL }}">{{ .Name }}</a> | ||||
|         {{ end }} | ||||
|     </nav> | ||||
|  | ||||
|     {{ if .Site.IsMultiLingual }} | ||||
|         <details class="langpicker" aria-label="{{ i18n "aria_langpicker" }}"> | ||||
|             <summary> | ||||
|                 {{- partial "icon.html" "world" -}} | ||||
|             </summary> | ||||
|             <ul class="languages" aria-label="{{ i18n "aria_langpicker_list" }}"> | ||||
|                 {{ range .AllTranslations }} | ||||
|                     <li> | ||||
|                         <a class="langpicker-item{{ if eq .Language $.Site.Language }} active{{ end }}" href="{{ .Permalink }}">{{ .Language.LanguageName }}</a> | ||||
|                     </li> | ||||
|                 {{ end }} | ||||
|  | ||||
|                 {{ $site_translations := slice }} | ||||
|                 {{ range .Site.Languages }} | ||||
|                     {{ $site_translations = $site_translations | append .LanguageName }} | ||||
|                 {{ end }} | ||||
|  | ||||
|                 {{ $translation_codes := slice }} | ||||
|                 {{ range .AllTranslations }} | ||||
|                     {{ $translation_codes = $translation_codes | append .Language }} | ||||
|                 {{ end }} | ||||
|  | ||||
|                 {{ range (.Site.Languages | complement $translation_codes) }} | ||||
|                     <li> | ||||
|                         <a class="langpicker-item unavailable" aria-disabled="true">{{ .LanguageName }}</a> | ||||
|                     </li> | ||||
|                 {{ end }} | ||||
|             </ul> | ||||
|         </details> | ||||
|     {{ end }} | ||||
| </div> | ||||
							
								
								
									
										3
									
								
								layouts/search.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								layouts/search.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,3 @@ | ||||
| {{ define "main" }} | ||||
|     <div id="search-box"></div> | ||||
| {{ end }} | ||||
							
								
								
									
										25
									
								
								layouts/section.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										25
									
								
								layouts/section.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,25 @@ | ||||
| {{ define "main" }} | ||||
|     <h1> | ||||
|         {{ with .Params.icon }}{{ partial "icon.html" . }}{{ end }} | ||||
|         {{ .Title | markdownify }} | ||||
|         {{ partial "rss-link.html" . }} | ||||
|     </h1> | ||||
|  | ||||
|     {{ with .Content }} | ||||
|         {{ . }} | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="list-page-container"> | ||||
|         {{ with .Sections }} | ||||
|             <div class="sections"> | ||||
|                 {{ range . }} | ||||
|                     {{ .Render "summary" }} | ||||
|                 {{ end }} | ||||
|             </div> | ||||
|         {{ end }} | ||||
|  | ||||
|         {{ partial "page-list.html" .Paginator.Pages }} | ||||
|     </div> | ||||
|  | ||||
|     {{ partial "pagination.html" . }} | ||||
| {{ end }} | ||||
| @@ -5,8 +5,10 @@ | ||||
|             {{ .Title | markdownify }} | ||||
|         </h2> | ||||
| 
 | ||||
|         {{ with .Summary }} | ||||
|             <div class="section-description"> | ||||
|             {{ partial "description-or-summary.html" . }} | ||||
|                 {{ . }} | ||||
|             </div> | ||||
|         {{ end }} | ||||
|     </div> | ||||
| </a> | ||||
| @@ -4,13 +4,17 @@ | ||||
|         {{ .Title | markdownify }} | ||||
|     </h1> | ||||
|  | ||||
|     <div class="series-taxonomy"> | ||||
|         {{ with .Pages }} | ||||
|             <ul> | ||||
|                 {{ range . }} | ||||
|                     <li>{{ .Render "summary/series" }}</li> | ||||
|     {{ with .Content }} | ||||
|         {{ . }} | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="page-list series"> | ||||
|         {{ with .Paginator.Pages }} | ||||
|             {{ range . }} | ||||
|                 <div class="page series"> | ||||
|                     {{ .Render "summary" }} | ||||
|                 </div> | ||||
|             {{ end }} | ||||
|             </ul> | ||||
|         {{ else }} | ||||
|             <div> | ||||
|                 {{ i18n "no_posts" }} | ||||
|   | ||||
							
								
								
									
										21
									
								
								layouts/series/summary.html
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								layouts/series/summary.html
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,21 @@ | ||||
| <h2 class="page-title"> | ||||
|     {{ with .Parent.Params.icon }}{{ partial "icon.html" . }}{{ end }} | ||||
|     <a href="{{ .Permalink }}">{{ .Title | markdownify }}</a> | ||||
|     {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }} | ||||
| </h2> | ||||
|  | ||||
| {{ partial "page-metadata/series.html" . }} | ||||
|  | ||||
| {{ with .Summary }} | ||||
|     <div class="page-description"> | ||||
|         {{ . }} | ||||
|     </div> | ||||
| {{ end }} | ||||
|  | ||||
| <div class="page-list series-inner"> | ||||
|     {{ range .Data.Pages.Reverse }} | ||||
|         <article class="page"> | ||||
|             {{ .Render "summary" }} | ||||
|         </article> | ||||
|     {{ end }} | ||||
| </div> | ||||
| @@ -5,28 +5,16 @@ | ||||
|         {{ partial "rss-link.html" . }} | ||||
|     </h1> | ||||
|  | ||||
|     {{ partial "post-metadata/series.html" . }} | ||||
|     {{ partial "page-metadata/series.html" . }} | ||||
|  | ||||
|     {{ partial "description-or-summary.html" . }} | ||||
|     {{ with .Content }} | ||||
|         {{ . }} | ||||
|     {{ end }} | ||||
|  | ||||
|     <div class="page-list"> | ||||
|     {{ with .Paginator.Pages.Reverse }} | ||||
|             <ul> | ||||
|                 {{ $i := 0 }} | ||||
|                 {{ $total := len $.Pages }} | ||||
|                 {{ range . }} | ||||
|                     {{ $i = add 1 $i }} | ||||
|                     {{ .Scratch.Set "series_position" $i }} | ||||
|                     {{ .Scratch.Set "series_total" $total }} | ||||
|                     <li>{{ .Render "summary/post" }}</li> | ||||
|         {{ partial "page-list.html" . }} | ||||
|     {{ end }} | ||||
|             </ul> | ||||
|         {{ else }} | ||||
|             <div> | ||||
|                 {{ i18n "no_posts" }} | ||||
|             </div> | ||||
|         {{ end }} | ||||
|     </div> | ||||
|  | ||||
|  | ||||
|     {{ partial "pagination.html" . }} | ||||
| {{ end }} | ||||
|   | ||||
| @@ -1,7 +0,0 @@ | ||||
| <aside> | ||||
|     {{ with .Inner }} | ||||
|         {{ . | markdownify }} | ||||
|     {{ else }} | ||||
|         {{ errorf "The aside shortcode needs to be a closing one (similar to the highlight shortcode, see https://gohugo.io/templates/shortcode-templates/#inner" }} | ||||
|     {{ end }} | ||||
| </aside> | ||||
| @@ -1,15 +0,0 @@ | ||||
| {{ $resource := $.Page.Resources.GetMatch (.Get "src") }} | ||||
|  | ||||
| {{ $noborder := false }} | ||||
| {{ if .Get "noborder" }} | ||||
|     {{ $noborder = true }} | ||||
| {{ end }} | ||||
|  | ||||
| {{ $hidecaption := false }} | ||||
| {{ if .Get "hidecaption" }} | ||||
|     {{ $hidecaption = true }} | ||||
| {{ end }} | ||||
|  | ||||
| <p> | ||||
|     {{ partial "figure.html" (dict "src" $resource "noborder" $noborder "hidecaption" $hidecaption) }} | ||||
| </p> | ||||
| @@ -1,13 +0,0 @@ | ||||
| {{ $border := false }} | ||||
| {{ if .Get "border" }} | ||||
|     {{ $border = true }} | ||||
| {{ end }} | ||||
|  | ||||
| {{ $hidecaption := false }} | ||||
| {{ if .Get "hidecaption" }} | ||||
|     {{ $hidecaption = true }} | ||||
| {{ end }} | ||||
|  | ||||
| <p> | ||||
|     {{ partial "remote_figure.html" (dict "src" (.Get "src") "border" $border "hidecaption" $hidecaption "type" "image" "alt" (.Get "alt")) }} | ||||
| </p> | ||||
Some files were not shown because too many files have changed in this diff Show More
		Reference in New Issue
	
	Block a user