frozen_rails 0.0.7 → 0.0.8
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
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b5bb2f03024a8d7fe0378a3bc7bf968947e1a1f93972d0531da354a5971e182d
|
|
4
|
+
data.tar.gz: 6178832be002fb37d3dffb32d3209142facc34cbaf8a0c97bbd8a5bcbbca416f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 7874f3f9d5634b77f00e4873df2688ecd75f3964e31e73b6a01677418375583aa119bfdce42ab402baaf3cf6e2a15754d29cb088bd541d68245c692d5b28f3f4
|
|
7
|
+
data.tar.gz: c4e2fb6e64e819eb4665fcb09527dbc149c721f6720eda96e5957f98c127809cae5f977de7d92b62b1e0b9d1b4a4e39bad561c8d5c9fbf35b45207e2af0cef35
|
data/lib/frozen_rails/version.rb
CHANGED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html style="background-color: <%= params.dig(:lookbook, :display, :bg_color) || "white" %>">
|
|
3
|
+
<head>
|
|
4
|
+
<title>Component Preview</title>
|
|
5
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
|
6
|
+
|
|
7
|
+
<%# Use propshaft in development and precompiled_assets in production. Very brittle. %>
|
|
8
|
+
<% if Rails.env.development? %>
|
|
9
|
+
<%= stylesheet_link_tag :app, media: 'all' %>
|
|
10
|
+
<% else %>
|
|
11
|
+
<%= stylesheet_link_tag "application", media: 'all' %>
|
|
12
|
+
<% end %>
|
|
13
|
+
<%= javascript_include_tag 'application' %>
|
|
14
|
+
</head>
|
|
15
|
+
|
|
16
|
+
<body style="padding: 20px">
|
|
17
|
+
<div style="margin-left: auto; margin-right: auto; max-width: <%= params.dig(:lookbook, :display, :max_width) || "100%" %>">
|
|
18
|
+
<%= yield %>
|
|
19
|
+
</div>
|
|
20
|
+
</body>
|
|
21
|
+
</html>
|
|
@@ -130,6 +130,7 @@ YAML4
|
|
|
130
130
|
config.view_component.generate.preview = true
|
|
131
131
|
config.view_component.generate.preview_path = "test/components"
|
|
132
132
|
config.view_component.generate.locale = true
|
|
133
|
+
config.view_component.previews.default_layout = "component_preview"
|
|
133
134
|
config.asset_path = "/assets"
|
|
134
135
|
# Use propshaft in development and precompiled_assets in production. Very brittle.
|
|
135
136
|
config.assets.paths << Rails.root.join("app/assets") if Rails.env.development?
|
|
@@ -138,6 +139,7 @@ YAML4
|
|
|
138
139
|
|
|
139
140
|
def setup_lookbook
|
|
140
141
|
copy_file "lookbook/lookbook_helper.rb", "app/helpers/lookbook_helper.rb"
|
|
142
|
+
copy_file "lookbook/component_preview.html.erb", "app/views/layouts/component_preview.html.erb"
|
|
141
143
|
|
|
142
144
|
config = <<~RUBY
|
|
143
145
|
# frozen:ui
|
|
@@ -170,6 +172,7 @@ YAML4
|
|
|
170
172
|
|
|
171
173
|
def copy_demo_component
|
|
172
174
|
copy_directory "demo_component", "app/components"
|
|
175
|
+
empty_directory "test/components"
|
|
173
176
|
copy_directory "demo_component_test", "test/components"
|
|
174
177
|
end
|
|
175
178
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: frozen_rails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Klaus Weidinger
|
|
@@ -135,6 +135,7 @@ files:
|
|
|
135
135
|
- lib/generators/frozen/templates/ui/lib/templates/view_component/frozen_extensions/unpoly_compiler.js.tt
|
|
136
136
|
- lib/generators/frozen/templates/ui/lib/templates/view_component/frozen_extensions/view_spec.rb.tt
|
|
137
137
|
- lib/generators/frozen/templates/ui/lib/templates/view_component/preview/component_preview.rb.tt
|
|
138
|
+
- lib/generators/frozen/templates/ui/lookbook/component_preview.html.erb
|
|
138
139
|
- lib/generators/frozen/templates/ui/lookbook/lookbook_helper.rb
|
|
139
140
|
- lib/generators/frozen/ui_generator.rb
|
|
140
141
|
homepage: https://github.com/dunkelziffer/frozen_rails
|