trestle 0.8.4 → 0.8.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/.gitignore +4 -0
- data/.travis.yml +14 -1
- data/Gemfile +6 -0
- data/README.md +15 -9
- data/app/assets/javascripts/trestle/admin.js +11 -10
- data/app/assets/javascripts/trestle/components/_confirmation.js +40 -0
- data/app/assets/javascripts/trestle/components/_datepicker.js +37 -0
- data/app/assets/javascripts/trestle/components/_dialog.js +136 -0
- data/app/assets/javascripts/trestle/{_errors.js → components/_errors.js} +2 -2
- data/app/assets/javascripts/trestle/components/_form.js +75 -0
- data/app/assets/javascripts/trestle/{_gallery.js → components/_gallery.js} +3 -3
- data/app/assets/javascripts/trestle/{_select.js → components/_select.js} +2 -2
- data/app/assets/javascripts/trestle/components/_sidebar.js +77 -0
- data/app/assets/javascripts/trestle/{_table.js → components/_table.js} +1 -1
- data/app/assets/javascripts/trestle/components/_tabs.js +25 -0
- data/app/assets/javascripts/trestle/components/_tooltips.js +19 -0
- data/app/assets/javascripts/trestle/core/_contexts.js +13 -0
- data/app/assets/javascripts/trestle/core/_cookies.js +24 -0
- data/app/assets/javascripts/trestle/core/_events.js +39 -0
- data/app/assets/javascripts/trestle/core/_l10n.js +23 -0
- data/app/assets/javascripts/trestle/core/_visit.js +10 -0
- data/app/assets/stylesheets/trestle/components/_alerts.scss +28 -0
- data/app/assets/stylesheets/trestle/components/_avatar.scss +23 -1
- data/app/assets/stylesheets/trestle/components/_breadcrumbs.scss +12 -0
- data/app/assets/stylesheets/trestle/components/_buttons.scss +111 -1
- data/app/assets/stylesheets/trestle/components/_content.scss +53 -21
- data/app/assets/stylesheets/trestle/components/_datepicker.scss +28 -0
- data/app/assets/stylesheets/trestle/components/_fields.scss +17 -0
- data/app/assets/stylesheets/trestle/components/_input-group.scss +26 -1
- data/app/assets/stylesheets/trestle/components/_modal.scss +108 -0
- data/app/assets/stylesheets/trestle/components/_navigation.scss +104 -14
- data/app/assets/stylesheets/trestle/components/_pagination.scss +3 -3
- data/app/assets/stylesheets/trestle/components/_scopes.scss +11 -2
- data/app/assets/stylesheets/trestle/components/_sidebar.scss +3 -2
- data/app/assets/stylesheets/trestle/components/_table.scss +34 -10
- data/app/assets/stylesheets/trestle/components/_tags.scss +9 -0
- data/app/assets/stylesheets/trestle/components/_timestamp.scss +4 -1
- data/app/assets/stylesheets/trestle/components/_toolbars.scss +55 -0
- data/app/assets/stylesheets/trestle/components/_wells.scss +9 -1
- data/app/assets/stylesheets/trestle/core/_defaults.scss +21 -6
- data/app/assets/stylesheets/trestle/core/_layout.scss +8 -0
- data/app/assets/stylesheets/trestle/core/_mixins.scss +11 -0
- data/app/assets/stylesheets/trestle/core/_typography.scss +39 -0
- data/app/controllers/concerns/trestle/controller/breadcrumbs.rb +21 -0
- data/app/controllers/concerns/trestle/controller/callbacks.rb +21 -0
- data/app/controllers/concerns/trestle/controller/dialog.rb +16 -0
- data/app/controllers/concerns/trestle/controller/helpers.rb +18 -0
- data/app/controllers/concerns/trestle/controller/layout.rb +16 -0
- data/app/controllers/concerns/trestle/controller/location.rb +15 -0
- data/app/controllers/trestle/application_controller.rb +6 -30
- data/app/helpers/trestle/avatar_helper.rb +9 -2
- data/app/helpers/trestle/flash_helper.rb +15 -0
- data/app/helpers/trestle/form_helper.rb +8 -5
- data/app/helpers/trestle/format_helper.rb +7 -3
- data/app/helpers/trestle/headings_helper.rb +27 -0
- data/app/helpers/trestle/hook_helper.rb +13 -4
- data/app/helpers/trestle/i18n_helper.rb +14 -0
- data/app/helpers/trestle/panel_helper.rb +24 -0
- data/app/helpers/trestle/tab_helper.rb +2 -2
- data/app/helpers/trestle/table_helper.rb +41 -2
- data/app/helpers/trestle/timestamp_helper.rb +49 -7
- data/app/helpers/trestle/toolbars_helper.rb +34 -0
- data/app/helpers/trestle/url_helper.rb +72 -8
- data/app/views/layouts/trestle/admin.html.erb +3 -5
- data/app/views/trestle/application/_dialog.html.erb +34 -0
- data/app/views/trestle/application/_header.html.erb +22 -20
- data/app/views/trestle/application/_layout.html.erb +1 -1
- data/app/views/trestle/application/_tabs.html.erb +8 -2
- data/app/views/trestle/{application → flash}/_alert.html.erb +7 -2
- data/app/views/trestle/flash/_debug.html.erb +8 -0
- data/app/views/trestle/flash/_flash.html.erb +7 -0
- data/app/views/trestle/resource/_scopes.html.erb +1 -1
- data/app/views/trestle/resource/edit.html.erb +8 -10
- data/app/views/trestle/resource/index.html.erb +16 -4
- data/app/views/trestle/resource/new.html.erb +6 -6
- data/app/views/trestle/resource/show.html.erb +8 -10
- data/app/views/trestle/shared/_sidebar.html.erb +10 -7
- data/app/views/trestle/shared/_title.html.erb +14 -0
- data/app/views/trestle/table/_table.html.erb +4 -6
- data/bower.json +1 -1
- data/config/locales/cs.rb +18 -0
- data/config/locales/cs.yml +95 -0
- data/config/locales/en.yml +65 -36
- data/config/locales/es-MX.yml +94 -0
- data/config/locales/es.yml +94 -0
- data/config/locales/fr.rb +18 -0
- data/config/locales/fr.yml +84 -0
- data/config/locales/lv.rb +18 -0
- data/config/locales/lv.yml +94 -0
- data/config/locales/nl.rb +18 -0
- data/config/locales/nl.yml +82 -0
- data/config/locales/pl.rb +18 -0
- data/config/locales/pl.yml +85 -0
- data/config/locales/pt-BR.rb +18 -0
- data/config/locales/pt-BR.yml +84 -0
- data/config/locales/zh-CN.rb +18 -0
- data/config/locales/zh-CN.yml +94 -0
- data/gemfiles/rails-4.2.gemfile +16 -0
- data/gemfiles/rails-5.0.gemfile +16 -0
- data/gemfiles/rails-5.1.gemfile +16 -0
- data/gemfiles/rails-5.2.gemfile +16 -0
- data/gemfiles/rails-edge.gemfile +17 -0
- data/lib/generators/trestle/install/templates/trestle.rb.erb +18 -2
- data/lib/generators/trestle/resource/templates/admin.rb.erb +2 -2
- data/lib/trestle/adapters/active_record_adapter.rb +2 -6
- data/lib/trestle/adapters/adapter.rb +40 -15
- data/lib/trestle/adapters/sequel_adapter.rb +2 -6
- data/lib/trestle/admin/builder.rb +42 -12
- data/lib/trestle/admin/controller.rb +3 -1
- data/lib/trestle/admin.rb +84 -3
- data/lib/trestle/breadcrumb.rb +16 -1
- data/lib/trestle/configurable.rb +6 -0
- data/lib/trestle/configuration.rb +28 -5
- data/lib/trestle/display.rb +1 -1
- data/lib/trestle/engine.rb +10 -4
- data/lib/trestle/form/automatic.rb +6 -3
- data/lib/trestle/form/builder.rb +5 -1
- data/lib/trestle/form/field.rb +1 -1
- data/lib/trestle/form/fields/date_picker.rb +2 -2
- data/lib/trestle/form/fields/form_control.rb +14 -4
- data/lib/trestle/form/fields/form_group.rb +14 -3
- data/lib/trestle/form/fields/select.rb +5 -1
- data/lib/trestle/form/fields/tag_select.rb +1 -1
- data/lib/trestle/form/renderer.rb +2 -2
- data/lib/trestle/form.rb +7 -3
- data/lib/trestle/hook.rb +27 -0
- data/lib/trestle/model_name.rb +64 -0
- data/lib/trestle/navigation/group.rb +16 -0
- data/lib/trestle/navigation/item.rb +11 -1
- data/lib/trestle/navigation.rb +24 -6
- data/lib/trestle/options.rb +7 -5
- data/lib/trestle/reloader.rb +1 -1
- data/lib/trestle/resource/adapter_methods.rb +62 -0
- data/lib/trestle/resource/builder.rb +43 -17
- data/lib/trestle/resource/collection.rb +68 -0
- data/lib/trestle/resource/controller.rb +70 -33
- data/lib/trestle/resource.rb +97 -105
- data/lib/trestle/scope.rb +13 -3
- data/lib/trestle/tab.rb +4 -0
- data/lib/trestle/table/actions_column.rb +41 -31
- data/lib/trestle/table/automatic.rb +1 -2
- data/lib/trestle/table/builder.rb +2 -2
- data/lib/trestle/table/column.rb +40 -9
- data/lib/trestle/table/row.rb +18 -2
- data/lib/trestle/table.rb +18 -2
- data/lib/trestle/toolbar/builder.rb +52 -0
- data/lib/trestle/toolbar/context.rb +39 -0
- data/lib/trestle/toolbar.rb +43 -0
- data/lib/trestle/version.rb +1 -1
- data/lib/trestle.rb +9 -4
- data/trestle.gemspec +5 -3
- data/vendor/assets/bower_components/trestle/select2/dist/js/select2.full.js +90 -69
- data/vendor/assets/javascripts/trestle/flatpickr.js.erb +2 -0
- data/vendor/assets/stylesheets/trestle/magnific-popup.scss +13 -1
- metadata +99 -22
- data/app/assets/javascripts/trestle/_confirmation.js +0 -23
- data/app/assets/javascripts/trestle/_datepicker.js +0 -22
- data/app/assets/javascripts/trestle/_form.js +0 -6
- data/app/assets/javascripts/trestle/_sidebar.js +0 -52
- data/app/assets/javascripts/trestle/_tabs.js +0 -13
- data/app/assets/javascripts/trestle/_tooltips.js +0 -3
- data/app/helpers/trestle/title_helper.rb +0 -26
- data/app/views/trestle/application/_flash.html.erb +0 -11
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
//= require trestle/flatpickr/dist/flatpickr
|
|
2
2
|
|
|
3
|
+
<% flatpickr_locale_conversions = { ca: "cat", el: "gr", nb: "no", vi: "vn" } %>
|
|
3
4
|
<% I18n.available_locales.each do |locale| %>
|
|
5
|
+
<% locale = flatpickr_locale_conversions[locale] if flatpickr_locale_conversions.key?(locale) %>
|
|
4
6
|
<% require_asset("trestle/flatpickr/dist/l10n/#{locale}") rescue nil %>
|
|
5
7
|
<% end %>
|
|
@@ -1 +1,13 @@
|
|
|
1
|
-
@import "trestle/magnific-popup/dist/magnific-popup"
|
|
1
|
+
@import "trestle/magnific-popup/dist/magnific-popup";
|
|
2
|
+
|
|
3
|
+
$mfp-z-index-base: 1140;
|
|
4
|
+
|
|
5
|
+
.mfp-bg { z-index: $mfp-z-index-base + 2; }
|
|
6
|
+
.mfp-wrap { z-index: $mfp-z-index-base + 3; }
|
|
7
|
+
.mfp-content { z-index: $mfp-z-index-base + 5; }
|
|
8
|
+
.mfp-preloader { z-index: $mfp-z-index-base + 4; }
|
|
9
|
+
|
|
10
|
+
button.mfp-close,
|
|
11
|
+
button.mfp-arrow {
|
|
12
|
+
z-index: $mfp-z-index-base + 6;
|
|
13
|
+
}
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: trestle
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.8.
|
|
4
|
+
version: 0.8.11
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Sam Pohlenz
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2018-09-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: railties
|
|
@@ -24,32 +24,46 @@ dependencies:
|
|
|
24
24
|
- - ">="
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
26
|
version: 4.2.0
|
|
27
|
+
- !ruby/object:Gem::Dependency
|
|
28
|
+
name: activemodel
|
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
|
30
|
+
requirements:
|
|
31
|
+
- - ">="
|
|
32
|
+
- !ruby/object:Gem::Version
|
|
33
|
+
version: 4.2.0
|
|
34
|
+
type: :runtime
|
|
35
|
+
prerelease: false
|
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
37
|
+
requirements:
|
|
38
|
+
- - ">="
|
|
39
|
+
- !ruby/object:Gem::Version
|
|
40
|
+
version: 4.2.0
|
|
27
41
|
- !ruby/object:Gem::Dependency
|
|
28
42
|
name: sass-rails
|
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
|
30
44
|
requirements:
|
|
31
|
-
- - "
|
|
45
|
+
- - ">="
|
|
32
46
|
- !ruby/object:Gem::Version
|
|
33
47
|
version: 5.0.6
|
|
34
48
|
type: :runtime
|
|
35
49
|
prerelease: false
|
|
36
50
|
version_requirements: !ruby/object:Gem::Requirement
|
|
37
51
|
requirements:
|
|
38
|
-
- - "
|
|
52
|
+
- - ">="
|
|
39
53
|
- !ruby/object:Gem::Version
|
|
40
54
|
version: 5.0.6
|
|
41
55
|
- !ruby/object:Gem::Dependency
|
|
42
56
|
name: autoprefixer-rails
|
|
43
57
|
requirement: !ruby/object:Gem::Requirement
|
|
44
58
|
requirements:
|
|
45
|
-
- - "
|
|
59
|
+
- - ">="
|
|
46
60
|
- !ruby/object:Gem::Version
|
|
47
61
|
version: 7.1.2
|
|
48
62
|
type: :runtime
|
|
49
63
|
prerelease: false
|
|
50
64
|
version_requirements: !ruby/object:Gem::Requirement
|
|
51
65
|
requirements:
|
|
52
|
-
- - "
|
|
66
|
+
- - ">="
|
|
53
67
|
- !ruby/object:Gem::Version
|
|
54
68
|
version: 7.1.2
|
|
55
69
|
- !ruby/object:Gem::Dependency
|
|
@@ -58,14 +72,14 @@ dependencies:
|
|
|
58
72
|
requirements:
|
|
59
73
|
- - "~>"
|
|
60
74
|
- !ruby/object:Gem::Version
|
|
61
|
-
version: 1.0
|
|
75
|
+
version: 1.1.0
|
|
62
76
|
type: :runtime
|
|
63
77
|
prerelease: false
|
|
64
78
|
version_requirements: !ruby/object:Gem::Requirement
|
|
65
79
|
requirements:
|
|
66
80
|
- - "~>"
|
|
67
81
|
- !ruby/object:Gem::Version
|
|
68
|
-
version: 1.0
|
|
82
|
+
version: 1.1.0
|
|
69
83
|
- !ruby/object:Gem::Dependency
|
|
70
84
|
name: bundler
|
|
71
85
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -122,6 +136,20 @@ dependencies:
|
|
|
122
136
|
- - "~>"
|
|
123
137
|
- !ruby/object:Gem::Version
|
|
124
138
|
version: 0.7.1
|
|
139
|
+
- !ruby/object:Gem::Dependency
|
|
140
|
+
name: database_cleaner
|
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
|
142
|
+
requirements:
|
|
143
|
+
- - "~>"
|
|
144
|
+
- !ruby/object:Gem::Version
|
|
145
|
+
version: 1.6.2
|
|
146
|
+
type: :development
|
|
147
|
+
prerelease: false
|
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
149
|
+
requirements:
|
|
150
|
+
- - "~>"
|
|
151
|
+
- !ruby/object:Gem::Version
|
|
152
|
+
version: 1.6.2
|
|
125
153
|
- !ruby/object:Gem::Dependency
|
|
126
154
|
name: sqlite3
|
|
127
155
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -167,17 +195,23 @@ files:
|
|
|
167
195
|
- Rakefile
|
|
168
196
|
- app/assets/images/trestle/textures/billie-holiday.png
|
|
169
197
|
- app/assets/images/trestle/textures/bright-squares.png
|
|
170
|
-
- app/assets/javascripts/trestle/_confirmation.js
|
|
171
|
-
- app/assets/javascripts/trestle/_datepicker.js
|
|
172
|
-
- app/assets/javascripts/trestle/_errors.js
|
|
173
|
-
- app/assets/javascripts/trestle/_form.js
|
|
174
|
-
- app/assets/javascripts/trestle/_gallery.js
|
|
175
|
-
- app/assets/javascripts/trestle/_select.js
|
|
176
|
-
- app/assets/javascripts/trestle/_sidebar.js
|
|
177
|
-
- app/assets/javascripts/trestle/_table.js
|
|
178
|
-
- app/assets/javascripts/trestle/_tabs.js
|
|
179
|
-
- app/assets/javascripts/trestle/_tooltips.js
|
|
180
198
|
- app/assets/javascripts/trestle/admin.js
|
|
199
|
+
- app/assets/javascripts/trestle/components/_confirmation.js
|
|
200
|
+
- app/assets/javascripts/trestle/components/_datepicker.js
|
|
201
|
+
- app/assets/javascripts/trestle/components/_dialog.js
|
|
202
|
+
- app/assets/javascripts/trestle/components/_errors.js
|
|
203
|
+
- app/assets/javascripts/trestle/components/_form.js
|
|
204
|
+
- app/assets/javascripts/trestle/components/_gallery.js
|
|
205
|
+
- app/assets/javascripts/trestle/components/_select.js
|
|
206
|
+
- app/assets/javascripts/trestle/components/_sidebar.js
|
|
207
|
+
- app/assets/javascripts/trestle/components/_table.js
|
|
208
|
+
- app/assets/javascripts/trestle/components/_tabs.js
|
|
209
|
+
- app/assets/javascripts/trestle/components/_tooltips.js
|
|
210
|
+
- app/assets/javascripts/trestle/core/_contexts.js
|
|
211
|
+
- app/assets/javascripts/trestle/core/_cookies.js
|
|
212
|
+
- app/assets/javascripts/trestle/core/_events.js
|
|
213
|
+
- app/assets/javascripts/trestle/core/_l10n.js
|
|
214
|
+
- app/assets/javascripts/trestle/core/_visit.js
|
|
181
215
|
- app/assets/javascripts/trestle/custom.js
|
|
182
216
|
- app/assets/stylesheets/trestle/_custom.scss
|
|
183
217
|
- app/assets/stylesheets/trestle/_support.scss
|
|
@@ -197,6 +231,7 @@ files:
|
|
|
197
231
|
- app/assets/stylesheets/trestle/components/_header.scss
|
|
198
232
|
- app/assets/stylesheets/trestle/components/_input-group.scss
|
|
199
233
|
- app/assets/stylesheets/trestle/components/_media-grid.scss
|
|
234
|
+
- app/assets/stylesheets/trestle/components/_modal.scss
|
|
200
235
|
- app/assets/stylesheets/trestle/components/_navigation.scss
|
|
201
236
|
- app/assets/stylesheets/trestle/components/_pagination.scss
|
|
202
237
|
- app/assets/stylesheets/trestle/components/_popover.scss
|
|
@@ -207,31 +242,42 @@ files:
|
|
|
207
242
|
- app/assets/stylesheets/trestle/components/_tabs.scss
|
|
208
243
|
- app/assets/stylesheets/trestle/components/_tags.scss
|
|
209
244
|
- app/assets/stylesheets/trestle/components/_timestamp.scss
|
|
245
|
+
- app/assets/stylesheets/trestle/components/_toolbars.scss
|
|
210
246
|
- app/assets/stylesheets/trestle/components/_turbolinks.scss
|
|
211
247
|
- app/assets/stylesheets/trestle/components/_wells.scss
|
|
212
248
|
- app/assets/stylesheets/trestle/core/_defaults.scss
|
|
213
249
|
- app/assets/stylesheets/trestle/core/_layout.scss
|
|
214
250
|
- app/assets/stylesheets/trestle/core/_mixins.scss
|
|
215
251
|
- app/assets/stylesheets/trestle/core/_typography.scss
|
|
252
|
+
- app/controllers/concerns/trestle/controller/breadcrumbs.rb
|
|
253
|
+
- app/controllers/concerns/trestle/controller/callbacks.rb
|
|
254
|
+
- app/controllers/concerns/trestle/controller/dialog.rb
|
|
255
|
+
- app/controllers/concerns/trestle/controller/helpers.rb
|
|
256
|
+
- app/controllers/concerns/trestle/controller/layout.rb
|
|
257
|
+
- app/controllers/concerns/trestle/controller/location.rb
|
|
216
258
|
- app/controllers/trestle/application_controller.rb
|
|
217
259
|
- app/controllers/trestle/dashboard_controller.rb
|
|
218
260
|
- app/helpers/trestle/avatar_helper.rb
|
|
219
261
|
- app/helpers/trestle/container_helper.rb
|
|
220
262
|
- app/helpers/trestle/display_helper.rb
|
|
263
|
+
- app/helpers/trestle/flash_helper.rb
|
|
221
264
|
- app/helpers/trestle/form_helper.rb
|
|
222
265
|
- app/helpers/trestle/format_helper.rb
|
|
223
266
|
- app/helpers/trestle/grid_helper.rb
|
|
267
|
+
- app/helpers/trestle/headings_helper.rb
|
|
224
268
|
- app/helpers/trestle/hook_helper.rb
|
|
269
|
+
- app/helpers/trestle/i18n_helper.rb
|
|
225
270
|
- app/helpers/trestle/icon_helper.rb
|
|
226
271
|
- app/helpers/trestle/navigation_helper.rb
|
|
227
272
|
- app/helpers/trestle/pagination_helper.rb
|
|
273
|
+
- app/helpers/trestle/panel_helper.rb
|
|
228
274
|
- app/helpers/trestle/params_helper.rb
|
|
229
275
|
- app/helpers/trestle/sort_helper.rb
|
|
230
276
|
- app/helpers/trestle/status_helper.rb
|
|
231
277
|
- app/helpers/trestle/tab_helper.rb
|
|
232
278
|
- app/helpers/trestle/table_helper.rb
|
|
233
279
|
- app/helpers/trestle/timestamp_helper.rb
|
|
234
|
-
- app/helpers/trestle/
|
|
280
|
+
- app/helpers/trestle/toolbars_helper.rb
|
|
235
281
|
- app/helpers/trestle/url_helper.rb
|
|
236
282
|
- app/views/kaminari/trestle/_first_page.html.erb
|
|
237
283
|
- app/views/kaminari/trestle/_gap.html.erb
|
|
@@ -240,13 +286,15 @@ files:
|
|
|
240
286
|
- app/views/kaminari/trestle/_paginator.html.erb
|
|
241
287
|
- app/views/layouts/trestle/admin.html.erb
|
|
242
288
|
- app/views/trestle/admin/index.html.erb
|
|
243
|
-
- app/views/trestle/application/
|
|
244
|
-
- app/views/trestle/application/_flash.html.erb
|
|
289
|
+
- app/views/trestle/application/_dialog.html.erb
|
|
245
290
|
- app/views/trestle/application/_header.html.erb
|
|
246
291
|
- app/views/trestle/application/_layout.html.erb
|
|
247
292
|
- app/views/trestle/application/_tabs.html.erb
|
|
248
293
|
- app/views/trestle/application/_utilities.html.erb
|
|
249
294
|
- app/views/trestle/dashboard/index.html.erb
|
|
295
|
+
- app/views/trestle/flash/_alert.html.erb
|
|
296
|
+
- app/views/trestle/flash/_debug.html.erb
|
|
297
|
+
- app/views/trestle/flash/_flash.html.erb
|
|
250
298
|
- app/views/trestle/resource/_form.html.erb
|
|
251
299
|
- app/views/trestle/resource/_scopes.html.erb
|
|
252
300
|
- app/views/trestle/resource/_table.html.erb
|
|
@@ -257,14 +305,36 @@ files:
|
|
|
257
305
|
- app/views/trestle/shared/_footer.html.erb
|
|
258
306
|
- app/views/trestle/shared/_header.html.erb
|
|
259
307
|
- app/views/trestle/shared/_sidebar.html.erb
|
|
308
|
+
- app/views/trestle/shared/_title.html.erb
|
|
260
309
|
- app/views/trestle/table/_pagination.html.erb
|
|
261
310
|
- app/views/trestle/table/_table.html.erb
|
|
262
311
|
- bin/console
|
|
263
312
|
- bin/setup
|
|
264
313
|
- bower.json
|
|
314
|
+
- config/locales/cs.rb
|
|
315
|
+
- config/locales/cs.yml
|
|
265
316
|
- config/locales/en.rb
|
|
266
317
|
- config/locales/en.yml
|
|
318
|
+
- config/locales/es-MX.yml
|
|
319
|
+
- config/locales/es.yml
|
|
320
|
+
- config/locales/fr.rb
|
|
321
|
+
- config/locales/fr.yml
|
|
322
|
+
- config/locales/lv.rb
|
|
323
|
+
- config/locales/lv.yml
|
|
324
|
+
- config/locales/nl.rb
|
|
325
|
+
- config/locales/nl.yml
|
|
326
|
+
- config/locales/pl.rb
|
|
327
|
+
- config/locales/pl.yml
|
|
328
|
+
- config/locales/pt-BR.rb
|
|
329
|
+
- config/locales/pt-BR.yml
|
|
330
|
+
- config/locales/zh-CN.rb
|
|
331
|
+
- config/locales/zh-CN.yml
|
|
267
332
|
- config/routes.rb
|
|
333
|
+
- gemfiles/rails-4.2.gemfile
|
|
334
|
+
- gemfiles/rails-5.0.gemfile
|
|
335
|
+
- gemfiles/rails-5.1.gemfile
|
|
336
|
+
- gemfiles/rails-5.2.gemfile
|
|
337
|
+
- gemfiles/rails-edge.gemfile
|
|
268
338
|
- lib/generators/trestle/admin/admin_generator.rb
|
|
269
339
|
- lib/generators/trestle/admin/templates/admin.rb.erb
|
|
270
340
|
- lib/generators/trestle/admin/templates/index.html.erb
|
|
@@ -329,6 +399,8 @@ files:
|
|
|
329
399
|
- lib/trestle/form/fields/url_field.rb
|
|
330
400
|
- lib/trestle/form/fields/week_field.rb
|
|
331
401
|
- lib/trestle/form/renderer.rb
|
|
402
|
+
- lib/trestle/hook.rb
|
|
403
|
+
- lib/trestle/model_name.rb
|
|
332
404
|
- lib/trestle/navigation.rb
|
|
333
405
|
- lib/trestle/navigation/block.rb
|
|
334
406
|
- lib/trestle/navigation/group.rb
|
|
@@ -336,7 +408,9 @@ files:
|
|
|
336
408
|
- lib/trestle/options.rb
|
|
337
409
|
- lib/trestle/reloader.rb
|
|
338
410
|
- lib/trestle/resource.rb
|
|
411
|
+
- lib/trestle/resource/adapter_methods.rb
|
|
339
412
|
- lib/trestle/resource/builder.rb
|
|
413
|
+
- lib/trestle/resource/collection.rb
|
|
340
414
|
- lib/trestle/resource/controller.rb
|
|
341
415
|
- lib/trestle/scope.rb
|
|
342
416
|
- lib/trestle/tab.rb
|
|
@@ -347,6 +421,9 @@ files:
|
|
|
347
421
|
- lib/trestle/table/column.rb
|
|
348
422
|
- lib/trestle/table/row.rb
|
|
349
423
|
- lib/trestle/table/select_column.rb
|
|
424
|
+
- lib/trestle/toolbar.rb
|
|
425
|
+
- lib/trestle/toolbar/builder.rb
|
|
426
|
+
- lib/trestle/toolbar/context.rb
|
|
350
427
|
- lib/trestle/version.rb
|
|
351
428
|
- trestle.gemspec
|
|
352
429
|
- vendor/assets/bower_components/trestle/bootstrap-confirmation2/bootstrap-confirmation.js
|
|
@@ -560,7 +637,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
560
637
|
version: '0'
|
|
561
638
|
requirements: []
|
|
562
639
|
rubyforge_project:
|
|
563
|
-
rubygems_version: 2.6
|
|
640
|
+
rubygems_version: 2.7.6
|
|
564
641
|
signing_key:
|
|
565
642
|
specification_version: 4
|
|
566
643
|
summary: A modern, responsive admin framework for Ruby on Rails
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
Trestle.ready(function() {
|
|
2
|
-
// This must be bound to an element beneath document so
|
|
3
|
-
// that it is fired before any jquery_ujs events.
|
|
4
|
-
var root = $('body');
|
|
5
|
-
|
|
6
|
-
// Ensure it is only initialized once
|
|
7
|
-
if (root.data('bs.confirmation')) return;
|
|
8
|
-
|
|
9
|
-
root.confirmation({
|
|
10
|
-
rootSelector: 'body',
|
|
11
|
-
selector: '[data-toggle="confirm-delete"]',
|
|
12
|
-
singleton: true,
|
|
13
|
-
popout: true,
|
|
14
|
-
title: Trestle.i18n['admin.confirmation.title'],
|
|
15
|
-
btnOkIcon: '',
|
|
16
|
-
btnOkClass: 'btn-danger',
|
|
17
|
-
btnOkLabel: Trestle.i18n['admin.confirmation.delete'] || 'Delete',
|
|
18
|
-
btnCancelIcon: '',
|
|
19
|
-
btnCancelClass: 'btn-default',
|
|
20
|
-
btnCancelLabel: Trestle.i18n['admin.confirmation.cancel'] || 'Cancel',
|
|
21
|
-
copyAttributes: ''
|
|
22
|
-
});
|
|
23
|
-
});
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
Trestle.ready(function() {
|
|
2
|
-
$('input[type="date"][data-picker="true"]').flatpickr({
|
|
3
|
-
allowInput: true,
|
|
4
|
-
altInput: true,
|
|
5
|
-
altFormat: "m/d/Y",
|
|
6
|
-
});
|
|
7
|
-
|
|
8
|
-
$('input[type="datetime"][data-picker="true"], input[type="datetime-local"][data-picker="true"]').flatpickr({
|
|
9
|
-
enableTime: true,
|
|
10
|
-
allowInput: true,
|
|
11
|
-
altInput: true,
|
|
12
|
-
altFormat: "m/d/Y h:i K",
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
$('input[type="time"][data-picker="true"]').flatpickr({
|
|
16
|
-
enableTime: true,
|
|
17
|
-
noCalendar: true,
|
|
18
|
-
allowInput: true,
|
|
19
|
-
altInput: true,
|
|
20
|
-
altFormat: "h:i K"
|
|
21
|
-
});
|
|
22
|
-
});
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
Trestle.ready(function() {
|
|
2
|
-
var sidebar = $('.app-sidebar');
|
|
3
|
-
|
|
4
|
-
// Toggle mobile navigation using menu button
|
|
5
|
-
|
|
6
|
-
sidebar.find('.navbar-toggle').on('click', function(e) {
|
|
7
|
-
e.preventDefault();
|
|
8
|
-
|
|
9
|
-
$('.app-wrapper').addClass('animate');
|
|
10
|
-
$('body').toggleClass('mobile-nav-expanded');
|
|
11
|
-
});
|
|
12
|
-
|
|
13
|
-
$('.app-wrapper').on('transitionend webkitTransitionEnd', function() {
|
|
14
|
-
$(this).removeClass('animate');
|
|
15
|
-
});
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
// Interacting outside of the sidebar closes the navigation
|
|
19
|
-
|
|
20
|
-
$('.app-wrapper').on('click touchstart', function(e) {
|
|
21
|
-
var navExpanded = $('body').hasClass('mobile-nav-expanded');
|
|
22
|
-
|
|
23
|
-
var clickInHeader = $(e.target).closest('.app-header').length;
|
|
24
|
-
var clickInSidebar = $(e.target).closest('.app-sidebar').length;
|
|
25
|
-
|
|
26
|
-
if (navExpanded && !clickInHeader && !clickInSidebar) {
|
|
27
|
-
e.stopPropagation();
|
|
28
|
-
e.preventDefault();
|
|
29
|
-
|
|
30
|
-
$('.app-wrapper').addClass('animate');
|
|
31
|
-
$('body').removeClass('mobile-nav-expanded');
|
|
32
|
-
}
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
// Toggle sidebar expand/collapse
|
|
37
|
-
|
|
38
|
-
sidebar.find('.toggle-sidebar').on('click', function(e) {
|
|
39
|
-
e.preventDefault();
|
|
40
|
-
|
|
41
|
-
if (sidebar.hasClass('expanded') || sidebar.hasClass('collapsed')) {
|
|
42
|
-
sidebar.removeClass('expanded').removeClass('collapsed');
|
|
43
|
-
document.cookie = "trestle:sidebar=; path=/; expires=Thu, 01 Jan 1970 00:00:00 GMT";
|
|
44
|
-
} else if ($(document).width() >= 1200) {
|
|
45
|
-
sidebar.addClass('collapsed');
|
|
46
|
-
document.cookie = "trestle:sidebar=collapsed; path=/";
|
|
47
|
-
} else if ($(document).width() >= 768) {
|
|
48
|
-
sidebar.addClass('expanded');
|
|
49
|
-
document.cookie = "trestle:sidebar=expanded; path=/";
|
|
50
|
-
}
|
|
51
|
-
});
|
|
52
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
Trestle.ready(function() {
|
|
2
|
-
$("a[data-toggle='tab']").on('shown.bs.tab', function(e) {
|
|
3
|
-
var hash = $(this).attr("href");
|
|
4
|
-
|
|
5
|
-
if (hash.substr(0, 1) == "#") {
|
|
6
|
-
history.replaceState({ turbolinks: {} }, "", "#!" + hash.substr(1));
|
|
7
|
-
}
|
|
8
|
-
});
|
|
9
|
-
|
|
10
|
-
if (location.hash.substr(0, 2) == "#!") {
|
|
11
|
-
$("a[data-toggle='tab'][href='#" + location.hash.substr(2) + "']").tab("show");
|
|
12
|
-
}
|
|
13
|
-
});
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
module Trestle
|
|
2
|
-
module TitleHelper
|
|
3
|
-
def trestle_title
|
|
4
|
-
if Trestle.config.site_logo
|
|
5
|
-
if Trestle.config.site_logo_small
|
|
6
|
-
safe_join([
|
|
7
|
-
image_tag(Trestle.config.site_logo, class: "visible-xs-inline visible-lg-inline", alt: Trestle.config.site_title),
|
|
8
|
-
image_tag(Trestle.config.site_logo_small, class: "visible-sm-inline visible-md-inline", alt: Trestle.config.site_title)
|
|
9
|
-
], "\n")
|
|
10
|
-
else
|
|
11
|
-
image_tag(Trestle.config.site_logo)
|
|
12
|
-
end
|
|
13
|
-
elsif Trestle.config.site_logo_small
|
|
14
|
-
safe_join([
|
|
15
|
-
image_tag(Trestle.config.site_logo_small, alt: ""),
|
|
16
|
-
content_tag(:span, Trestle.config.site_title, class: "visible-xs-inline visible-lg-inline")
|
|
17
|
-
], "\n")
|
|
18
|
-
else
|
|
19
|
-
safe_join([
|
|
20
|
-
content_tag(:span, Trestle.config.site_title, class: "visible-xs-inline visible-lg-inline"),
|
|
21
|
-
content_tag(:span, Trestle.config.site_title.split(/ /).map(&:first).first(3).join, class: "visible-sm-inline visible-md-inline")
|
|
22
|
-
], "\n")
|
|
23
|
-
end
|
|
24
|
-
end
|
|
25
|
-
end
|
|
26
|
-
end
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
<% if flash[:message] -%>
|
|
2
|
-
<%= render "alert", html_class: "alert-success",
|
|
3
|
-
icon: icon("alert-icon ion-ios-checkmark-outline"),
|
|
4
|
-
title: t("trestle.flash.success.title", default: "Success!"),
|
|
5
|
-
message: flash[:message] %>
|
|
6
|
-
<% elsif flash[:error] -%>
|
|
7
|
-
<%= render "alert", html_class: "alert-danger",
|
|
8
|
-
icon: icon("alert-icon ion-ios-close-outline"),
|
|
9
|
-
title: t("trestle.flash.failure.title", default: "Warning!"),
|
|
10
|
-
message: flash[:error] %>
|
|
11
|
-
<% end -%>
|