View Issue Details

IDProjectCategoryView StatusLast Update
0007829TalerWeb site(s)public2023-09-23 13:09
Reporterdvn Assigned ToStefan Resolution deadline
ImplementerReviewer 
Release signed byDeployed by 
VerifierCommunicator 
Data protection authority notification requiredNo  
CSIRT notification requiredNo  
Estimated effort (hours)Actual effort (hours)0 
Fast-trackNo
Work packagenone
PrioritynormalSeveritytextReproducibilityalways
Status closedResolutionfixed 
Target Version0.9.3Fixed in Version0.9.3 
Summary0007829: Suboptimal Link Previews for taler.net
DescriptionWhen sharing the taler.net URL in a common messaging application, or social media site, the link preview generated shows a blurry GNU favicon instead of the Taler logo, and is non-descriptive.

This is due to the taler.net website lacking Open Graph[0] metadata in its HTML header. Link previews are generated using this metadata, if available.

I've included a patch which fixes this, and I've attached before and after screenshots of the link preview card. SVG is not supported, so I converted the logo to PNG and attached that, as well.


[0] https://ogp.me/
Steps To ReproduceShare "https://taler.net/" (or any localization) over a messenger such as Signal (what I did to test), or on a social media site like Twitter.
TagsNo tags attached.
Attached Files
opengraph.patch (855 bytes)   
diff --git a/common/base.j2 b/common/base.j2
index 31b5f1e..cc8afc2 100644
--- a/common/base.j2
+++ b/common/base.j2
@@ -3,7 +3,11 @@
   <head>
     <meta charset="UTF-8"/>
     <title>{{ _("GNU Taler") }}</title>
-    <meta name="description" content="{{ _('Taxable Anonymous Libre Electronic Reserves') }}" />
+    <meta property="og:title" content="GNU Taler - Taxable Anonymous Libre Electronic Reserves" />
+    <meta property="og:type" content="website" />
+    <meta property="og:url" content="{{ url_localized('index.html') }}" />
+    <meta property="og:image" content="{{ url_static('images/logo-2021.png') }}" />
+    <meta name="description" content="{{ _('A payment system that makes privacy-friendly online transactions fast and easy.') }}" />
     {% include "common/header.j2.inc" %}
     {% block head_content %}{% endblock %}
   </head>
opengraph.patch (855 bytes)   
BEFORE-taler-linkpreview.png (20,580 bytes)   
BEFORE-taler-linkpreview.png (20,580 bytes)   
AFTER-taler-linkpreview.png (38,204 bytes)   
AFTER-taler-linkpreview.png (38,204 bytes)   
logo-2021.png (28,781 bytes)   
logo-2021.png (28,781 bytes)   

Required notifications

Address or linkRemarkAdded byNotifiedActions

Activities

dvn

2023-04-29 17:45

reporter   ~0020171

This was auto-assigned to Stefan. I'm not sure if that's as it should be, but I don't seem to have the ability to change that.

dvn

2023-05-04 15:11

reporter   ~0020176

Stefan, what are your thoughts?

Stefan

2023-05-04 16:32

reporter   ~0020178

I poked a bit around with ICO generators and have now a couple of most common ICO and PNG files as well as an SVG image. 16x16 and 32x32 ICO images are awkward, so none of them will be at disposal.

All icon images have to be squares. favicon,ico and favicon.png have to be in the root folder (this requires an IE convention).

base.j2 shows the code to integrate all images. This is my solution to combine two worlds for an optimum outcome, also including your contribution as well. This code will be commited to Git and tested on several devices after I pushed the images to the git server, too.
 
Cheers,
Stefan
base.j2 (1,559 bytes)   
<!DOCTYPE html>
<html lang="{{ lang }}">
  <head>
    <meta charset="UTF-8"/>
    <title>{{ _("GNU Taler") }}</title>
    <meta name="description" content="{{ _('Taxable Anonymous Libre Electronic Reserves') }}" />
    <link rel="icon" type="image/svg+xml" href="{{ url_static('images/favicon.svg') }}" sizes="any">
    <link rel="icon" type="image/png" href="{{ url_static('images/android-chrome-192x192.png') }}" sizes="192x192">
    <link rel="icon" type="image/png" href="{{ url_static('images/android-chrome-512x512.png') }}" sizes="512x512">
    <link rel="apple-touch-icon" sizes="180x180" href="{{ url_static('images/apple-touch-icon.png') }}">
    <meta name="msapplication-TileColor" content="#ffffff">
    <meta name="msapplication-TileImage" content="{{ url_static('images/mstile-150x150.png') }}">
    <meta property="og:title" content="GNU Taler - Taxable Anonymous Libre Electronic Reserves" />
    <meta property="og:type" content="website" />
    <meta property="og:url" content="{{ url_localized('index.html') }}" />
    <meta property="og:image" content="{{ url_static('images/favicon-240x240.ico') }}" />
    <meta name="description" content="{{ _('A payment system that makes privacy-friendly online transactions fast and easy.') }}" />
    {% include "common/header.j2.inc" %}
    {% block head_content %}{% endblock %}
  </head>
  <body id="mybody">
    {% include "common/navigation.j2.inc" %}
    <div id="body_content">
    {% block body_content %}{% endblock %}
    </div>
    {% include "common/footer.j2.inc" %}
  </body>
</html>
base.j2 (1,559 bytes)   

dvn

2023-05-04 18:17

reporter   ~0020181

Okay, so if I understand correctly you want to also update the icon/favicon to improve compatibility and image resolution?

That's a separate issue, in my mind, but it seems like a good idea.

The only thing I see that's a problem is in your `base.j2` attachment, is that you've added another `<meta name="description" [...]`

When you push the changes to master, can you make a comment here so we can look at https://stage.taler.net/ ?

Stefan

2023-05-04 21:24

reporter   ~0020183

You are absolutely right about the superfluous meta tag for description. I got rid of it now in the base-file and pushed changes in git to master so that you can see the effect on the staged website.

The 32x32 px favicon looks just ridiculous to me. I recommend to use the favicon we have on https://taler-systems.com instead (this was my choice over the old favicon). But please take a look yourself, whether it's OK for your eyes what you see on https://stage.taler.net/.

Thank you for your work in advance, dvn, looking forward to get your comments.
Cheers,
Stefan

dvn

2023-05-04 21:35

reporter   ~0020184

I agree that the current favicon does not look good scaled down so small. I also concur that the favicon https://taler-systems.com looks much better. I'd go with that if there's no reason *not* to.

As for the link previews, it is not showing any image, as I don't think .ico is supported by most clients. I've attached how it looks now.
We are not constrained to a square with the Open Graph image, so I think we should just use a PNG of the main Taler logo as I demonstrated before.
stage.taler.png (22,757 bytes)   
stage.taler.png (22,757 bytes)   

Stefan

2023-05-05 04:31

reporter   ~0020185

OK. Please test now.

Christian, is there any reason to not use the favicon we have for https://taler-systems.com?

dvn

2023-05-05 14:04

reporter   ~0020186

Stefan, it looks the same.

Stefan

2023-07-03 21:54

reporter   ~0020332

Hi Devan,

can you test with your device(s) how my last push worked out? Thanks in advance.
Stefan

Stefan

2023-07-04 04:47

reporter   ~0020333

There was an issue with the apple-touch-icon. I created a single 180x180 icon (which will be scaled down to different resolutions on iOS platforms according to specific needs of devices and applications) and linked it

<link rel="apple-touch-icon" sizes="180x180" href="{{ url_static('images/apple-touch-icon.png') }}">

as <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"> did not work (Buildbot failure...).

I hope this satisfies iOS now, but due to an Apple convention I prefer to leave the apple-touch-icon.png at two places, namely in /www/static/images AND in /

Please test how the result works... Thanks again!

Cheers
Stefan

dvn

2023-07-04 13:27

reporter   ~0020334

The iOS stuff is not the same as the Opengraph convention. So it still doesn't look as good as it did from my patch (in my opinion), but it does look better than before. I've attached an image of how it looks for me now.
image.png (16,240 bytes)   
image.png (16,240 bytes)   

Stefan

2023-07-04 20:12

reporter   ~0020338

True, the iOS stuff is not the same as the Opengraph convention. It's an Apple convention. Hopefully, it works.

Maybe my workaround with an array of meta tags for different favicons will do the job now. Attached, you will find base.j2 with OG metatags and direct and relative links to favicon.ico.

Please be so kind to test again now or later. Thanks!
S.
base-2.j2 (1,634 bytes)   
<!DOCTYPE html>
<html lang="{{ lang }}">
  <head>
    <meta charset="UTF-8"/>
    <title>{{ _("GNU Taler") }}</title>
    <link rel="shortcut icon" href="/favicon.ico">
    <link rel="icon" type="image/svg+xml" href="{{ url_static('images/favicon.svg') }}" sizes="any">
    <link rel="icon" type="image/png" href="{{ url_static('images/android-chrome-192x192.png') }}" sizes="192x192">
    <link rel="icon" type="image/png" href="{{ url_static('images/android-chrome-512x512.png') }}" sizes="512x512">
    <link rel="apple-touch-icon" sizes="180x180" href="{{ url_static('images/apple-touch-icon.png') }}">
    <meta name="msapplication-TileColor" content="#ffffff">
    <meta name="msapplication-TileImage" content="{{ url_static('images/mstile-150x150.png') }}">
    <meta property="og:title" content="GNU Taler - Taxable Anonymous Libre Electronic Reserves" />
    <meta property="og:type" content="website" />
    <meta property="og:url" content="{{ url_localized('index.html') }}" />
    <meta property="og:image" content="https://taler.net/favicon.ico" />
    <meta property="og:image" content="/favicon.ico" />
    <meta property="og:image" content="{{ url_static('images/favicon.png') }}" />
    <meta name="description" content="{{ _('A payment system that makes privacy-friendly online transactions fast and easy.') }}" />
    {% include "common/header.j2.inc" %}
    {% block head_content %}{% endblock %}
  </head>
  <body id="mybody">
    {% include "common/navigation.j2.inc" %}
    <div id="body_content">
    {% block body_content %}{% endblock %}
    </div>
    {% include "common/footer.j2.inc" %}
  </body>
</html>
base-2.j2 (1,634 bytes)   

Stefan

2023-07-07 09:05

reporter   ~0020343

In case we would like to be kind to Twitter users it might be recommendable to add for 'Twitter Cards':

<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:site"@taler">
<meta name="twitter:title" content="GNU Taler - Taxable Anonymous Libre Electronic Reserves">
<meta name="twitter:url" content="https://taler.net/">
<meta name="twitter:description" content="A payment system that makes privacy-friendly online transactions fast and easy.">
<meta name="twitter:image:src" content="{{ url_static('images/favicon.png') }}">

See more info on https://developer.twitter.com/en/docs/twitter-for-websites/cards/guides/getting-started

Christian Grothoff

2023-07-16 14:08

manager   ~0020353

I don't think we want to be kind to Twitter or any other specific proprietary platform. If there is a vendor-neutral standard, that's fine, but let's not put proprietary tags.

Is the issue then resolved?

Stefan

2023-07-17 06:39

reporter   ~0020354

Devan, can you be so nice to test again and reply with your verdict whether you think this issue to be resolved?

    Regarding kindness to Twitter: NA
    Kindness towards Twitter users: Depends on how ugly Twitter displays the GNU Taler link preview in their media.
    Kindness to vendor-neutral standards: Yes, please, name them and pass on to me.

Open Graph[0] metadata was originally conceived by Facebook, by the way, IIRC.

S.

dvn

2023-07-17 13:28

reporter   ~0020355

Yes, it looks good now. Screenshot attached.

Twitter will use Open Graph tags if no Twitter tags are present: https://developer.twitter.com/en/docs/twitter-for-websites/cards/guides/getting-started#opengraph
image-2.png (31,826 bytes)   
image-2.png (31,826 bytes)   

Stefan

2023-07-17 14:26

reporter   ~0020356

Well then: Success!

Thank you, Devan, for this Mantis ticket and for our nice conversation regarding the link review / favicon issue before we even had the chance to get acquainted on another channel.

CU
Stefan

Christian Grothoff

2023-07-17 15:44

manager   ~0020357

dvn/stefan: please mark issues as *resolved* when key people involved agree that the issue has been fixed.

Issue History

Date ModifiedUsernameFieldChange
2023-04-29 17:41dvnNew Issue
2023-04-29 17:41dvnStatusnew => assigned
2023-04-29 17:41dvnAssigned To => Stefan
2023-04-29 17:41dvnFile Added: opengraph.patch
2023-04-29 17:41dvnFile Added: BEFORE-taler-linkpreview.png
2023-04-29 17:41dvnFile Added: AFTER-taler-linkpreview.png
2023-04-29 17:41dvnFile Added: logo-2021.png
2023-04-29 17:45dvnNote Added: 0020171
2023-04-30 17:04Christian GrothoffSeverityminor => text
2023-05-04 15:11dvnNote Added: 0020176
2023-05-04 16:32StefanNote Added: 0020178
2023-05-04 16:32StefanFile Added: base.j2
2023-05-04 18:17dvnNote Added: 0020181
2023-05-04 21:24StefanNote Added: 0020183
2023-05-04 21:35dvnNote Added: 0020184
2023-05-04 21:35dvnFile Added: stage.taler.png
2023-05-05 04:31StefanNote Added: 0020185
2023-05-05 14:04dvnNote Added: 0020186
2023-07-03 21:54StefanNote Added: 0020332
2023-07-04 04:47StefanNote Added: 0020333
2023-07-04 13:27dvnNote Added: 0020334
2023-07-04 13:27dvnFile Added: image.png
2023-07-04 20:12StefanNote Added: 0020338
2023-07-04 20:12StefanFile Added: base-2.j2
2023-07-07 09:05StefanNote Added: 0020343
2023-07-16 14:08Christian GrothoffNote Added: 0020353
2023-07-17 06:39StefanNote Added: 0020354
2023-07-17 13:28dvnNote Added: 0020355
2023-07-17 13:28dvnFile Added: image-2.png
2023-07-17 14:26StefanNote Added: 0020356
2023-07-17 15:44Christian GrothoffNote Added: 0020357
2023-07-17 15:44Christian GrothoffStatusassigned => informing
2023-07-17 15:44Christian GrothoffResolutionopen => fixed
2023-07-17 15:44Christian GrothoffFixed in Version => 0.9.3
2023-07-17 15:44Christian GrothoffTarget Version => 0.9.3
2023-09-23 13:09Christian GrothoffStatusinforming => closed