shiyiya / oplayer

:zap: Another HTM5 video player.

Home Page:https://oplayer.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to add custom icon in it.

MuhammadTufailAli opened this issue · comments

In documentation it is said that to add custom icon do following
{
icons: {
play: '',
pause: '',
volume: ['', ''], //on off
fullscreen: ['', ''], //on off
pip: '',
setting: '',
screenshot: '',
playbackRate: '',
loop: '',
progressIndicator: '',
loadingIndicator: ''
}
}
But it only accepts string, in documentation it is not specified how to use your custom svg or png has icon or how can we use react icon instead of oplayer default icons> Can you please help me about this issue.

commented

Sorry, there is no support for using react-component, only for using HTML Dom string, which you can interpret as a dom created using innerHTML. you can copy the svg after your react render

commented

progressIndicator: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22">