promethee 1.11.24 → 1.11.25

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 844151d68f3a0540c09f5aa26c6c14c1307104c710d0220a6214a6cb3a02f9ab
4
- data.tar.gz: 457ca6f70745f2ccedcc28444630111d18adb71170b744d6236dd8934f6160e8
3
+ metadata.gz: f64874c36b9f5787d2e2cdcf97a7d833cd7cc2c2abd28bd5c0478151207e4624
4
+ data.tar.gz: 17758c5432c9382a668040890580b8aa8ab5265ed745aab31fe995daa11f816e
5
5
  SHA512:
6
- metadata.gz: c0f478d3e67bd22ca2c3df3a387e345501caa973865a14fb4389070853d6d9d21ef32f738e8903031395bf929d884f01c79366476e0b6eb2d65d3631c6f2428a
7
- data.tar.gz: 9d162ffaead029d30eac07473d2a263a38f88608f81e3dec953f31874db1230e08b9fca10d472b9d4006fd7a4f056b8deeb0430cba9e20ec3e2bdc9da7e5b623
6
+ metadata.gz: f020fc077bee3525d47b54bd61e180d4315c3b5663eb65b13df95e182a8b988402d9a7ce357ab46775e8bbfbd2c52f79db05c9a3d1ee8ddc414f57544d96eb1a
7
+ data.tar.gz: 04c4416686698a97346981bf0f2f4cc069a53aafde70d160e78cd454f540bda0ec1110b95dc029958d44465bce6eb8a834601d7161b8391c0a4a90cf06473edb
@@ -4,4 +4,4 @@
4
4
  //= require angular-bootstrap-colorpicker/js/bootstrap-colorpicker-module
5
5
  //= require @fancyapps/fancybox/dist/jquery.fancybox.min
6
6
  //= require jquery-warn-before-unload/jquery.warnBeforeUnload
7
- //= require promethee/fancybox
7
+ //= require_tree ./promethee
@@ -0,0 +1,12 @@
1
+ /*global $, document */
2
+ $(function () {
3
+ 'use strict';
4
+ // NOTE: srcset is supposed to be clean, but when we resize the iframe the images inside aren't recalculate to switch to the proper src.
5
+ // It takes the desktop image and reduce it.
6
+ // To avoid this unwanted effect we just remove the srcset on preview, so we always use the base src image
7
+ $('.promethee-previewmode').click(function () {
8
+ $('.promethee-edit__preview-frame').contents().find('img').each(function () {
9
+ $(this).removeAttr('srcset');
10
+ });
11
+ });
12
+ });
@@ -0,0 +1,17 @@
1
+ /*global $, document */
2
+ $(function () {
3
+ 'use strict';
4
+
5
+ if ($('div[ng-app=Promethee]').length === 0) {
6
+ return;
7
+ }
8
+
9
+ // CTRL + S on promethee does save the page
10
+ $(document).bind('keydown', function (e) {
11
+ if ((e.ctrlKey || e.metaKey) && (e.which === 83)) {
12
+ e.preventDefault();
13
+ $('form').submit();
14
+ return false;
15
+ }
16
+ });
17
+ });
@@ -1,5 +1,5 @@
1
1
  module Promethee
2
2
  module Rails
3
- VERSION = '1.11.24'
3
+ VERSION = '1.11.25'
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.11.24
4
+ version: 1.11.25
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sébastien Gaya
@@ -14,7 +14,7 @@ authors:
14
14
  autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
- date: 2018-12-21 00:00:00.000000000 Z
17
+ date: 2019-01-14 00:00:00.000000000 Z
18
18
  dependencies:
19
19
  - !ruby/object:Gem::Dependency
20
20
  name: rails
@@ -164,6 +164,8 @@ files:
164
164
  - app/assets/images/logo-promethee-vertical.svg
165
165
  - app/assets/javascripts/promethee.js
166
166
  - app/assets/javascripts/promethee/fancybox.js
167
+ - app/assets/javascripts/promethee/preview-srcset.js
168
+ - app/assets/javascripts/promethee/save.js
167
169
  - app/assets/stylesheets/promethee-edit.sass
168
170
  - app/assets/stylesheets/promethee-edit/_layout.sass
169
171
  - app/assets/stylesheets/promethee-edit/_loader.sass