mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-24 12:07:08 -04:00
Merge pull request #191 from ErikMichelson/feature/ogmetadata
Add customizable opengraph metadata for notes (see #40)
This commit is contained in:
commit
cd34a8c702
6 changed files with 55 additions and 2 deletions
|
@ -4,6 +4,14 @@
|
|||
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
||||
<meta name="mobile-web-app-capable" content="yes">
|
||||
<% for (var og in opengraph) { %>
|
||||
<% if (opengraph.hasOwnProperty(og) && opengraph[og].trim() !== '') { %>
|
||||
<meta property="og:<%- og %>" content="<%- opengraph[og] %>">
|
||||
<% }} if (!opengraph.hasOwnProperty('image')) { %>
|
||||
<meta property="og:image" content="<%- serverURL %>/codimd-icon-1024.png">
|
||||
<meta property="og:image:alt" content="CodiMD logo">
|
||||
<meta property="og:image:type" content="image/png">
|
||||
<% } %>
|
||||
<title><%= title %></title>
|
||||
<link rel="icon" type="image/png" href="<%- serverURL %>/favicon.png">
|
||||
<link rel="apple-touch-icon" href="<%- serverURL %>/apple-touch-icon.png">
|
||||
|
|
|
@ -6,6 +6,13 @@
|
|||
<meta name="mobile-web-app-capable" content="yes">
|
||||
<meta name="description" content="<%= __('Best way to write and share your knowledge in markdown.') %>">
|
||||
<meta name="keywords" content="Collaborative, Markdown, Notes">
|
||||
<meta property="og:title" content="CodiMD - <%= __('Collaborative markdown notes') %>">
|
||||
<meta property="og:description" content="<%= __('Best way to write and share your knowledge in markdown.') %>">
|
||||
<meta property="og:type" content="website">
|
||||
<meta property="og:url" content="<%- serverURL %>">
|
||||
<meta property="og:image" content="<%- serverURL %>/codimd-icon-1024.png">
|
||||
<meta property="og:image:alt" content="CodiMD logo">
|
||||
<meta property="og:image:type" content="image/png">
|
||||
<title>CodiMD - <%= __('Collaborative markdown notes') %></title>
|
||||
<link rel="icon" type="image/png" href="<%- serverURL %>/favicon.png">
|
||||
<link rel="apple-touch-icon" href="<%- serverURL %>/apple-touch-icon.png">
|
||||
|
|
|
@ -14,6 +14,14 @@
|
|||
<% if(typeof description !== 'undefined' && description) { %>
|
||||
<meta name="description" content="<%= description %>">
|
||||
<% } %>
|
||||
<% for (var og in opengraph) { %>
|
||||
<% if (opengraph.hasOwnProperty(og) && opengraph[og].trim() !== '') { %>
|
||||
<meta property="og:<%= og %>" content="<%= opengraph[og] %>">
|
||||
<% }} if (!opengraph.hasOwnProperty('image')) { %>
|
||||
<meta property="og:image" content="<%- serverURL %>/codimd-icon-1024.png">
|
||||
<meta property="og:image:alt" content="CodiMD logo">
|
||||
<meta property="og:image:type" content="image/png">
|
||||
<% } %>
|
||||
<title><%= title %></title>
|
||||
<link rel="icon" type="image/png" href="<%- serverURL %>/favicon.png">
|
||||
<link rel="apple-touch-icon" href="<%- serverURL %>/apple-touch-icon.png">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue