Media 1202#16
Merged
Merged
Conversation
migrate news images to media
update to new media image field
3 tasks
Contributor
There was a problem hiding this comment.
Pull request overview
Reworks how “news” hero images are handled by migrating from a direct file field to a media reference, and updates token/meta-tag generation to use the new media-backed hero image plus a dedicated Open Graph image style.
Changes:
- Removes a previous news form validation tied to the old front image field.
- Adds a new
[oittoken:og_image]token and updates token/meta-tag image generation to use a hero media field (includingsocial_sharestyle for OG). - Adds a deploy hook to migrate existing
field_news_front_imagefiles intonews_imagesmedia entities and populatefield_media_hero_image.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
oit.module |
Adds OG token + switches token/meta-tag image sourcing to a new hero media field via oit_get_hero_image_fid(). |
oit.deploy.php |
Adds a batch deploy hook to migrate existing news hero images into media entities and set the new media reference field. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Contributor
|
@protitude I've opened a new pull request, #17, to work on those changes. Once the pull request is ready, I'll request review from you. |
Co-authored-by: protitude <695625+protitude@users.noreply.github.com> Agent-Logs-Url: https://github.com/UCBoulder/oit/sessions/8e098423-2adf-4adb-a230-aefd77eab276
Fix entity reference field key and add null safety for taxonomy term loading
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe context / purpose for this PR
News Images - Rework
Issue link
#1202
Any other related PRs?
Link to MultiDev instance
http://md-1202-ucbsub-oit.pantheonsite.io
Checklist for PR author