promethee 1.6.56 → 1.6.57

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 790e194d9821d04c836ce4ca37f59d61221c11ac
4
- data.tar.gz: 4cbe83183afe76f1033bac464d00a8d43f786f18
3
+ metadata.gz: 95113f8934d4909f93431170485fd0fdd92ca6ce
4
+ data.tar.gz: a66233bdbe90a369e7f020ee198f16d07f24743b
5
5
  SHA512:
6
- metadata.gz: 4b23b0b288346213719683cfd817c1408bf1e2939f835e29900fafddc4c04c6a7dfd4377c41b3a55c6ef59bd3acdc5dd45a11307b2548fae69ccb9bd079d2430
7
- data.tar.gz: f572f1c89c18a3375459dc7af251a6ed057d6d5f0a1c63796453edc66d0c1b4e71fb6ad6bc29a34e47b5e3e45b58767500e70d98cdef47c8a24cd3a4d15532ae
6
+ metadata.gz: b63b3590823f3b9e84f76fbb259137da29f31bf38c71395c5fd5f4ec9b8bde3984082e6d96609634790c4387be0b68b8984844604f6fa622a53dd587adfef631
7
+ data.tar.gz: 535bf7a39ff1bf0f7ff124fa66a45d3c83aff5a1743d862205d4dca66ace828ab617f0233beb76b8a79c9245b179594ed80db9f90c4390c4d4689ec8edf99865
@@ -8,7 +8,8 @@
8
8
  data: {
9
9
  type: 'video',
10
10
  attributes: {
11
- url: 'https://vimeo.com/115082758'
11
+ url: 'https://vimeo.com/115082758',
12
+ autoplay: false
12
13
  }
13
14
  }
14
15
  })
@@ -1,8 +1,11 @@
1
1
  <script type="text/ng-template" id="promethee/components/video/edit/inspect">
2
2
  <div class="form-group">
3
- <label class="label-control">Url</label>
4
- <input ng-model="promethee.inspected.attributes.url"
5
- class="form-control"
6
- type="text" />
3
+ <label class="label-control">Url</label>
4
+ <input ng-model="promethee.inspected.attributes.url" class="form-control" type="text" />
5
+ </div>
6
+
7
+ <div class="form-group">
8
+ <input ng-model="promethee.inspected.attributes.autoplay" type="checkbox" />
9
+ <label class="label-control"> Autoplay</label>
7
10
  </div>
8
11
  </script>
@@ -4,9 +4,11 @@ url = component[:attributes][:url].to_s
4
4
  if 'vimeo'.in? url
5
5
  video_id = url.gsub(/\A(?:https?:)?\/\/(?:(?:www|player)\.)?vimeo\.com\/(?:video\/)?(\d+).*?\z/, '\1')
6
6
  iframe_src = "https://player.vimeo.com/video/#{video_id}?color=ffffff&title=0&byline=0&portrait=0"
7
+ iframe_src += "&loop=1&autoplay=1&autopause=0&muted=1" if component[:attributes][:autoplay]
7
8
  elsif 'youtube'.in? url
8
9
  video_id = url.split('watch?v=').last
9
- iframe_src = "http://www.youtube.com/embed/#{video_id}"
10
+ iframe_src = "https://www.youtube.com/embed/#{video_id}"
11
+ iframe_src += "?autoplay=1&mute=1&loop=1" if component[:attributes][:autoplay]
10
12
  else
11
13
  iframe_src = url
12
14
  end
@@ -14,10 +16,10 @@ end
14
16
  <div class="<%= promethee_class_for component %>">
15
17
  <div class="embed-responsive embed-responsive-16by9">
16
18
  <% if iframe_src.present? %>
17
- <iframe frameborder="0"
18
- webkitallowfullscreen=""
19
- mozallowfullscreen=""
20
- allowfullscreen="allowfullscreen"
19
+ <iframe frameborder="0"
20
+ webkitallowfullscreen=""
21
+ mozallowfullscreen=""
22
+ allowfullscreen="allowfullscreen"
21
23
  src="<%= iframe_src %>"></iframe>
22
24
  <% end %>
23
25
  </div>
@@ -1,5 +1,5 @@
1
1
  module Promethee
2
2
  module Rails
3
- VERSION = '1.6.56'
3
+ VERSION = '1.6.57'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: promethee
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.56
4
+ version: 1.6.57
5
5
  platform: ruby
6
6
  authors:
7
7
  - Julien Dargelos
@@ -13,7 +13,7 @@ authors:
13
13
  autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
- date: 2018-07-24 00:00:00.000000000 Z
16
+ date: 2018-07-25 00:00:00.000000000 Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: rails