cyperful 0.1.9 → 0.1.10
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 +4 -4
- data/lib/cyperful/framework_injections.rb +0 -10
- data/lib/cyperful/railtie.rb +9 -0
- data/lib/cyperful.rb +1 -0
- data/public/assets/{index--K1anXib.js → index-CrBQcYdq.js} +14 -14
- data/public/assets/{syntax-highlighter-worker-BSRAN01e.js → syntax-highlighter-worker-Cumko8SL.js} +1 -1
- data/public/index.html +1 -1
- metadata +5 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f340215ffcef3e16c1738d36eb2b71461bbd32e2011598d000793326f806b6d4
|
4
|
+
data.tar.gz: 545e19084294a2d481a7e9d156f6ba5e4758fb52332c17dc2e2574be820b2256
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 524bbb91d707a457adfa888bc8db5a2d97886714dedc026d8647d2f243f8ff381f46a47af8cffe3fb4d46242aacfd515f2dda1b2a794252f758b5899ca312e9a
|
7
|
+
data.tar.gz: e20223308f8c0df25df5aab64d97f24d4ef6f0b57bb530106e82a3234f5701f1ca434afa87dad9b50155f73043aef6b1afbe328ebb99aed35ad53fac29dc5ef9
|
@@ -98,15 +98,5 @@ ActionDispatch::SystemTesting::Driver.prepend(PrependSystemTestingDriver)
|
|
98
98
|
# Minitest::Test::PASSTHROUGH_EXCEPTIONS << Cyperful::AbstractCommand
|
99
99
|
# end
|
100
100
|
|
101
|
-
# we need to allow the iframe to be embedded in the cyperful server
|
102
|
-
# TODO: use Rack middleware instead to support non-Rails apps
|
103
|
-
if defined?(Rails)
|
104
|
-
Rails.application.config.content_security_policy do |policy|
|
105
|
-
policy.frame_ancestors(:self, "localhost:#{Cyperful.config.port}")
|
106
|
-
end
|
107
|
-
else
|
108
|
-
warn "Cyperful: Rails not detected, skipping content_security_policy fix.\nThe Cyperful UI may not work correctly."
|
109
|
-
end
|
110
|
-
|
111
101
|
# fix for: Set-Cookie (SameSite=Lax) doesn't work when within an iframe with host 127.0.0.1
|
112
102
|
Capybara.server_host = "localhost"
|
@@ -0,0 +1,9 @@
|
|
1
|
+
# we need to allow the iframe to be embedded in the cyperful server
|
2
|
+
# TODO: consider Rack middleware instead to support non-Rails apps?
|
3
|
+
class Cyperful::Railtie < Rails::Railtie
|
4
|
+
config.after_initialize do |app|
|
5
|
+
app.config.content_security_policy do |policy|
|
6
|
+
policy.frame_ancestors(:self, "localhost:#{Cyperful.config.port}")
|
7
|
+
end
|
8
|
+
end
|
9
|
+
end
|
data/lib/cyperful.rb
CHANGED