|
80 | 80 | <!-- Schema.org --> |
81 | 81 | {% comment %} Social links generator for "sameAs schema" {% endcomment %} |
82 | 82 | {% assign sameaslinks = '' | split: ',' %} |
83 | | - {% if site.orcid_id %} |
84 | | - {% capture link %}https://orcid.org/{{ site.orcid_id }}{% endcapture %} |
85 | | - {% assign sameaslinks = sameaslinks | push: link %} |
86 | | - {% endif %} |
87 | | - {% if site.scholar_userid %} |
88 | | - {% capture link %}https://scholar.google.com/citations?user={{ site.scholar_userid }}{% endcapture %} |
89 | | - {% assign sameaslinks = sameaslinks | push: link %} |
90 | | - {% endif %} |
91 | | - {% if site.semanticscholar_id %} |
92 | | - {% capture link %}https://www.semanticscholar.org/author/{{ site.semanticscholar_id }}{% endcapture %} |
93 | | - {% assign sameaslinks = sameaslinks | push: link %} |
94 | | - {% endif %} |
95 | | - {% if site.publons_id %} |
96 | | - {% capture link %}https://publons.com/a/{{ site.publons_id }}/{% endcapture %} |
97 | | - {% assign sameaslinks = sameaslinks | push: link %} |
98 | | - {% endif %} |
99 | | - {% if site.lattes_id %} |
100 | | - {% capture link %}http://lattes.cnpq.br/{{ site.lattes_id }}{% endcapture %} |
101 | | - {% assign sameaslinks = sameaslinks | push: link %} |
102 | | - {% endif %} |
103 | | - {% if site.osf_id %} |
104 | | - {% capture link %}https://osf.io/{{ site.osf_id }}/{% endcapture %} |
105 | | - {% assign sameaslinks = sameaslinks | push: link %} |
106 | | - {% endif %} |
107 | | - {% if site.research_gate_profile %} |
108 | | - {% capture link %}https://www.researchgate.net/profile/{{ site.research_gate_profile }}{% endcapture %} |
109 | | - {% assign sameaslinks = sameaslinks | push: link %} |
110 | | - {% endif %} |
111 | | - {% if site.scopus_id %} |
112 | | - {% capture link %}https://www.scopus.com/authid/detail.uri?authorId={{ site.scopus_id }}{% endcapture %} |
113 | | - {% assign sameaslinks = sameaslinks | push: link %} |
114 | | - {% endif %} |
115 | | - {% if site.github_username %} |
116 | | - {% capture link %}https://github.com/{{ site.github_username }}{% endcapture %} |
117 | | - {% assign sameaslinks = sameaslinks | push: link %} |
118 | | - {% endif %} |
119 | | - {% if site.telegram_username %} |
120 | | - {% capture link %}https://telegram.me/{{ site.telegram_username }}{% endcapture %} |
121 | | - {% assign sameaslinks = sameaslinks | push: link %} |
122 | | - {% endif %} |
123 | | - {% if site.linkedin_username %} |
124 | | - {% capture link %}https://www.linkedin.com/in/{{ site.linkedin_username }}{% endcapture %} |
125 | | - {% assign sameaslinks = sameaslinks | push: link %} |
126 | | - {% endif %} |
127 | | - {% if site.x_username %} |
128 | | - {% capture link %}https://twitter.com/{{ site.x_username }}{% endcapture %} |
129 | | - {% assign sameaslinks = sameaslinks | push: link %} |
130 | | - {% endif %} |
131 | | - {% if site.mastodon_username %} |
132 | | - {% capture link %}https://{{ site.mastodon_username }}{% endcapture %} |
133 | | - {% assign sameaslinks = sameaslinks | push: link %} |
134 | | - {% endif %} |
135 | | - {% if site.medium_username %} |
136 | | - {% capture link %}https://medium.com/@{{ site.medium_username }}{% endcapture %} |
137 | | - {% assign sameaslinks = sameaslinks | push: link %} |
138 | | - {% endif %} |
139 | | - {% if site.quora_username %} |
140 | | - {% capture link %}https://www.quora.com/profile/{{ site.quora_username }}{% endcapture %} |
141 | | - {% assign sameaslinks = sameaslinks | push: link %} |
142 | | - {% endif %} |
143 | | - {% if site.blogger_url %} |
144 | | - {% capture link %}{{ site.blogger_url }}{% endcapture %} |
145 | | - {% assign sameaslinks = sameaslinks | push: link %} |
146 | | - {% endif %} |
147 | | - {% if site.work_url %} |
148 | | - {% capture link %}{{ site.work_url }}{% endcapture %} |
149 | | - {% assign sameaslinks = sameaslinks | push: link %} |
150 | | - {% endif %} |
151 | | - {% if site.wikidata_id %} |
152 | | - {% capture link %}https://www.wikidata.org/wiki/{{ site.wikidata_id }}{% endcapture %} |
153 | | - {% assign sameaslinks = sameaslinks | push: link %} |
154 | | - {% endif %} |
155 | | - {% if site.wikipedia_id %} |
156 | | - {% capture link %}https://wikipedia.org/wiki/User:{{ site.wikipedia_id }}{% endcapture %} |
157 | | - {% assign sameaslinks = sameaslinks | push: link %} |
158 | | - {% endif %} |
159 | | - {% if site.strava_userid %} |
160 | | - {% capture link %}https://www.strava.com/athletes/{{ site.strava_userid }}{% endcapture %} |
161 | | - {% assign sameaslinks = sameaslinks | push: link %} |
162 | | - {% endif %} |
163 | | - {% if site.keybase_username %} |
164 | | - {% capture link %}https://keybase.io/{{ site.keybase_username }}{% endcapture %} |
165 | | - {% assign sameaslinks = sameaslinks | push: link %} |
166 | | - {% endif %} |
167 | | - {% if site.gitlab_username %} |
168 | | - {% capture link %}https://gitlab.com/{{ site.gitlab_username }}{% endcapture %} |
169 | | - {% assign sameaslinks = sameaslinks | push: link %} |
170 | | - {% endif %} |
171 | | - {% if site.dblp_url %} |
172 | | - {% capture link %}{{ site.dblp_url }}{% endcapture %} |
173 | | - {% assign sameaslinks = sameaslinks | push: link %} |
174 | | - {% endif %} |
175 | | - {% if site.stackoverflow_id %} |
176 | | - {% capture link %}https://stackoverflow.com/users/{{ site.stackoverflow_id }}{% endcapture %} |
177 | | - {% assign sameaslinks = sameaslinks | push: link %} |
178 | | - {% endif %} |
179 | | - {% if site.kaggle_id %} |
180 | | - {% capture link %}https://www.kaggle.com/{{ site.kaggle_id }}{% endcapture %} |
181 | | - {% assign sameaslinks = sameaslinks | push: link %} |
182 | | - {% endif %} |
183 | | - {% if site.lastfm_id %} |
184 | | - {% capture link %}https://www.last.fm/user/{{ site.lastfm_id }}{% endcapture %} |
185 | | - {% assign sameaslinks = sameaslinks | push: link %} |
186 | | - {% endif %} |
187 | | - {% if site.spotify_id %} |
188 | | - {% capture link %}https://open.spotify.com/user/{{ site.spotify_id }}{% endcapture %} |
189 | | - {% assign sameaslinks = sameaslinks | push: link %} |
190 | | - {% endif %} |
191 | | - {% if site.pinterest_id %} |
192 | | - {% capture link %}https://www.pinterest.com/{{ site.pinterest_id }}{% endcapture %} |
193 | | - {% assign sameaslinks = sameaslinks | push: link %} |
194 | | - {% endif %} |
195 | | - {% if site.unsplash_id %} |
196 | | - {% capture link %}https://unsplash.com/@{{ site.unsplash_id }}{% endcapture %} |
197 | | - {% assign sameaslinks = sameaslinks | push: link %} |
198 | | - {% endif %} |
199 | | - {% if site.instagram_id %} |
200 | | - {% capture link %}https://instagram.com/{{ site.instagram_id }}{% endcapture %} |
201 | | - {% assign sameaslinks = sameaslinks | push: link %} |
202 | | - {% endif %} |
203 | | - {% if site.facebook_id %} |
204 | | - {% capture link %}https://facebook.com/{{ site.facebook_id }}{% endcapture %} |
205 | | - {% assign sameaslinks = sameaslinks | push: link %} |
206 | | - {% endif %} |
207 | | - {% if site.youtube_id %} |
208 | | - {% capture link %}https://youtube.com/@{{ site.youtube_id }}{% endcapture %} |
209 | | - {% assign sameaslinks = sameaslinks | push: link %} |
210 | | - {% endif %} |
211 | | - {% if site.discord_id %} |
212 | | - {% capture link %}https://discord.com/users/{{ site.discord_id }}{% endcapture %} |
213 | | - {% assign sameaslinks = sameaslinks | push: link %} |
214 | | - {% endif %} |
215 | | - {% if site.zotero_username %} |
216 | | - {% capture link %}https://www.zotero.org/{{ site.zotero_username }}{% endcapture %} |
217 | | - {% assign sameaslinks = sameaslinks | push: link %} |
218 | | - {% endif %} |
219 | | - {% if sameaslinks != blank %} |
220 | | - {% assign sameaslinks = sameaslinks | split: '' %} |
221 | | - {% endif %} |
| 83 | + {% for social in site.data.socials %} |
| 84 | + {% case social[0] %} |
| 85 | + {% when 'acm_id' %} |
| 86 | + {% capture link %}https://dl.acm.org/profile/{{ social[1] }}/{% endcapture %} |
| 87 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 88 | + {% when 'blogger_url' %} |
| 89 | + {% capture link %}{{ social[1] }}{% endcapture %} |
| 90 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 91 | + {% when 'bluesky_url' %} |
| 92 | + {% capture link %}{{ social[1] }}{% endcapture %} |
| 93 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 94 | + {% when 'dblp_url' %} |
| 95 | + {% capture link %}{{ social[1] }}{% endcapture %} |
| 96 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 97 | + {% when 'discord_id' %} |
| 98 | + {% capture link %}https://discord.com/users/{{ social[1] }}{% endcapture %} |
| 99 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 100 | + {% when 'email' %} |
| 101 | + {% comment %} |
| 102 | + {% capture link %}mailto:{{ social[1] | encode_email }}{% endcapture %} |
| 103 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 104 | + {% endcomment %} |
| 105 | + {% when 'facebook_id' %} |
| 106 | + {% capture link %}https://facebook.com/{{ social[1] }}{% endcapture %} |
| 107 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 108 | + {% when 'flickr_id' %} |
| 109 | + {% capture link %}https://www.flickr.com/{{ social[1] }}{% endcapture %} |
| 110 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 111 | + {% when 'github_username' %} |
| 112 | + {% capture link %}https://github.com/{{ social[1] }}{% endcapture %} |
| 113 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 114 | + {% when 'gitlab_username' %} |
| 115 | + {% capture link %}https://gitlab.com/{{ social[1] }}{% endcapture %} |
| 116 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 117 | + {% when 'hal_id' %} |
| 118 | + {% capture link %}https://cv.hal.science/{{ social[1] }}/{% endcapture %} |
| 119 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 120 | + {% when 'ieee_id' %} |
| 121 | + {% capture link %}https://ieeexplore.ieee.org/author/{{ social[1] }}/{% endcapture %} |
| 122 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 123 | + {% when 'inspirehep_id' %} |
| 124 | + {% capture link %}https://inspirehep.net/authors/{{ social[1] }}{% endcapture %} |
| 125 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 126 | + {% when 'instagram_id' %} |
| 127 | + {% capture link %}https://instagram.com/{{ social[1] }}{% endcapture %} |
| 128 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 129 | + {% when 'kaggle_id' %} |
| 130 | + {% capture link %}https://www.kaggle.com/{{ social[1] }}{% endcapture %} |
| 131 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 132 | + {% when 'keybase_username' %} |
| 133 | + {% capture link %}https://keybase.io/{{ social[1] }}{% endcapture %} |
| 134 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 135 | + {% when 'lastfm_id' %} |
| 136 | + {% capture link %}https://www.last.fm/user/{{ social[1] }}{% endcapture %} |
| 137 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 138 | + {% when 'lattes_id' %} |
| 139 | + {% capture link %}http://lattes.cnpq.br/{{ social[1] }}{% endcapture %} |
| 140 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 141 | + {% when 'leetcode_id' %} |
| 142 | + {% capture link %}https://leetcode.com/u/{{ social[1] }}/{% endcapture %} |
| 143 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 144 | + {% when 'linkedin_username' %} |
| 145 | + {% capture link %}https://www.linkedin.com/in/{{ social[1] }}{% endcapture %} |
| 146 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 147 | + {% when 'mastodon_username' %} |
| 148 | + {% capture link %}https://{{ social[1] }}{% endcapture %} |
| 149 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 150 | + {% when 'medium_username' %} |
| 151 | + {% capture link %}https://medium.com/@{{ social[1] }}{% endcapture %} |
| 152 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 153 | + {% when 'orcid_id' %} |
| 154 | + {% capture link %}https://orcid.org/{{ social[1] }}{% endcapture %} |
| 155 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 156 | + {% when 'osf_id' %} |
| 157 | + {% capture link %}https://osf.io/{{ social[1] }}/{% endcapture %} |
| 158 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 159 | + {% when 'pinterest_id' %} |
| 160 | + {% capture link %}https://www.pinterest.com/{{ social[1] }}{% endcapture %} |
| 161 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 162 | + {% when 'publons_id' %} |
| 163 | + {% capture link %}https://publons.com/a/{{ social[1] }}/{% endcapture %} |
| 164 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 165 | + {% when 'quora_username' %} |
| 166 | + {% capture link %}https://www.quora.com/profile/{{ social[1] }}{% endcapture %} |
| 167 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 168 | + {% when 'research_gate_profile' %} |
| 169 | + {% capture link %}https://www.researchgate.net/profile/{{ social[1] }}/{% endcapture %} |
| 170 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 171 | + {% when 'rss_icon' %} |
| 172 | + {% comment %} |
| 173 | + {% capture link %}{{ site.baseurl }}/feed.xml{% endcapture %} |
| 174 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 175 | + {% endcomment %} |
| 176 | + {% when 'scholar_userid' %} |
| 177 | + {% capture link %}https://scholar.google.com/citations?user={{ social[1] }}{% endcapture %} |
| 178 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 179 | + {% when 'scopus_id' %} |
| 180 | + {% capture link %}https://www.scopus.com/authid/detail.uri?authorId={{ social[1] }}{% endcapture %} |
| 181 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 182 | + {% when 'semanticscholar_id' %} |
| 183 | + {% capture link %}https://www.semanticscholar.org/author/{{ social[1] }}{% endcapture %} |
| 184 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 185 | + {% when 'spotify_id' %} |
| 186 | + {% capture link %}https://open.spotify.com/user/{{ social[1] }}{% endcapture %} |
| 187 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 188 | + {% when 'stackoverflow_id' %} |
| 189 | + {% capture link %}https://stackoverflow.com/users/{{ social[1] }}{% endcapture %} |
| 190 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 191 | + {% when 'strava_userid' %} |
| 192 | + {% capture link %}https://www.strava.com/athletes/{{ social[1] }}{% endcapture %} |
| 193 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 194 | + {% when 'telegram_username' %} |
| 195 | + {% capture link %}https://telegram.me/{{ social[1] }}{% endcapture %} |
| 196 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 197 | + {% when 'unsplash_id' %} |
| 198 | + {% capture link %}https://unsplash.com/@{{ social[1] }}{% endcapture %} |
| 199 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 200 | + {% when 'whatsapp_number' %} |
| 201 | + {% capture link %}https://wa.me/{{ social[1] }}{% endcapture %} |
| 202 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 203 | + {% when 'wikidata_id' %} |
| 204 | + {% capture link %}https://www.wikidata.org/wiki/{{ social[1] }}{% endcapture %} |
| 205 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 206 | + {% when 'wikipedia_id' %} |
| 207 | + {% capture link %}https://wikipedia.org/wiki/User:{{ social[1] }}{% endcapture %} |
| 208 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 209 | + {% when 'work_url' %} |
| 210 | + {% capture link %}{{ social[1] }}{% endcapture %} |
| 211 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 212 | + {% when 'x_username' %} |
| 213 | + {% capture link %}https://twitter.com/{{ social[1] }}{% endcapture %} |
| 214 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 215 | + {% when 'youtube_id' %} |
| 216 | + {% capture link %}https://youtube.com/@{{ social[1] }}{% endcapture %} |
| 217 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 218 | + {% when 'zotero_username' %} |
| 219 | + {% capture link %}https://www.zotero.org/{{ social[1] }}{% endcapture %} |
| 220 | + {% assign sameaslinks = sameaslinks | push: link %} |
| 221 | + {% else %} |
| 222 | + {% assign sameaslinks = sameaslinks | push: social[1].url %} |
| 223 | + {% endcase %} |
| 224 | + {% endfor %} |
222 | 225 |
|
223 | 226 | <script type="application/ld+json"> |
224 | 227 | { |
|
232 | 235 | "description": "{% if page.description %}{{ page.description }}{% else if site.description %}{{ site.description }}{% endif %}", |
233 | 236 | "headline": "{% if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}", |
234 | 237 | {% if sameaslinks != blank %} |
235 | | - "sameAs": {{ sameaslinks }}, |
| 238 | + "sameAs": {{ sameaslinks | jsonify }}, |
236 | 239 | {% endif %} |
237 | 240 | "name": "{{ author_name }}", |
238 | 241 | "@context": "https://schema.org" |
|
0 commit comments