2024-06-21 11:20:34 +02:00
# openvidu-angular-v2compatibility
2022-01-19 17:24:11 +01:00
2022-10-07 16:40:25 +02:00
OpenVidu Components for Angular.
2022-04-11 16:03:48 +02:00
[](http://www.apache.org/licenses/LICENSE-2.0)
2022-06-08 14:40:26 +02:00
[](https://github.com/OpenVidu/openvidu/actions/workflows/openvidu-ce-test.yml)
2022-06-13 14:05:22 +02:00
[](https://github.com/OpenVidu/openvidu/actions/workflows/openvidu-components-angular-E2E.yml)
2024-06-21 11:20:34 +02:00
[](https://npmjs.org/package/openvidu-angular-v2compatibility)
[](https://npmjs.org/package/openvidu-angular-v2compatibility)
2022-04-08 14:01:47 +02:00
**The easier way to build powerful OpenVidu videoconference frontend applications.**
2022-01-19 17:24:11 +01:00
2022-04-11 16:03:48 +02:00
## Requirements:
2022-05-30 12:10:28 +02:00
You will need NPM and Angular CLI to serve the Angular app. Check your installation with the following command:
2022-04-11 16:03:48 +02:00
```bash
npm -v
ng v
```
2022-04-18 12:50:20 +02:00
## How to install it
2022-01-19 17:24:11 +01:00
2024-06-21 11:20:34 +02:00
1. You need to install the openvidu-angular-v2compatibility library in your Angular application:
2022-04-11 16:03:48 +02:00
2022-03-28 16:51:12 +02:00
```
2024-06-21 11:20:34 +02:00
npm install openvidu-angular-v2compatibility
2022-04-11 16:03:48 +02:00
```
2022-09-19 10:39:20 +02:00
< br >
2. Also you need Angular Material. Check the [Angular Material documentation ](https://material.angular.io/guide/getting-started ) for installing it.
2022-04-11 16:03:48 +02:00
2022-04-18 12:50:20 +02:00
## Configure it
2022-03-28 16:51:12 +02:00
2024-06-21 11:20:34 +02:00
You need to import the openvidu-angular-v2compatibility module in your `app.module.ts` :
2022-01-19 17:24:11 +01:00
2022-04-08 13:52:12 +02:00
```typescript
2024-06-21 11:20:34 +02:00
import { OpenViduAngularConfig, OpenViduAngularModule } from 'openvidu-angular-v2compatibility';
2022-04-18 12:50:20 +02:00
import { environment } from 'src/environments/environment';
2022-01-19 17:24:11 +01:00
2022-04-08 13:52:12 +02:00
const config: OpenViduAngularConfig = {
production: environment.production
};
2022-01-19 17:24:11 +01:00
@NgModule ({
2022-04-08 13:52:12 +02:00
imports: [
...
OpenViduAngularModule.forRoot(config)
]
})
2022-04-18 12:50:20 +02:00
```
2022-05-30 12:10:28 +02:00
You can also add the default styles in your `styles.scss` file:
2022-04-18 12:50:20 +02:00
```css
:root {
2022-10-07 16:40:25 +02:00
--ov-primary-color: #303030 ;
--ov-secondary-color: #3e3f3f ;
--ov-tertiary-color: #598eff ;
--ov-warn-color: #eb5144 ;
--ov-accent-color: #ffae35 ;
--ov-light-color: #e6e6e6 ;
2022-04-18 13:33:53 +02:00
2022-10-07 16:40:25 +02:00
--ov-logo-background-color: #3a3d3d ;
2022-04-18 12:50:20 +02:00
2022-10-07 16:40:25 +02:00
--ov-text-color: #ffffff ;
2022-04-18 12:50:20 +02:00
2022-10-07 16:40:25 +02:00
--ov-panel-text-color: #1d1d1d ;
--ov-panel-background: #ffffff ;
2022-04-18 12:50:20 +02:00
2022-10-07 16:40:25 +02:00
--ov-buttons-radius: 50%;
--ov-leave-button-radius: 10px;
--ov-video-radius: 5px;
--ov-panel-radius: 5px;
2022-04-18 12:50:20 +02:00
}
2022-10-07 16:40:25 +02:00
```
2023-01-26 10:48:32 +01:00
## How to use it
OpenVidu team has created a few tutorials to help you to start using OpenVidu Angular components. You can find them [here ](https://docs.openvidu.io/en/stable/components/#where-to-start ).
2024-06-21 11:20:34 +02:00
## openvidu-angular-v2compatibility API
2023-01-26 10:48:32 +01:00
2024-06-21 11:20:34 +02:00
openvidu-angular-v2compatibility API documentation is available [here ](https://docs.openvidu.io/en/stable/api/openvidu-angular-v2compatibility/ ).