-
Notifications
You must be signed in to change notification settings - Fork 163
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
Upload bloom format files in studio #4590
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.
Let's update to the published le-utils version, and just make sure we're using the code generation script.
contentcuration/contentcuration/migrations/0149_auto_20240612_1847.py
Outdated
Show resolved
Hide resolved
contentcuration/contentcuration/frontend/shared/leUtils/FormatPresets.js
Outdated
Show resolved
Hide resolved
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.
As long as automated checks pass, this should be good to go.
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.
Just a question about the tests change, but overall this LGTM
expect(wrapper.vm.primaryFileMapping[1].file.id).toBe('file-3'); | ||
expect(wrapper.vm.primaryFileMapping[2].file.id).toBe('file-1'); |
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.
Were these failing before or just not testing what they were supposed to test?
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.
They were just brittle to the order of file presets - because the bloompub preset happened to go before epub and pdf, (because alphabetical) it moved them each down a place.
I confirm that it's possible to upload bloom files. There's no preview of the files and they cannot be imported in Kolibri which I guess will be implemented at a later stage. |
Summary
Description of the change(s) you made
I have added the bloompub preset in the contentcuration le-utlis shared folder to allow users to upload bloom files in the studio
Screenshots
References
#4583
#36
Comments
When uploading the bloom file from our PC the File object created on frontend is not able to detect the mimetype of the file and hence sending null to backend in the type property. Should we hardcode it othe front endnd for this format?
Contributor's Checklist
PR process:
CHANGELOG
label been added to this PR. Note: items with this label will be added to the CHANGELOG at a later timedocs
label has been added if this introduces a change that needs to be updated in the user docs?requirements.txt
files also included in this PRStudio-specifc:
notranslate
class been added to elements that shouldn't be translated by Google Chrome's automatic translation feature (e.g. icons, user-generated text)pages
,components
, andlayouts
directories as described in the docsTesting:
Reviewer's Checklist
This section is for reviewers to fill out.
yarn
andpip
)