Skip to content
This repository has been archived by the owner on Nov 4, 2023. It is now read-only.

Commit

Permalink
fix(MEDIA_PLAYER): localized translation for mediaplayer "Source" label
Browse files Browse the repository at this point in the history
  • Loading branch information
mikyjazz authored and rchl committed Apr 24, 2021
1 parent 4495134 commit af9b961
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,10 @@ Tile Object. [Click here for some real-life examples](TILE_EXAMPLES.md)
* Value options: true, false
*/
hideSource: false,
/* textSource: localized/customized text for 'Source'
* (optional)
*/
textSource: 'Audio Input',
/** type: SLIDER **/
/* filter: Function for filtering/formatting the value */
filter: function (value) {return value},
Expand Down
1 change: 1 addition & 0 deletions TILE_EXAMPLES.md
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,7 @@ Locks and unlocks the lock on tap. Also shows icon depending on the state<br>
id: 'media_player.volumio',
type: TYPES.MEDIA_PLAYER,
hideSource: false,
textSource: 'Sorgente',
hideMuteButton: false,
state: false,
//state: '@attributes.media_title',
Expand Down
2 changes: 1 addition & 1 deletion scripts/directives/tile.html
Original file line number Diff line number Diff line change
Expand Up @@ -607,7 +607,7 @@
<td colspan="3" class="media-player-table--td-source">
<div class="media-player--source" ng-click="openSelect(item)"
ng-if="entity.attributes.source_list.length && !item.hideSource">
<span ng-bind="entity.attributes.source || 'Source'"></span>
<span ng-bind="item.textSource || entity.attributes.source || 'Source'"></span>
</div>
</td>
</tr>
Expand Down

0 comments on commit af9b961

Please sign in to comment.