katalyst-kpop 2.0.3 → 2.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/app/helpers/kpop_helper.rb +7 -4
- data/lib/katalyst/kpop/version.rb +1 -1
- metadata +2 -3
- data/lib/tasks/yarn.rake +0 -23
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 132ccf15922a7201b808f5e05d0ebfa5294a80fb52fbffd9394b17620ef7e841
|
4
|
+
data.tar.gz: ab016bd132de1ad7e039e4eca8e0e5aeb5668442a26d08be233625b864d34754
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e46ae5a99a83e236123445f6273a0d5aa44a7e7d42676ed775d2fe523629f6ba7dcde29ceec1a8c650e7ec77d1d6460fa62abdf296e342335270f79aeb2b4a4e
|
7
|
+
data.tar.gz: 63e704500714934863e32822335956c3896bea1670ff141ddfb32679369c4087e028077fbb487f24b9639cca30ec89099c44f76b8b4a507c9e3d77bd00332227
|
data/README.md
CHANGED
@@ -96,7 +96,7 @@ frame. The targeted action will need to generate content in a `kpop_frame_tag`,
|
|
96
96
|
```
|
97
97
|
|
98
98
|
Note that, because kpop modals render in a turbo frame, if you want to navigate the parent frame you will need to use
|
99
|
-
`target: "_top"` on your links and forms.
|
99
|
+
`target: "_top"` on your links and forms, or add `target: "_top"` to the `kpop_frame_tag` call in your body.
|
100
100
|
|
101
101
|
## Development
|
102
102
|
|
data/app/helpers/kpop_helper.rb
CHANGED
@@ -13,10 +13,13 @@ module KpopHelper
|
|
13
13
|
end
|
14
14
|
|
15
15
|
# Render a turbo frame tag that can be targeted for rendering kpop modals.
|
16
|
-
def kpop_frame_tag(&block)
|
17
|
-
|
18
|
-
|
19
|
-
|
16
|
+
def kpop_frame_tag(**html_attributes, &block)
|
17
|
+
html_attributes[:class] ||= "kpop-container"
|
18
|
+
html_attributes[:data] ||= {}
|
19
|
+
html_attributes[:data][:controller] = "kpop"
|
20
|
+
html_attributes[:data][:action] = "scrim:hide@window->kpop#dismiss"
|
21
|
+
|
22
|
+
turbo_frame_tag("kpop", **html_attributes) do
|
20
23
|
capture(&block) if block
|
21
24
|
end
|
22
25
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: katalyst-kpop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Katalyst Interactive
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-07-28 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description:
|
14
14
|
email:
|
@@ -38,7 +38,6 @@ files:
|
|
38
38
|
- lib/katalyst/kpop.rb
|
39
39
|
- lib/katalyst/kpop/engine.rb
|
40
40
|
- lib/katalyst/kpop/version.rb
|
41
|
-
- lib/tasks/yarn.rake
|
42
41
|
homepage: https://github.com/katalyst/kpop
|
43
42
|
licenses:
|
44
43
|
- MIT
|
data/lib/tasks/yarn.rake
DELETED
@@ -1,23 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
namespace :yarn do
|
4
|
-
desc "Install npm packages with yarn"
|
5
|
-
task install: :environment do
|
6
|
-
sh "yarn install"
|
7
|
-
end
|
8
|
-
|
9
|
-
desc "Lint JS/SCSS files using yarn (prettier)"
|
10
|
-
task lint: :install do
|
11
|
-
sh "yarn lint"
|
12
|
-
end
|
13
|
-
|
14
|
-
desc "Autoformat JS/SCSS files using yarn (prettier)"
|
15
|
-
task format: :install do
|
16
|
-
sh "yarn format"
|
17
|
-
end
|
18
|
-
|
19
|
-
desc "Compile js/css"
|
20
|
-
task build: :install do
|
21
|
-
sh "yarn build && yarn build:css"
|
22
|
-
end
|
23
|
-
end
|