@ -19726,12 +19726,12 @@ class PlexMeetsHomeAssistantEditor extends HTMLElement {
else if ( lodash . isObjectLike ( this . config . entity ) ) {
hasUIConfig = false ;
}
if ( hasUIConfig ) {
const devicesTitle = document . createElement ( 'h2' ) ;
devicesTitle . innerHTML = ` Devices Configuration ` ;
devicesTitle . style . lineHeight = '29px' ;
devicesTitle . style . marginBottom = '0px' ;
devicesTitle . style . marginTop = '20px' ;
if ( hasUIConfig ) {
const addDeviceButton = document . createElement ( 'button' ) ;
addDeviceButton . style . float = 'right' ;
addDeviceButton . style . fontSize = '20px' ;
@ -19744,7 +19744,10 @@ class PlexMeetsHomeAssistantEditor extends HTMLElement {
}
} ) ;
devicesTitle . appendChild ( addDeviceButton ) ;
}
this . plexValidSection . appendChild ( devicesTitle ) ;
// todo: convert entities setup to simple one if not using plexPlayer
if ( hasUIConfig ) {
if ( lodash . isString ( this . config . entity ) ) {
this . config . entity = [ this . config . entity ] ;
}
@ -19759,6 +19762,12 @@ class PlexMeetsHomeAssistantEditor extends HTMLElement {
} ) ;
}
}
else {
const entitiesUINotAvailable = document . createElement ( 'div' ) ;
entitiesUINotAvailable . innerHTML =
'Devices configuration is not available when using plexPlayer client device.<br/>You can edit any other settings through UI and use <b>Show code editor</b> to edit entities.' ;
this . plexValidSection . appendChild ( entitiesUINotAvailable ) ;
}
if ( ! lodash . isEmpty ( this . sections ) ) {
lodash . forEach ( this . sections , ( section ) => {
libraryItems . appendChild ( addDropdownItem ( section . title ) ) ;