ponkotsu-md-editor 0.2.37 → 0.3.0
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: 2b5d9c48a261404a86755c2f7ddb86107ad4eb4542ff32b168b840e30e487b6f
|
|
4
|
+
data.tar.gz: 1c52ab405ad31d840defe057c86b4d5e4fb51de0d6e7c720577e7de44d1a5f75
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0dcc1603a4e7e39ec12559e796ba370b86b4d733e477090a862d3a7e64632cfc507fd9844ada34c0f966a812727a45fba5803ded816c9051a01c80cdd4ddd795
|
|
7
|
+
data.tar.gz: 9410db0726fde2dd9a395afe6a719e9e2aeab6c5a228322b600674bfd06e54bdac54d0d988d6b080270072857dc58d45340714852acea2a81596e404daf7e39d
|
|
@@ -151,10 +151,20 @@
|
|
|
151
151
|
// 同期的に値を設定(確実性のため)
|
|
152
152
|
hiddenField.value = (textarea.innerText || '').replaceAll('\u00A0', ' ');
|
|
153
153
|
|
|
154
|
+
// 送信ボタンのパラメーターを取得して追加
|
|
155
|
+
const submitter = e.submitter;
|
|
156
|
+
if (submitter && submitter.name && submitter.value) {
|
|
157
|
+
const input = document.createElement('input');
|
|
158
|
+
input.type = 'hidden';
|
|
159
|
+
input.name = submitter.name;
|
|
160
|
+
input.value = submitter.value;
|
|
161
|
+
form.appendChild(input);
|
|
162
|
+
}
|
|
163
|
+
|
|
154
164
|
// 次のティックで送信
|
|
155
165
|
setTimeout(() => {
|
|
156
166
|
// console.log('Form submitting with content length:', hiddenField.value.length);
|
|
157
|
-
form.
|
|
167
|
+
form.submit();
|
|
158
168
|
}, 0);
|
|
159
169
|
});
|
|
160
170
|
}
|
|
@@ -28,7 +28,8 @@ module PonkotsuMdEditor
|
|
|
28
28
|
attribute = attribute[:attribute] if attribute.is_a?(Hash)
|
|
29
29
|
content = content[:attribute] if content.is_a?(Hash)
|
|
30
30
|
options = options[:options] if options.is_a?(Hash)
|
|
31
|
-
render "ponkotsu_md_editor/editor",
|
|
31
|
+
render "ponkotsu_md_editor/editor",
|
|
32
|
+
locals: { attribute: attribute, content: content, form: form, options: options }
|
|
32
33
|
end
|
|
33
34
|
end
|
|
34
35
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ponkotsu-md-editor
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.3.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- dhq_boiler
|
|
@@ -15,14 +15,14 @@ dependencies:
|
|
|
15
15
|
requirements:
|
|
16
16
|
- - "~>"
|
|
17
17
|
- !ruby/object:Gem::Version
|
|
18
|
-
version: 8.
|
|
18
|
+
version: '8.1'
|
|
19
19
|
type: :runtime
|
|
20
20
|
prerelease: false
|
|
21
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
22
22
|
requirements:
|
|
23
23
|
- - "~>"
|
|
24
24
|
- !ruby/object:Gem::Version
|
|
25
|
-
version: 8.
|
|
25
|
+
version: '8.1'
|
|
26
26
|
description: There is a bug in Chrome where entering large amounts of text into a
|
|
27
27
|
textarea element causes significant slowness (https://issues.chromium.org/issues/341564372).
|
|
28
28
|
This gem serves as a countermeasure for that issue.
|
|
@@ -64,7 +64,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
64
64
|
requirements:
|
|
65
65
|
- - ">="
|
|
66
66
|
- !ruby/object:Gem::Version
|
|
67
|
-
version: 3.4.
|
|
67
|
+
version: 3.4.7
|
|
68
68
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
69
69
|
requirements:
|
|
70
70
|
- - ">="
|