solidus_backend 4.2.0 → 4.2.2
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4e6afe37aa6cfa084e6d9dc12d006659668e0090a34d1de2bd978bb75760b95d
|
4
|
+
data.tar.gz: 67dc657454bd6ff95dc4ae1d5553a66e59715a5ea965eb50cd7dba0e324657a0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4a7df5d2d01ecd14aef6c6bf0b8abc09a3abcb61080ce3fc98d516f627aa8c12d2615a445c482eda9c27c0e2576d77b581ea7ce841f958cbc1a39e4422e56d93
|
7
|
+
data.tar.gz: ace130bfb583fc816364d812e19c4dd21e920221fbc40dc17708fc83864a6f9ef3eff25d63d34e2fdc7bd4e6a8e2eda06282941ad2a570e3bdf3520de2082772
|
data/Rakefile
CHANGED
@@ -1,25 +1,27 @@
|
|
1
1
|
Spree.ready(function() {
|
2
|
-
if (
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
2
|
+
if (!document.querySelector(".solidus-admin--nav")) {
|
3
|
+
if (window.screen.width <= 1024 && !document.cookie.includes("admin_nav_hidden")) {
|
4
|
+
// Set default nav to collapse on small screens - but don't override user preference
|
5
|
+
document.body.classList.add("admin-nav-hidden");
|
6
|
+
document.cookie = "admin_nav_hidden=true; expires=Fri, 31 Dec 9999 23:59:59 GMT";
|
7
|
+
}
|
8
|
+
|
9
|
+
var adminNavToggle = document.querySelector("#admin-nav-toggle");
|
10
|
+
|
11
|
+
if (adminNavToggle) {
|
12
|
+
adminNavToggle.addEventListener("click", function(e) {
|
13
|
+
e.preventDefault();
|
14
|
+
document.body.classList.toggle("admin-nav-hidden");
|
15
|
+
$(document.body).trigger("sticky_kit:recalc");
|
16
|
+
adminNavToggle.classList.toggle("fa-chevron-circle-left");
|
17
|
+
adminNavToggle.classList.toggle("fa-chevron-circle-right");
|
18
|
+
document.cookie = "admin_nav_hidden=" + document.body.classList.contains("admin-nav-hidden") + "; expires=Fri, 31 Dec 9999 23:59:59 GMT";
|
19
|
+
});
|
20
|
+
}
|
21
|
+
|
22
|
+
if (document.body.classList.contains('admin-nav-hidden')) {
|
23
|
+
$(adminNavToggle).removeClass('fa-chevron-circle-left').addClass('fa-chevron-circle-right');
|
24
|
+
}
|
23
25
|
}
|
24
26
|
|
25
27
|
let solidusAdminSwitch = document.querySelector("#solidus-admin-switch");
|
@@ -54,7 +54,7 @@ module Spree
|
|
54
54
|
end
|
55
55
|
|
56
56
|
@condition = condition || -> { true }
|
57
|
-
@sections = sections
|
57
|
+
@sections = sections || []
|
58
58
|
@icon = icon
|
59
59
|
@label = label
|
60
60
|
@partial = partial
|
@@ -78,27 +78,26 @@ module Spree
|
|
78
78
|
end
|
79
79
|
|
80
80
|
def match_path?(request)
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
match_path.call
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
81
|
+
matches =
|
82
|
+
if match_path.is_a? Regexp
|
83
|
+
request.fullpath =~ match_path
|
84
|
+
elsif match_path.respond_to?(:call)
|
85
|
+
match_path.call(request)
|
86
|
+
elsif match_path
|
87
|
+
request.fullpath.starts_with?("#{spree.admin_path}#{match_path}")
|
88
|
+
end
|
89
|
+
matches ||= request.fullpath.to_s.starts_with?(url.to_s) if url.present?
|
90
|
+
matches ||= @sections.include?(request.controller_class.controller_name.to_sym) if @sections.present?
|
91
|
+
|
92
|
+
matches
|
90
93
|
end
|
91
94
|
|
92
95
|
def url
|
93
|
-
if @url.respond_to?(:call)
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
spree.send("admin_#{@label}_path")
|
99
|
-
else
|
100
|
-
@url
|
101
|
-
end
|
96
|
+
url = @url.call if @url.respond_to?(:call)
|
97
|
+
url ||= spree.public_send(@url) if @url.is_a?(Symbol) && spree.respond_to?(@url)
|
98
|
+
url ||= spree.send("admin_#{@label}_path") if @url.nil? && @label && spree.respond_to?("admin_#{@label}_path")
|
99
|
+
url ||= @url.to_s
|
100
|
+
url
|
102
101
|
end
|
103
102
|
|
104
103
|
private
|
@@ -16,7 +16,7 @@ module Spree
|
|
16
16
|
|
17
17
|
# @!attribute [rw] theme
|
18
18
|
# @return [String] Default admin theme name
|
19
|
-
versioned_preference :theme, :string, initial_value: 'classic', boundaries: { "4.
|
19
|
+
versioned_preference :theme, :string, initial_value: 'classic', boundaries: { "4.2.0" => "solidus_admin" }
|
20
20
|
|
21
21
|
def theme_path(user_theme = nil)
|
22
22
|
user_theme ? themes.fetch(user_theme.to_sym) : themes.fetch(theme.to_sym)
|
@@ -25,8 +25,7 @@ module Spree
|
|
25
25
|
# @!attribute [rw] admin_updated_navbar
|
26
26
|
# @return [Boolean] Should the updated navbar be used in admin (default: +false+)
|
27
27
|
#
|
28
|
-
|
29
|
-
versioned_preference :admin_updated_navbar, :boolean, initial_value: false, boundaries: { "4.1.0.a" => true }
|
28
|
+
versioned_preference :admin_updated_navbar, :boolean, initial_value: false, boundaries: { "4.2.0" => true }
|
30
29
|
|
31
30
|
preference :frontend_product_path,
|
32
31
|
:proc,
|
@@ -40,7 +39,7 @@ module Spree
|
|
40
39
|
|
41
40
|
# @!attribute [rw] prefer_menu_item_partials
|
42
41
|
# @return [Boolean] Whether or not to prefer menu item partials when both a partial and children are present.
|
43
|
-
|
42
|
+
versioned_preference :prefer_menu_item_partials, :boolean, initial_value: true, boundaries: { "4.2.0" => false }
|
44
43
|
|
45
44
|
autoload :ORDER_TABS, 'spree/backend_configuration/deprecated_tab_constants'
|
46
45
|
autoload :PRODUCT_TABS, 'spree/backend_configuration/deprecated_tab_constants'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: solidus_backend
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.2.
|
4
|
+
version: 4.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Solidus Team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-11-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: solidus_api
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 4.2.
|
19
|
+
version: 4.2.2
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 4.2.
|
26
|
+
version: 4.2.2
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: solidus_core
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - '='
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 4.2.
|
33
|
+
version: 4.2.2
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - '='
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 4.2.
|
40
|
+
version: 4.2.2
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: font-awesome-rails
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -930,7 +930,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
930
930
|
- !ruby/object:Gem::Version
|
931
931
|
version: 1.8.23
|
932
932
|
requirements: []
|
933
|
-
rubygems_version: 3.
|
933
|
+
rubygems_version: 3.4.17
|
934
934
|
signing_key:
|
935
935
|
specification_version: 4
|
936
936
|
summary: Admin interface for the Solidus e-commerce framework.
|