Skip to content

Commit

Permalink
Issue #IQ-269 feat: replacing the github url in all README files
Browse files Browse the repository at this point in the history
  • Loading branch information
rajnishdargan committed Feb 9, 2023
1 parent 6f3011f commit 313c5bd
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 22 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ It will install sunbird-quml-player for the default application specified in you
ng add @project-sunbird/sunbird-quml-player --project myProject
```
Schematics will create `question-cursor-implementation.service.ts`. Please update the `listUrl` in it.
For more information refer [question-cursor-implementation.service.ts](https://github.com/project-sunbird/sunbird-quml-player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts) and do not forget to add your question list API URL here, for example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";
For more information refer [question-cursor-implementation.service.ts](https://github.com/Sunbird-inQuiry/player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts) and do not forget to add your question list API URL here, for example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";

### Manual installation
If you prefer not to use schematics or want to add `sunbird-quml-player` to an older project, you'll need to do the following:
Expand Down Expand Up @@ -46,7 +46,7 @@ If you prefer not to use schematics or want to add `sunbird-quml-player` to an o
Create a **question-cursor-implementation.service.ts** in a project and which will implement the `QuestionCursor` abstract class.
`QuestionCursor` is an abstract class, exported from the library, which needs to be implemented. Basically, it has some methods which should make an API request over HTTP

For more information refer [question-cursor-implementation.service.ts](https://github.com/project-sunbird/sunbird-quml-player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts) and do not forget to add your question list API URL here, for example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";
For more information refer [question-cursor-implementation.service.ts](https://github.com/Sunbird-inQuiry/player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts) and do not forget to add your question list API URL here, for example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";

### :label: Step 3: Include the styles, scripts and assets in angular.json
Add the following under `architect.build.assets` for default project
Expand Down Expand Up @@ -112,13 +112,13 @@ Import the required modules such as **CarouselModule**, **QumlLibraryModule**, *

</details>

Note: To avoid CORS errors, add proxy configuration for API's refer - [proxy.conf.json](https://github.com/project-sunbird/sunbird-quml-player/blob/release-5.1.0/projects/quml-demo-app/src/proxy.conf.json)
Note: To avoid CORS errors, add proxy configuration for API's refer - [proxy.conf.json](https://github.com/Sunbird-inQuiry/player/blob/release-5.1.0/projects/quml-demo-app/src/proxy.conf.json)

## :label: Send input to render QuML player
User can get a response from the `api/questionset/v1/hierarchy/:do_id` or can use the provided mock config for demo

Use the mock config in your component to send input to QuML player as `playerConfig`
Click to see the mock - [samplePlayerConfig](https://github.com/project-sunbird/sunbird-quml-player/blob/release-5.1.0/projects/quml-demo-app/src/app/quml-library-data.ts#L495)
Click to see the mock - [samplePlayerConfig](https://github.com/Sunbird-inQuiry/player/blob/release-5.1.0/projects/quml-demo-app/src/app/quml-library-data.ts#L495)

```html
<quml-main-player [playerConfig]="samplePlayerConfig" ><quml-main-player>
Expand Down Expand Up @@ -155,13 +155,13 @@ If context is not passed in playerConfig telemetry event of player will not be c
QuML Library can also be used as web component which means user can import this library in any web application and use these custom components.
Follow below-mentioned steps to use it in plain JavaScript project:

- Insert [library](https://github.com/project-sunbird/sunbird-quml-player/blob/release-4.7.0/web-component/sunbird-quml-player.js) as below:
- Insert [library](https://github.com/Sunbird-inQuiry/player/blob/release-4.7.0/web-component/sunbird-quml-player.js) as below:
```javascript
<script type="text/javascript" src="sunbird-quml-player.js"></script>
```
- Create a asset folder and copy all the files from [here](https://github.com/project-sunbird/sunbird-quml-player/tree/release-4.7.0/web-component/assets), library requires these assets internally to work well.
- Create a asset folder and copy all the files from [here](https://github.com/Sunbird-inQuiry/player/tree/release-4.7.0/web-component/assets), library requires these assets internally to work well.

- Get sample playerConfig from here: [playerConfig](https://github.com/project-sunbird/sunbird-quml-player/blob/release-4.7.0/projects/quml-demo-app/src/app/quml-library-data.ts)
- Get sample playerConfig from here: [playerConfig](https://github.com/Sunbird-inQuiry/player/blob/release-4.7.0/projects/quml-demo-app/src/app/quml-library-data.ts)

- Pass the Question List API baseUrl for, e.g. [https://staging.sunbirded.org/api/question/v1/list](https://staging.sunbirded.org/api/question/v1/list)

Expand Down Expand Up @@ -191,14 +191,14 @@ Follow below-mentioned steps to use it in plain JavaScript project:
const myPlayer = document.getElementById("my-player");
myPlayer.appendChild(qumlPlayerElement);
```
- :arrow_forward: Refer demo [example](https://github.com/project-sunbird/sunbird-quml-player/blob/release-4.7.0/web-component/index.html)
- :arrow_forward: Refer demo [example](https://github.com/Sunbird-inQuiry/player/blob/release-4.7.0/web-component/index.html)

---

# :bookmark_tabs: QuML Player Contribution Guide
## Repo Setup
- Install Node 14.x and Angular 12
- Clone the Repo with desired release-branch - https://github.com/project-sunbird/sunbird-quml-player
- Clone the Repo with desired release-branch - https://github.com/Sunbird-inQuiry/player
- Add the baseUrl in the *environment.ts* and *proxy.conf.json* files
- If there are any changes in API endpoints, update the *app.constant.ts* file
- Change the default content ID in *app.component.ts* file if pointing to different baseUrl
Expand Down
18 changes: 9 additions & 9 deletions projects/quml-library/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ It will install sunbird-quml-player for the default application specified in you
```red
ng add @project-sunbird/sunbird-quml-player --project myProject
```
Schematics will create `question-cursor-implementation.service.ts`. Please update the `listUrl` in it. For more information, refer [question-cursor-implementation.service.ts](https://github.com/project-sunbird/sunbird-quml-player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts)
Schematics will create `question-cursor-implementation.service.ts`. Please update the `listUrl` in it. For more information, refer [question-cursor-implementation.service.ts](https://github.com/Sunbird-inQuiry/player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts)
example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";

### Manual installation
Expand Down Expand Up @@ -46,7 +46,7 @@ If you prefer not to use schematics or want to add `sunbird-quml-player` to an o
Create a **question-cursor-implementation.service.ts** in a project and which will implement the `QuestionCursor` abstract class.
`QuestionCursor` is an abstract class, exported from the library, which needs to be implemented. Basically, it has some methods which should make an API request over HTTP

For more information refer [question-cursor-implementation.service.ts](https://github.com/project-sunbird/sunbird-quml-player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts) and do not forget to add your question list API URL here, for example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";
For more information refer [question-cursor-implementation.service.ts](https://github.com/Sunbird-inQuiry/player/blob/main/projects/quml-demo-app/src/app/question-cursor-implementation.service.ts) and do not forget to add your question list API URL here, for example: listUrl = "https://staging.sunbirded.org/api/question/v1/list";
### :label: Step 3: Include the styles, scripts and assets in angular.json
Add the following under `architect.build.assets` for default project
```javascript
Expand Down Expand Up @@ -111,13 +111,13 @@ If you prefer not to use schematics or want to add `sunbird-quml-player` to an o

</details>

Note: To avoid CORS errors, add proxy configuration for API's refer - [proxy.conf.json](https://github.com/project-sunbird/sunbird-quml-player/blob/release-5.1.0/projects/quml-demo-app/src/proxy.conf.json)
Note: To avoid CORS errors, add proxy configuration for API's refer - [proxy.conf.json](https://github.com/Sunbird-inQuiry/player/blob/release-5.1.0/projects/quml-demo-app/src/proxy.conf.json)

## :label: Send input to render QuML player
User can get a response from the `api/questionset/v1/hierarchy/:do_id` or can use the provided mock config for demo

Use the mock config in your component to send input to QuML player as `playerConfig`
Click to see the mock - [samplePlayerConfig](https://github.com/project-sunbird/sunbird-quml-player/blob/release-5.1.0/projects/quml-demo-app/src/app/quml-library-data.ts#L495)
Click to see the mock - [samplePlayerConfig](https://github.com/Sunbird-inQuiry/player/blob/release-5.1.0/projects/quml-demo-app/src/app/quml-library-data.ts#L495)

```html
<quml-main-player [playerConfig]="samplePlayerConfig" ><quml-main-player>
Expand Down Expand Up @@ -153,13 +153,13 @@ If context is not passed in playerConfig telemetry event of player will not be c
QuML Library can also be used as web component which means user can import this library in any web application and use these custom components.
Follow below-mentioned steps to use it in plain JavaScript project:

- Insert [library](https://github.com/project-sunbird/sunbird-quml-player/blob/main/web-component/sunbird-quml-player.js) as below:
- Insert [library](https://github.com/Sunbird-inQuiry/player/blob/main/web-component/sunbird-quml-player.js) as below:
```javascript
<script type="text/javascript" src="sunbird-quml-player.js"></script>
```
- Create an asset folder and copy all the files from [here](https://github.com/project-sunbird/sunbird-quml-player/tree/main/web-component/assets), library requires these assets internally to work well.
- Create an asset folder and copy all the files from [here](https://github.com/Sunbird-inQuiry/player/tree/main/web-component/assets), library requires these assets internally to work well.

- Get sample playerConfig from here: [samplePlayerConfig](https://github.com/project-sunbird/sunbird-quml-player/blob/release-5.1.0/projects/quml-demo-app/src/app/quml-library-data.ts)
- Get sample playerConfig from here: [samplePlayerConfig](https://github.com/Sunbird-inQuiry/player/blob/release-5.1.0/projects/quml-demo-app/src/app/quml-library-data.ts)

- Pass the Question List API baseUrl for, e.g. [https://staging.sunbirded.org/api/question/v1/list](https://staging.sunbirded.org/api/question/v1/list)

Expand Down Expand Up @@ -189,14 +189,14 @@ Follow below-mentioned steps to use it in plain JavaScript project:
const myPlayer = document.getElementById("my-player");
myPlayer.appendChild(qumlPlayerElement);
```
- :arrow_forward: Refer demo [example](https://github.com/project-sunbird/sunbird-quml-player/blob/main/web-component/index.html)
- :arrow_forward: Refer demo [example](https://github.com/Sunbird-inQuiry/player/blob/main/web-component/index.html)

---

# :bookmark_tabs: QuML Player Contribution Guide
## Repo Setup
- Install Node 14.x and Angular 12
- Clone the Repo with desired release-branch - https://github.com/project-sunbird/sunbird-quml-player
- Clone the Repo with desired release-branch - https://github.com/Sunbird-inQuiry/player
- Add the baseUrl in the *environment.ts* and *proxy.conf.json* files
- If there are any changes in API endpoints, update the *app.constant.ts* file
- Change the default content ID in *app.component.ts* file if pointing to different baseUrl
Expand Down
4 changes: 2 additions & 2 deletions projects/quml-library/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@
"copyfiles": "2.4.1",
"typescript": "~4.3.5"
},
"homepage": "https://github.com/project-sunbird/sunbird-quml-player#readme",
"homepage": "https://github.com/Sunbird-inQuiry/player#readme",
"keywords": [
"sunbird",
"sunbird QuML player",
"project-sunbird"
],
"repository": {
"type": "git",
"url": "https://github.com/project-sunbird/sunbird-quml-player.git"
"url": "https://github.com/Sunbird-inQuiry/player.git"
},
"license": "MIT"
}
2 changes: 1 addition & 1 deletion web-component-examples/react-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

- Create react app if not exist with `npx create-react-app my-app`

- Copy files from the `https://github.com/project-sunbird/sunbird-quml-player/tree/main/web-component`
- Copy files from the `https://github.com/Sunbird-inQuiry/player/tree/main/web-component`
- Copy `assets` folder to `public` folder to access the assets from `sunbird-quml-player`
- Create new folder in `src` (e.g. Sunbird) and keep `sunbird-quml-player.js`, `style.css` and font files in it.

Expand Down
2 changes: 1 addition & 1 deletion web-component-examples/vanilla-js/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
## STEPS TO USE SUNBIRD-QUML-PLAYER AS WEB-COMPONENT IN VANILLA JAVASCRIPT


- Copy files from the `https://github.com/project-sunbird/sunbird-quml-player/tree/main/web-component` to the root of this vanilla javascript project
- Copy files from the `https://github.com/Sunbird-inQuiry/player/tree/main/web-component` to the root of this vanilla javascript project

0 comments on commit 313c5bd

Please sign in to comment.