pageflow-before-after 1.1.0 → 1.2.0

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: 4ef58fe60813a3aa8419c775c50935babbd7369cf5fbd44cb95e2879e69827e1
4
- data.tar.gz: 044a0b8a6d12d0a7496c76a91496ca1c59ff6af3179039e93fc89c0516a2366e
3
+ metadata.gz: 1e1eab8cb1cdabfac12b7170127f2b4522e2b444bc7262f634f650e324da1339
4
+ data.tar.gz: fa8e76828a91cccda21ffc3d34c9a1390ad31202f4da3b2ed6809b7e3a024582
5
5
  SHA512:
6
- metadata.gz: 35a1385435ec14e1076191059b03c8e239b0f87e37a87b2fe421751de21e341eb521b8e4e2df921acb3285107507d4b9e427bd3892dea5fd8e9f9c4617adad19
7
- data.tar.gz: fd23506ee916156bcaa02f4e011fe9f0e6a03337cd1027cb0e363862193b83d8cd192b451e15f43169d0dc7fbd56ab6517e2e97a141552af41a1994e6a4e0da4
6
+ metadata.gz: 3ce3949db87a3413a651b2da7b155f593dab4151b9ef0178dfc3fd87570b8de937e42d274653f7b0f0a91b59a6d14a408cdf0b27a4e3b09fc2eadca1762e00c2
7
+ data.tar.gz: e2ec3960250087b8a3ed438cbd19ee3d8d389eb673c484493884a26ed427e21d5f54dcc3fbaed2e050921c2c02aa7ff7db95443847f04b7a22f3730c85346325
data/.gitignore CHANGED
@@ -13,6 +13,7 @@ lib/bundler/man
13
13
  pkg
14
14
  rdoc
15
15
  spec/reports
16
+ spec/dummy
16
17
  test/tmp
17
18
  test/version_tmp
18
19
  tmp
@@ -0,0 +1,10 @@
1
+ language: ruby
2
+ rvm: 2.5
3
+
4
+ # User container based travis infrastructure which allows caching
5
+ # features for open source projects.
6
+ sudo: false
7
+ cache: bundler
8
+
9
+ script:
10
+ - bin/rspec
@@ -1,14 +1,16 @@
1
1
  # CHANGELOG
2
2
 
3
- ### Version 1.1.0
3
+ ### Version 1.2.0
4
4
 
5
- 2018-12-07
5
+ 2019-04-08
6
6
 
7
- [Compare changes](https://github.com/codevise/pageflow-before-after/compare/1-0-stable...v1.1.0)
7
+ [Compare changes](https://github.com/codevise/pageflow-before-after/compare/1-1-stable...v1.2.0)
8
8
 
9
- - Add support for Pageflow 13
10
- ([#22](https://github.com/codevise/pageflow-before-after/pull/22))
9
+ - Adapt page dom for pageflow 14
10
+ ([#24](https://github.com/codevise/pageflow-before-after/pull/24))
11
+ - Setup page type lint specs
12
+ ([#23](https://github.com/codevise/pageflow-before-after/pull/23))
11
13
 
12
14
  See
13
- [1-0-stable branch](https://github.com/codevise/pageflow-before-after/blob/1-0-stable/CHANGELOG.md)
15
+ [1-1-stable branch](https://github.com/codevise/pageflow-before-after/blob/1-1-stable/CHANGELOG.md)
14
16
  for previous changes.
data/README.md CHANGED
@@ -1,6 +1,7 @@
1
1
  # Pageflow Before After
2
2
 
3
3
  [![Gem Version](https://badge.fury.io/rb/pageflow-before-after.svg)](http://badge.fury.io/rb/pageflow-before-after)
4
+ [![Build Status](https://travis-ci.org/codevise/pageflow-before-after.svg?branch=master)](https://travis-ci.org/codevise/pageflow-before-after)
4
5
 
5
6
  Page type showing before/after image sliders (Digit style).
6
7
 
@@ -60,11 +60,7 @@ pageflow.pageType.register('before_after', _.extend({
60
60
  deactivated: function(pageElement, configuration) {},
61
61
 
62
62
  update: function(pageElement, configuration) {
63
-
64
- pageElement.find('h2 .tagline').text(configuration.get('tagline') || '');
65
- pageElement.find('h2 .title').text(configuration.get('title') || '');
66
- pageElement.find('h2 .subtitle').text(configuration.get('subtitle') || '');
67
- pageElement.find('p').html(configuration.get('text') || '');
63
+ this.updateDefaultPageContent(pageElement, configuration);
68
64
  pageElement.find('.control_bar_text').text(configuration.get('control_bar_text') ||
69
65
  I18n.t('pageflow.public.before_after.start', {
70
66
  locale: pageflow.seed.locale
@@ -89,4 +85,4 @@ pageflow.pageType.register('before_after', _.extend({
89
85
  }
90
86
  };
91
87
  }
92
- }, pageflow.commonPageCssClasses, pageflow.infoBox));
88
+ }, pageflow.commonPageCssClasses, pageflow.infoBox, pageflow.defaultPageContent));
@@ -34,7 +34,7 @@
34
34
  var beforeImg = $('.before_image', obj);
35
35
  var afterImg = $('.after_image', obj);
36
36
 
37
- var section = $(obj).parentsUntil(".backgroundArea").last();
37
+ var section = $(obj).parentsUntil(".page_background").last();
38
38
 
39
39
  var imgWidth;
40
40
  var imgHeight;
@@ -56,15 +56,13 @@
56
56
  }
57
57
 
58
58
  .page .beforeAfterPage {
59
-
60
- .videoWrapper {
59
+ .uncropped_media_wrapper {
61
60
  height: 100%;
62
61
  }
63
62
 
64
63
  .shadow {
65
64
  z-index: 1;
66
65
  }
67
-
68
66
  }
69
67
 
70
68
  .hideText .beforeAfterPage .before_wrapper {
@@ -78,8 +76,7 @@
78
76
  }
79
77
 
80
78
  .js .beforeAfterPage {
81
-
82
- .contentText {
79
+ .page_text {
83
80
  margin-bottom: 200px;
84
81
 
85
82
  @include phone {
@@ -1,4 +1,4 @@
1
- <div class="blackLayer"></div>
1
+ <div class="black_layer"></div>
2
2
  <div class="content_and_background beforeAfterPage">
3
3
  <div class="close_button text_hidden_only" tabindex="4" title="<%= t('pageflow.public.before_after.leave_view') %>">
4
4
  <div class="label">
@@ -6,8 +6,8 @@
6
6
  </div>
7
7
  </div>
8
8
 
9
- <div class="backgroundArea page_background page_background-for_page_with_player_controls">
10
- <div class="videoWrapper">
9
+ <div class="page_background page_background-for_page_with_player_controls">
10
+ <div class="uncropped_media_wrapper">
11
11
  <div class="before_after_container">
12
12
  <div class="before_after">
13
13
  <div class="before_wrapper">
@@ -38,18 +38,8 @@
38
38
 
39
39
  <div class="scroller">
40
40
  <div>
41
- <div class="contentWrapper">
42
- <div class="page_header">
43
- <h2>
44
- <span class="tagline"><%= configuration['tagline'] %></span>
45
- <span class="title"><%= configuration['title'] %></span>
46
- <span class="subtitle"><%= configuration['subtitle'] %></span>
47
- </h2>
48
- <%= background_image_tag(configuration['background_image_id'], {:class => "print_image"}) %>
49
- </div>
50
- <div class="contentText">
51
- <p><%= raw configuration['text'] %></p>
52
- </div>
41
+ <div class="content_wrapper">
42
+ <%= page_default_content(page) %>
53
43
  </div>
54
44
  </div>
55
45
  </div>
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ #
5
+ # This file was generated by Bundler.
6
+ #
7
+ # The application 'rspec' is installed as part of a gem, and
8
+ # this file is here to facilitate running it.
9
+ #
10
+
11
+ require "pathname"
12
+ ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
13
+ Pathname.new(__FILE__).realpath)
14
+
15
+ bundle_binstub = File.expand_path("../bundle", __FILE__)
16
+
17
+ if File.file?(bundle_binstub)
18
+ if File.read(bundle_binstub, 150) =~ /This file was generated by Bundler/
19
+ load(bundle_binstub)
20
+ else
21
+ abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
22
+ Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
23
+ end
24
+ end
25
+
26
+ require "rubygems"
27
+ require "bundler/setup"
28
+
29
+ load Gem.bin_path("rspec-core", "rspec")
@@ -1,5 +1,5 @@
1
1
  module Pageflow
2
2
  module BeforeAfter
3
- VERSION = '1.1.0'.freeze
3
+ VERSION = '1.2.0'.freeze
4
4
  end
5
5
  end
@@ -18,11 +18,14 @@ Gem::Specification.new do |spec|
18
18
 
19
19
  spec.required_ruby_version = '~> 2.1'
20
20
 
21
- spec.add_dependency 'pageflow', ['>= 0.11', '< 14']
21
+ spec.add_dependency 'pageflow', '~> 14.x'
22
22
  spec.add_dependency 'pageflow-public-i18n', '~> 1.8'
23
23
 
24
24
  spec.add_dependency 'jquery-ui-rails', '~> 5.0'
25
25
 
26
+ spec.add_development_dependency 'pageflow-support', '~> 14.x'
27
+ spec.add_development_dependency 'rspec-rails', '~> 3.0'
28
+
26
29
  # Semantic versioning rake tasks
27
30
  spec.add_development_dependency 'semmy', '~> 1.0'
28
31
  end
@@ -0,0 +1,4 @@
1
+ require 'spec_helper'
2
+ require 'pageflow/lint'
3
+
4
+ Pageflow::Lint.page_type(Pageflow::BeforeAfter.page_type)
@@ -0,0 +1,14 @@
1
+ ENV['RAILS_ENV'] ||= 'test'
2
+ ENV['PAGEFLOW_PLUGIN_ENGINE'] = 'pageflow_before_after'
3
+
4
+ require 'pageflow/support'
5
+ Pageflow::Dummy.setup
6
+
7
+ require 'rspec/rails'
8
+
9
+ engine_root = File.join(File.dirname(__FILE__), '..')
10
+ Dir[File.join(engine_root, 'spec/support/**/*.rb')].each { |file| require(file) }
11
+
12
+ RSpec.configure do |config|
13
+ config.use_transactional_fixtures = true
14
+ end
metadata CHANGED
@@ -1,35 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pageflow-before-after
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Codevise Solutions
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-12-07 00:00:00.000000000 Z
11
+ date: 2019-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: pageflow
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">="
18
- - !ruby/object:Gem::Version
19
- version: '0.11'
20
- - - "<"
17
+ - - "~>"
21
18
  - !ruby/object:Gem::Version
22
- version: '14'
19
+ version: 14.x
23
20
  type: :runtime
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
- - - ">="
28
- - !ruby/object:Gem::Version
29
- version: '0.11'
30
- - - "<"
24
+ - - "~>"
31
25
  - !ruby/object:Gem::Version
32
- version: '14'
26
+ version: 14.x
33
27
  - !ruby/object:Gem::Dependency
34
28
  name: pageflow-public-i18n
35
29
  requirement: !ruby/object:Gem::Requirement
@@ -58,6 +52,34 @@ dependencies:
58
52
  - - "~>"
59
53
  - !ruby/object:Gem::Version
60
54
  version: '5.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: pageflow-support
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: 14.x
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: 14.x
69
+ - !ruby/object:Gem::Dependency
70
+ name: rspec-rails
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '3.0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '3.0'
61
83
  - !ruby/object:Gem::Dependency
62
84
  name: semmy
63
85
  requirement: !ruby/object:Gem::Requirement
@@ -80,6 +102,7 @@ extensions: []
80
102
  extra_rdoc_files: []
81
103
  files:
82
104
  - ".gitignore"
105
+ - ".travis.yml"
83
106
  - CHANGELOG.md
84
107
  - Gemfile
85
108
  - README.md
@@ -101,6 +124,7 @@ files:
101
124
  - app/assets/stylesheets/pageflow/before_after.scss
102
125
  - app/assets/stylesheets/pageflow/before_after/themes/default.scss
103
126
  - app/views/pageflow/before_after/page.html.erb
127
+ - bin/rspec
104
128
  - config/locales/de.yml
105
129
  - config/locales/en.yml
106
130
  - lib/pageflow-before-after.rb
@@ -108,6 +132,8 @@ files:
108
132
  - lib/pageflow/before_after/page_type.rb
109
133
  - lib/pageflow/before_after/version.rb
110
134
  - pageflow-before-after.gemspec
135
+ - spec/integration/page_type_spec.rb
136
+ - spec/spec_helper.rb
111
137
  homepage: https://github.com/codevise/pageflow-before-after
112
138
  licenses:
113
139
  - MIT
@@ -128,8 +154,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
128
154
  version: '0'
129
155
  requirements: []
130
156
  rubyforge_project:
131
- rubygems_version: 2.7.0
157
+ rubygems_version: 2.7.5
132
158
  signing_key:
133
159
  specification_version: 4
134
160
  summary: Pageflow page type for before/after image slider.
135
- test_files: []
161
+ test_files:
162
+ - spec/integration/page_type_spec.rb
163
+ - spec/spec_helper.rb