ponkotsu-md-editor 0.2.37 → 0.2.38

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: 3fc85c453bbae9a24b6650133e33bca26d1ec9b030380e6a1aca7f9aeeade15a
4
- data.tar.gz: db217162995018236d1dad008c61fc6f9e377c3d7d5727d309f24f9184e8d530
3
+ metadata.gz: 5302c9a2279a1cc63c0eb45bc2bef74a3293fc792c4c1b21b73d69368fe75054
4
+ data.tar.gz: 496540544d96bf811322e4de5338fc6cab9d6706c0d061d545272e64630ae528
5
5
  SHA512:
6
- metadata.gz: b8e9dbb0d77c58d30170935b7d0c09434d620473dd74d4307bcbe814a46ceabfb52a76232b651430a9c37348641026ac8cdf674375f79fffd627c696e210b582
7
- data.tar.gz: 2298cf2348fdcd08e64def9928ccd4825681f7d3e686242b887210ed3f327dc24c2ada88326aa69973f46a27c9a030f3373dfb05c1407af9322abc015bd3523c
6
+ metadata.gz: 040fc09a76dec0d164fd9190b297cfc63acd4a8059d74a3ee8a492bf2888f11dbaba03b194b83ac285609d522b3cd359b62e273a257bf3a4e829af7e9d8ab592
7
+ data.tar.gz: 8f0cfef74e8bc86cdffb916f5bf7af964578dae487288d3b46da2b91dff1331767d9a045a1157baad4476b64c9981a40258b7b2c15eb53561da4db95d33f3152
@@ -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.requestSubmit();
167
+ form.submit();
158
168
  }, 0);
159
169
  });
160
170
  }
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PonkotsuMdEditor
4
- VERSION = "0.2.37"
4
+ VERSION = "0.2.38"
5
5
  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.2.37
4
+ version: 0.2.38
5
5
  platform: ruby
6
6
  authors:
7
7
  - dhq_boiler