-
Notifications
You must be signed in to change notification settings - Fork 0
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
fix(FEC-14000): Download plugins opens empty overlay while there are … #56
base: master
Are you sure you want to change the base?
Conversation
…no files to download
@@ -34,7 +34,13 @@ module.exports = { | |||
{ | |||
test: /\.scss$/, | |||
use: [ | |||
'style-loader', | |||
{ |
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.
why is this needed ?
src/download.tsx
Outdated
@@ -143,11 +144,11 @@ class Download extends KalturaPlayer.core.BasePlugin { | |||
await this.ready; | |||
|
|||
this.downloadPluginManager.setShowOverlay(false, false); | |||
const downloadMetadata = await this.downloadPluginManager.getDownloadMetadata(true); | |||
this.downloadMetadata = await this.downloadPluginManager.getDownloadMetadata(true); |
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.
we should also clean up the value, probably in reset()
return flavor.height > 0; | ||
}); | ||
const sortedFlavors = flavors.sort((a: {height: number}, b: {height: number}) => { | ||
return a.height < b.height ? 1 : -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.
return a.height < b.height ? 1 : -1; | |
return a.height - b.height; |
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.
you mean b - a in that case
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.
you're right
so b.height - a.height it is
return flavor.height > 0; | ||
}); | ||
const sortedFlavors = flavors.sort((a: {height: number}, b: {height: number}) => { | ||
return a.height < b.height ? 1 : -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.
you're right
so b.height - a.height it is
@@ -158,7 +165,10 @@ class Download extends KalturaPlayer.core.BasePlugin { | |||
|
|||
reset() { | |||
this.upperBarManager?.remove(this.iconId); | |||
// @ts-ignore | |||
this.player.getService('AudioPluginsManager').remove(this.audioPlayerIconId) |
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.
you can add a getter for the service
Resolves FEC-14000, FEC-13915 FEC-13939
Related pr:
kaltura/kaltura-player-js#805
kaltura/playkit-js-audio-player#27
kaltura/playkit-js-share#50
kaltura/playkit-js-transcript#205