You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After the merge of #35639, we have the ability to serve static assets from Learning Core, but we haven't hooked it into the Learning Core XBlock runtime so that we can display it properly. A draft of this functionality is available in _lookup_asset_url from this older, abandoned static asset PR, but that pre-dates the version-awareness that was added in #35626.
Acceptance Criteria
Implement _lookup_asset_url borrowing from the original draft implementation of this functionality, but checking for the block. _runtime_requested_version in order to figure out which version we should be pulling it from. Add tests.
This can be tested manually by using the add_assets_to_component management command to add/replace/delete images.
So the steps would be:
Create an HTML component in a Library, and specify a /static/test.jpeg image inside of it using the raw HTML editor.
Use the add_assets_to_component management command to manually add the test.jpeg asset.
Verify it shows up in the library preview.
Use the add_assets_to_component management command to change the test.jpeg asset.
Verify the new asset shows up in the library preview.
Verify the old asset shows up when referencing the embed URL with the old version of the component.
The text was updated successfully, but these errors were encountered:
Background
After the merge of #35639, we have the ability to serve static assets from Learning Core, but we haven't hooked it into the Learning Core XBlock runtime so that we can display it properly. A draft of this functionality is available in
_lookup_asset_url
from this older, abandoned static asset PR, but that pre-dates the version-awareness that was added in #35626.Acceptance Criteria
Implement
_lookup_asset_url
borrowing from the original draft implementation of this functionality, but checking for theblock. _runtime_requested_version
in order to figure out which version we should be pulling it from. Add tests.This can be tested manually by using the
add_assets_to_component
management command to add/replace/delete images.So the steps would be:
/static/test.jpeg
image inside of it using the raw HTML editor.add_assets_to_component
management command to manually add thetest.jpeg
asset.add_assets_to_component
management command to change thetest.jpeg
asset.The text was updated successfully, but these errors were encountered: