locomotivecms_wagon 3.1.0.beta1 → 3.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/generators/blank/package.json.tt +1 -1
- data/lib/locomotive/wagon/commands/delete_command.rb +1 -1
- data/lib/locomotive/wagon/commands/push_sub_commands/push_pages_command.rb +1 -1
- data/lib/locomotive/wagon/commands/serve_command.rb +1 -1
- data/lib/locomotive/wagon/decorators/content_entry_decorator.rb +4 -2
- data/lib/locomotive/wagon/decorators/site_decorator.rb +6 -2
- data/lib/locomotive/wagon/version.rb +1 -1
- data/locomotivecms_wagon.gemspec +1 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 899cb917d33c9f96cff7040c74ab3eb5cdb8dc260f853049837d13aef67b1b73
|
4
|
+
data.tar.gz: 742fcc8cf7296a44a7b28f08841056b4449c1561e60b8f99f222732f4aa035f9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 825827f36be71a50cdb76fef76003919c7ee6b6ee5ca1e16aea16f2495e6b10c43adab06c8e3feeaa3d62eace8f4e39df687f388b7a29f5130419547800289e7
|
7
|
+
data.tar.gz: d4e33cca3199a9b22bca46ec445939f8ecc7770c4cd91290de08c1fbb10b47b20c9f0e378a0161cac2ef437efedff649c634db574dd69fd3d2559793c0a6a488
|
@@ -23,7 +23,7 @@
|
|
23
23
|
"file-loader": "^1.1.11",
|
24
24
|
"image-webpack-loader": "^4.3.0",
|
25
25
|
"mini-css-extract-plugin": "^0.4.0",
|
26
|
-
"
|
26
|
+
"sass": "^1.49.9",
|
27
27
|
"optimize-css-assets-webpack-plugin": "^4.0.2",
|
28
28
|
"postcss-flexbugs-fixes": "^3.3.1",
|
29
29
|
"postcss-loader": "^2.1.5",
|
@@ -20,7 +20,7 @@ module Locomotive::Wagon
|
|
20
20
|
new(*args).delete
|
21
21
|
end
|
22
22
|
|
23
|
-
# @raise [ ArgumentError ] unless the given resources is in SINGLE_RESOURCES or
|
23
|
+
# @raise [ ArgumentError ] unless the given resources is in SINGLE_RESOURCES or ALL_RESOURCES
|
24
24
|
def delete
|
25
25
|
if resource == SITE_RESOURCE
|
26
26
|
delete_site
|
@@ -49,7 +49,7 @@ module Locomotive::Wagon
|
|
49
49
|
end
|
50
50
|
|
51
51
|
def can_update?(local_entity)
|
52
|
-
# checking
|
52
|
+
# checking paths only if the current locale is the default one
|
53
53
|
if local_entity.__locale__.to_s == default_locale.to_s &&
|
54
54
|
local_entity.handle &&
|
55
55
|
id = remote_entity_id_from_handle(local_entity)
|
@@ -141,7 +141,7 @@ module Locomotive::Wagon
|
|
141
141
|
filepath = File.join(File.expand_path(path), 'app', 'views', 'pages', fullpath + (locale != default_locale ? ".#{locale}" : '') + '.liquid')
|
142
142
|
|
143
143
|
message = if File.exists?(filepath)
|
144
|
-
"[Warning]".red + ' by default and unless you
|
144
|
+
"[Warning]".red + ' by default and unless you override the slug in the YAML header of your page, Wagon will replace underscores by dashes in your page slug. Try this instead: ' + fullpath.dasherize.light_white
|
145
145
|
else
|
146
146
|
"[Tip]".light_white + " add a new page in your Wagon site at this location: " + filepath.light_white
|
147
147
|
end
|
@@ -8,6 +8,8 @@ module Locomotive
|
|
8
8
|
|
9
9
|
attr_accessor :__base_path__, :__content_assets_pusher__
|
10
10
|
|
11
|
+
DEFAULT_ATTRIBUTES = %i(_slug seo_title meta_keywords meta_description).freeze
|
12
|
+
|
11
13
|
def initialize(object, locale = nil, base_path, content_assets_pusher)
|
12
14
|
self.__base_path__ = base_path
|
13
15
|
self.__content_assets_pusher__ = content_assets_pusher
|
@@ -23,7 +25,7 @@ module Locomotive
|
|
23
25
|
end
|
24
26
|
|
25
27
|
def __attributes__
|
26
|
-
|
28
|
+
DEFAULT_ATTRIBUTES + fields.no_associations.map { |f| f.name.to_sym }
|
27
29
|
end
|
28
30
|
|
29
31
|
def method_missing(name, *args, &block)
|
@@ -60,7 +62,7 @@ module Locomotive
|
|
60
62
|
alias :decorate_time_field :decorate_date_time_field
|
61
63
|
|
62
64
|
def to_hash
|
63
|
-
if (hash = super).keys ==
|
65
|
+
if (hash = super).keys == DEFAULT_ATTRIBUTES
|
64
66
|
{}
|
65
67
|
else
|
66
68
|
hash
|
@@ -52,6 +52,10 @@ module Locomotive
|
|
52
52
|
self[:overwrite_same_content_assets]
|
53
53
|
end
|
54
54
|
|
55
|
+
def allow_dots_in_slugs
|
56
|
+
self[:allow_dots_in_slugs]
|
57
|
+
end
|
58
|
+
|
55
59
|
%i(robots_txt timezone seo_title meta_keywords meta_description asset_host routes).each do |name|
|
56
60
|
define_method(name) do
|
57
61
|
self[name]
|
@@ -59,7 +63,7 @@ module Locomotive
|
|
59
63
|
end
|
60
64
|
|
61
65
|
def __attributes__
|
62
|
-
%i(name handle robots_txt locales timezone seo_title meta_keywords meta_description picture metafields_schema metafields metafields_ui asset_host sections_content routes overwrite_same_content_assets)
|
66
|
+
%i(name handle robots_txt locales timezone seo_title meta_keywords meta_description picture metafields_schema metafields metafields_ui asset_host sections_content routes overwrite_same_content_assets allow_dots_in_slugs)
|
63
67
|
end
|
64
68
|
end
|
65
69
|
|
@@ -74,7 +78,7 @@ module Locomotive
|
|
74
78
|
class UpdateSiteDecorator < SiteDecorator
|
75
79
|
|
76
80
|
def __attributes__
|
77
|
-
%i(picture timezone locales metafields_schema metafields metafields_ui asset_host sections_content routes overwrite_same_content_assets)
|
81
|
+
%i(picture timezone locales metafields_schema metafields metafields_ui asset_host sections_content routes overwrite_same_content_assets allow_dots_in_slugs)
|
78
82
|
end
|
79
83
|
|
80
84
|
end
|
data/locomotivecms_wagon.gemspec
CHANGED
@@ -31,7 +31,7 @@ Gem::Specification.new do |gem|
|
|
31
31
|
|
32
32
|
gem.add_dependency 'locomotivecms_common', '~> 0.4.0'
|
33
33
|
gem.add_dependency 'locomotivecms_coal', '~> 1.7.0'
|
34
|
-
gem.add_dependency 'locomotivecms_steam', '~> 1.6.
|
34
|
+
gem.add_dependency 'locomotivecms_steam', '~> 1.6.1'
|
35
35
|
|
36
36
|
gem.add_dependency 'haml', '~> 5.1.2'
|
37
37
|
gem.add_dependency 'listen', '~> 3.3.1'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: locomotivecms_wagon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.1.
|
4
|
+
version: 3.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Didier Lafforgue
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2022-10-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rake
|
@@ -115,14 +115,14 @@ dependencies:
|
|
115
115
|
requirements:
|
116
116
|
- - "~>"
|
117
117
|
- !ruby/object:Gem::Version
|
118
|
-
version: 1.6.
|
118
|
+
version: 1.6.1
|
119
119
|
type: :runtime
|
120
120
|
prerelease: false
|
121
121
|
version_requirements: !ruby/object:Gem::Requirement
|
122
122
|
requirements:
|
123
123
|
- - "~>"
|
124
124
|
- !ruby/object:Gem::Version
|
125
|
-
version: 1.6.
|
125
|
+
version: 1.6.1
|
126
126
|
- !ruby/object:Gem::Dependency
|
127
127
|
name: haml
|
128
128
|
requirement: !ruby/object:Gem::Requirement
|
@@ -357,11 +357,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
357
357
|
version: '0'
|
358
358
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
359
359
|
requirements:
|
360
|
-
- - "
|
360
|
+
- - ">="
|
361
361
|
- !ruby/object:Gem::Version
|
362
|
-
version:
|
362
|
+
version: '0'
|
363
363
|
requirements: []
|
364
|
-
rubygems_version: 3.1.
|
364
|
+
rubygems_version: 3.1.6
|
365
365
|
signing_key:
|
366
366
|
specification_version: 4
|
367
367
|
summary: Wagon is a site generator for the LocomotiveCMS engine powered by all the
|