@xibosignage/xibo-layout-renderer 1.0.0 → 1.0.2

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.
@@ -712,6 +712,9 @@ function composeResourceUrl(options, params) {
712
712
  var serverKey = options && ((_options$config3 = options.config) === null || _options$config3 === void 0 ? void 0 : _options$config3.cmsKey);
713
713
  return '/pwa/getResource' + '?v=' + schemaVersion + '&serverKey=' + serverKey + '&hardwareKey=' + hardwareKey + '&layoutId=' + params.layoutId + '&regionId=' + params.regionId + '&mediaId=' + params.mediaId;
714
714
  }
715
+ function composeVideoUrl(params) {
716
+ return '/xmds.php?file=' + params.uri;
717
+ }
715
718
  function composeBgUrlByPlatform(platform, params) {
716
719
  var bgImageUrl = params.layoutBackgroundDownloadUrl.replace(":id", params.layout.id) + '?preview=1&width=' + params.layout.sWidth + '&height=' + params.layout.sHeight + '&dynamic&proportional=0';
717
720
  if (platform === 'chromeOS') {
@@ -1285,6 +1288,9 @@ function Media(region, mediaId, xml, options, xlr) {
1285
1288
  tmpUrl = composeResourceUrlByPlatform(xlr.config, resourceUrlParams);
1286
1289
  } else if (xlr.config.platform === 'chromeOS') {
1287
1290
  tmpUrl = composeResourceUrl(xlr.config, resourceUrlParams);
1291
+ if (self.mediaType === 'video') {
1292
+ tmpUrl = composeVideoUrl(resourceUrlParams);
1293
+ }
1288
1294
  }
1289
1295
  self.url = tmpUrl;
1290
1296
  // Loop if media has loop, or if region has loop and a single media
@@ -2070,7 +2076,9 @@ function Layout(data, options, xlr, layout) {
2070
2076
  $screen && $screen.appendChild($layout);
2071
2077
  if ($layout) {
2072
2078
  $layout.style.display = 'none';
2073
- $layout.style.outline = 'red solid thin';
2079
+ if (xlr.config.platform === 'CMS') {
2080
+ $layout.style.outline = 'red solid thin';
2081
+ }
2074
2082
  }
2075
2083
  layout.layoutNode = props.data;
2076
2084
  /* Calculate the screen size */