Skip to content

Allow video / video_local media on Banner paragraph background (ITCP-712) - #124

Open
shuklina wants to merge 1 commit into
mainfrom
ITCP-712-banner-paragraph-video-background
Open

shuklina wants to merge 1 commit into
mainfrom
ITCP-712-banner-paragraph-video-background

Conversation

@shuklina

Copy link
Copy Markdown
Contributor

Summary

  • Widens field_prgf_image (paragraph:banner) target_bundles from image-only to image/video/video_local, mirroring lb_hero's field_media which already supports the same three bundles on the same entity_reference-to-media pattern.
  • Updates the media_library_widget's media_types to match.
  • Adds openy_prgf_banner_update_10003() so existing sites (which never re-import config/install) pick this up on the next deploy.

Companion change

Rendering support (actually showing the video as a background instead of the image) is openy_carnation theme territory — separate project, separate MR: https://git.drupalcode.org/project/openy_carnation/-/merge_requests/126. This PR alone just makes the field able to reference video media; without the theme MR the video option shows in the media library but doesn't render as a background yet.

Scope note

small_banner paragraph has the identical image-only field_prgf_image limitation, intentionally left untouched here pending confirmation it should get the same treatment.

Test plan

  • Local: fresh field settings allow Image/Video/Video Local tabs in the media library widget on the Banner paragraph edit form
  • openy_prgf_banner_update_10003() tested against a site with the old image-only config; runs clean and produces the same end state as a fresh install

…712)

Widens field_prgf_image (paragraph:banner) target_bundles from
image-only to image/video/video_local, mirroring lb_hero's field_media
which already supports the same three bundles on the same
entity_reference-to-media pattern. Updates the media_library_widget's
media_types to match, and adds update_10003 so existing sites (which
never re-import config/install) pick this up on the next deploy.

Companion change: openy_carnation's paragraph--banner.html.twig
currently only renders an image background. Rendering support for the
new media types is in a separate MR since that's a different project:
https://git.drupalcode.org/project/openy_carnation/-/merge_requests/126

small_banner has the identical image-only field but is intentionally
left untouched here pending confirmation it's in scope.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant