Difference between revisions of "Content Item Object"

From MSX - Wiki
Jump to navigation Jump to search
Line 57: Line 57:
 
The ID of the content item. This property can be used to identify the item. The ID must be unique and only consist of letters, numbers, and the special characters <code>"_"</code>, <code>"-"</code>, <code>"."</code>.
 
The ID of the content item. This property can be used to identify the item. The ID must be unique and only consist of letters, numbers, and the special characters <code>"_"</code>, <code>"-"</code>, <code>"."</code>.
 
|-
 
|-
| <code>version</code> || <code>string</code> || <code>null</code> || No || data-sort-value=0|0.1.0 ||  
+
| <code>type</code> || <code>string</code> || <code>"default"</code> || No || data-sort-value=0|0.1.0 ||  
The version of the content. This property is only used if the content data is loaded at startup and can be used to add a content version. This value is displayed in the about panel of the Media Station X application.
+
The type of the content item.
|-
 
| <code>flag</code> || <code>string</code> || <code>null</code> || No || data-sort-value=120|'''0.1.120''' ||
 
A custom content flag that can be evaluated by plugins and/or servers.
 
|-
 
| <code>reuse</code> || <code>boolean</code> || <code>true</code> || No || data-sort-value=0|0.1.0 ||
 
Indicates if the content data can be reused. If this property is set to <code>false</code>, the content data is recreated each time it is displayed.
 
|-
 
| <code>cache</code> || <code>boolean</code> || <code>true</code> || No || data-sort-value=58|'''0.1.58''' ||
 
Indicates if the content data is being cached. This property can be used to disable the cache feature.
 
|-
 
| <code>restore</code> || <code>boolean</code> || <code>true</code> || No || data-sort-value=120|'''0.1.120''' ||
 
Indicates if the content data is restorable. If this property is set to <code>false</code>, the content data is not restored when the application returns from a link action. This property has no effect if the content is displayed in a panel.
 
  
'''Note: If the content is loaded via a menu and the menu data has set the <code>restore</code> property to <code>false</code>, this property is ignored.'''
+
* <code>"default"</code>: Default item.
|-
+
* <code>"teaser"</code>: Teaser items are similar to "default" items, but they have a larger title.
| <code>important</code> || <code>boolean</code> || <code>false</code> || No || data-sort-value=58|'''0.1.58''' ||
+
* <code>"button"</code>: Button items have a frame and a transparent background color. The icon and label properties are typically used with this type.
Indicates if the content data is important. This property can be used to enforce that the content headline is displayed.
+
* <code>"separate"</code>: Separate items have seperated titles.
 +
* <code>"space"</code>: Space items are not selectable and can be used to add background or foreground items.
 +
* <code>"control"</code>: Control items are similar to "button" items and mainly designed for internal purposes (e.g. they are used in context menus and settings). The icon and label properties are typically used with this type. Additionally, the extensionLabel and extensionIcon properties are available for this type.
  
'''Note: The content headline is not displayed if the content is loaded via a menu, because in that case the menu item label is used as headline.'''
 
|-
 
| <code>wrap</code> || <code>boolean</code> || <code>false</code> || No || data-sort-value=102|'''0.1.102''' ||
 
Indicates if the content data is wrapped. If this property is set to <code>true</code>, a corresponding menu can not be entered by using the navigation keys (i.e. left and right key). This property has no effect if the content is displayed in a panel or the content is not loaded via a menu.
 
 
'''Note: If the active content page has its own <code>wrap</code> property, this property is ignored.'''
 
|-
 
| <code>transparent</code> || <code>boolean</code> || <code>false</code> || No || data-sort-value=120|'''0.1.120''' ||
 
Indicates if the content background is transparent. By default, the content background is set to a semi-transparent gray to darken the underlying video/image and make the content more visible. This property has no effect if the content is displayed in a panel.
 
 
'''Note: If the active content page has its own <code>transparent</code> property, this property is ignored.'''
 
 
|}
 
|}

Revision as of 13:07, 11 January 2021

{   
    "id": "content_item_id",
    "type": "default",
    "layout": "0,0,1,1",
    "area": "0,0,12,6",
    "offset": "0,0,0,0",
    "display": true,
    "enable": true,
    "focus": false,
    "enumerate": false,
    "group": "Item Group",
    "color": "msx-glass",
    "title": "Item Title",
    "titleHeader": "Item Title Header",
    "titleFooter": "Item Title Footer",
    "label": "Item Label",
    "icon": "blank",
    "iconSize": "medium",
    "headline": "Item Headline",
    "text": "Item Text",   
    "alignment": "left",
    "tag": "Item Tag",
    "tagColor": "msx-red",
    "badge": "Item Badge",
    "badgeColor": "msx-green",
    "progress": -1,
    "progressColor": "msx-yellow",
    "wrapperColor": "msx-blue",
    "image": "http://link.to.image",
    "imageFiller": "default",
    "imageWidth": -1,
    "imageHeight": -1,
    "imageOverlay": -1,
    "imagePreload": false,
    "imageLabel": "Image Label",
    "imageColor": "msx-black",
    "imageScreenFiller": "fit",      
    "playerLabel": "Player Label",
    "background": "http://link.to.image",    
    "extensionIcon": "blank",
    "extensionLabel": "Extension Label",
    "action": null,
    "data": null,
    "properties": null,
    "live": null,
    "selection": null,
    "options": null
}
Property Type Default Value Mandatory Since Version Description
id string null No 0.1.0

The ID of the content item. This property can be used to identify the item. The ID must be unique and only consist of letters, numbers, and the special characters "_", "-", ".".

type string "default" No 0.1.0

The type of the content item.

  • "default": Default item.
  • "teaser": Teaser items are similar to "default" items, but they have a larger title.
  • "button": Button items have a frame and a transparent background color. The icon and label properties are typically used with this type.
  • "separate": Separate items have seperated titles.
  • "space": Space items are not selectable and can be used to add background or foreground items.
  • "control": Control items are similar to "button" items and mainly designed for internal purposes (e.g. they are used in context menus and settings). The icon and label properties are typically used with this type. Additionally, the extensionLabel and extensionIcon properties are available for this type.