scribo 1.0.42 → 1.0.44
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +30 -24
- data/app/assets/stylesheets/scribo/components/file-icons.css +7 -7
- data/app/assets/stylesheets/scribo/components/tree-view.css +11 -9
- data/app/models/scribo/content.rb +6 -3
- data/app/services/scribo/site_export_service.rb +2 -0
- data/lib/scribo/version.rb +1 -1
- data/scribo.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1afdd24cf12cb2306dad841425f948bbed9c5d0180478433841d83044efcb349
|
4
|
+
data.tar.gz: 8372cb65bbdbd763320b4136578eb4170273822b4694efe085096b2e1235fc19
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9fec9b1dca212ef7eefb1e1ccb2d82e43680e43b466b632e20d1f10f3b9c3295503b504be63b06e3b98d1a1cc0edeabbfcb6a53131656195f4cb578160c4912a
|
7
|
+
data.tar.gz: '059c41eb871820ce584a9f2539370c78026472c853ffd90bf4cf64fa645eebbb8eb16d31c67e36bd63dbd43c6884384a9067a7f2358ac02fe48926384590da07'
|
data/Gemfile.lock
CHANGED
@@ -9,9 +9,9 @@ GIT
|
|
9
9
|
PATH
|
10
10
|
remote: .
|
11
11
|
specs:
|
12
|
-
scribo (1.0.
|
13
|
-
ancestry
|
12
|
+
scribo (1.0.43)
|
14
13
|
babel-transpiler (~> 0.7)
|
14
|
+
closure_tree
|
15
15
|
down (~> 5.2)
|
16
16
|
importmap-rails
|
17
17
|
kaminari
|
@@ -107,8 +107,6 @@ GEM
|
|
107
107
|
tzinfo (~> 2.0)
|
108
108
|
addressable (2.8.6)
|
109
109
|
public_suffix (>= 2.0.2, < 6.0)
|
110
|
-
ancestry (4.3.3)
|
111
|
-
activerecord (>= 5.2.6)
|
112
110
|
ansi (1.5.0)
|
113
111
|
ast (2.4.2)
|
114
112
|
auxilium (3.0.24)
|
@@ -135,6 +133,9 @@ GEM
|
|
135
133
|
rack-test (>= 0.6.3)
|
136
134
|
regexp_parser (>= 1.5, < 3.0)
|
137
135
|
xpath (~> 3.2)
|
136
|
+
closure_tree (7.4.0)
|
137
|
+
activerecord (>= 4.2.10)
|
138
|
+
with_advisory_lock (>= 4.0.0)
|
138
139
|
coderay (1.1.3)
|
139
140
|
concurrent-ruby (1.2.3)
|
140
141
|
connection_pool (2.4.1)
|
@@ -143,7 +144,7 @@ GEM
|
|
143
144
|
capybara (~> 3.0)
|
144
145
|
ferrum (~> 0.14.0)
|
145
146
|
date (3.3.4)
|
146
|
-
down (5.4.
|
147
|
+
down (5.4.2)
|
147
148
|
addressable (~> 2.8)
|
148
149
|
drb (2.2.1)
|
149
150
|
erubi (1.12.0)
|
@@ -153,7 +154,7 @@ GEM
|
|
153
154
|
concurrent-ruby (~> 1.1)
|
154
155
|
webrick (~> 1.7)
|
155
156
|
websocket-driver (>= 0.6, < 0.8)
|
156
|
-
ffi (1.
|
157
|
+
ffi (1.17.0)
|
157
158
|
globalid (1.2.1)
|
158
159
|
activesupport (>= 6.1)
|
159
160
|
i18n (1.14.1)
|
@@ -187,19 +188,20 @@ GEM
|
|
187
188
|
kramdown-parser-gfm (1.1.0)
|
188
189
|
kramdown (~> 2.0)
|
189
190
|
language_server-protocol (3.17.0.3)
|
190
|
-
liquid (5.
|
191
|
-
liquidum (1.
|
191
|
+
liquid (5.3.0)
|
192
|
+
liquidum (1.2.1)
|
192
193
|
addressable (~> 2)
|
193
194
|
babel-transpiler (~> 0.7)
|
194
195
|
i18n (~> 1.8)
|
195
196
|
kramdown (~> 2.1)
|
196
197
|
kramdown-parser-gfm (~> 1.0)
|
197
|
-
liquid (
|
198
|
+
liquid (< 5.4)
|
198
199
|
parslet
|
199
200
|
pg
|
200
201
|
rails (>= 5.2)
|
201
202
|
sassc (~> 2.2)
|
202
|
-
slim-rails (~> 3.
|
203
|
+
slim-rails (~> 3.6)
|
204
|
+
logger (1.6.1)
|
203
205
|
loofah (2.22.0)
|
204
206
|
crass (~> 1.0.2)
|
205
207
|
nokogiri (>= 1.12.0)
|
@@ -211,9 +213,10 @@ GEM
|
|
211
213
|
marcel (1.0.4)
|
212
214
|
matrix (0.4.2)
|
213
215
|
method_source (1.0.0)
|
214
|
-
mime-types (3.
|
216
|
+
mime-types (3.6.0)
|
217
|
+
logger
|
215
218
|
mime-types-data (~> 3.2015)
|
216
|
-
mime-types-data (3.2024.
|
219
|
+
mime-types-data (3.2024.1001)
|
217
220
|
mimemagic (0.4.3)
|
218
221
|
nokogiri (~> 1)
|
219
222
|
rake
|
@@ -337,29 +340,28 @@ GEM
|
|
337
340
|
pg
|
338
341
|
rails (> 6.0)
|
339
342
|
state_machines-activemodel
|
340
|
-
slim (
|
341
|
-
temple (
|
342
|
-
tilt (>= 2.0
|
343
|
-
slim-rails (3.
|
343
|
+
slim (5.2.1)
|
344
|
+
temple (~> 0.10.0)
|
345
|
+
tilt (>= 2.1.0)
|
346
|
+
slim-rails (3.6.3)
|
344
347
|
actionpack (>= 3.1)
|
345
348
|
railties (>= 3.1)
|
346
|
-
slim (>= 3.0, < 5.0)
|
349
|
+
slim (>= 3.0, < 6.0, != 5.0.0)
|
347
350
|
state_machines (0.6.0)
|
348
351
|
state_machines-activemodel (0.9.0)
|
349
352
|
activemodel (>= 6.0)
|
350
353
|
state_machines (>= 0.6.0)
|
351
|
-
stimulus-rails (1.3.
|
354
|
+
stimulus-rails (1.3.4)
|
352
355
|
railties (>= 6.0.0)
|
353
356
|
stringio (3.1.0)
|
354
|
-
tailwindcss-rails (2.
|
355
|
-
railties (>=
|
356
|
-
temple (0.
|
357
|
+
tailwindcss-rails (2.7.7)
|
358
|
+
railties (>= 7.0.0)
|
359
|
+
temple (0.10.3)
|
357
360
|
thor (1.3.1)
|
358
|
-
tilt (2.0
|
361
|
+
tilt (2.4.0)
|
359
362
|
timeout (0.4.1)
|
360
|
-
turbo-rails (2.0.
|
363
|
+
turbo-rails (2.0.10)
|
361
364
|
actionpack (>= 6.0.0)
|
362
|
-
activejob (>= 6.0.0)
|
363
365
|
railties (>= 6.0.0)
|
364
366
|
tzinfo (2.0.6)
|
365
367
|
concurrent-ruby (~> 1.0)
|
@@ -369,6 +371,9 @@ GEM
|
|
369
371
|
websocket-driver (0.7.6)
|
370
372
|
websocket-extensions (>= 0.1.0)
|
371
373
|
websocket-extensions (0.1.5)
|
374
|
+
with_advisory_lock (5.1.0)
|
375
|
+
activerecord (>= 6.1)
|
376
|
+
zeitwerk (>= 2.6)
|
372
377
|
xpath (3.2.0)
|
373
378
|
nokogiri (~> 1.8)
|
374
379
|
zeitwerk (2.6.13)
|
@@ -379,6 +384,7 @@ PLATFORMS
|
|
379
384
|
DEPENDENCIES
|
380
385
|
auxilium (~> 3.0)
|
381
386
|
capybara
|
387
|
+
closure_tree
|
382
388
|
cuprite
|
383
389
|
jbuilder
|
384
390
|
key_path!
|
@@ -40,7 +40,7 @@
|
|
40
40
|
.name[data-path="LICENSE"] {
|
41
41
|
background-image: url("scribo/icons/markdown.svg");
|
42
42
|
}
|
43
|
-
|
43
|
+
/* script */
|
44
44
|
.name[data-path$=".js"] {
|
45
45
|
background-image: url("scribo/icons/javascript.svg");
|
46
46
|
}
|
@@ -54,7 +54,7 @@
|
|
54
54
|
background-image: url("scribo/icons/ruby.svg");
|
55
55
|
}
|
56
56
|
|
57
|
-
|
57
|
+
/* image */
|
58
58
|
.name[data-path$=".png"] {
|
59
59
|
background-image: url("scribo/icons/image.svg");
|
60
60
|
}
|
@@ -80,7 +80,7 @@
|
|
80
80
|
background-image: url("scribo/icons/image.svg");
|
81
81
|
}
|
82
82
|
|
83
|
-
|
83
|
+
/* video */
|
84
84
|
.name[data-path$=".webm"] {
|
85
85
|
background-image: url("scribo/icons/video.svg");
|
86
86
|
}
|
@@ -91,7 +91,7 @@
|
|
91
91
|
background-image: url("scribo/icons/video.svg");
|
92
92
|
}
|
93
93
|
|
94
|
-
|
94
|
+
/* audio */
|
95
95
|
.name[data-path$=".midi"] {
|
96
96
|
background-image: url("scribo/icons/audio.svg");
|
97
97
|
}
|
@@ -105,7 +105,7 @@
|
|
105
105
|
background-image: url("scribo/icons/audio.svg");
|
106
106
|
}
|
107
107
|
|
108
|
-
|
108
|
+
/* document */
|
109
109
|
.name[data-path$=".doc"] {
|
110
110
|
background-image: url("scribo/icons/word.svg");
|
111
111
|
}
|
@@ -134,7 +134,7 @@
|
|
134
134
|
background-image: url("scribo/icons/zip.svg");
|
135
135
|
}
|
136
136
|
|
137
|
-
|
137
|
+
/* font */
|
138
138
|
.name[data-path$=".eot"] {
|
139
139
|
background-image: url("scribo/icons/font.svg");
|
140
140
|
}
|
@@ -151,7 +151,7 @@
|
|
151
151
|
background-image: url("scribo/icons/font.svg");
|
152
152
|
}
|
153
153
|
|
154
|
-
|
154
|
+
/* other */
|
155
155
|
.name[data-path$=".link"] {
|
156
156
|
background-image: url("scribo/icons/http.svg");
|
157
157
|
}
|
@@ -201,15 +201,17 @@
|
|
201
201
|
background-size: 18px 18px;
|
202
202
|
}
|
203
203
|
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
204
|
+
/*
|
205
|
+
.tree-view .entry.selected:before {
|
206
|
+
content: '';
|
207
|
+
position: absolute;
|
208
|
+
left: 0;
|
209
|
+
right: 0;
|
210
|
+
height: 25px;
|
211
|
+
background-color: #f5f5f5;
|
212
|
+
z-index: -1;
|
213
|
+
}
|
214
|
+
*/
|
213
215
|
|
214
216
|
.tree-view .directory.closed > ul {
|
215
217
|
display: none;
|
@@ -9,6 +9,8 @@ module Scribo
|
|
9
9
|
belongs_to :site, class_name: 'Site', foreign_key: 'scribo_site_id'
|
10
10
|
has_one_attached :asset
|
11
11
|
|
12
|
+
|
13
|
+
|
12
14
|
validate :post_path
|
13
15
|
validate :layout_cant_be_current_content
|
14
16
|
|
@@ -18,6 +20,8 @@ module Scribo
|
|
18
20
|
after_save -> { store_full_path(true) }
|
19
21
|
after_update -> {store_full_path(true)}
|
20
22
|
|
23
|
+
|
24
|
+
|
21
25
|
scope :layouts, -> { in_folder('_layouts') }
|
22
26
|
scope :posts, -> { in_folder('_posts') }
|
23
27
|
scope :pages, -> { not_in_folder('_posts').restricted.where(kind: 'text') }
|
@@ -301,7 +305,7 @@ module Scribo
|
|
301
305
|
elsif part_of_collection? && site.output_collection?(collection_name)
|
302
306
|
result = "#{collection_name}/#{path}"
|
303
307
|
else
|
304
|
-
result = (ancestors.map(&:path) << path).join('/')
|
308
|
+
result = (ancestors.reverse.map(&:path) << path).join('/')
|
305
309
|
end
|
306
310
|
result = '/' + result unless result.start_with?('/')
|
307
311
|
|
@@ -313,9 +317,8 @@ module Scribo
|
|
313
317
|
end
|
314
318
|
end
|
315
319
|
|
316
|
-
|
317
320
|
def tree_path
|
318
|
-
result = (ancestors.map(&:path) << path).join('/')
|
321
|
+
result = (ancestors.reverse.map(&:path) << path).join('/')
|
319
322
|
result = '/' + result unless result.start_with?('/')
|
320
323
|
result
|
321
324
|
end
|
data/lib/scribo/version.rb
CHANGED
data/scribo.gemspec
CHANGED
@@ -20,7 +20,7 @@ Gem::Specification.new do |s|
|
|
20
20
|
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
21
21
|
end
|
22
22
|
|
23
|
-
s.add_dependency '
|
23
|
+
s.add_dependency 'closure_tree'
|
24
24
|
s.add_dependency 'babel-transpiler', '~> 0.7'
|
25
25
|
s.add_dependency 'down', '~> 5.2'
|
26
26
|
s.add_dependency 'kaminari'
|
metadata
CHANGED
@@ -1,17 +1,17 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scribo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.44
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tom de Grunt
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-10-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: closure_tree
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
17
|
- - ">="
|