Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: meaningful link previews #3597

Open
marsrobertson opened this issue Aug 10, 2024 · 2 comments
Open

Feature Request: meaningful link previews #3597

marsrobertson opened this issue Aug 10, 2024 · 2 comments

Comments

@marsrobertson
Copy link

marsrobertson commented Aug 10, 2024

Current state:

image

Better preview:

image

This is managed by the metatags. For my personal purposes I'm doing this combination:

  <meta property="og:title" content="Impact Evaluation Foundation (IEF)"/>
  <meta property="og:image" content="../preview-grant.jpg""/>
  <meta property="og:site_name" content=""/>
  <meta property="og:description" content="Meeting place for all the things impact / externalities / cobenefits"/>

  <meta name="twitter:card" content="summary_large_image">
  <meta name="twitter:site" content="@ImpactEvalFDN">
  <meta name="twitter:creator" content="@marsXrobertson">
  <meta name="twitter:title" content="Impact Evaluation Foundation (IEF)">
  <meta name="twitter:description" content="Meeting place for all the things impact / externalities / cobenefits">
  <meta name="twitter:image" content="../preview-grant.jpg">

Some of them can be retrieved from the title. Some of them can be provided via additional fields.

Generation of the image can be a bit tricky. The simplest way: each project in the round has the same preview that is optimised for the round "donate for our GG21 grant in CCN"

A little bit more but still doable could be https://imagemagick.org + reuse cover photo / profile photo + merge / overlay with Gitcoin logo

Optionally, probably not needed for this use case: run a headless browser and save screenshot as preview.jpg.


In case you want to see it live: https://impactevaluation.foundation/grant?🌱🌱🌱

Redirect in the following way:

  <script type="text/javascript">
    window.location.replace("https://explorer.gitcoin.co/#/round/42161/388/70");
  </script>

Some other way didn't work well with Telegram, adding some stuff after ? to refresh the preview.

EDIT / UPDATE: of course need to ensure correct aspect ratio. Yesterday optimising for TG, misaligned on FB:
image

Copy link

linear bot commented Aug 10, 2024

@onyedikachi-david
Copy link

Can i get assigned?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants