@signageos/front-applet 5.2.0 → 5.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
4
4
  The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
5
5
  and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [5.3.0] - 2022-04-13
8
+ ### Added
9
+ - Documentation for device info
10
+
7
11
  ## [5.2.0] - 2022-04-06
8
12
  ### Added
9
13
  - Method onStatus in sos.sync - return connected devices in sync group
@@ -29,6 +29,7 @@ Universal APIs for File system, access to accelerated video playback, sensor man
29
29
  | **[Basic information](/api/js/content/latest/js-applet-basics)** | General information required to use the signageOS JS API |
30
30
  | [Applet Resources](/api/js/content/latest/js-applet-resources) | Pre-load necessary files required by your HTML5 player/Applet |
31
31
  | [Display](/api/js/content/latest/js-display) | Query features supported by the display |
32
+ | [DeviceInfo](/api/js/content/latest/js-device-info) | Device-related informations |
32
33
  | [Browser](/api/js/content/latest/js-browser) | Opening managed web-browser on Android devices inc. whitelisting, blacklisting and other features |
33
34
  | [Command](/api/js/content/latest/js-command) | Sending business or technical logs through signageOS in secured offline-ready way |
34
35
  | [File system](/api/js/content/latest/js-file-system) | Full-featured file system API including ZIP and folder management |
@@ -0,0 +1,56 @@
1
+ ---
2
+ title: Device Info
3
+ author: Robert Pecha
4
+ date: 13.4.2022
5
+ type: js-api
6
+ tags:
7
+ - applet
8
+ - applet_api
9
+ - api
10
+ - js_api
11
+ description: "[Content JS API] There are many device-related informations that are grouped."
12
+ ---
13
+
14
+ # Device Info
15
+ There are many device-related informations that are grouped.
16
+
17
+ ## All methods
18
+
19
+ ::: table-responsive
20
+ | Method | Description | Supported since |
21
+ | ----------------- | ------------------ | :---------------: |
22
+ | `getLocation()` | Returns location when assigned to device | 5.2.0 |
23
+ | `getOrganizationTags()` | Returns list of organization tags when some assigned to device | 5.2.0 |
24
+ :::
25
+
26
+ ## getLocation()
27
+ Location is requested from server on application start, automatically updated when changed and persists in local storage.
28
+
29
+ ### Javascript
30
+ ```javascript
31
+ sos.deviceInfo.getLocation();
32
+ ```
33
+
34
+ ```typescript
35
+ interface IDeviceLocation {
36
+ name: string;
37
+ customId?: string;
38
+ description?: string;
39
+ }
40
+
41
+ getLocation(): Promise<IDeviceLocation | null>;
42
+ ```
43
+
44
+ ## getOrganizationTags()
45
+ Location is requested from server on application start, automatically updated when assigned or unassigned and persists in local storage.
46
+ ```javascript
47
+ sos.deviceInfo.getOrganizationTags()
48
+ ```
49
+
50
+ ```typescript
51
+ interface IOrganizationTag {
52
+ name: string;
53
+ }
54
+
55
+ getOrganizationTags(): Promise<IOrganizationTag[]>;
56
+ ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@signageos/front-applet",
3
- "version": "5.2.0",
3
+ "version": "5.3.0",
4
4
  "main": "dist/bundle.js",
5
5
  "types": "es6/bundle.d.ts",
6
6
  "files": [