chulapa-jekyll 2.0.1 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (170) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +148 -35
  3. data/README.md +96 -72
  4. data/_data/version.yml +2 -2
  5. data/_includes/components/breadcrumbdatesocial.html +15 -11
  6. data/_includes/components/headers.html +17 -10
  7. data/_includes/components/indexcards.html +2 -2
  8. data/_includes/components/navbeforeafter.html +2 -2
  9. data/_includes/components/random.html +103 -0
  10. data/_includes/components/related.html +82 -90
  11. data/_includes/components/simplelist.html +26 -0
  12. data/_includes/footer.html +53 -1
  13. data/_includes/head.html +237 -98
  14. data/_includes/search/fusejs.html +36 -0
  15. data/_includes/search/lunr.html +27 -7
  16. data/_includes/search/simplesearch.html +46 -0
  17. data/_includes/snippets/article-images.html +25 -0
  18. data/_includes/snippets/bootstrapdemo.html +1454 -1303
  19. data/_includes/snippets/breadcrumb-names.html +5 -0
  20. data/_includes/snippets/canonical-url.html +17 -0
  21. data/_includes/snippets/datetranslate.html +7 -1
  22. data/_includes/snippets/jsonld-string.html +16 -0
  23. data/_includes/snippets/og-locale.html +19 -0
  24. data/_includes/snippets/page-language.html +4 -0
  25. data/_includes/snippets/publisher.html +25 -0
  26. data/_includes/snippets/video-metadata.html +15 -0
  27. data/_includes/snippets/video.html +20 -17
  28. data/_includes/snippets/youtube.html +9 -4
  29. data/_includes/welcomments/template.html +1 -1
  30. data/_layouts/archive.html +1 -1
  31. data/_layouts/cloudcategory.html +4 -4
  32. data/_layouts/cloudtag.html +4 -4
  33. data/_layouts/default.html +4 -4
  34. data/_layouts/landingpage.html +8 -5
  35. data/_layouts/minimal.html +10 -4
  36. data/_layouts/search.html +12 -13
  37. data/_sass/chulapa/_classes.scss +68 -58
  38. data/_sass/chulapa/_reboot.scss +31 -0
  39. data/_sass/chulapa/_variables.scss +8 -1
  40. data/_sass/highlight/README.md +176 -14
  41. data/_sass/highlight/abap.scss +62 -0
  42. data/_sass/highlight/algol.scss +46 -0
  43. data/_sass/highlight/algol_nu.scss +46 -0
  44. data/_sass/highlight/arduino.scss +63 -0
  45. data/_sass/highlight/autumn.scss +69 -58
  46. data/_sass/highlight/base16.scss +90 -0
  47. data/_sass/highlight/borland.scss +55 -46
  48. data/_sass/highlight/bw.scss +70 -34
  49. data/_sass/highlight/cobalt2.scss +197 -0
  50. data/_sass/highlight/coffee.scss +82 -0
  51. data/_sass/highlight/colorful.scss +178 -61
  52. data/_sass/highlight/cran.scss +185 -169
  53. data/_sass/highlight/default.scss +72 -61
  54. data/_sass/highlight/dracula.scss +93 -169
  55. data/_sass/highlight/emacs.scss +72 -61
  56. data/_sass/highlight/friendly.scss +72 -61
  57. data/_sass/highlight/friendly_grayscale.scss +72 -0
  58. data/_sass/highlight/fruity.scss +82 -70
  59. data/_sass/highlight/github.dark.scss +83 -0
  60. data/_sass/highlight/github.scss +116 -61
  61. data/_sass/highlight/gruvbox.dark.scss +83 -0
  62. data/_sass/highlight/gruvbox.light.scss +68 -84
  63. data/_sass/highlight/gruvbox.scss +97 -0
  64. data/_sass/highlight/igor.scss +36 -0
  65. data/_sass/highlight/igorpro.scss +45 -0
  66. data/_sass/highlight/inkpot.scss +78 -0
  67. data/_sass/highlight/lightbulb.scss +82 -0
  68. data/_sass/highlight/lilypond.scss +58 -0
  69. data/_sass/highlight/lovelace.scss +74 -0
  70. data/_sass/highlight/magritte.scss +175 -0
  71. data/_sass/highlight/manni.scss +72 -61
  72. data/_sass/highlight/material.scss +81 -0
  73. data/_sass/highlight/molokai.scss +211 -0
  74. data/_sass/highlight/monokai.scss +217 -65
  75. data/_sass/highlight/monokai.sublime.scss +203 -0
  76. data/_sass/highlight/murphy.scss +72 -61
  77. data/_sass/highlight/native.scss +82 -70
  78. data/_sass/highlight/night-owl.scss +201 -0
  79. data/_sass/highlight/nord.darker.scss +82 -0
  80. data/_sass/highlight/nord.scss +82 -0
  81. data/_sass/highlight/oksolar.dark.scss +175 -0
  82. data/_sass/highlight/oksolar.light.scss +175 -0
  83. data/_sass/highlight/one.dark.scss +82 -0
  84. data/_sass/highlight/panda.scss +195 -0
  85. data/_sass/highlight/paraiso.dark.scss +76 -0
  86. data/_sass/highlight/paraiso.light.scss +76 -0
  87. data/_sass/highlight/pastie.scss +154 -60
  88. data/_sass/highlight/perldoc.scss +69 -58
  89. data/_sass/highlight/rainbow_dash.scss +65 -0
  90. data/_sass/highlight/rrt.scss +82 -0
  91. data/_sass/highlight/sas.scss +63 -0
  92. data/_sass/highlight/selenized.black.scss +175 -0
  93. data/_sass/highlight/selenized.dark.scss +175 -0
  94. data/_sass/highlight/selenized.light.scss +175 -0
  95. data/_sass/highlight/selenized.white.scss +175 -0
  96. data/_sass/highlight/skeletor.scss +190 -140
  97. data/_sass/highlight/solarized.dark.scss +82 -0
  98. data/_sass/highlight/solarized.light.scss +82 -0
  99. data/_sass/highlight/stackoverflow.dark.scss +175 -0
  100. data/_sass/highlight/stackoverflow.light.scss +175 -0
  101. data/_sass/highlight/staroffice.scss +82 -0
  102. data/_sass/highlight/stata.dark.scss +82 -0
  103. data/_sass/highlight/stata.light.scss +49 -0
  104. data/_sass/highlight/tango.scss +81 -69
  105. data/_sass/highlight/template.scss +290 -0
  106. data/_sass/highlight/thankful_eyes.scss +180 -173
  107. data/_sass/highlight/trac.scss +70 -59
  108. data/_sass/highlight/tulip.scss +171 -0
  109. data/_sass/highlight/vim.scss +82 -70
  110. data/_sass/highlight/vs.scss +41 -33
  111. data/_sass/highlight/xcode.scss +65 -0
  112. data/_sass/highlight/zenburn.scss +82 -136
  113. data/_sass/reset-algolia.scss +27 -17
  114. data/_sass/skins/academia.scss +19 -10
  115. data/_sass/skins/auto.scss +5 -2
  116. data/_sass/skins/butterfly-dark.scss +54 -0
  117. data/_sass/skins/butterfly-dim.scss +54 -0
  118. data/_sass/skins/butterfly.scss +33 -0
  119. data/_sass/skins/chulapa.scss +10 -3
  120. data/_sass/skins/cyborg.scss +512 -0
  121. data/_sass/skins/dark-bg.scss +83 -49
  122. data/_sass/skins/darkly.scss +424 -0
  123. data/_sass/skins/deeply.scss +262 -63
  124. data/_sass/skins/electro.scss +24 -17
  125. data/_sass/skins/flatly.scss +386 -0
  126. data/_sass/skins/focal.scss +24 -18
  127. data/_sass/skins/gitdev-dark.scss +12 -20
  128. data/_sass/skins/gitdev.scss +20 -17
  129. data/_sass/skins/graymor.scss +22 -14
  130. data/_sass/skins/hootstrap.scss +17 -10
  131. data/_sass/skins/journal.scss +74 -86
  132. data/_sass/skins/listen.scss +51 -0
  133. data/_sass/skins/lux.scss +171 -237
  134. data/_sass/skins/lymcha.scss +14 -9
  135. data/_sass/skins/materia.scss +889 -0
  136. data/_sass/skins/media.scss +29 -11
  137. data/_sass/skins/mickie.scss +27 -11
  138. data/_sass/skins/minco.scss +30 -10
  139. data/_sass/skins/minty.scss +226 -85
  140. data/_sass/skins/monotone.scss +15 -1
  141. data/_sass/skins/navi.scss +26 -0
  142. data/_sass/skins/pear.scss +16 -5
  143. data/_sass/skins/preptor.scss +13 -12
  144. data/_sass/skins/skeeblu.scss +11 -11
  145. data/_sass/skins/sketchy.scss +366 -377
  146. data/_sass/skins/slate.scss +719 -0
  147. data/_sass/skins/solar.scss +425 -0
  148. data/_sass/skins/sunset.scss +27 -12
  149. data/_sass/skins/towards.scss +19 -5
  150. data/_sass/skins/twitter-dim.scss +20 -11
  151. data/_sass/skins/twitter-lights-out.scss +22 -11
  152. data/_sass/skins/twitter.scss +22 -10
  153. data/_sass/skins/united.scss +57 -0
  154. data/_sass/skins/universal.scss +29 -27
  155. data/_sass/skins/wandoo.scss +12 -11
  156. data/_sass/skins/yeti.scss +673 -0
  157. data/assets/atom.xml +10 -6
  158. data/assets/js/better404/better404.js +75 -0
  159. data/assets/js/ch_ytdefer/ch_ytdefer.js +0 -1
  160. data/assets/js/chulapa_script.js +2 -2
  161. data/assets/js/fusejs/fusejs-search.js +197 -0
  162. data/assets/js/fusejs/fusejs-search.min.js +4 -0
  163. data/assets/js/fusejs/fusejs-store.js +43 -0
  164. data/assets/js/lunr/lunr-search.js +249 -114
  165. data/assets/js/lunr/lunr-search.min.js +4 -0
  166. data/assets/js/lunr/lunr-store.js +31 -23
  167. data/assets/js/simplesearch/simplesearch-store.json +45 -0
  168. data/assets/rss.xml +4 -3
  169. metadata +81 -8
  170. data/_sass/highlight/UNLICENSE.txt +0 -24
data/_includes/head.html CHANGED
@@ -1,73 +1,162 @@
1
1
  <head>
2
2
  <meta charset="utf-8">
3
- <!-- Chulapa Jekyll Theme - 2.0.1 -->
3
+ <!-- Chulapa Jekyll Theme - v2.1.0 -->
4
4
  <!-- MIT License-->
5
5
  <!-- Docs: https://dieghernan.github.io/chulapa -->
6
6
  <!-- Repo: https://github.com/dieghernan/chulapa -->
7
- <!-- Page build {{ site.time }} -->
7
+ <!-- Page build {{ site.time | date: "%Y-%m-%d" }} -->
8
8
  <!-- Jekyll Version {{ jekyll.version }} -->
9
- {%- assign canonical_url = page.url | replace: "index.html", "" | absolute_url | uri_escape -%}
10
- {%- assign home_url = "index.html" | absolute_url | replace: "index.html", "" | uri_escape -%}
11
- {%- assign metatitle1 = page.title | default: site.title | default: site.github.repository_name | strip_html -%}
12
- {%- assign metatitle2 = site.title | default: site.github.repository_name | strip_html -%}
13
- {%- assign strippedurl = page.url | replace: "index.html", "" -%}
9
+ {%- include snippets/canonical-url.html url=page.url canonical=page.canonical_url -%}
10
+ {%- assign home_url = '/' | absolute_url | uri_escape -%}
11
+ {%- include snippets/breadcrumb-names.html -%}
12
+ {%- assign metatitle1 = page.title | default: site.title | default: site.github.repository_name | markdownify | strip_html | strip -%}
13
+ {%- assign metatitle2 = site.title | default: site.github.repository_name | markdownify | strip_html | strip -%}
14
+ {%- assign strippedurl = canonical_path -%}
14
15
  {%- if strippedurl == "/" -%}
15
- {%- assign metatitle1 = site.title | default: site.github.repository_name -%}
16
- {%- assign metatitle2 = site.subtitle | default: site.github.project_tagline -%}
16
+ {%- assign metatitle1 = site.title | default: site.github.repository_name | strip -%}
17
+ {%- assign metatitle2 = site.subtitle | default: site.github.project_tagline | strip -%}
17
18
  {%- endif -%}
18
- {%- capture metatitle -%}{{ metatitle1 | strip_html }} {{ site.title_separator | default: "|" }} {{ metatitle2 | strip_html }}{%- endcapture -%}
19
+ {%- assign metatitle1 = metatitle1 | strip_html | strip -%}
20
+ {%- assign metatitle2 = metatitle2 | strip_html | strip -%}
21
+ {%- capture metatitle -%}{{ metatitle1 }}{%- if metatitle1 != empty and metatitle2 != empty %} {{ site.title_separator | default: "|" }} {% endif -%}{{ metatitle2 }}{%- endcapture -%}
22
+ {%- assign seo_title = page.seo_title | markdownify | strip_html | strip -%}
23
+ {%- if seo_title != empty -%}
24
+ {%- assign metatitle = seo_title -%}
25
+ {%- assign metatitle1 = seo_title -%}
26
+ {%- endif -%}
27
+ {%- assign social_title = page.og_title | markdownify | strip_html | strip -%}
28
+ {%- if social_title == empty -%}{%- assign social_title = metatitle -%}{%- endif -%}
19
29
  {%- assign mainname = site.title | default: site.github.repository_name -%}
20
- {%- assign mainsub = site.subtitle | default: site.github.project_tagline -%}
21
- {%- capture sitename -%}{{ mainname | strip_html }} {{ site.title_separator | default: "|" }} {{ mainsub | strip_html }}{%- endcapture -%}
22
- {%- assign ogimage = page.og_image | default: page.header_img | default: site.og_image | default: site.author.avatar | default: site.github.owner_gravatar_url | absolute_url -%}
30
+ {%- assign sitename = mainname | markdownify | strip_html | strip -%}
31
+ {%- assign page_image_source = page.og_image | default: page.header_img | strip -%}
32
+ {%- assign ogimage_source = page.og_image | default: page.header_img | default: site.og_image | default: site.author.avatar | default: site.github.owner_gravatar_url | strip -%}
33
+ {%- assign ogimage = nil -%}
34
+ {%- if ogimage_source != empty -%}
35
+ {%- assign ogimage = ogimage_source | absolute_url -%}
36
+ {%- endif -%}
23
37
  {%- assign descfallback = page.content |
24
38
  markdownify | newline_to_br |
25
39
  replace:"<br />", ",.," |
26
40
  replace:"{{", ",.," |
27
41
  replace:"{%", ",.," |
28
42
  split: ",.," | first -%}
29
- {%- assign ogdesc = page.excerpt | default: descfallback |
30
- strip_html | escape_once -%}
31
- {%- if page.subtitle -%}
32
- {%- assign ogdesc = page.subtitle | append: " - " | append: ogdesc | strip_html | escape_once -%}
43
+ {%- assign explicit_description = page.description | markdownify | strip_html | split: ' ' | join: ' ' | strip -%}
44
+ {%- assign ogdesc = page.excerpt | markdownify | strip_html | split: ' ' | join: ' ' | strip -%}
45
+ {%- if ogdesc == empty and strippedurl == '/' -%}
46
+ {%- assign ogdesc = site.description | markdownify | strip_html | split: ' ' | join: ' ' | strip -%}
47
+ {%- endif -%}
48
+ {%- if ogdesc == empty -%}
49
+ {%- assign ogdesc = descfallback | markdownify | strip_html | split: ' ' | join: ' ' | strip -%}
33
50
  {%- endif -%}
51
+ {%- assign metasubtitle = page.subtitle | markdownify | strip_html | split: ' ' | join: ' ' | strip -%}
52
+ {%- if explicit_description != empty -%}
53
+ {%- assign ogdesc = explicit_description -%}
54
+ {%- elsif metasubtitle != empty -%}
55
+ {%- assign description_lower = ogdesc | downcase -%}
56
+ {%- assign subtitle_lower = metasubtitle | downcase -%}
57
+ {%- if ogdesc == empty -%}
58
+ {%- assign ogdesc = metasubtitle -%}
59
+ {%- else -%}
60
+ {%- unless description_lower contains subtitle_lower -%}
61
+ {%- assign ogdesc = metasubtitle | append: ' - ' | append: ogdesc -%}
62
+ {%- endunless -%}
63
+ {%- endif -%}
64
+ {%- endif -%}
65
+ {%- assign ogdesc = ogdesc | newline_to_br | replace: '<br />', ' ' | strip_newlines | strip | escape_once -%}
34
66
  {%- assign links = page.author.links | default: site.author.links -%}
35
- {%- for item in links -%}
36
- {%- if item.url contains "twitter.com/" -%}
37
- {%- assign twitterauthor = item.url | split: "/" | last -%}
38
- {%- break -%}
67
+ {%- assign creator_links = site.author.links -%}
68
+ {%- if page.author -%}
69
+ {%- assign creator_links = page.author.links -%}
70
+ {%- endif -%}
71
+ {%- assign twitterauthor = nil -%}
72
+ {%- assign twitter_reserved_paths = 'home,explore,search,notifications,messages,settings,i,intent,share,compose,login,logout,signup,about,privacy,tos,help,download,jobs,hashtag,lists,communities,premium,verified,account' | split: ',' -%}
73
+ {%- assign twitter_username_chars = 'abcdefghijklmnopqrstuvwxyz0123456789_' -%}
74
+ {%- for item in creator_links -%}
75
+ {%- assign author_profile_url = item.url | split: '?' | first | split: '#' | first -%}
76
+ {%- assign author_url_parts = author_profile_url | split: '/' -%}
77
+ {%- assign author_scheme = author_url_parts[0] | downcase -%}
78
+ {%- assign author_host = nil -%}
79
+ {%- unless author_url_parts[2] contains '@' -%}
80
+ {%- assign author_host = author_url_parts[2] | split: ':' | first | downcase -%}
81
+ {%- endunless -%}
82
+ {%- if author_host == "twitter.com" or author_host == "www.twitter.com" or author_host == "x.com" or author_host == "www.x.com" -%}
83
+ {%- assign twitter_username = author_url_parts[3] -%}
84
+ {%- assign twitter_username_lower = twitter_username | downcase -%}
85
+ {%- assign twitter_username_size = twitter_username | size -%}
86
+ {%- assign twitter_profile_path = author_url_parts[0] | append: '//' | append: author_url_parts[2] | append: '/' | append: twitter_username -%}
87
+ {%- assign twitter_profile_path_slash = twitter_profile_path | append: '/' -%}
88
+ {%- assign twitter_profile_valid = false -%}
89
+ {%- if author_scheme == 'https:' or author_scheme == 'http:' -%}
90
+ {%- if author_profile_url == twitter_profile_path or author_profile_url == twitter_profile_path_slash -%}
91
+ {%- if twitter_username_size > 0 and twitter_username_size <= 15 -%}
92
+ {%- unless twitter_reserved_paths contains twitter_username_lower -%}
93
+ {%- assign twitter_profile_valid = true -%}
94
+ {%- assign twitter_characters = twitter_username_lower | split: '' -%}
95
+ {%- for character in twitter_characters -%}
96
+ {%- unless twitter_username_chars contains character -%}
97
+ {%- assign twitter_profile_valid = false -%}
98
+ {%- endunless -%}
99
+ {%- endfor -%}
100
+ {%- endunless -%}
101
+ {%- endif -%}
102
+ {%- endif -%}
103
+ {%- endif -%}
104
+ {%- if twitter_profile_valid -%}
105
+ {%- assign twitterauthor = twitter_username -%}
106
+ {%- break -%}
107
+ {%- endif -%}
39
108
  {%- endif -%}
40
109
  {%- endfor %}
41
110
  {%- assign authorlink = links | where_exp: "item", "item.url contains 'http'" %}
111
+ {%- if page.collection == "posts" -%}
112
+ {%- assign schema_type = "BlogPosting" -%}
113
+ {%- elsif strippedurl == "/" -%}
114
+ {%- assign schema_type = "WebSite" -%}
115
+ {%- else -%}
116
+ {%- assign schema_type = "WebPage" -%}
117
+ {%- endif %}
42
118
  <!--Google Structured Data-->
43
119
  <script type="application/ld+json">
44
120
  {
45
121
  "@context": "https://schema.org",
46
- {% if page.collection == "posts" %}
47
- "@type": "BlogPosting",
48
- {% else %}
49
- "@type": "Article",
50
- {% endif %}
122
+ "@type": {{ schema_type | jsonify }},
123
+ {% if schema_type == 'WebPage' %}
124
+ "@id": {% include snippets/jsonld-string.html value=canonical_url decode_html=false %},
125
+ "name": {% include snippets/jsonld-string.html value=metatitle1 %},
126
+ "description": {% include snippets/jsonld-string.html value=ogdesc %},
127
+ {% elsif schema_type == 'WebSite' %}
128
+ "@id": {%- assign jsonld_value = home_url | append: '#website' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
129
+ "name": {% include snippets/jsonld-string.html value=breadcrumb_site_name %},
130
+ "url": {% include snippets/jsonld-string.html value=home_url decode_html=false %},
131
+ {% else %}
132
+ "@id": {%- assign jsonld_value = canonical_url | append: '#article' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
51
133
  "mainEntityOfPage": {
52
134
  "@type": "WebPage",
53
- "@id": "{{ canonical_url }}"
135
+ "@id": {% include snippets/jsonld-string.html value=canonical_url decode_html=false %}
54
136
  },
55
- "headline": "{{ metatitle1 | strip_html }}",
56
- "image": "{{ ogimage }}",
57
- "datePublished": "{{ page.date | default: site.time | date_to_xmlschema }}",
58
- "dateModified": "{{ page.last_modified_at | default: page.date | default: site.time | date_to_xmlschema }}",
137
+ {% endif %}
138
+ "headline": {%- assign jsonld_value = metatitle1 | strip_html | strip -%}{% include snippets/jsonld-string.html value=jsonld_value %},
139
+ {% if schema_type == 'BlogPosting' %}
140
+ {% include snippets/article-images.html %}
141
+ {% else %}
142
+ "image": {% include snippets/jsonld-string.html value=ogimage decode_html=false %},
143
+ {% endif %}
144
+ {% if page.date %}
145
+ "datePublished": {{ page.date | date_to_xmlschema | jsonify }},
146
+ "dateModified": {{ page.last_modified_at | default: page.date | date_to_xmlschema | jsonify }},
147
+ {% endif %}
59
148
  "author": {
60
149
  "@type": "Person",
61
- "name": "{{ page.author.name | default: site.author.name | default: site.github.owner_name }}"
150
+ "name": {%- assign jsonld_value = page.author.name | default: site.author.name | default: site.github.owner_name -%}{% include snippets/jsonld-string.html value=jsonld_value %}
62
151
  {% if authorlink %}
63
152
  {% for item in authorlink %}
64
153
  {% if forloop.first %}
65
- , "url": "{{ item.url }}"
154
+ , "url": {% include snippets/jsonld-string.html value=item.url decode_html=false %}
66
155
  {% else %}
67
156
  {% if forloop.index == 2 %}
68
157
  , "sameAs" : [
69
158
  {% endif %}
70
- "{{ item.url }}"
159
+ {% include snippets/jsonld-string.html value=item.url decode_html=false %}
71
160
  {%- if forloop.last %}
72
161
  ]
73
162
  {% else %}
@@ -77,29 +166,23 @@
77
166
  {% endfor %}
78
167
  {% endif %}
79
168
  },
80
- "publisher": {
81
- "@type": "Organization",
82
- "name": "{{ site.author.name | default: site.github.owner_name }}",
83
- "url": "{{ home_url }}",
84
- "logo": {
85
- "@type": "ImageObject",
86
- "url": "{{ site.og_image | default: site.author.avatar | default: site.github.owner_gravatar_url | absolute_url }}"
87
- }
88
- }
169
+ "publisher": {% include snippets/publisher.html %}
89
170
  }
90
171
  </script>
91
- {% if page.breadcrumb_list %}
172
+ {% if page.breadcrumb_list.size > 0 %}
92
173
  <script type="application/ld+json">
93
174
  {
94
175
  "@context": "https://schema.org",
95
176
  "@type": "BreadcrumbList",
177
+ "@id": {%- assign jsonld_value = canonical_url | append: '#breadcrumb' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
96
178
  "itemListElement": [
97
179
  {% for item in page.breadcrumb_list %}
98
180
  {
99
181
  "@type": "ListItem",
182
+ "@id": {%- assign jsonld_value = canonical_url | append: '#breadcrumb-' | append: forloop.index -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
100
183
  "position": {{ forloop.index }},
101
- "name": "{{ item.label | strip_html }}",
102
- "item": "{{ item.url | absolute_url }}"
184
+ "name": {%- assign jsonld_value = item.label | strip_html | strip | default: item.url | default: breadcrumb_home_name -%}{% include snippets/jsonld-string.html value=jsonld_value %},
185
+ "item": {%- assign jsonld_value = item.url | absolute_url -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %}
103
186
  },
104
187
  {% if forloop.last %}
105
188
  {% assign loopplus1 = forloop.index | plus: 1 %}
@@ -107,39 +190,47 @@
107
190
  {% endfor %}
108
191
  {
109
192
  "@type": "ListItem",
193
+ "@id": {%- assign jsonld_value = canonical_url | append: '#breadcrumb-' | append: loopplus1 -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
110
194
  "position": {{ loopplus1 }},
111
- "name": "{{ page.title | strip_html }}"
195
+ "item": {% include snippets/jsonld-string.html value=canonical_url decode_html=false %},
196
+ "name": {% include snippets/jsonld-string.html value=breadcrumb_page_name %}
112
197
  }]
113
198
  }
114
199
  </script>
115
- {% else %}
200
+ {% elsif strippedurl != "/" %}
116
201
  <script type="application/ld+json">
117
202
  {
118
203
  "@context": "https://schema.org",
119
204
  "@type": "BreadcrumbList",
205
+ "@id": {%- assign jsonld_value = canonical_url | append: '#breadcrumb' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
120
206
  "itemListElement": [{
121
207
  "@type": "ListItem",
208
+ "@id": {%- assign jsonld_value = canonical_url | append: '#breadcrumb-1' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
122
209
  "position": 1,
123
- "name": "{{ site.navbar.brand.title | default: site.title | default: site.github.repository_name | strip_html }}",
124
- "item": "{{ "/" | absolute_url }}"
210
+ "name": {% include snippets/jsonld-string.html value=breadcrumb_home_name %},
211
+ "item": {%- assign jsonld_value = "/" | absolute_url -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %}
125
212
  },{
126
213
  "@type": "ListItem",
214
+ "@id": {%- assign jsonld_value = canonical_url | append: '#breadcrumb-2' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
127
215
  "position": 2,
128
- "name": "{{ page.title | strip_html }}"
216
+ "item": {% include snippets/jsonld-string.html value=canonical_url decode_html=false %},
217
+ "name": {% include snippets/jsonld-string.html value=breadcrumb_page_name %}
129
218
  }]
130
219
  }
131
220
  </script>
132
221
  {% endif %}
133
-
134
- <script type="application/ld+json">
135
- {
136
- "@context": "http://schema.org",
137
- "@type": "WebPage",
138
- "name": "{{ metatitle1 | strip_html }}",
139
- "description": "{{ ogdesc }}"
140
- }
141
- }
222
+ {% if schema_type != 'WebPage' %}
223
+ <script type="application/ld+json">
224
+ {
225
+ "@context": "https://schema.org",
226
+ "@type": "WebPage",
227
+ "@id": {% include snippets/jsonld-string.html value=canonical_url decode_html=false %},
228
+ "isPartOf": {"@id": {%- assign jsonld_value = home_url | append: '#website' -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %}},
229
+ "name": {%- assign jsonld_value = metatitle1 | strip_html -%}{% include snippets/jsonld-string.html value=jsonld_value %},
230
+ "description": {% include snippets/jsonld-string.html value=ogdesc %}
231
+ }
142
232
  </script>
233
+ {% endif %}
143
234
  {%- assign sitelink = site.author.links |
144
235
  where_exp: "item", "item.url contains 'http'"
145
236
  -%}
@@ -148,21 +239,22 @@ where_exp: "item", "item.url contains 'http'"
148
239
  "@context" : "https://schema.org",
149
240
  "@type" : "Person",
150
241
  {% if site.author.avatar %}
151
- "image": "{{ site.author.avatar | absolute_url }}",
242
+ "image": {%- assign jsonld_value = site.author.avatar | absolute_url -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
152
243
  {% endif %}
153
244
  {% if site.author.location %}
154
245
  "homeLocation": {
155
246
  "@type": "Place",
156
- "name": "{{ site.author.location }}"
247
+ "name": {% include snippets/jsonld-string.html value=site.author.location %}
157
248
  },
158
249
  {% endif %}
159
- "description": "Publisher",
160
- "name" : "{{ site.author.name | default: site.github.owner_name }}",
161
- "url" : "{{ "/" | absolute_url }}"
250
+ {%- capture publisher_settings -%}{{ site.publisher.type }}{{ site.publisher.name }}{{ site.publisher.url }}{{ site.publisher.logo }}{{ site.publisher.image }}{%- endcapture -%}
251
+ "description": {% if publisher_settings != empty %}"Site author"{% else %}"Publisher"{% endif %},
252
+ "name" : {%- assign jsonld_value = site.author.name | default: site.github.owner_name -%}{% include snippets/jsonld-string.html value=jsonld_value %},
253
+ "url" : {%- assign jsonld_value = "/" | absolute_url -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %}
162
254
  {% if sitelink %}
163
255
  , "sameAs" : [
164
256
  {% for item in sitelink %}
165
- "{{ item.url }}"{%- if forloop.last %}{% else %},{% endif %}
257
+ {% include snippets/jsonld-string.html value=item.url decode_html=false %}{%- if forloop.last %}{% else %},{% endif %}
166
258
  {% endfor %}
167
259
  ]
168
260
  {% endif %}
@@ -177,25 +269,25 @@ where_exp: "item", "item.url contains 'http'"
177
269
  "@context" : "https://schema.org",
178
270
  "@type" : "Person",
179
271
  {% if page.author.avatar %}
180
- "image": "{{ page.author.avatar | absolute_url }}",
272
+ "image": {%- assign jsonld_value = page.author.avatar | absolute_url -%}{% include snippets/jsonld-string.html value=jsonld_value decode_html=false %},
181
273
  {% endif %}
182
274
  {% if page.author.location %}
183
275
  "homeLocation": {
184
276
  "@type": "Place",
185
- "name": "{{ page.author.location }}"
277
+ "name": {% include snippets/jsonld-string.html value=page.author.location %}
186
278
  },
187
279
  {% endif %}
188
280
  "description": "Collaborator",
189
- "name" : "{{ page.author.name }}"
281
+ "name" : {% include snippets/jsonld-string.html value=page.author.name %}
190
282
  {% if pagelink %}
191
283
  {% for item in pagelink %}
192
284
  {% if forloop.first %}
193
- , "url": "{{ item.url }}"
285
+ , "url": {% include snippets/jsonld-string.html value=item.url decode_html=false %}
194
286
  {% else %}
195
287
  {% if forloop.index == 2 %}
196
288
  , "sameAs" : [
197
289
  {% endif %}
198
- "{{ item.url }}"
290
+ {% include snippets/jsonld-string.html value=item.url decode_html=false %}
199
291
  {%- if forloop.last %}
200
292
  ]
201
293
  {% else %}
@@ -207,39 +299,90 @@ where_exp: "item", "item.url contains 'http'"
207
299
  }
208
300
  </script>
209
301
  {% endif %}
210
- <title>{{ metatitle | strip_html }}</title>
211
- <link rel="canonical" href="{{ canonical_url }}">
302
+ <title>{{ metatitle | escape_once }}</title>
303
+ <link rel="canonical" href="{{ canonical_url | escape }}">
212
304
  <!-- Atom feed -->
213
305
  <link href="{{ './atom.xml' | absolute_url }}" type="application/atom+xml" rel="alternate" title="Atom feed {{ site.title }}" >
214
306
  <!-- RSS 2.0 feed -->
215
307
  <link href="{{ './rss.xml' | absolute_url }}" type="application/rss+xml" rel="alternate" title="RSS 2.0 feed {{ site.title }}" >
216
308
  <!-- Meta tags -->
217
309
  <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
218
- <meta name="author" content="{{ page.author.name | default: site.author.name | default: site.github.owner_name }}" >
219
- <meta name="copyright" content="{{ site.author.name | default: site.github.owner_name }}" >
220
- <meta name="description" content="{{- ogdesc | truncate: 160 -}}">
221
- <meta name="thumbnail" content="{{ ogimage }}" >
222
- <meta name="robots" content="index, follow">
223
- {%- assign: keyword = site.github.public_repositories |
224
- where_exp:"item", "item.name == site.github.repository_name " |
225
- map: "topics" -%}
226
- {% if keyword -%}
227
- <meta name="keywords" content="{{- keyword - | join: ','}}">
228
- {%- endif %}
310
+ <meta name="author" content="{{ page.author.name | default: site.author.name | default: site.github.owner_name | escape_once }}" >
311
+ <meta name="copyright" content="{{ site.author.name | default: site.github.owner_name | escape_once }}" >
312
+ <meta name="description" content="{{- ogdesc -}}">
313
+ {% if ogimage %}<meta name="thumbnail" content="{{ ogimage | escape_once }}" >{% endif %}
314
+ <meta name="robots" content="{{ page.robots | default: 'index, follow' | strip | default: 'index, follow' | escape }}">
229
315
  {% if site.chulapa-skin.vars.primary -%}
230
316
  <!-- Chrome, Firefox OS and Opera -->
231
317
  <meta name="theme-color" content="{{ site.chulapa-skin.vars.primary }}">
232
318
  {%- endif %}
233
319
  <!-- OpenGraph -->
234
- <meta property="og:title" content="{{ metatitle | strip_html }}" >
235
- <meta property="og:site_name" content="{{ sitename | strip_html }}" >
236
- <meta property="og:url" content="{{ canonical_url }}" >
237
- <meta property="og:type" content="website" >
238
- <meta property="og:description" content="{{ ogdesc | truncatewords: 20 }}" >
239
- <meta property="og:locale" content="{{- site.locale | default: 'en-US' -}}" >
240
- <meta property="og:image" content="{{- ogimage -}}" >
320
+ <meta property="og:title" content="{{ social_title | escape_once }}" >
321
+ <meta property="og:site_name" content="{{ sitename | strip_html | escape_once }}" >
322
+ <meta property="og:url" content="{{ canonical_url | escape }}" >
323
+ {%- assign og_type = page.og_type | strip -%}
324
+ {%- if og_type == empty -%}
325
+ {%- if page.collection == 'posts' -%}{%- assign og_type = 'article' -%}
326
+ {%- else -%}{%- assign og_type = 'website' -%}{%- endif -%}
327
+ {%- endif %}
328
+ <meta property="og:type" content="{{ og_type | escape }}" >
329
+ {% if og_type == 'article' %}
330
+ {% if page.date %}<meta property="article:published_time" content="{{ page.date | date_to_xmlschema | escape }}">{% endif %}
331
+ {% if page.last_modified_at %}<meta property="article:modified_time" content="{{ page.last_modified_at | date_to_xmlschema | escape }}">{% endif %}
332
+ {%- assign article_author = page.og_article_author | strip -%}
333
+ {%- if article_author == empty -%}
334
+ {%- if page.author -%}{%- assign article_author = page.author.url | strip -%}
335
+ {%- else -%}{%- assign article_author = site.author.url | strip -%}{%- endif -%}
336
+ {%- endif -%}
337
+ {% if article_author != empty %}<meta property="article:author" content="{{ article_author | absolute_url | escape }}">{% endif %}
338
+ {%- assign article_section = page.og_article_section | strip -%}
339
+ {%- if article_section == empty -%}{%- assign article_section = page.categories | first | strip -%}{%- endif -%}
340
+ {% if article_section != empty %}<meta property="article:section" content="{{ article_section | escape }}">{% endif %}
341
+ {% for article_tag in page.tags %}
342
+ {%- assign article_tag_text = article_tag | strip -%}
343
+ {% if article_tag_text != empty %}<meta property="article:tag" content="{{ article_tag_text | escape }}">{% endif %}
344
+ {% endfor %}
345
+ {% endif %}
346
+ <meta property="og:description" content="{{ ogdesc }}" >
347
+ {%- include snippets/page-language.html -%}
348
+ {%- assign og_locale_input = page.og_locale | strip -%}
349
+ {%- assign explicit_page_language = page.locale | strip -%}
350
+ {%- if og_locale_input == empty and explicit_page_language != empty -%}{%- assign og_locale_input = page_language -%}{%- endif -%}
351
+ {%- if og_locale_input == empty -%}{%- assign og_locale_input = site.og_locale | strip -%}{%- endif -%}
352
+ {%- if og_locale_input == empty -%}{%- assign og_locale_input = page_language -%}{%- endif -%}
353
+ {%- include snippets/og-locale.html locale=og_locale_input -%}
354
+ {%- assign primary_og_locale = normalized_og_locale -%}
355
+ {% if primary_og_locale %}<meta property="og:locale" content="{{ primary_og_locale }}">{% endif %}
356
+ {%- assign alternate_locales = site.og_locale_alternate -%}
357
+ {%- if page.og_locale_alternate != nil -%}{%- assign alternate_locales = page.og_locale_alternate -%}{%- endif -%}
358
+ {%- assign emitted_locales = ',' | append: primary_og_locale | append: ',' -%}
359
+ {% for alternate_locale in alternate_locales %}
360
+ {%- include snippets/og-locale.html locale=alternate_locale -%}
361
+ {%- assign locale_token = ',' | append: normalized_og_locale | append: ',' -%}
362
+ {%- if normalized_og_locale -%}
363
+ {%- unless emitted_locales contains locale_token %}
364
+ <meta property="og:locale:alternate" content="{{ normalized_og_locale }}">
365
+ {%- assign emitted_locales = emitted_locales | append: locale_token -%}
366
+ {% endunless -%}
367
+ {%- endif -%}
368
+ {% endfor %}
369
+ {% if ogimage %}
370
+ <meta property="og:image" content="{{- ogimage | escape_once -}}" >
371
+ {%- assign image_fields = 'alt,width,height,type' | split: ',' -%}
372
+ {%- for field in image_fields -%}
373
+ {%- assign field_key = 'og_image_' | append: field -%}
374
+ {%- assign image_value = page[field_key] | strip -%}
375
+ {%- if image_value == empty and page_image_source == empty and ogimage_source == site.og_image -%}
376
+ {%- assign image_value = site[field_key] | strip -%}
377
+ {%- endif -%}
378
+ {%- if image_value != empty %}
379
+ <meta property="og:image:{{ field }}" content="{{ image_value | escape_once }}" >
380
+ {%- endif -%}
381
+ {%- endfor %}
382
+ {% endif %}
241
383
  <!-- Twitter/X Cards -->
242
384
  <meta name="twitter:card" content="summary_large_image">
385
+ <meta name="twitter:description" content="{{ ogdesc }}">
243
386
  {%- if site.twitter_site %}
244
387
  <meta name="twitter:site" content="@{{- site.twitter_site -}}" >
245
388
  {% endif -%}
@@ -257,7 +400,7 @@ where_exp: "item", "item.url contains 'http'"
257
400
  {%- endif %}
258
401
  <!-- Preconnect with Google Fonts -->
259
402
  <link rel="preconnect" href="https://fonts.googleapis.com">
260
- <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
403
+ <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
261
404
  {% for font in site.googlefonts -%}
262
405
  {% if font.url -%}
263
406
  <link href="{{ font.url }}" rel="stylesheet">
@@ -265,7 +408,7 @@ where_exp: "item", "item.url contains 'http'"
265
408
  {%- endfor %}
266
409
  <!-- Fontawesome-->
267
410
  <!-- v6 -->
268
- {% assign fakit = site.fa5_kit_code | default: fa_kit_code %}
411
+ {% assign fakit = site.fa5_kit_code | default: site.fa_kit_code %}
269
412
  {% if fakit -%}
270
413
  <script src="https://kit.fontawesome.com/{{ fakit }}.js" crossorigin="anonymous"></script>
271
414
  {%- else -%}
@@ -275,11 +418,7 @@ where_exp: "item", "item.url contains 'http'"
275
418
  <!-- Compatibility with FontAwesome 4 -->
276
419
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@5/css/v4-shims.min.css">
277
420
  {%- endif %}
278
- {%- if page.show_applause %}
279
- <link rel="stylesheet" href="https://unpkg.com/applause-button/dist/applause-button.css">
280
- <script src="https://unpkg.com/applause-button/dist/applause-button.js"></script>
281
- {% endif -%}
282
- <link rel="preload" href="https://cdn.jsdelivr.net/gh/dieghernan/chulapa@master/assets/js/chulapa_script.js" as="script" >
421
+ <link rel="preload" href="{{ '/assets/js/chulapa_script.js' | relative_url }}" as="script" >
283
422
  <link rel="preload" href="https://cdn.jsdelivr.net/gh/dieghernan/chulapa@master/assets/fonts/Chulapa/Chulapa-Bold_vmod.otf" as="font" type="font/otf" crossorigin>
284
423
  <!-- Theme css (Bootstrap included) -->
285
424
  <link rel="stylesheet" id="maincss" href="{{- "assets/css/main.css " | absolute_url -}}" >
@@ -0,0 +1,36 @@
1
+ {% if site.search.show_attrib == false %}
2
+ {% assign show_attrib = site.search.show_attrib %}
3
+ {% else %}
4
+ {% assign show_attrib = true %}
5
+ {% endif %}
6
+
7
+ {% if show_attrib %}
8
+ <style>
9
+ @import url('https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@200..900&display=swap');
10
+
11
+ .fuse {
12
+ font-family: "Source Sans 3", serif;
13
+ font-weight: 400;
14
+ }
15
+
16
+ .fuse-logo {
17
+ color: #9b59b6;
18
+ font-weight: bolder;
19
+ --fa-animation-iteration-count:1;
20
+ --fa-animation-duration: 0.5s;
21
+ --fa-animation-delay: 0.5s;
22
+ }
23
+
24
+ </style>
25
+
26
+ {% endif %}
27
+
28
+ <form class="input-group">
29
+ <label class="sr-only" for="search"> Search </label>
30
+ <input type="search" id="search" class="form-control rounded-right" placeholder="{{ site.search.label | default: "Search" }}...">
31
+ </form>
32
+ {% if show_attrib %}
33
+ <p class="text-right small mt-1"> Powered by <i class="fa-solid fa-asterisk fa-lg fa-spin fuse-logo"></i> <a href="https://www.fusejs.io/">Fuse.js</a></p>
34
+ {% endif %}
35
+ <div id="resultscount"></div>
36
+ <div id="results" class="mt-3 text-left"></div>
@@ -1,7 +1,27 @@
1
- <form class="input-group">
2
- <label class="sr-only" for="search"> Search </label>
3
- <input type="search" id="search" class="form-control rounded-right" placeholder="{{ site.search.label | default: "Search" }}...">
4
- </form>
5
- <p class="text-right small mt-1"> Powered by <a href="https://lunrjs.com/" class="lunr px-2">L U N R</a></p>
6
- <div id="resultscount"></div>
7
- <div id="results" class="mt-3 text-left"></div>
1
+ {% if site.search.show_attrib == false %}
2
+ {% assign show_attrib = site.search.show_attrib %}
3
+ {% else %}
4
+ {% assign show_attrib = true %}
5
+ {% endif %}
6
+
7
+ {% if show_attrib %}
8
+ <style>
9
+ @import url('https://fonts.googleapis.com/css2?family=Heebo:wght@300&display=swap');
10
+
11
+ .lunr{
12
+ font-family: 'Heebo', sans-serif;
13
+ background-color: black;
14
+ color: white;
15
+ }
16
+ </style>
17
+ {% endif %}
18
+
19
+ <form class="input-group">
20
+ <label class="sr-only" for="search"> Search </label>
21
+ <input type="search" id="search" class="form-control rounded-right" placeholder="{{ site.search.label | default: "Search" }}...">
22
+ </form>
23
+ {% if show_attrib %}
24
+ <p class="text-right small mt-1"> Powered by <a href="https://lunrjs.com/" class="lunr px-2">L U N R</a></p>
25
+ {% endif %}
26
+ <div id="resultscount"></div>
27
+ <div id="results" class="mt-3 text-left"></div>
@@ -0,0 +1,46 @@
1
+ {% if site.search.show_attrib == false %}
2
+ {% assign show_attrib = site.search.show_attrib %}
3
+ {% else %}
4
+ {% assign show_attrib = true %}
5
+ {% endif %}
6
+
7
+ <form class="input-group">
8
+ <label class="sr-only" for="search"> Search </label>
9
+ <input type="search" id="search-input" class="form-control rounded-right" placeholder="{{ site.search.label | default: "Search" }}...">
10
+ </form>
11
+ {% if show_attrib %}
12
+ <p class="text-right small mt-1"> Powered by <a href="https://github.com/christian-fei/Simple-Jekyll-Search">Simple-Jekyll-Search</a></p>
13
+ {% endif %}
14
+
15
+ <div id="results-container" class="mt-3 text-left"></div>
16
+
17
+ <script src="https://unpkg.com/simple-jekyll-search@latest/dest/simple-jekyll-search.min.js"></script>
18
+
19
+ <script>
20
+ SimpleJekyllSearch({
21
+ searchInput: document.getElementById('search-input'),
22
+ resultsContainer: document.getElementById('results-container'),
23
+ searchResultTemplate: '<article class="my-2 text-left">' +
24
+ '<div class="row">' +
25
+ '<div class="col">' +
26
+ '<h5 class="chulapa-links-hover-only">' +
27
+ '<a href="{url}" rel="permalink">{title}</a>' +
28
+ '</h5>' +
29
+ '</div>' +
30
+ '<div class="col-4 col-md-3">' +
31
+ '<a href="{url}" rel="permalink">' +
32
+ '<div class="rounded-lg chulapa-overlay-img chulapa-min-h-10"'+
33
+ 'style="background-image{img}" ></div>' +
34
+ '</div></a>' +
35
+ '</div>' +
36
+ '<div class="row mt-2">' +
37
+ '<div class="col">' +
38
+ '<p>{excerpt}</p>' +
39
+ '</div>' +
40
+ '</div>' +
41
+ '<hr>' +
42
+ '</article>',
43
+ fuzzy: false,
44
+ json: '{{ "/assets/js/simplesearch/simplesearch-store.json" | absolute_url }}'
45
+ });
46
+ </script>