@signageos/front-applet 7.2.0 → 8.0.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.
Files changed (420) hide show
  1. package/dist/bundle.js +8 -4
  2. package/dist/bundle.js.map +1 -1
  3. package/docs/fpath/index.md +316 -0
  4. package/docs/index.md +18 -85
  5. package/docs/sos/browser.md +210 -0
  6. package/docs/sos/command.md +68 -0
  7. package/docs/sos/debug.md +25 -0
  8. package/docs/sos/deviceInfo.md +49 -0
  9. package/docs/sos/display.md +21 -0
  10. package/docs/sos/fileSystem.md +594 -0
  11. package/docs/sos/hardware/barcodeScanner.md +40 -0
  12. package/docs/sos/hardware/index.md +64 -0
  13. package/docs/sos/hardware/led.md +14 -0
  14. package/docs/sos/index.md +82 -0
  15. package/docs/sos/input.md +73 -0
  16. package/docs/sos/monitors.md +21 -0
  17. package/docs/sos/native/index.md +5 -0
  18. package/docs/sos/native/mdc.md +240 -0
  19. package/docs/sos/offline/cache.md +183 -0
  20. package/docs/sos/offline/index.md +188 -0
  21. package/docs/sos/osd.md +13 -0
  22. package/docs/sos/proofOfPlay.md +37 -0
  23. package/docs/sos/stream.md +960 -0
  24. package/docs/sos/sync.md +298 -0
  25. package/docs/sos/video.md +285 -0
  26. package/docs/sos_management/app.md +102 -0
  27. package/docs/sos_management/audio.md +29 -0
  28. package/docs/sos_management/debug.md +33 -0
  29. package/docs/sos_management/firmware.md +86 -0
  30. package/docs/sos_management/index.md +212 -0
  31. package/docs/sos_management/network.md +197 -0
  32. package/docs/sos_management/os.md +54 -0
  33. package/docs/sos_management/package.md +33 -0
  34. package/docs/sos_management/power.md +136 -0
  35. package/docs/sos_management/proxy.md +41 -0
  36. package/docs/sos_management/remoteControl.md +72 -0
  37. package/docs/sos_management/screen.md +198 -0
  38. package/docs/sos_management/security.md +47 -0
  39. package/docs/sos_management/time.md +101 -0
  40. package/docs/sos_management/wifi.md +366 -0
  41. package/es6/FrontApplet/Browser/Browser.d.ts +61 -8
  42. package/es6/FrontApplet/Browser/Browser.js +91 -39
  43. package/es6/FrontApplet/Browser/Browser.js.map +1 -1
  44. package/es6/FrontApplet/Browser/events.js +2 -2
  45. package/es6/FrontApplet/Browser/events.js.map +1 -1
  46. package/es6/FrontApplet/Command/Command.d.ts +37 -3
  47. package/es6/FrontApplet/Command/Command.js +49 -20
  48. package/es6/FrontApplet/Command/Command.js.map +1 -1
  49. package/es6/FrontApplet/Command/ICommandEvent.d.ts +6 -2
  50. package/es6/FrontApplet/Connect/Connect.d.ts +3 -0
  51. package/es6/FrontApplet/Connect/Connect.js +55 -7
  52. package/es6/FrontApplet/Connect/Connect.js.map +1 -1
  53. package/es6/FrontApplet/Connect/IConnectMessage.d.ts +1 -1
  54. package/es6/FrontApplet/Debug/Debug.d.ts +15 -1
  55. package/es6/FrontApplet/Debug/Debug.js +27 -17
  56. package/es6/FrontApplet/Debug/Debug.js.map +1 -1
  57. package/es6/FrontApplet/Debug/debugDecorator.d.ts +3 -3
  58. package/es6/FrontApplet/Debug/debugDecorator.js +13 -7
  59. package/es6/FrontApplet/Debug/debugDecorator.js.map +1 -1
  60. package/es6/FrontApplet/DeviceInfo/DeviceInfo.d.ts +23 -0
  61. package/es6/FrontApplet/DeviceInfo/DeviceInfo.js +36 -27
  62. package/es6/FrontApplet/DeviceInfo/DeviceInfo.js.map +1 -1
  63. package/es6/FrontApplet/Dimensions/coordinationsHelper.js +1 -2
  64. package/es6/FrontApplet/Dimensions/coordinationsHelper.js.map +1 -1
  65. package/es6/FrontApplet/Display/Display.d.ts +25 -3
  66. package/es6/FrontApplet/Display/Display.js +35 -19
  67. package/es6/FrontApplet/Display/Display.js.map +1 -1
  68. package/es6/FrontApplet/Display/IDisplay.d.ts +3 -1
  69. package/es6/FrontApplet/Error/AppletCommandError.js +12 -3
  70. package/es6/FrontApplet/Error/AppletCommandError.js.map +1 -1
  71. package/es6/FrontApplet/Error/AppletError.js +10 -2
  72. package/es6/FrontApplet/Error/AppletError.js.map +1 -1
  73. package/es6/FrontApplet/Error/AppletHardwareError.js +12 -3
  74. package/es6/FrontApplet/Error/AppletHardwareError.js.map +1 -1
  75. package/es6/FrontApplet/Error/AppletOfflineCacheError.js +10 -2
  76. package/es6/FrontApplet/Error/AppletOfflineCacheError.js.map +1 -1
  77. package/es6/FrontApplet/Error/AppletResourcesError.js +12 -3
  78. package/es6/FrontApplet/Error/AppletResourcesError.js.map +1 -1
  79. package/es6/FrontApplet/Error/AppletSecurityError.js +12 -3
  80. package/es6/FrontApplet/Error/AppletSecurityError.js.map +1 -1
  81. package/es6/FrontApplet/Error/AppletStreamError.js +10 -2
  82. package/es6/FrontApplet/Error/AppletStreamError.js.map +1 -1
  83. package/es6/FrontApplet/Error/AppletVideoError.js +12 -3
  84. package/es6/FrontApplet/Error/AppletVideoError.js.map +1 -1
  85. package/es6/FrontApplet/Error/ErrorCodesMessages.js +4 -1
  86. package/es6/FrontApplet/Error/ErrorCodesMessages.js.map +1 -1
  87. package/es6/FrontApplet/Error/ErrorSuggestions.js +1 -0
  88. package/es6/FrontApplet/Error/ErrorSuggestions.js.map +1 -1
  89. package/es6/FrontApplet/Error/FileNotFoundError.js +10 -2
  90. package/es6/FrontApplet/Error/FileNotFoundError.js.map +1 -1
  91. package/es6/FrontApplet/Error/SosError.js +4 -0
  92. package/es6/FrontApplet/Error/SosError.js.map +1 -1
  93. package/es6/FrontApplet/Error/errorHelper.js +5 -6
  94. package/es6/FrontApplet/Error/errorHelper.js.map +1 -1
  95. package/es6/FrontApplet/Exchange/Exchange.js +7 -14
  96. package/es6/FrontApplet/Exchange/Exchange.js.map +1 -1
  97. package/es6/FrontApplet/FileSystem/FileSystem.d.ts +156 -1
  98. package/es6/FrontApplet/FileSystem/FileSystem.js +316 -193
  99. package/es6/FrontApplet/FileSystem/FileSystem.js.map +1 -1
  100. package/es6/FrontApplet/FileSystem/HashAlgorithm.d.ts +2 -0
  101. package/es6/FrontApplet/{Stream/streamListeners.js → FileSystem/HashAlgorithm.js} +1 -1
  102. package/es6/FrontApplet/FileSystem/HashAlgorithm.js.map +1 -0
  103. package/es6/FrontApplet/Font/fontFaceGenerator.js.map +1 -1
  104. package/es6/FrontApplet/FrontApplet.d.ts +55 -4
  105. package/es6/FrontApplet/FrontApplet.js +124 -47
  106. package/es6/FrontApplet/FrontApplet.js.map +1 -1
  107. package/es6/FrontApplet/Hardware/BarcodeScanner/BarcodeScanner.d.ts +2 -0
  108. package/es6/FrontApplet/Hardware/BarcodeScanner/BarcodeScanner.js +35 -54
  109. package/es6/FrontApplet/Hardware/BarcodeScanner/BarcodeScanner.js.map +1 -1
  110. package/es6/FrontApplet/Hardware/Hardware.d.ts +16 -2
  111. package/es6/FrontApplet/Hardware/Hardware.js +31 -19
  112. package/es6/FrontApplet/Hardware/Hardware.js.map +1 -1
  113. package/es6/FrontApplet/Hardware/IHardware.d.ts +2 -2
  114. package/es6/FrontApplet/Hardware/ISerialPort.d.ts +16 -0
  115. package/es6/FrontApplet/Hardware/ISerialPortOptions.js +1 -1
  116. package/es6/FrontApplet/Hardware/ISerialPortOptions.js.map +1 -1
  117. package/es6/FrontApplet/Hardware/Led/Led.d.ts +8 -0
  118. package/es6/FrontApplet/Hardware/Led/Led.js +20 -18
  119. package/es6/FrontApplet/Hardware/Led/Led.js.map +1 -1
  120. package/es6/FrontApplet/Hardware/SerialPort.d.ts +1 -1
  121. package/es6/FrontApplet/Hardware/SerialPort.js +15 -23
  122. package/es6/FrontApplet/Hardware/SerialPort.js.map +1 -1
  123. package/es6/FrontApplet/Hash/generator.js +1 -2
  124. package/es6/FrontApplet/Hash/generator.js.map +1 -1
  125. package/es6/FrontApplet/Iframe/Iframe.d.ts +9 -8
  126. package/es6/FrontApplet/Iframe/Iframe.js +10 -0
  127. package/es6/FrontApplet/Iframe/Iframe.js.map +1 -1
  128. package/es6/FrontApplet/Input/IInput.d.ts +1 -2
  129. package/es6/FrontApplet/Input/IKeyUpEvent.d.ts +32 -2
  130. package/es6/FrontApplet/Input/IKeyUpEvent.js +32 -0
  131. package/es6/FrontApplet/Input/IKeyUpEvent.js.map +1 -1
  132. package/es6/FrontApplet/Input/Input.d.ts +19 -3
  133. package/es6/FrontApplet/Input/Input.js +43 -22
  134. package/es6/FrontApplet/Input/Input.js.map +1 -1
  135. package/es6/FrontApplet/Management/App/App.d.ts +48 -10
  136. package/es6/FrontApplet/Management/App/App.js +45 -30
  137. package/es6/FrontApplet/Management/App/App.js.map +1 -1
  138. package/es6/FrontApplet/Management/App/IApp.d.ts +3 -1
  139. package/es6/FrontApplet/Management/Audio/Audio.d.ts +16 -0
  140. package/es6/FrontApplet/Management/Audio/Audio.js +30 -22
  141. package/es6/FrontApplet/Management/Audio/Audio.js.map +1 -1
  142. package/es6/FrontApplet/Management/AutoRecovery/AutoRecovery.d.ts +4 -0
  143. package/es6/FrontApplet/Management/AutoRecovery/AutoRecovery.js +15 -22
  144. package/es6/FrontApplet/Management/AutoRecovery/AutoRecovery.js.map +1 -1
  145. package/es6/FrontApplet/Management/AutoRecovery/IAutoRecovery.js +4 -1
  146. package/es6/FrontApplet/Management/AutoRecovery/IAutoRecovery.js.map +1 -1
  147. package/es6/FrontApplet/Management/Debug/Debug.d.ts +19 -0
  148. package/es6/FrontApplet/Management/Debug/Debug.js +37 -30
  149. package/es6/FrontApplet/Management/Debug/Debug.js.map +1 -1
  150. package/es6/FrontApplet/Management/Firmware/Firmware.d.ts +37 -10
  151. package/es6/FrontApplet/Management/Firmware/Firmware.js +34 -30
  152. package/es6/FrontApplet/Management/Firmware/Firmware.js.map +1 -1
  153. package/es6/FrontApplet/Management/Firmware/IFirmware.d.ts +1 -2
  154. package/es6/FrontApplet/Management/IManagement.d.ts +3 -1
  155. package/es6/FrontApplet/Management/Management.d.ts +106 -15
  156. package/es6/FrontApplet/Management/Management.js +191 -113
  157. package/es6/FrontApplet/Management/Management.js.map +1 -1
  158. package/es6/FrontApplet/Management/Network/INetworkInfo.d.ts +1 -1
  159. package/es6/FrontApplet/Management/Network/Network.d.ts +56 -8
  160. package/es6/FrontApplet/Management/Network/Network.js +85 -67
  161. package/es6/FrontApplet/Management/Network/Network.js.map +1 -1
  162. package/es6/FrontApplet/Management/OS/OS.d.ts +20 -0
  163. package/es6/FrontApplet/Management/OS/OS.js +34 -27
  164. package/es6/FrontApplet/Management/OS/OS.js.map +1 -1
  165. package/es6/FrontApplet/Management/Package/Package.d.ts +20 -0
  166. package/es6/FrontApplet/Management/Package/Package.js +37 -22
  167. package/es6/FrontApplet/Management/Package/Package.js.map +1 -1
  168. package/es6/FrontApplet/Management/PeerRecovery/IPeerRecovery.js +4 -1
  169. package/es6/FrontApplet/Management/PeerRecovery/IPeerRecovery.js.map +1 -1
  170. package/es6/FrontApplet/Management/PeerRecovery/PeerRecovery.d.ts +4 -0
  171. package/es6/FrontApplet/Management/PeerRecovery/PeerRecovery.js +15 -22
  172. package/es6/FrontApplet/Management/PeerRecovery/PeerRecovery.js.map +1 -1
  173. package/es6/FrontApplet/Management/Power/Power.d.ts +64 -0
  174. package/es6/FrontApplet/Management/Power/Power.js +160 -115
  175. package/es6/FrontApplet/Management/Power/Power.js.map +1 -1
  176. package/es6/FrontApplet/Management/Proxy/Proxy.d.ts +21 -0
  177. package/es6/FrontApplet/Management/Proxy/Proxy.js +41 -35
  178. package/es6/FrontApplet/Management/Proxy/Proxy.js.map +1 -1
  179. package/es6/FrontApplet/Management/RemoteControl/RemoteControl.d.ts +43 -0
  180. package/es6/FrontApplet/Management/RemoteControl/RemoteControl.js +63 -39
  181. package/es6/FrontApplet/Management/RemoteControl/RemoteControl.js.map +1 -1
  182. package/es6/FrontApplet/Management/Screen/Screen.d.ts +127 -0
  183. package/es6/FrontApplet/Management/Screen/Screen.js +197 -89
  184. package/es6/FrontApplet/Management/Screen/Screen.js.map +1 -1
  185. package/es6/FrontApplet/Management/Security/Security.d.ts +20 -5
  186. package/es6/FrontApplet/Management/Security/Security.js +33 -31
  187. package/es6/FrontApplet/Management/Security/Security.js.map +1 -1
  188. package/es6/FrontApplet/Management/Time/Time.d.ts +31 -5
  189. package/es6/FrontApplet/Management/Time/Time.js +49 -40
  190. package/es6/FrontApplet/Management/Time/Time.js.map +1 -1
  191. package/es6/FrontApplet/Management/Wifi/IWifiEvent.d.ts +18 -0
  192. package/es6/FrontApplet/Management/Wifi/IWifiEvent.js +19 -1
  193. package/es6/FrontApplet/Management/Wifi/IWifiEvent.js.map +1 -1
  194. package/es6/FrontApplet/Management/Wifi/Wifi.d.ts +108 -7
  195. package/es6/FrontApplet/Management/Wifi/Wifi.js +162 -86
  196. package/es6/FrontApplet/Management/Wifi/Wifi.js.map +1 -1
  197. package/es6/FrontApplet/Management/helpers/DeviceHelper.js +2 -2
  198. package/es6/FrontApplet/Management/helpers/DeviceHelper.js.map +1 -1
  199. package/es6/FrontApplet/Management/helpers/SecurityHelper.js +8 -6
  200. package/es6/FrontApplet/Management/helpers/SecurityHelper.js.map +1 -1
  201. package/es6/FrontApplet/Management/helpers/TimerHelper.js +2 -2
  202. package/es6/FrontApplet/Management/helpers/TimerHelper.js.map +1 -1
  203. package/es6/FrontApplet/Management/helpers/UpgradeHelper.js +35 -3
  204. package/es6/FrontApplet/Management/helpers/UpgradeHelper.js.map +1 -1
  205. package/es6/FrontApplet/Management/helpers/VideoHelper.js +1 -1
  206. package/es6/FrontApplet/Management/helpers/VideoHelper.js.map +1 -1
  207. package/es6/FrontApplet/Monitors/Monitors.d.ts +9 -0
  208. package/es6/FrontApplet/Monitors/Monitors.js +16 -16
  209. package/es6/FrontApplet/Monitors/Monitors.js.map +1 -1
  210. package/es6/FrontApplet/NativeCommands/MDC/CodesMDC.js +1 -1
  211. package/es6/FrontApplet/NativeCommands/MDC/CodesMDC.js.map +1 -1
  212. package/es6/FrontApplet/NativeCommands/MDC/Mdc.d.ts +51 -2
  213. package/es6/FrontApplet/NativeCommands/MDC/Mdc.js +79 -38
  214. package/es6/FrontApplet/NativeCommands/MDC/Mdc.js.map +1 -1
  215. package/es6/FrontApplet/NativeCommands/NativeCommands.d.ts +4 -0
  216. package/es6/FrontApplet/NativeCommands/NativeCommands.js +12 -2
  217. package/es6/FrontApplet/NativeCommands/NativeCommands.js.map +1 -1
  218. package/es6/FrontApplet/OSD/OSD.d.ts +9 -0
  219. package/es6/FrontApplet/OSD/OSD.js +15 -15
  220. package/es6/FrontApplet/OSD/OSD.js.map +1 -1
  221. package/es6/FrontApplet/Offline/Cache/Cache.d.ts +91 -2
  222. package/es6/FrontApplet/Offline/Cache/Cache.js +192 -130
  223. package/es6/FrontApplet/Offline/Cache/Cache.js.map +1 -1
  224. package/es6/FrontApplet/Offline/Flags/AppendFlagController.d.ts +1 -1
  225. package/es6/FrontApplet/Offline/Flags/AppendFlagController.js +17 -25
  226. package/es6/FrontApplet/Offline/Flags/AppendFlagController.js.map +1 -1
  227. package/es6/FrontApplet/Offline/Flags/IFlags.d.ts +4 -4
  228. package/es6/FrontApplet/Offline/IAddFont.d.ts +3 -1
  229. package/es6/FrontApplet/Offline/IAddFont.js.map +1 -1
  230. package/es6/FrontApplet/Offline/ISaveFile.js +5 -2
  231. package/es6/FrontApplet/Offline/ISaveFile.js.map +1 -1
  232. package/es6/FrontApplet/Offline/LoadFile/CssLoadFileController.js +2 -1
  233. package/es6/FrontApplet/Offline/LoadFile/CssLoadFileController.js.map +1 -1
  234. package/es6/FrontApplet/Offline/LoadFile/JavascriptLoadFileController.js +2 -1
  235. package/es6/FrontApplet/Offline/LoadFile/JavascriptLoadFileController.js.map +1 -1
  236. package/es6/FrontApplet/Offline/Offline.d.ts +75 -4
  237. package/es6/FrontApplet/Offline/Offline.js +116 -56
  238. package/es6/FrontApplet/Offline/Offline.js.map +1 -1
  239. package/es6/FrontApplet/ProofOfPlay/ProofOfPlay.d.ts +19 -1
  240. package/es6/FrontApplet/ProofOfPlay/ProofOfPlay.js +41 -29
  241. package/es6/FrontApplet/ProofOfPlay/ProofOfPlay.js.map +1 -1
  242. package/es6/FrontApplet/Sensors/Proximity.d.ts +4 -3
  243. package/es6/FrontApplet/Sensors/Proximity.js +12 -4
  244. package/es6/FrontApplet/Sensors/Proximity.js.map +1 -1
  245. package/es6/FrontApplet/Sensors/Sensors.d.ts +2 -0
  246. package/es6/FrontApplet/Sensors/Sensors.js +9 -2
  247. package/es6/FrontApplet/Sensors/Sensors.js.map +1 -1
  248. package/es6/FrontApplet/Stream/IStream.d.ts +10 -10
  249. package/es6/FrontApplet/Stream/Stream.d.ts +130 -15
  250. package/es6/FrontApplet/Stream/Stream.js +229 -130
  251. package/es6/FrontApplet/Stream/Stream.js.map +1 -1
  252. package/es6/FrontApplet/Stream/StreamProtocol.js.map +1 -1
  253. package/es6/FrontApplet/Sync/Sync.d.ts +152 -6
  254. package/es6/FrontApplet/Sync/Sync.js +196 -112
  255. package/es6/FrontApplet/Sync/Sync.js.map +1 -1
  256. package/es6/FrontApplet/Sync/syncEvents.d.ts +3 -1
  257. package/es6/FrontApplet/Sync/syncMessages.js +1 -1
  258. package/es6/FrontApplet/Sync/syncMessages.js.map +1 -1
  259. package/es6/FrontApplet/Timing/Timing.d.ts +1 -0
  260. package/es6/FrontApplet/Timing/Timing.js +9 -2
  261. package/es6/FrontApplet/Timing/Timing.js.map +1 -1
  262. package/es6/FrontApplet/Timing/Triggers/ITimingTriggersMessage.d.ts +1 -1
  263. package/es6/FrontApplet/Timing/Triggers/Triggers.d.ts +9 -0
  264. package/es6/FrontApplet/Timing/Triggers/Triggers.js +16 -18
  265. package/es6/FrontApplet/Timing/Triggers/Triggers.js.map +1 -1
  266. package/es6/FrontApplet/Touch/Touch.d.ts +3 -0
  267. package/es6/FrontApplet/Touch/Touch.js +13 -3
  268. package/es6/FrontApplet/Touch/Touch.js.map +1 -1
  269. package/es6/FrontApplet/Validate/Validate.js +14 -11
  270. package/es6/FrontApplet/Validate/Validate.js.map +1 -1
  271. package/es6/FrontApplet/Validate/ValidateObjectInterface.js +7 -2
  272. package/es6/FrontApplet/Validate/ValidateObjectInterface.js.map +1 -1
  273. package/es6/FrontApplet/Video/IOptions.d.ts +8 -1
  274. package/es6/FrontApplet/Video/IVideo.d.ts +8 -8
  275. package/es6/FrontApplet/Video/IVideoEvent.js +3 -3
  276. package/es6/FrontApplet/Video/IVideoEvent.js.map +1 -1
  277. package/es6/FrontApplet/Video/Video.d.ts +84 -12
  278. package/es6/FrontApplet/Video/Video.js +161 -102
  279. package/es6/FrontApplet/Video/Video.js.map +1 -1
  280. package/es6/FrontApplet/createFrontApplet.js +5 -2
  281. package/es6/FrontApplet/createFrontApplet.js.map +1 -1
  282. package/es6/Monitoring/Display/handleDisplayRequests.d.ts +2 -2
  283. package/es6/Monitoring/Display/handleDisplayRequests.js +5 -15
  284. package/es6/Monitoring/Display/handleDisplayRequests.js.map +1 -1
  285. package/es6/Monitoring/FileSystem/fileSystemCommands.d.ts +10 -1
  286. package/es6/Monitoring/FileSystem/fileSystemCommands.js +3 -1
  287. package/es6/Monitoring/FileSystem/fileSystemCommands.js.map +1 -1
  288. package/es6/Monitoring/FileSystem/handleFileSystemRequests.d.ts +2 -2
  289. package/es6/Monitoring/FileSystem/handleFileSystemRequests.js +41 -45
  290. package/es6/Monitoring/FileSystem/handleFileSystemRequests.js.map +1 -1
  291. package/es6/Monitoring/Html/handleHtmlSnapshotTakingRequests.d.ts +2 -2
  292. package/es6/Monitoring/Html/handleHtmlSnapshotTakingRequests.js +4 -14
  293. package/es6/Monitoring/Html/handleHtmlSnapshotTakingRequests.js.map +1 -1
  294. package/es6/Monitoring/Management/App/handleApplicationRequests.d.ts +2 -2
  295. package/es6/Monitoring/Management/App/handleApplicationRequests.js +9 -19
  296. package/es6/Monitoring/Management/App/handleApplicationRequests.js.map +1 -1
  297. package/es6/Monitoring/Management/Audio/handleAudioRequests.d.ts +2 -2
  298. package/es6/Monitoring/Management/Audio/handleAudioRequests.js +7 -17
  299. package/es6/Monitoring/Management/Audio/handleAudioRequests.js.map +1 -1
  300. package/es6/Monitoring/Management/AutoRecovery/handleAutoRecoveryRequests.d.ts +2 -2
  301. package/es6/Monitoring/Management/AutoRecovery/handleAutoRecoveryRequests.js +7 -17
  302. package/es6/Monitoring/Management/AutoRecovery/handleAutoRecoveryRequests.js.map +1 -1
  303. package/es6/Monitoring/Management/Debug/handleDebugRequests.d.ts +2 -2
  304. package/es6/Monitoring/Management/Debug/handleDebugRequests.js +9 -19
  305. package/es6/Monitoring/Management/Debug/handleDebugRequests.js.map +1 -1
  306. package/es6/Monitoring/Management/Network/handleManagementNetworkRequests.d.ts +2 -2
  307. package/es6/Monitoring/Management/Network/handleManagementNetworkRequests.js +11 -21
  308. package/es6/Monitoring/Management/Network/handleManagementNetworkRequests.js.map +1 -1
  309. package/es6/Monitoring/Management/Os/managementOsRequests.d.ts +2 -2
  310. package/es6/Monitoring/Management/Os/managementOsRequests.js +9 -19
  311. package/es6/Monitoring/Management/Os/managementOsRequests.js.map +1 -1
  312. package/es6/Monitoring/Management/PeerRecovery/handlePeerRecoveryRequests.d.ts +2 -2
  313. package/es6/Monitoring/Management/PeerRecovery/handlePeerRecoveryRequests.js +7 -17
  314. package/es6/Monitoring/Management/PeerRecovery/handlePeerRecoveryRequests.js.map +1 -1
  315. package/es6/Monitoring/Management/Power/handlePowerRequests.d.ts +2 -2
  316. package/es6/Monitoring/Management/Power/handlePowerRequests.js +19 -29
  317. package/es6/Monitoring/Management/Power/handlePowerRequests.js.map +1 -1
  318. package/es6/Monitoring/Management/RemoteControl/handleRemoteControlRequests.d.ts +2 -2
  319. package/es6/Monitoring/Management/RemoteControl/handleRemoteControlRequests.js +15 -25
  320. package/es6/Monitoring/Management/RemoteControl/handleRemoteControlRequests.js.map +1 -1
  321. package/es6/Monitoring/Management/Screen/handleScreenRequests.d.ts +2 -2
  322. package/es6/Monitoring/Management/Screen/handleScreenRequests.js +19 -29
  323. package/es6/Monitoring/Management/Screen/handleScreenRequests.js.map +1 -1
  324. package/es6/Monitoring/Management/Security/handleSecurityCommands.d.ts +2 -2
  325. package/es6/Monitoring/Management/Security/handleSecurityCommands.js +9 -19
  326. package/es6/Monitoring/Management/Security/handleSecurityCommands.js.map +1 -1
  327. package/es6/Monitoring/Management/Time/handleTimeCommands.d.ts +2 -2
  328. package/es6/Monitoring/Management/Time/handleTimeCommands.js +9 -19
  329. package/es6/Monitoring/Management/Time/handleTimeCommands.js.map +1 -1
  330. package/es6/Monitoring/Management/handleManagementRequests.d.ts +2 -2
  331. package/es6/Monitoring/Management/handleManagementRequests.js +23 -33
  332. package/es6/Monitoring/Management/handleManagementRequests.js.map +1 -1
  333. package/es6/Monitoring/{Montoring.d.ts → Monitoring.d.ts} +1 -0
  334. package/es6/Monitoring/{Montoring.js → Monitoring.js} +12 -23
  335. package/es6/Monitoring/Monitoring.js.map +1 -0
  336. package/es6/Monitoring/NativeCommands/handleNativeCommands.d.ts +2 -2
  337. package/es6/Monitoring/NativeCommands/handleNativeCommands.js +5 -15
  338. package/es6/Monitoring/NativeCommands/handleNativeCommands.js.map +1 -1
  339. package/es6/Monitoring/OSD/handleOsdRequests.d.ts +2 -2
  340. package/es6/Monitoring/OSD/handleOsdRequests.js +5 -15
  341. package/es6/Monitoring/OSD/handleOsdRequests.js.map +1 -1
  342. package/es6/Monitoring/Offline/Cache/handleOfflineCacheRequests.d.ts +2 -2
  343. package/es6/Monitoring/Offline/Cache/handleOfflineCacheRequests.js +23 -33
  344. package/es6/Monitoring/Offline/Cache/handleOfflineCacheRequests.js.map +1 -1
  345. package/es6/Monitoring/Video/handleVideoRequests.d.ts +2 -2
  346. package/es6/Monitoring/Video/handleVideoRequests.js +36 -9
  347. package/es6/Monitoring/Video/handleVideoRequests.js.map +1 -1
  348. package/es6/Monitoring/handleMonitoringRequests.d.ts +2 -2
  349. package/es6/Monitoring/handleMonitoringRequests.js +6 -16
  350. package/es6/Monitoring/handleMonitoringRequests.js.map +1 -1
  351. package/es6/Sensors/IButton.js +1 -1
  352. package/es6/Sensors/IButton.js.map +1 -1
  353. package/es6/Sensors/IRfidAntenna.js +1 -1
  354. package/es6/Sensors/IRfidAntenna.js.map +1 -1
  355. package/es6/Util/Console/enhancer.js +1 -2
  356. package/es6/Util/Console/enhancer.js.map +1 -1
  357. package/es6/bundle.d.ts +1 -1
  358. package/es6/bundle.js +6 -3
  359. package/es6/bundle.js.map +1 -1
  360. package/es6/fpath.js +34 -1
  361. package/es6/fpath.js.map +1 -1
  362. package/es6/utils/types.d.ts +1 -0
  363. package/es6/{FrontApplet/Input/IKeyUpEventListener.js → utils/types.js} +1 -1
  364. package/es6/utils/types.js.map +1 -0
  365. package/package.json +27 -25
  366. package/CHANGELOG.md +0 -484
  367. package/docs/applet-basics.md +0 -272
  368. package/docs/content/js-applet-resources.md +0 -154
  369. package/docs/content/js-browser.md +0 -163
  370. package/docs/content/js-command.md +0 -154
  371. package/docs/content/js-debug.md +0 -36
  372. package/docs/content/js-device-info.md +0 -56
  373. package/docs/content/js-display.md +0 -56
  374. package/docs/content/js-file-system.md +0 -670
  375. package/docs/content/js-fonts.md +0 -115
  376. package/docs/content/js-hardware.md +0 -55
  377. package/docs/content/js-iframes.md +0 -66
  378. package/docs/content/js-input.md +0 -71
  379. package/docs/content/js-offline-cache-media-files.md +0 -257
  380. package/docs/content/js-offline-cache-simple-data.md +0 -129
  381. package/docs/content/js-osd.md +0 -32
  382. package/docs/content/js-proof-of-play.md +0 -60
  383. package/docs/content/js-sensors.md +0 -70
  384. package/docs/content/js-serial.md +0 -165
  385. package/docs/content/js-sync-playback.md +0 -384
  386. package/docs/content/js-video-inputs-internal-ports.md +0 -131
  387. package/docs/content/js-video-stream.md +0 -618
  388. package/docs/content/js-video.md +0 -232
  389. package/docs/management/js-management-application.md +0 -107
  390. package/docs/management/js-management-audio.md +0 -44
  391. package/docs/management/js-management-debug.md +0 -40
  392. package/docs/management/js-management-firmware.md +0 -93
  393. package/docs/management/js-management-management.md +0 -178
  394. package/docs/management/js-management-monitoring-commands.md +0 -107
  395. package/docs/management/js-management-monitors.md +0 -55
  396. package/docs/management/js-management-native-commands-mdc.md +0 -90
  397. package/docs/management/js-management-network.md +0 -223
  398. package/docs/management/js-management-os.md +0 -62
  399. package/docs/management/js-management-package.md +0 -48
  400. package/docs/management/js-management-power.md +0 -175
  401. package/docs/management/js-management-proxy.md +0 -81
  402. package/docs/management/js-management-remote-control.md +0 -58
  403. package/docs/management/js-management-screen.md +0 -225
  404. package/docs/management/js-management-security.md +0 -71
  405. package/docs/management/js-management-time.md +0 -161
  406. package/docs/management/js-management-wifi.md +0 -341
  407. package/es6/FrontApplet/Command/ICommandEventListener.d.ts +0 -6
  408. package/es6/FrontApplet/Command/ICommandEventListener.js +0 -3
  409. package/es6/FrontApplet/Command/ICommandEventListener.js.map +0 -1
  410. package/es6/FrontApplet/Input/IKeyUpEventListener.d.ts +0 -5
  411. package/es6/FrontApplet/Input/IKeyUpEventListener.js.map +0 -1
  412. package/es6/FrontApplet/Management/Firmware/FirmwareType.d.ts +0 -4
  413. package/es6/FrontApplet/Management/Firmware/FirmwareType.js +0 -9
  414. package/es6/FrontApplet/Management/Firmware/FirmwareType.js.map +0 -1
  415. package/es6/FrontApplet/Stream/streamListeners.d.ts +0 -10
  416. package/es6/FrontApplet/Stream/streamListeners.js.map +0 -1
  417. package/es6/FrontApplet/Video/IVideoEventListener.d.ts +0 -5
  418. package/es6/FrontApplet/Video/IVideoEventListener.js +0 -3
  419. package/es6/FrontApplet/Video/IVideoEventListener.js.map +0 -1
  420. package/es6/Monitoring/Montoring.js.map +0 -1
@@ -1,56 +1,80 @@
1
1
  "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ /**
4
+ * The `sos.management.remoteControl` groups together methods for enabling or disabling control of the device using IR remote controller (TV controller).
5
+ */
12
6
  class RemoteControl {
7
+ messagePrefix;
8
+ postMessage;
9
+ /** @internal */
13
10
  constructor(messagePrefix, postMessage) {
14
11
  this.messagePrefix = messagePrefix;
15
12
  this.postMessage = postMessage;
16
13
  }
17
- enable() {
18
- return __awaiter(this, void 0, void 0, function* () {
19
- yield this.setEnabled(true);
20
- });
14
+ /**
15
+ * The `enable()` method enables remote control.
16
+ *
17
+ * :::warning
18
+ *
19
+ * **Android:** In order to prevent Android from displaying Android homepage and thus not showing your content, you
20
+ * must Enable Kiosk Mode (or Lock Remote Control) either through Box device settings or through API.
21
+ *
22
+ * Always set the Remote Control Lock to `enable` after the deployment.
23
+ *
24
+ * :::
25
+ *
26
+ * @since 3.0.0
27
+ */
28
+ async enable() {
29
+ await this.setEnabled(true);
21
30
  }
22
- disable() {
23
- return __awaiter(this, void 0, void 0, function* () {
24
- yield this.setEnabled(false);
25
- });
31
+ /**
32
+ * The `disable()` method disables remote control.
33
+ *
34
+ * @since 3.0.0
35
+ */
36
+ async disable() {
37
+ await this.setEnabled(false);
26
38
  }
27
- isEnabled() {
28
- return __awaiter(this, void 0, void 0, function* () {
29
- const { isRemoteControlEnabled } = yield this.postMessage({
30
- type: this.getMessage('get_is_remote_control_enabled'),
31
- });
32
- return isRemoteControlEnabled;
39
+ /**
40
+ * The `isEnabled()` method returns whether the remote control is enabled.
41
+ *
42
+ * @since 4.0.0
43
+ */
44
+ async isEnabled() {
45
+ const { isRemoteControlEnabled } = await this.postMessage({
46
+ type: this.getMessage('get_is_remote_control_enabled'),
33
47
  });
48
+ return isRemoteControlEnabled;
34
49
  }
35
- lock() {
36
- return __awaiter(this, void 0, void 0, function* () {
37
- yield this.disable();
38
- });
50
+ /**
51
+ * The `lock()` method is an alias for the `disable()` method.
52
+ *
53
+ * @since 4.0.0
54
+ */
55
+ async lock() {
56
+ await this.disable();
39
57
  }
40
- unlock() {
41
- return __awaiter(this, void 0, void 0, function* () {
42
- yield this.enable();
43
- });
58
+ /**
59
+ * The `unlock()` method is an alias for the `enable()` method.
60
+ *
61
+ * @since 4.0.0
62
+ */
63
+ async unlock() {
64
+ await this.enable();
44
65
  }
45
- isLocked() {
46
- return this.isEnabled();
66
+ /**
67
+ * The `isLocked()` method returns whether the remote control is locked (disabled).
68
+ *
69
+ * @since 4.0.0
70
+ */
71
+ async isLocked() {
72
+ return !(await this.isEnabled());
47
73
  }
48
- setEnabled(enabled) {
49
- return __awaiter(this, void 0, void 0, function* () {
50
- yield this.postMessage({
51
- type: this.getMessage('set_remote_control_enabled'),
52
- enabled,
53
- });
74
+ async setEnabled(enabled) {
75
+ await this.postMessage({
76
+ type: this.getMessage('set_remote_control_enabled'),
77
+ enabled,
54
78
  });
55
79
  }
56
80
  getMessage(name) {
@@ -1 +1 @@
1
- {"version":3,"file":"RemoteControl.js","sourceRoot":"","sources":["../../../../src/FrontApplet/Management/RemoteControl/RemoteControl.ts"],"names":[],"mappings":";;;;;;;;;;;AAGA,MAAqB,aAAa;IACjC,YACS,aAAqB,EACrB,WAA8B;QAD9B,kBAAa,GAAb,aAAa,CAAQ;QACrB,gBAAW,GAAX,WAAW,CAAmB;IACpC,CAAC;IAES,MAAM;;YAClB,MAAM,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;QAC7B,CAAC;KAAA;IAEY,OAAO;;YACnB,MAAM,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC;QAC9B,CAAC;KAAA;IAEY,SAAS;;YACrB,MAAM,EAAE,sBAAsB,EAAE,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC;gBACzD,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,+BAA+B,CAAC;aACtD,CAAC,CAAC;YAEH,OAAO,sBAAsB,CAAC;QAC/B,CAAC;KAAA;IAEY,IAAI;;YAChB,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;QACtB,CAAC;KAAA;IAEY,MAAM;;YAClB,MAAM,IAAI,CAAC,MAAM,EAAE,CAAC;QACrB,CAAC;KAAA;IAEM,QAAQ;QACd,OAAO,IAAI,CAAC,SAAS,EAAE,CAAC;IACzB,CAAC;IAEa,UAAU,CAAC,OAAgB;;YACxC,MAAM,IAAI,CAAC,WAAW,CAAC;gBACtB,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,4BAA4B,CAAC;gBACnD,OAAO;aACP,CAAC,CAAC;QACJ,CAAC;KAAA;IAEO,UAAU,CAAC,IAAY;QAC9B,OAAO,IAAI,CAAC,aAAa,GAAG,GAAG,GAAG,IAAI,CAAC;IACxC,CAAC;CACD;AA5CD,gCA4CC"}
1
+ {"version":3,"file":"RemoteControl.js","sourceRoot":"","sources":["../../../../src/FrontApplet/Management/RemoteControl/RemoteControl.ts"],"names":[],"mappings":";;AAGA;;GAEG;AACH,MAAqB,aAAa;IAGxB;IACA;IAHT,gBAAgB;IAChB,YACS,aAAqB,EACrB,WAA8B;QAD9B,kBAAa,GAAb,aAAa,CAAQ;QACrB,gBAAW,GAAX,WAAW,CAAmB;IACpC,CAAC;IAEJ;;;;;;;;;;;;;OAaG;IACI,KAAK,CAAC,MAAM;QAClB,MAAM,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;IAC7B,CAAC;IAED;;;;OAIG;IACI,KAAK,CAAC,OAAO;QACnB,MAAM,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,CAAC;IAC9B,CAAC;IAED;;;;OAIG;IACI,KAAK,CAAC,SAAS;QACrB,MAAM,EAAE,sBAAsB,EAAE,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC;YACzD,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,+BAA+B,CAAC;SACtD,CAAC,CAAC;QAEH,OAAO,sBAAsB,CAAC;IAC/B,CAAC;IAED;;;;OAIG;IACI,KAAK,CAAC,IAAI;QAChB,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;IACtB,CAAC;IAED;;;;OAIG;IACI,KAAK,CAAC,MAAM;QAClB,MAAM,IAAI,CAAC,MAAM,EAAE,CAAC;IACrB,CAAC;IAED;;;;OAIG;IACI,KAAK,CAAC,QAAQ;QACpB,OAAO,CAAC,CAAC,MAAM,IAAI,CAAC,SAAS,EAAE,CAAC,CAAC;IAClC,CAAC;IAEO,KAAK,CAAC,UAAU,CAAC,OAAgB;QACxC,MAAM,IAAI,CAAC,WAAW,CAAC;YACtB,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,4BAA4B,CAAC;YACnD,OAAO;SACP,CAAC,CAAC;IACJ,CAAC;IAEO,UAAU,CAAC,IAAY;QAC9B,OAAO,IAAI,CAAC,aAAa,GAAG,GAAG,GAAG,IAAI,CAAC;IACxC,CAAC;CACD;AApFD,gCAoFC"}
@@ -2,17 +2,144 @@ import IPostMessage from '../../IPostMessage';
2
2
  import IBrightness from './IBrightness';
3
3
  import IOrientation from './IOrientation';
4
4
  import IScreen from './IScreen';
5
+ /**
6
+ * The `sos.management.screen` API groups together methods for controlling the screen of the device. It allows to manipulate the screen
7
+ * resolution or orientation, set brightness, retrieve the current brightness of the display and manipulate the power mode.
8
+ *
9
+ * :::warning
10
+ *
11
+ * This method only turns on/off the display/backlight. It will **not** set any power-saving mode. We also strongly recommend to reboot any
12
+ * device once a day.
13
+ *
14
+ * :::
15
+ *
16
+ * :::info
17
+ *
18
+ * There is a specific behavior based on the device type you operate:
19
+ * **On SoC displays** (e.g. Samsung Tizen, LG webOS, Android-based SoC displays from Sony, Vestel Philips,...)
20
+ * - `powerOn()` and `powerOff()` are turning the display backlight and the panel off
21
+ *
22
+ * **On external media players** (e.g. BrightSign, Windows PC, Android players, Raspberry Pi)
23
+ * - `powerOn()` and `powerOff()` are turning off the video output (typically HDMI-out); the connected display backlight is not managed by this functionality and needs to be controlled via RS232 or another way.
24
+ *
25
+ * :::
26
+ */
5
27
  export default class Screen implements IScreen {
6
28
  private messagePrefix;
7
29
  private postMessage;
30
+ /** @internal */
8
31
  constructor(messagePrefix: string, postMessage: IPostMessage<any>);
32
+ /**
33
+ * The `resize()` method changes resolution and orientation of the display.
34
+ *
35
+ * :::info
36
+ *
37
+ * For Tizen, you have to provide `baseUrl` which points to the Core App for Tizen which will be downloaded to the device [Read more how to upload your Core Apps here.](https://docs.signageos.io/hc/en-us/articles/4405245195666).
38
+ *
39
+ * :::
40
+ *
41
+ * @param baseUrl SSSP & Tizen devices requires to install a orientation-specific Core App if you want to switch orientation to portrait or landscape.
42
+ * @param orientation Screen orientation
43
+ * @param resolution Where it applies (mainly SSSP 2/3)
44
+ * @param currentVersion Core App version
45
+ * @param videoOrientation If the video has different orientation than the HTML5 content
46
+ *
47
+ * @since 3.0.0
48
+ *
49
+ * @example
50
+ * // for Tizen
51
+ * await sos.management.screen.resize(
52
+ * "https://cdn.your-cms.com/tizen/1.0.4",
53
+ * "PORTRAIT",
54
+ * "FULL_READY",
55
+ * "1.0.4"
56
+ * );
57
+ *
58
+ * // for all other supported device
59
+ * await sos.management.screen.resize(
60
+ * "",
61
+ * "PORTRAIT",
62
+ * "HD_READY",
63
+ * ""
64
+ * );
65
+ *
66
+ * @example // {@link https://github.com/signageos/applet-examples/blob/master/examples/management-js-api/resize/ |How to resize screen on device}
67
+ */
9
68
  resize(baseUrl: string, orientation: string, resolution: string, currentVersion: string, videoOrientation?: string): Promise<void>;
69
+ /**
70
+ * The `getOrientation()` method returns the current orientation of the screen.
71
+ *
72
+ * @since 4.7.0
73
+ */
10
74
  getOrientation(): Promise<IOrientation>;
75
+ /**
76
+ * The `setBrightness()` method sets the brightness of the screen. It supports 2 different brightness values for 2 time points in the day.
77
+ *
78
+ * @param timeFrom1 Time in the XX:XX format
79
+ * @param brightness1 Brightness value between 0 and 100
80
+ * @param timeFrom2 Time in the XX:XX format
81
+ * @param brightness2 Brightness value between 0 and 100
82
+ *
83
+ * @since 3.0.0
84
+ *
85
+ * @example
86
+ * await sos.management.screen.setBrightness(
87
+ * '00:00',
88
+ * '10',
89
+ * '17:00',
90
+ * '30'
91
+ * );
92
+ */
11
93
  setBrightness(timeFrom1: string, brightness1: number, timeFrom2: string, brightness2: number): Promise<void>;
94
+ /**
95
+ * The `getBrightness()` method returns information about the currently set brightness values.
96
+ *
97
+ * @since 3.0.0
98
+ */
12
99
  getBrightness(): Promise<IBrightness>;
100
+ /**
101
+ * The `takeAndUploadScreenshot()` method takes a screenshot and uploads it to a specified url. This can be either a signageOS upload url
102
+ * (`https://upload.signageos.io`) or a dedicated server url for uploading screenshots. Format in which the screenshot is uploaded may be
103
+ * different for every platform.
104
+ *
105
+ * To implement a custom screenshot upload server, it needs to implement these endpoints:
106
+ * - POST `/upload/file?prefix=screenshot/` - Endpoint for receiving screenshot using form data, with the image set to the `file` field.
107
+ * - POST `/upload/raw?prefix=screenshot/` - Endpoint for receiving screenshots as a raw data.
108
+ * - POST `/upload/image-data-uri?prefix=screenshot/` - Endpoint for receiving screenshots encoded as a data url.
109
+ *
110
+ * signageOS provides standalone server which is implements all of those methods. It is provided to all of our partners through the
111
+ * [support ticketing system](https://box.signageos.io/support/).
112
+ *
113
+ * @since 3.0.0
114
+ */
13
115
  takeAndUploadScreenshot(uploadBaseUrl: string): Promise<string>;
116
+ /**
117
+ * The `powerOn()` method turns the screen on.
118
+ *
119
+ *
120
+ * @since 3.0.0
121
+ */
14
122
  powerOn(): Promise<void>;
123
+ /**
124
+ * The `powerOff()` method turn the screen off.
125
+ *
126
+ * :::warning
127
+ *
128
+ * On Android devices, `powerOff()` also shuts down the webview and the Applet. It's default Android behavior that cannot be changed. Once
129
+ * the Applet is off, you cannot call `powerOn()` to resume the playback.
130
+ *
131
+ * To manage the display On/Off state, use [REST API Power Actions](https://developers.signageos.io/api/#tag/DevicePower-Actions) instead.
132
+ *
133
+ * :::
134
+ *
135
+ * @since 3.0.0
136
+ */
15
137
  powerOff(): Promise<void>;
138
+ /**
139
+ * The `isPoweredOn()` method returns whether the screen is on.
140
+ *
141
+ * @since 3.0.0
142
+ */
16
143
  isPoweredOn(): Promise<boolean>;
17
144
  private getMessage;
18
145
  private getMessagePrefix;
@@ -1,117 +1,225 @@
1
1
  "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
10
4
  };
11
5
  Object.defineProperty(exports, "__esModule", { value: true });
12
6
  const DeviceHelper_1 = require("../helpers/DeviceHelper");
13
7
  const VideoHelper_1 = require("../helpers/VideoHelper");
14
- const Validate_1 = require("../../Validate/Validate");
8
+ const Validate_1 = __importDefault(require("../../Validate/Validate"));
9
+ // TODO: how does this work if there are multiple displays
10
+ /**
11
+ * The `sos.management.screen` API groups together methods for controlling the screen of the device. It allows to manipulate the screen
12
+ * resolution or orientation, set brightness, retrieve the current brightness of the display and manipulate the power mode.
13
+ *
14
+ * :::warning
15
+ *
16
+ * This method only turns on/off the display/backlight. It will **not** set any power-saving mode. We also strongly recommend to reboot any
17
+ * device once a day.
18
+ *
19
+ * :::
20
+ *
21
+ * :::info
22
+ *
23
+ * There is a specific behavior based on the device type you operate:
24
+ * **On SoC displays** (e.g. Samsung Tizen, LG webOS, Android-based SoC displays from Sony, Vestel Philips,...)
25
+ * - `powerOn()` and `powerOff()` are turning the display backlight and the panel off
26
+ *
27
+ * **On external media players** (e.g. BrightSign, Windows PC, Android players, Raspberry Pi)
28
+ * - `powerOn()` and `powerOff()` are turning off the video output (typically HDMI-out); the connected display backlight is not managed by this functionality and needs to be controlled via RS232 or another way.
29
+ *
30
+ * :::
31
+ */
15
32
  class Screen {
33
+ messagePrefix;
34
+ postMessage;
35
+ /** @internal */
16
36
  constructor(messagePrefix, postMessage) {
17
37
  this.messagePrefix = messagePrefix;
18
38
  this.postMessage = postMessage;
19
39
  }
20
- resize(baseUrl, orientation, resolution, currentVersion, videoOrientation) {
21
- return __awaiter(this, void 0, void 0, function* () {
22
- (0, Validate_1.default)({ baseUrl }).required().uri();
23
- (0, Validate_1.default)({ currentVersion }).required().string();
24
- if (typeof DeviceHelper_1.Orientation[orientation] === 'undefined') {
25
- throw new Error('Invalid orientation');
26
- }
27
- if (typeof DeviceHelper_1.Resolution[resolution] === 'undefined') {
28
- throw new Error('Invalid resolution');
29
- }
30
- if (videoOrientation && typeof VideoHelper_1.Orientation[videoOrientation] === 'undefined') {
31
- throw new Error('Invalid video orientation');
32
- }
33
- yield this.postMessage({
34
- type: this.getMessage('resize_screen'),
35
- baseUrl,
36
- orientation,
37
- resolution,
38
- currentVersion,
39
- videoOrientation,
40
- });
40
+ /**
41
+ * The `resize()` method changes resolution and orientation of the display.
42
+ *
43
+ * :::info
44
+ *
45
+ * For Tizen, you have to provide `baseUrl` which points to the Core App for Tizen which will be downloaded to the device [Read more how to upload your Core Apps here.](https://docs.signageos.io/hc/en-us/articles/4405245195666).
46
+ *
47
+ * :::
48
+ *
49
+ * @param baseUrl SSSP & Tizen devices requires to install a orientation-specific Core App if you want to switch orientation to portrait or landscape.
50
+ * @param orientation Screen orientation
51
+ * @param resolution Where it applies (mainly SSSP 2/3)
52
+ * @param currentVersion Core App version
53
+ * @param videoOrientation If the video has different orientation than the HTML5 content
54
+ *
55
+ * @since 3.0.0
56
+ *
57
+ * @example
58
+ * // for Tizen
59
+ * await sos.management.screen.resize(
60
+ * "https://cdn.your-cms.com/tizen/1.0.4",
61
+ * "PORTRAIT",
62
+ * "FULL_READY",
63
+ * "1.0.4"
64
+ * );
65
+ *
66
+ * // for all other supported device
67
+ * await sos.management.screen.resize(
68
+ * "",
69
+ * "PORTRAIT",
70
+ * "HD_READY",
71
+ * ""
72
+ * );
73
+ *
74
+ * @example // {@link https://github.com/signageos/applet-examples/blob/master/examples/management-js-api/resize/ |How to resize screen on device}
75
+ */
76
+ async resize(baseUrl, orientation, resolution, currentVersion, videoOrientation) {
77
+ (0, Validate_1.default)({ baseUrl }).required().uri();
78
+ (0, Validate_1.default)({ currentVersion }).required().string();
79
+ if (typeof DeviceHelper_1.Orientation[orientation] === 'undefined') {
80
+ throw new Error('Invalid orientation');
81
+ }
82
+ if (typeof DeviceHelper_1.Resolution[resolution] === 'undefined') {
83
+ throw new Error('Invalid resolution');
84
+ }
85
+ if (videoOrientation && typeof VideoHelper_1.Orientation[videoOrientation] === 'undefined') {
86
+ throw new Error('Invalid video orientation');
87
+ }
88
+ await this.postMessage({
89
+ type: this.getMessage('resize_screen'),
90
+ baseUrl,
91
+ orientation,
92
+ resolution,
93
+ currentVersion,
94
+ videoOrientation,
41
95
  });
42
96
  }
43
- getOrientation() {
44
- return __awaiter(this, void 0, void 0, function* () {
45
- const { screenOrientation } = yield this.postMessage({
46
- type: this.getMessage('get_screen_orientation'),
47
- });
48
- return screenOrientation;
97
+ /**
98
+ * The `getOrientation()` method returns the current orientation of the screen.
99
+ *
100
+ * @since 4.7.0
101
+ */
102
+ async getOrientation() {
103
+ const { screenOrientation } = await this.postMessage({
104
+ type: this.getMessage('get_screen_orientation'),
49
105
  });
106
+ return screenOrientation;
50
107
  }
51
- setBrightness(timeFrom1, brightness1, timeFrom2, brightness2) {
52
- return __awaiter(this, void 0, void 0, function* () {
53
- (0, Validate_1.default)({ brightness1 }).required().number().min(0).max(100);
54
- (0, Validate_1.default)({ brightness2 }).required().number().min(0).max(100);
55
- (0, Validate_1.default)({ timeFrom1 })
56
- .canBeNull()
57
- .required()
58
- .string()
59
- .matchRegExp(/\d{2}:\d{2}/)
60
- .timerTime();
61
- (0, Validate_1.default)({ timeFrom2 })
62
- .canBeNull()
63
- .required()
64
- .string()
65
- .matchRegExp(/\d{2}:\d{2}/)
66
- .timerTime();
67
- yield this.postMessage({
68
- type: this.getMessage('set_screen_brightness'),
69
- timeFrom1,
70
- brightness1,
71
- timeFrom2,
72
- brightness2,
73
- });
108
+ /**
109
+ * The `setBrightness()` method sets the brightness of the screen. It supports 2 different brightness values for 2 time points in the day.
110
+ *
111
+ * @param timeFrom1 Time in the XX:XX format
112
+ * @param brightness1 Brightness value between 0 and 100
113
+ * @param timeFrom2 Time in the XX:XX format
114
+ * @param brightness2 Brightness value between 0 and 100
115
+ *
116
+ * @since 3.0.0
117
+ *
118
+ * @example
119
+ * await sos.management.screen.setBrightness(
120
+ * '00:00',
121
+ * '10',
122
+ * '17:00',
123
+ * '30'
124
+ * );
125
+ */
126
+ async setBrightness(timeFrom1, brightness1, timeFrom2, brightness2) {
127
+ (0, Validate_1.default)({ brightness1 }).required().number().min(0).max(100);
128
+ (0, Validate_1.default)({ brightness2 }).required().number().min(0).max(100);
129
+ (0, Validate_1.default)({ timeFrom1 })
130
+ .canBeNull()
131
+ .required()
132
+ .string()
133
+ .matchRegExp(/\d{2}:\d{2}/)
134
+ .timerTime();
135
+ (0, Validate_1.default)({ timeFrom2 })
136
+ .canBeNull()
137
+ .required()
138
+ .string()
139
+ .matchRegExp(/\d{2}:\d{2}/)
140
+ .timerTime();
141
+ await this.postMessage({
142
+ type: this.getMessage('set_screen_brightness'),
143
+ timeFrom1,
144
+ brightness1,
145
+ timeFrom2,
146
+ brightness2,
74
147
  });
75
148
  }
76
- getBrightness() {
77
- return __awaiter(this, void 0, void 0, function* () {
78
- const { screenBrightness } = yield this.postMessage({
79
- type: this.getMessage('get_screen_brightness'),
80
- });
81
- return screenBrightness;
149
+ /**
150
+ * The `getBrightness()` method returns information about the currently set brightness values.
151
+ *
152
+ * @since 3.0.0
153
+ */
154
+ async getBrightness() {
155
+ const { screenBrightness } = await this.postMessage({
156
+ type: this.getMessage('get_screen_brightness'),
82
157
  });
158
+ return screenBrightness;
83
159
  }
84
- takeAndUploadScreenshot(uploadBaseUrl) {
85
- return __awaiter(this, void 0, void 0, function* () {
86
- (0, Validate_1.default)({ uploadBaseUrl }).required().uri();
87
- const { screenshotUrl } = yield this.postMessage({
88
- type: this.getMessage('upload_screenshot'),
89
- uploadBaseUrl,
90
- });
91
- return screenshotUrl;
160
+ /**
161
+ * The `takeAndUploadScreenshot()` method takes a screenshot and uploads it to a specified url. This can be either a signageOS upload url
162
+ * (`https://upload.signageos.io`) or a dedicated server url for uploading screenshots. Format in which the screenshot is uploaded may be
163
+ * different for every platform.
164
+ *
165
+ * To implement a custom screenshot upload server, it needs to implement these endpoints:
166
+ * - POST `/upload/file?prefix=screenshot/` - Endpoint for receiving screenshot using form data, with the image set to the `file` field.
167
+ * - POST `/upload/raw?prefix=screenshot/` - Endpoint for receiving screenshots as a raw data.
168
+ * - POST `/upload/image-data-uri?prefix=screenshot/` - Endpoint for receiving screenshots encoded as a data url.
169
+ *
170
+ * signageOS provides standalone server which is implements all of those methods. It is provided to all of our partners through the
171
+ * [support ticketing system](https://box.signageos.io/support/).
172
+ *
173
+ * @since 3.0.0
174
+ */
175
+ async takeAndUploadScreenshot(uploadBaseUrl) {
176
+ (0, Validate_1.default)({ uploadBaseUrl }).required().uri();
177
+ const { screenshotUrl } = await this.postMessage({
178
+ type: this.getMessage('upload_screenshot'),
179
+ uploadBaseUrl,
92
180
  });
181
+ return screenshotUrl;
93
182
  }
94
- powerOn() {
95
- return __awaiter(this, void 0, void 0, function* () {
96
- yield this.postMessage({
97
- type: this.getMessage('power_on_display'),
98
- });
183
+ /**
184
+ * The `powerOn()` method turns the screen on.
185
+ *
186
+ *
187
+ * @since 3.0.0
188
+ */
189
+ async powerOn() {
190
+ await this.postMessage({
191
+ type: this.getMessage('power_on_display'),
99
192
  });
100
193
  }
101
- powerOff() {
102
- return __awaiter(this, void 0, void 0, function* () {
103
- yield this.postMessage({
104
- type: this.getMessage('power_off_display'),
105
- });
194
+ /**
195
+ * The `powerOff()` method turn the screen off.
196
+ *
197
+ * :::warning
198
+ *
199
+ * On Android devices, `powerOff()` also shuts down the webview and the Applet. It's default Android behavior that cannot be changed. Once
200
+ * the Applet is off, you cannot call `powerOn()` to resume the playback.
201
+ *
202
+ * To manage the display On/Off state, use [REST API Power Actions](https://developers.signageos.io/api/#tag/DevicePower-Actions) instead.
203
+ *
204
+ * :::
205
+ *
206
+ * @since 3.0.0
207
+ */
208
+ async powerOff() {
209
+ await this.postMessage({
210
+ type: this.getMessage('power_off_display'),
106
211
  });
107
212
  }
108
- isPoweredOn() {
109
- return __awaiter(this, void 0, void 0, function* () {
110
- const { isDisplayPowerOn } = yield this.postMessage({
111
- type: this.getMessage('get_is_display_power_on'),
112
- });
113
- return isDisplayPowerOn;
213
+ /**
214
+ * The `isPoweredOn()` method returns whether the screen is on.
215
+ *
216
+ * @since 3.0.0
217
+ */
218
+ async isPoweredOn() {
219
+ const { isDisplayPowerOn } = await this.postMessage({
220
+ type: this.getMessage('get_is_display_power_on'),
114
221
  });
222
+ return isDisplayPowerOn;
115
223
  }
116
224
  getMessage(name) {
117
225
  return this.getMessagePrefix() + '.' + name;
@@ -1 +1 @@
1
- {"version":3,"file":"Screen.js","sourceRoot":"","sources":["../../../../src/FrontApplet/Management/Screen/Screen.ts"],"names":[],"mappings":";;;;;;;;;;;AAGA,0DAAkE;AAClE,wDAAyE;AACzE,sDAA+C;AAG/C,MAAqB,MAAM;IAC1B,YACS,aAAqB,EACrB,WAA8B;QAD9B,kBAAa,GAAb,aAAa,CAAQ;QACrB,gBAAW,GAAX,WAAW,CAAmB;IACpC,CAAC;IAES,MAAM,CAClB,OAAe,EACf,WAAmB,EACnB,UAAkB,EAClB,cAAsB,EACtB,gBAAyB;;YAEzB,IAAA,kBAAQ,EAAC,EAAE,OAAO,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,CAAC;YACvC,IAAA,kBAAQ,EAAC,EAAE,cAAc,EAAE,CA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,CAAC;SAC1C,CAAC,CAAC;IACJ,CAAC;IAED;;;;OAIG;IACI,KAAK,CAAC,WAAW;QACvB,MAAM,EAAE,gBAAgB,EAAE,GAAG,MAAM,IAAI,CAAC,WAAW,CAAC;YACnD,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,yBAAyB,CAAC;SAChD,CAAC,CAAC;QAEH,OAAO,gBAAgB,CAAC;IACzB,CAAC;IAEO,UAAU,CAAC,IAAY;QAC9B,OAAO,IAAI,CAAC,gBAAgB,EAAE,GAAG,GAAG,GAAG,IAAI,CAAC;IAC7C,CAAC;IAEO,gBAAgB;QACvB,OAAO,IAAI,CAAC,aAAa,CAAC;IAC3B,CAAC;CACD;AA1ND,yBA0NC"}
@@ -1,21 +1,36 @@
1
1
  import IPostMessage from '../../IPostMessage';
2
2
  import ISecurity from './ISecurity';
3
+ /**
4
+ * The `sos.management.security` API groups together methods for management of a security PIN code of the device.
5
+ */
3
6
  export default class Security implements ISecurity {
4
7
  private messagePrefix;
5
8
  private postMessage;
9
+ /** @internal */
6
10
  constructor(messagePrefix: string, postMessage: IPostMessage<any>);
7
11
  /**
8
- * Get PIN code
9
- * @returns 4 digits number string
12
+ * The `getPinCode()` method returns the currently set PIN code.
13
+ *
14
+ * @throws {AppletSecurityError} **41703**: Get PIN code failed because the PIN code has not been set yet.
15
+ *
16
+ * @since 4.1.0
10
17
  */
11
18
  getPinCode(): Promise<string>;
12
19
  /**
13
- * Set PIN code
14
- * @param pinCode 4 digits number string
20
+ * The `setPinCode()` method sets the pin code.
21
+ *
22
+ * @param pinCode The PIN code to be set.
23
+ *
24
+ * @throws {AppletSecurityError} **41701**: Invalid PIN code format (has to be 4-digits string).
25
+ * @throws {AppletSecurityError} **41702**: PIN code 0000 is not allowed, use another PIN code.
26
+ *
27
+ * @since 4.1.0
15
28
  */
16
29
  setPinCode(pinCode: string): Promise<void>;
17
30
  /**
18
- * Generate 4 digits number string and set it as PIN code
31
+ * The `getPinCode()` method sets the PIN code to a randomly generated one.
32
+ *
33
+ * @since 4.1.0
19
34
  */
20
35
  generateRandomPinCode(): Promise<void>;
21
36
  private getMessage;