Skip to content
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

✨(website) dashboard video #2086

Merged
merged 21 commits into from
Mar 7, 2023
Merged

Conversation

AntoLC
Copy link
Contributor

@AntoLC AntoLC commented Feb 23, 2023

Purpose

Integrate the dashboard video in the standalone website.

Proposal

  • adapt code to works on LTI and in the website
  • integrate in website
  • tests
dashboard.webm

@AntoLC AntoLC self-assigned this Feb 23, 2023
@AntoLC AntoLC changed the base branch from master to feature/anthony/website/create-video February 23, 2023 14:27
@AntoLC AntoLC added the feature label Feb 23, 2023
@AntoLC AntoLC force-pushed the feature/anthony/website/create-video branch from fbecb9f to d5c8e33 Compare February 24, 2023 13:41
@AntoLC AntoLC force-pushed the feature/anthony/website/update-video branch 2 times, most recently from 5f517a9 to 48358bd Compare February 27, 2023 10:24
@AntoLC AntoLC force-pushed the feature/anthony/website/create-video branch from d5c8e33 to 0297445 Compare February 27, 2023 11:18
Base automatically changed from feature/anthony/website/create-video to master February 27, 2023 11:36
@AntoLC AntoLC force-pushed the feature/anthony/website/update-video branch from 48358bd to 389daae Compare February 27, 2023 11:42
@AntoLC AntoLC added Frontend Site Linked to the marsha site labels Feb 27, 2023
@AntoLC AntoLC force-pushed the feature/anthony/website/update-video branch 6 times, most recently from 9f0a4fb to 2f64673 Compare February 28, 2023 15:09
@AntoLC AntoLC marked this pull request as ready for review February 28, 2023 15:16
Copy link
Contributor

@kernicPanel kernicPanel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some suggestions, but LGTM 👍

Comment on lines 37 to 38
columns = columns > 3 ? 3 : columns;
setNbrOfColumns(columns || 1);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we could extract those values to conf/global.ts ?
Something like MAX_WIDGETS_COLUMNS and MIN_WIDGETS_COLUMNS ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added some globals to be cleaner.
9226d81

I don't know about conf/global.ts, if it is used only in this module IMO I would rather let it inside the module. However if it is used in other modules, yes it would make sense to add them in conf/global.ts .

{mapper.map((_, indexColumn) => (
<Box
direction="column"
key={indexColumn}
width={`${100 / nbrOfColumns}%`}
width={{
max: '600px',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here with MAX_WIDGETS_COLUMN_SIZE ?

Comment on lines -246 to -247
INVITE: {
path: `/my-contents/videos/:videoId/invite/:inviteId`,
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be just deleted ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparently for the moment we will not use invitation link for the video.

@AntoLC AntoLC removed the request for review from lunika March 3, 2023 14:20
@AntoLC AntoLC force-pushed the feature/anthony/website/update-video branch from 2f64673 to fe44120 Compare March 3, 2023 15:25
@AntoLC AntoLC force-pushed the feature/anthony/website/update-video branch from fe44120 to 015c596 Compare March 3, 2023 16:52
@AntoLC AntoLC requested review from lunika and kernicPanel and removed request for lunika and kernicPanel March 3, 2023 17:01
@AntoLC AntoLC requested a review from lunika March 7, 2023 15:48

const messages = defineMessages({
404: {
defaultMessage: "We didn't find the video you were looking for.",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
defaultMessage: "We didn't find the video you were looking for.",
defaultMessage: "We don't find the video you are looking for.",

AntoLC and others added 21 commits March 7, 2023 20:31
Add my-playlist/create as sub route of my-playlist,
by making it a sub route the menu stays highlighted
when we are on the create modal.
- Changes prop itemsLength to hasResult to be more generic
- Add a new prop `error` to customize the error message
- expose ManageAPIState from Contents
Globalize conf react_query call api to avoid to repeat the same conf
for each call api.
Update the columns number depend the size of the parent container.
- migrate lti_site/components/DashboardVideoWrapper to lib-video
- adapt import in LTI project
Renamed LTIUploadHandlers to UploadHandlers to be more generic,
it will be used in the standalone site too.
- integrate video dashboard in the website
- adapt getOrInitAnonymousId to work with website token
A mock to the thumbnails api call was missing in
the VideoWidgetProvider test.
This commit adds it.
The license label was not correct.
We changed to a correct one.
The websocket was targeting the wrong url in local(port 3000).
We had to proxy it to the backend.
When a video is uploaded on our website, we automatically generate a
thumbnail for it. We can also manually select a thumbnail for a video.
If a video has both an automated and a manual thumbnail, we want to
prioritize the manual one and display it in the related video component.
Add a filter to the api to get only live video or only video on demand.
When a list of video is serialized, the first one having a thumbnail
stores ths thumbnail instance in a serializer property. This property is
never reset and the consequence is that this thumbnail instance will be
used by the next video instance serialized. To fix the issue, we must
force to set the thmubnail_instance to None at the beginning of the
to_representation method.
To be able to manage the video states between our apps,
we created useSetVideoState hook.
In LTI app some states video are only for one resource, but on the website
a lot of resources cohabit, so we have to reset the state
when we switch between resources.
When a user uploads a thumbnail, we display a progress
 to inform him about the upload status.
Before that the video id was determined from the token, but in the website
the token doesn't have this information. So we need to pass it
explicitly to the API.
- When a thumbnail was uploaded multiple times, the thumbnail
status was not reset correctly, causing an early resetUpload,
the thumbnail message status had problem because of that as well.

- The poster video was not updated correctly when the thumbnail was
uploaded multiple times.
Display the video menu item and the video in the Contents component.
Before that the video id was determined from the token, but in the website
the token doesn't have this information. So we need to pass it
explicitly to the API.
Before that the video id was determined from the token, but in the website
the token doesn't have this information. So we need to pass it
explicitly to the API.
- When a video was uploaded multiple times, the upload
status was reset too early, causing sometime an error 500.
@AntoLC AntoLC force-pushed the feature/anthony/website/update-video branch from d1ce201 to 50294ab Compare March 7, 2023 19:57
@AntoLC AntoLC enabled auto-merge (rebase) March 7, 2023 20:03
@AntoLC AntoLC merged commit fa79a15 into master Mar 7, 2023
@AntoLC AntoLC deleted the feature/anthony/website/update-video branch March 7, 2023 20:11
lunika added a commit that referenced this pull request Apr 19, 2023
Added

- standalone website:
  - Integrate VOD dashboard (#2086)
  - List the lives in the contents section (#2104)
  - Live session model
  - Livesession backend rewrite
  - Add sentry
  - Create a live from the website (#2134)
  - Integrate webinar dashboard (#2135)
- Add a License Manager widget for LTI VOD view
- Add a title to the classroom file dropzone
- Add can_edit property on a serialized video
- Add an attribute to consumer site to deactivate resources in LTI select
- live transpilation on lib-video (#2150)
- live transpilation on lib-classroom (#2157)
- live transpilation on lib-markdown (#2160)
- live transpilation on lib-components (#2161)
- live transpilation on lib-tests (#2163)
- live transpilation on lib-common (#2164)
- Add a widget provider for the classroom creation form
- Allow delete playlist resources
  - FileDepository
  - Classroom
  - Document
  - Markdown
- Allow delete playlist
- add routes related URL:
  - thumbnails
  - timed_text_track
  - shared_live_media
- Add classroom widgets :
  - InfoBar
  - Description
  - Scheduling
  - Invite links
  - Support sharing
  - Recordings
- Add classroom invite link for an instructor
- Add a "Tools & Applications" widget for classrooms

Changed

- Update live sessions API to use nested video ID route
- Move generic widget components from lib-video to lib-components
- Make video dashboard collapsed by default
- improve the dropdown languages positionning in the dashboard (#2138)
- Make video dashboard visible by default, and collapsed when using the
  Moodle atto plugin
- Update live_session api to use mixin to prevent url crafting
- standalone website:
  - put the creating ressource form submit button disabled when the
    form is invalid (#2175)

Fixed

- redirect to error page when VOD is deleted
- Manage disconnection when multiple tabs were open on standalone site
- synchronisation between pages for the VOD description widget
- tooltip position on the website context dashboard (#2136)
- thumbnail not reset correctly on the video player (#2137)
- display title / description when a classroom is not scheduled and not started
- correctly fetch transcript content in TranscriptReader
- remove unused 'initiate-live' permissions
- increase debounce time in classroom description widget
- remove id3 tags upload when live channel is not ready
- add an invitation link for moderators in a launched classroom if available
lunika added a commit that referenced this pull request Apr 19, 2023
Added

- standalone website:
  - Integrate VOD dashboard (#2086)
  - List the lives in the contents section (#2104)
  - Live session model
  - Livesession backend rewrite
  - Add sentry
  - Create a live from the website (#2134)
  - Integrate webinar dashboard (#2135)
- Add a License Manager widget for LTI VOD view
- Add a title to the classroom file dropzone
- Add can_edit property on a serialized video
- Add an attribute to consumer site to deactivate resources in LTI select
- live transpilation on lib-video (#2150)
- live transpilation on lib-classroom (#2157)
- live transpilation on lib-markdown (#2160)
- live transpilation on lib-components (#2161)
- live transpilation on lib-tests (#2163)
- live transpilation on lib-common (#2164)
- Add a widget provider for the classroom creation form
- Allow delete playlist resources
  - FileDepository
  - Classroom
  - Document
  - Markdown
- Allow delete playlist
- add routes related URL:
  - thumbnails
  - timed_text_track
  - shared_live_media
- Add classroom widgets :
  - InfoBar
  - Description
  - Scheduling
  - Invite links
  - Support sharing
  - Recordings
- Add classroom invite link for an instructor
- Add a "Tools & Applications" widget for classrooms

Changed

- Update live sessions API to use nested video ID route
- Move generic widget components from lib-video to lib-components
- Make video dashboard collapsed by default
- improve the dropdown languages positionning in the dashboard (#2138)
- Make video dashboard visible by default, and collapsed when using the
  Moodle atto plugin
- Update live_session api to use mixin to prevent url crafting
- standalone website:
  - put the creating ressource form submit button disabled when the
    form is invalid (#2175)

Fixed

- redirect to error page when VOD is deleted
- Manage disconnection when multiple tabs were open on standalone site
- synchronisation between pages for the VOD description widget
- tooltip position on the website context dashboard (#2136)
- thumbnail not reset correctly on the video player (#2137)
- display title / description when a classroom is not scheduled and not started
- correctly fetch transcript content in TranscriptReader
- remove unused 'initiate-live' permissions
- increase debounce time in classroom description widget
- remove id3 tags upload when live channel is not ready
- add an invitation link for moderators in a launched classroom if available
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Frontend Site Linked to the marsha site
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🐛(api) thumbnails set when it should not 🐛(frontend) upload thumbnail multiple times in Live
3 participants