SunbirdEd-Portal :: Configuring players as web components in portal #107
Replies: 9 comments 13 replies
|
@princegupta1131 instead of the Reflect.min.js with integrity use normal Reflect js file from cdn site |
|
Hi @HarishGangula I have refered the documentation => https://github.com/project-sunbird/sunbird-pdf-player/blob/release-5.2.0/web-component/index.html but there is no luck still getting below error. video and epub player is working but pdf having some issue. can you please Validate the Pdf-Player-Config . if any changes required please suggest. CC: @vinukumar-vs @ @rajeevsathish pdf-player-config |
|
Hi @HarishGangula I have shared the steps below that I used in Angular Portal. It would be helpful if you could confirm that this is the same procedure that you follow. CC: @vinukumar-vs @rajeevsathish Steps 1: added script inside the index.html Step 2: added pdf-player.js file in below path Step 3: imported these entries in angular json file inside styles Step 4: imported these entries in angular json file inside scripts Step 5: Imported CUSTOM_ELEMENTS_SCHEMA in app module & other required modules Step 6: added PLAYER_CONFIG in below path Using below line of code to get the playerconfig details in player component Steps 7: Imported sunbird-pdf-player in component |
|
@HarishGangula Tried mimicking the standalone app and it loads the pdf as expected whereas when tried to use the same config object in co-kreat pdf doesn't load, though doesn't throw up errors as well If we compare both the app's scripts files we can see the standalone app is able to load the viewer.js file which further loads the pdf.js and pdf-worker.js . This is not happening for the cokreat app. |
|
SunbirdEd-Mobile : Replacing library with web component for video player. Uncaught RangeError: Maximum call stack size exceeded
|
|
The FYI the allocated memory for my machine for server run is 4 MB (typo i meant 4GB) |
|
@princegupta1131 @arun1205 I have done the pdf player web component integration with the angular app project here is the project for your reference. |
|
@HarishGangula As mentioned earlier this has been done by us on the standalone app. The failure is happening when we integrate it with Sunbird ED/ Cokreat web application |
|
To : HarishGangula
cc:@pallakartheekreddy @vinukumar-vs @princegupta1131 @sedin-tushar |










Uh oh!
There was an error while loading. Please reload this page.
SunbirdEd-Portal : Replacing library with web component for players
we followed the steps which is mentioned in readme file => https://github.com/project-sunbird/sunbird-pdf-player#readme
Aboved script using cdn link to get the src file. Instead we downloaded the script and created the folder inside the assets and placed the scripts inside Reflect.min.js
Modifed Script
Getting console errror while using Modifed Script
ERROR 1
ERROR 2
ERROR 3:
@HarishGangula Could you please guide us on how to fix this Issue
CC: @rajeevsathish @vinukumar-vs @Krishnaj20
All reactions