-
-
Notifications
You must be signed in to change notification settings - Fork 199
Improves sharing previews #2380
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
Improves sharing previews #2380
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request improves social media sharing previews for workshop links by enhancing OpenGraph meta tags and consolidating meta tag handling across the application.
- Replaces basic workshop descriptions with more detailed content for better social previews
- Consolidates meta tag rendering logic into reusable partials to reduce duplication
- Updates localization keys for virtual workshops to be more consistent
Reviewed Changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 3 comments.
Show a summary per file
File | Description |
---|---|
config/locales/en.yml | Updated localization keys and descriptions for workshop sharing previews |
app/views/workshops/_meta_tags.html.haml | Enhanced OpenGraph meta tags with better titles, descriptions, and event-specific metadata |
app/views/virtual_workshops/show.html.haml | Updated to use consolidated meta tags partial and corrected localization keys |
app/views/virtual_workshops/_meta_tags.html.haml | Removed duplicate meta tags partial in favor of consolidated version |
app/views/layouts/application.html.haml | Refactored to use conditional meta tag rendering with fallback to default tags |
app/views/layouts/_meta_tags.html.haml | Added default meta tags partial for pages without specific workshop context |
app/views/errors/not_found.html.haml | Updated to use consolidated meta tags partial |
app/views/errors/error.html.haml | Updated to use consolidated meta tags partial |
app/mailers/virtual_workshop_invitation_mailer.rb | Fixed localization key reference to match updated structure |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
1418402
to
0153554
Compare
0153554
to
407b24e
Compare
407b24e
to
d1170de
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 9 out of 10 changed files in this pull request and generated 3 comments.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
title = if workshop.virtual? | ||
t('workshops.virtual.title_with_date', chapter: workshop.chapter.name, date: humanize_date(workshop.date_and_time)) | ||
else | ||
t('workshop.title', host: workshop.host.name, date: humanize_date(workshop.date_and_time)) |
Copilot
AI
Oct 15, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Translation key 'workshop.title' should be 'workshops.title' to match the locale file structure. The locale file shows the key under 'workshops:' not 'workshop:'.
t('workshop.title', host: workshop.host.name, date: humanize_date(workshop.date_and_time)) | |
t('workshops.title', host: workshop.host.name, date: humanize_date(workshop.date_and_time)) |
Copilot uses AI. Check for mistakes.
end | ||
url = request.original_url | ||
image = workshop.host.try(:image_url).presence || image_url('codebar-social.jpg') | ||
description = (workshop.virtual? ? t('workshops.virtual.lead') : t('workshops.lead')) |
Copilot
AI
Oct 15, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Translation key 'workshops.lead' should be 'workshop.lead' to match the locale file structure. The locale file shows 'lead' under 'workshop:' not 'workshops:'.
description = (workshop.virtual? ? t('workshops.virtual.lead') : t('workshops.lead')) | |
description = (workshop.virtual? ? t('workshops.virtual.lead') : t('workshop.lead')) |
Copilot uses AI. Check for mistakes.
1996cde
to
225c2c9
Compare
225c2c9
to
10d64cb
Compare
This will improve how codebar.io links look like when shared across social networks. Closes codebar#2371 and codebar#2353.
Replaces that with new Open Graph meta tags. Closes codebar#2335.
10d64cb
to
8a67ec6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks so much better, thank you so much 🎉
Stemming from #2371, this pull request addresses the poor previews we get when sharing workshop links. Here’s a before and after on virtual workshops:
I’m happy to take suggestions, let me know if you have ideas on how to improve this!