const options = {
advanced_features: [
{
name: 'custom_buttons',
visible: true,
data: [
{
buttonInfo: {
name: 'MyCustomButton',
// Material Symbols reference
// https://fonts.google.com/icons?icon.set=Material+Symbols&icon.platform=web
// Material Icons reference
// https://fonts.google.com/icons?icon.set=Material+Icons&icon.platform=web
materialSymbols: false, // default false
iconName: 'favorite',
color: 'white',
// should be inherited in like
// .shaka-video-container .my-custom-button"
cssClass: 'my-custom-button'
},
onEventType: 'click',
onEventTypeHandler: () => {
console.log('Hello! From custom button');
// your code here
}
},
{
buttonInfo: {
name: 'MyCustomButton2',
// Material Symbols reference
// https://fonts.google.com/icons?icon.set=Material+Symbols&icon.platform=web
// Material Icons reference
// https://fonts.google.com/icons?icon.set=Material+Icons&icon.platform=web
materialSymbols: false, // default false
iconName: 'download',
color: 'green',
// should be inherited in like:
// "shaka-video-container .my-custom-button2"
cssClass: 'my-custom-button2'
},
onEventType: 'click',
onEventTypeHandler: () => {
console.log('Hello! From custom button 2');
// your code here
}
}
]
}
]
}