User Story
As a programmer/themer
I should be able to set the src, title, and fallback text for an AMP video manually. Not all video services use the same URL formatting. (Ex. MPX)
Expected Result
The values I pass into the theme function are rendered into the video template.
Actual Result
These values are hard set in amp_preprocess_amp_video(), overriding any settings passed in via the theme hook and thus ignored.
Proposed Solution
Alter the preprocessor so values are only overridden if they are empty, thus allowing custom values to be passed in via the theme call. Some functionality should be moved to a hook_process() to ensure they run after any custom preprocessors have been called.
Comments
Comment #2
KeyboardCowboyComment #3
KeyboardCowboyAdding patch to:
video_attributes(rendered).src,fallback text.video_attributesstring intohook_process()callback.Comment #4
KeyboardCowboyComment #6
quicksketchThis looks great on all counts. Committed to 7.x-1.x. Thanks!