pageflow-outline-navigation-bar 1.2.0 → 1.3.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: 2bc0b8dac3cbbec7bb4a7a0cf9787f199774053070740c3afc099d92b5fc1356
4
- data.tar.gz: d2459b8e8adfa57c19de76eda9acdf85f2dfe673ae6b9edbf6b2117b7ea67493
3
+ metadata.gz: 642296c29e34b815cc5762831b3f8aff920070caca26dd1de7dd3a3fffc9b643
4
+ data.tar.gz: 1c6fa9d65cffb7455260652cb6be8d5c8431a70cc490f894f6f647499daee3ce
5
5
  SHA512:
6
- metadata.gz: d814a8c807b0b74844f6a77bea37b33b9fccc63d56f7edaf04df57feda832172927e93da2372ae33d46f437bface7ed20e15b39e7e180a64f68b2da76ec77976
7
- data.tar.gz: 7223dd2c1fb3f4909387f4721ceb5324a7ecb1e2b23a771331f793c24dadcd9b9da7f2379de532b675462402ea020502d1d549c404c9aea23b4b05175a833615
6
+ metadata.gz: 4469c8401ad9c4c3ea9ab62fdaf392839903be3434bae81af702adb002fcc66c6210beba5f9b58b55177f8560cc6053c166540636cac8eace51d057c1561e28c
7
+ data.tar.gz: 607521ffe200109b6f10fbdfe21d63027cad686a9231574609884266feb98be040779ec494f307f9736272b8a4b629c854e9438cd82bf9f7c1670c5f118e18af
data/CHANGELOG.md CHANGED
@@ -1,14 +1,14 @@
1
1
  # CHANGELOG
2
2
 
3
- ### Version 1.2.0
3
+ ### Version 1.3.0
4
4
 
5
- 2019-04-08
5
+ 2019-05-20
6
6
 
7
- [Compare changes](https://github.com/codevise/pageflow-outline-navigation-bar/compare/1-1-stable...v1.2.0)
7
+ [Compare changes](https://github.com/codevise/pageflow-outline-navigation-bar/compare/1-2-stable...v1.3.0)
8
8
 
9
- - Add support for pageflow 14
10
- ([#8](https://github.com/codevise/pageflow-outline-navigation-bar/pull/8))
9
+ - Support for configurable sharing providers
10
+ ([#9](https://github.com/codevise/pageflow-outline-navigation-bar/pull/9))
11
11
 
12
12
  See
13
- [1-1-stable branch](https://github.com/codevise/pageflow-outline-navigation-bar/blob/1-1-stable/CHANGELOG.md)
13
+ [1-2-stable branch](https://github.com/codevise/pageflow-outline-navigation-bar/blob/1-2-stable/CHANGELOG.md)
14
14
  for previous changes.
@@ -161,10 +161,12 @@
161
161
  });
162
162
 
163
163
  var shareBox = $('.share_box', this.element),
164
- shareLinks = $('a', shareBox);
164
+ shareLinks = $('.share_box_icons > .menu_item > a', shareBox);
165
165
 
166
166
  shareBox.shareMenu({
167
- insertAfter: shareLinks.parent().last(),
167
+ subMenu: $('.sub_share', element),
168
+ links: shareLinks,
169
+ insertAfter: $('.share_box_icons'),
168
170
  closeOnMouseLeaving: shareBox
169
171
  });
170
172
  },
@@ -10,14 +10,10 @@
10
10
  $outline-navigation-bar-icons: $widget-icons !default;
11
11
 
12
12
  /// @see $default-widget-icon-font-options
13
- $outline-navigation-bar-icon-font-options: (
14
- share-icon-color: #fff,
15
- active-share-icon-color: $main-color
16
- ) !default;
13
+ $outline-navigation-bar-icon-font-options: () !default;
17
14
 
18
15
  .outline_navigation_bar {
19
16
  @import "./default/mixins";
20
-
21
17
  @import "./default/icons/icon_font";
22
18
  @import "./default/icons/sprite";
23
19
 
@@ -80,8 +76,14 @@ $outline-navigation-bar-icon-font-options: (
80
76
  @import "./default/menu_items";
81
77
  @import "./default/toggle";
82
78
  @import "./default/volume_box";
83
- @import "./default/share_box";
84
79
  @import "./default/credits_box";
85
80
  @import "./default/mobile_sharing";
86
81
  @import "./default/scroller";
87
82
  }
83
+
84
+ body.has_no_phone_platform {
85
+ .menu_item.share_whats_app,
86
+ .menu_item.share_telegram {
87
+ display: none !important;
88
+ }
89
+ }
@@ -4,10 +4,7 @@
4
4
 
5
5
  $button-icon-color,
6
6
  $active-button-icon-color,
7
- $deactivated-button-icon-color,
8
-
9
- $share-icon-color,
10
- $active-share-icon-color
7
+ $deactivated-button-icon-color
11
8
  ) {
12
9
  .toggle.buttons,
13
10
  .buttons_menu_item {
@@ -99,48 +96,6 @@
99
96
  }
100
97
  }
101
98
 
102
- .share_box {
103
- .share {
104
- width: 45px;
105
-
106
- &:hover,
107
- &.active {
108
- .button:before {
109
- color: $active-share-icon-color;
110
- }
111
- }
112
- }
113
-
114
- .button {
115
- display: block;
116
- text-align: center;
117
- }
118
- }
119
-
120
- .share_box {
121
- .button.share_google,
122
- .button.share_facebook,
123
- .button.share_twitter {
124
- font-size: 1.5em;
125
-
126
- &:before {
127
- color: $share-icon-color;
128
- }
129
- }
130
-
131
- .button.share_google {
132
- @include fa-google-plus-icon;
133
- }
134
-
135
- .button.share_facebook {
136
- @include fa-facebook-icon;
137
- }
138
-
139
- .button.share_twitter {
140
- @include fa-twitter-icon;
141
- }
142
- }
143
-
144
99
  .volume-control:before,
145
100
  .volume-slider:before {
146
101
  color: $button-background-color;
@@ -62,30 +62,6 @@
62
62
  @include pageflow-sprite-icon-credits($target: ".button");
63
63
  }
64
64
 
65
- .share.google {
66
- @include pageflow-sprite-icon-google($target: ".button");
67
-
68
- &.active {
69
- @include pageflow-sprite-icon-google("active", $target: ".button");
70
- }
71
- }
72
-
73
- .share.twitter {
74
- @include pageflow-sprite-icon-twitter($target: ".button");
75
-
76
- &.active {
77
- @include pageflow-sprite-icon-twitter("active", $target: ".button");
78
- }
79
- }
80
-
81
- .share.facebook {
82
- @include pageflow-sprite-icon-facebook($target: ".button");
83
-
84
- &.active {
85
- @include pageflow-sprite-icon-facebook("active", $target: ".button");
86
- }
87
- }
88
-
89
65
  .share_box {
90
66
  a.share {
91
67
  width: 39px;
@@ -31,3 +31,12 @@ $outline-navigation-bar-display-hide-text-button: $navigation-display-hide-text-
31
31
  display: none;
32
32
  }
33
33
  }
34
+
35
+ &.without_sharing_button,
36
+ &.mobile_sharing_only {
37
+ .menu_item.share {
38
+ display: none;
39
+ }
40
+ }
41
+
42
+
@@ -46,9 +46,3 @@ $image-dir: "pageflow/themes/default/mobile_navigation";
46
46
  }
47
47
  }
48
48
  }
49
-
50
- .mobile_sharing a {
51
- &::before {
52
- background-image: image-url("#{$image-dir}/sharing_icons_sprite.png");
53
- }
54
- }
@@ -2,7 +2,7 @@
2
2
  li {
3
3
  > a {
4
4
  display: block;
5
- margin-left: 78px;
5
+ margin-left: 70px;
6
6
  color: white;
7
7
  text-decoration: none;
8
8
  font-size: 24px;
@@ -10,26 +10,13 @@
10
10
  border: 0;
11
11
  height: 80px;
12
12
 
13
- &:before {
14
- content: "";
13
+ svg {
14
+ fill: white;
15
15
  position: absolute;
16
- width: 42px;
17
- height: 37px;
18
- background-size: 100% auto;
19
- left: 20px;
20
- top: 30px;
21
- }
22
-
23
- &.facebook:before {
24
- background-position: center top;
25
- }
26
-
27
- &.twitter:before {
28
- background-position: center 122px;
29
- }
30
-
31
- &.google:before {
32
- background-position: center bottom;
16
+ left: 22px;
17
+ top: 36px;
18
+ width: 30px;
19
+ height: 30px;
33
20
  }
34
21
  }
35
22
  }
@@ -45,10 +32,6 @@
45
32
  display: block;
46
33
  margin: 0 1em 1em 1em;
47
34
  padding: 1em 0;
48
-
49
- &:hover {
50
- background-color: rgba(0, 0, 0, 0.6);
51
- }
52
35
  }
53
36
  }
54
37
 
@@ -75,3 +75,7 @@
75
75
  @include menu-item-shadow-off;
76
76
  }
77
77
  }
78
+
79
+ &.without_sharing_button .toggle.mobile_only.share.menu_item {
80
+ display: none;
81
+ }
@@ -37,16 +37,13 @@
37
37
 
38
38
  <li class="share buttons_menu_item menu_item" tabindex="2">
39
39
  <div class="menu_box share_box navigation_share_box">
40
- <div class="menu_item share_facebook">
41
- <%= render('pageflow/entries/share_menu/facebook_link', entry: entry) %>
40
+ <div class="share_box_icons">
41
+ <% entry.active_share_providers.each do |provider| %>
42
+ <div class="menu_item share_<%= provider %>">
43
+ <%= render("pageflow/entries/share_menu/#{provider}_link", entry: entry) %>
44
+ </div>
45
+ <% end %>
42
46
  </div>
43
- <div class="menu_item share_twitter">
44
- <%= render('pageflow/entries/share_menu/twitter_link', entry: entry) %>
45
- </div>
46
- <div class="menu_item share_google">
47
- <%= render('pageflow/entries/share_menu/google_link', entry: entry) %>
48
- </div>
49
-
50
47
  <div class="sub_share">
51
48
  <a tabindex="2" target="_blank"><%= t('pageflow.public.share_this_entry') %></a>
52
49
  <a tabindex="2" target="_blank"><%= t('pageflow.public.share_this_page') %></a>
@@ -1,15 +1,11 @@
1
1
  <div class="mobile_sharing panel mobile_panel">
2
2
  <div class="wrapper">
3
3
  <ul>
4
+ <% entry.active_share_providers.each do |provider| %>
4
5
  <li>
5
- <%= render 'pageflow/entries/share_menu/facebook_link', entry: entry %>
6
- </li>
7
- <li>
8
- <%= render 'pageflow/entries/share_menu/twitter_link', entry: entry %>
9
- </li>
10
- <li>
11
- <%= render 'pageflow/entries/share_menu/google_link', entry: entry %>
6
+ <%= render "pageflow/entries/share_menu/#{provider}_link", entry: entry %>
12
7
  </li>
8
+ <% end %>
13
9
  </ul>
14
10
  </div>
15
11
  <div class="sub_share">
@@ -1,5 +1,5 @@
1
1
  module Pageflow
2
2
  module OutlineNavigationBar
3
- VERSION = '1.2.0'.freeze
3
+ VERSION = '1.3.0'.freeze
4
4
  end
5
5
  end
@@ -18,7 +18,7 @@ Gem::Specification.new do |spec|
18
18
 
19
19
  spec.required_ruby_version = '~> 2.1'
20
20
 
21
- spec.add_runtime_dependency 'pageflow', ['>= 12.2.x', '< 15']
21
+ spec.add_runtime_dependency 'pageflow', '~> 14.1.x'
22
22
  spec.add_runtime_dependency 'pageflow-public-i18n', '~> 1.0'
23
23
 
24
24
  spec.add_development_dependency 'bundler', '~> 1.0'
metadata CHANGED
@@ -1,35 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pageflow-outline-navigation-bar
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Codevise Solutions Ltd.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-08 00:00:00.000000000 Z
11
+ date: 2019-05-20 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: 12.2.x
20
- - - "<"
17
+ - - "~>"
21
18
  - !ruby/object:Gem::Version
22
- version: '15'
19
+ version: 14.1.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: 12.2.x
30
- - - "<"
24
+ - - "~>"
31
25
  - !ruby/object:Gem::Version
32
- version: '15'
26
+ version: 14.1.x
33
27
  - !ruby/object:Gem::Dependency
34
28
  name: pageflow-public-i18n
35
29
  requirement: !ruby/object:Gem::Requirement
@@ -130,7 +124,6 @@ files:
130
124
  - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/parent_page_button.scss
131
125
  - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/prevent_focus_rect_on_pointer_down.scss
132
126
  - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/scroller.scss
133
- - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/share_box.scss
134
127
  - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/toggle.scss
135
128
  - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/volume_box.scss
136
129
  - app/assets/stylesheets/pageflow/outline_navigation_bar/themes/default/widget_margin.scss
@@ -1,20 +0,0 @@
1
- .share_box {
2
- top: 0;
3
- width: 210px;
4
-
5
- a {
6
- float: left;
7
- text-decoration: none;
8
- width: 70px;
9
- }
10
-
11
- p {
12
- font-size: 9px;
13
- margin: 0;
14
- }
15
-
16
- .menu_item {
17
- padding: 0 10px;
18
- min-height: 0;
19
- }
20
- }