compony 0.11.8 → 0.11.9
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/.yardopts +36 -1
- data/CHANGELOG.md +31 -0
- data/CLAUDE.md +85 -0
- data/Gemfile.lock +1 -1
- data/README.md +13 -3
- data/VERSION +1 -1
- data/compony.gemspec +3 -3
- data/doc/ComponentGenerator.html +1 -1
- data/doc/Components.html +1 -1
- data/doc/ComponentsGenerator.html +1 -1
- data/doc/Compony/Component.html +54 -54
- data/doc/Compony/ComponentMixins/Default/Labelling.html +1 -1
- data/doc/Compony/ComponentMixins/Default/Standalone/ResourcefulVerbDsl.html +1 -1
- data/doc/Compony/ComponentMixins/Default/Standalone/StandaloneDsl.html +109 -70
- data/doc/Compony/ComponentMixins/Default/Standalone/VerbDsl.html +64 -28
- data/doc/Compony/ComponentMixins/Default/Standalone.html +1 -1
- data/doc/Compony/ComponentMixins/Default.html +1 -1
- data/doc/Compony/ComponentMixins/Resourceful.html +213 -74
- data/doc/Compony/ComponentMixins.html +1 -1
- data/doc/Compony/Components/Buttons/CssButton.html +1 -1
- data/doc/Compony/Components/Buttons/Link.html +1 -1
- data/doc/Compony/Components/Buttons.html +1 -1
- data/doc/Compony/Components/Destroy.html +83 -29
- data/doc/Compony/Components/Edit.html +110 -38
- data/doc/Compony/Components/Form.html +551 -208
- data/doc/Compony/Components/Index.html +1 -1
- data/doc/Compony/Components/List.html +3 -3
- data/doc/Compony/Components/New.html +110 -38
- data/doc/Compony/Components/Show.html +1 -1
- data/doc/Compony/Components/WithForm.html +194 -47
- data/doc/Compony/Components.html +1 -1
- data/doc/Compony/ControllerMixin.html +1 -1
- data/doc/Compony/Engine.html +1 -1
- data/doc/Compony/Intent.html +2 -2
- data/doc/Compony/ManageIntentsDsl.html +1 -1
- data/doc/Compony/MethodAccessibleHash.html +1 -1
- data/doc/Compony/ModelFields/Anchormodel.html +1 -1
- data/doc/Compony/ModelFields/Association.html +1 -1
- data/doc/Compony/ModelFields/Attachment.html +1 -1
- data/doc/Compony/ModelFields/Base.html +1 -1
- data/doc/Compony/ModelFields/Boolean.html +1 -1
- data/doc/Compony/ModelFields/Color.html +1 -1
- data/doc/Compony/ModelFields/Currency.html +1 -1
- data/doc/Compony/ModelFields/Date.html +1 -1
- data/doc/Compony/ModelFields/Datetime.html +1 -1
- data/doc/Compony/ModelFields/Decimal.html +1 -1
- data/doc/Compony/ModelFields/Email.html +1 -1
- data/doc/Compony/ModelFields/Float.html +1 -1
- data/doc/Compony/ModelFields/Integer.html +1 -1
- data/doc/Compony/ModelFields/Percentage.html +1 -1
- data/doc/Compony/ModelFields/Phone.html +1 -1
- data/doc/Compony/ModelFields/RichText.html +1 -1
- data/doc/Compony/ModelFields/String.html +1 -1
- data/doc/Compony/ModelFields/Text.html +1 -1
- data/doc/Compony/ModelFields/Time.html +1 -1
- data/doc/Compony/ModelFields/Url.html +1 -1
- data/doc/Compony/ModelFields.html +1 -1
- data/doc/Compony/ModelMixin.html +1 -1
- data/doc/Compony/NaturalOrdering.html +1 -1
- data/doc/Compony/RequestContext.html +1 -1
- data/doc/Compony/Version.html +1 -1
- data/doc/Compony/ViewHelpers.html +1 -1
- data/doc/Compony/VirtualModel.html +1 -1
- data/doc/Compony.html +1 -1
- data/doc/ComponyController.html +1 -1
- data/doc/_index.html +97 -1
- data/doc/file.CHANGELOG.html +758 -0
- data/doc/file.README.html +25 -4
- data/doc/file.basic_component.html +314 -0
- data/doc/file.cookbook.html +189 -0
- data/doc/file.destroy.html +105 -0
- data/doc/file.dsl_reference.html +672 -0
- data/doc/file.edit.html +109 -0
- data/doc/file.example.html +291 -0
- data/doc/file.example_advanced.html +257 -0
- data/doc/file.feasibility.html +115 -0
- data/doc/file.form.html +195 -0
- data/doc/file.generators.html +89 -0
- data/doc/file.glossary.html +217 -0
- data/doc/file.gotchas.html +222 -0
- data/doc/file.index.html +135 -0
- data/doc/file.inheritance.html +136 -0
- data/doc/file.installation.html +115 -0
- data/doc/file.integrations.html +218 -0
- data/doc/file.intents.html +265 -0
- data/doc/file.internal_datastructures.html +129 -0
- data/doc/file.list.html +253 -0
- data/doc/file.maintaining.html +127 -0
- data/doc/file.model_fields.html +137 -0
- data/doc/file.nesting.html +237 -0
- data/doc/file.new.html +109 -0
- data/doc/file.ownership.html +98 -0
- data/doc/file.patterns.html +669 -0
- data/doc/file.pre_built_components.html +99 -0
- data/doc/file.resourceful.html +181 -0
- data/doc/file.show.html +158 -0
- data/doc/file.standalone.html +233 -0
- data/doc/file.virtual_models.html +117 -0
- data/doc/file.with_form.html +157 -0
- data/doc/file_list.html +160 -0
- data/doc/guide/cookbook.md +41 -0
- data/doc/guide/dsl_reference.md +155 -0
- data/doc/guide/example_advanced.md +209 -0
- data/doc/guide/generators.md +1 -1
- data/doc/guide/glossary.md +42 -0
- data/doc/guide/gotchas.md +125 -0
- data/doc/guide/maintaining.md +64 -0
- data/doc/guide/patterns.md +681 -0
- data/doc/guide/pre_built_components/edit.md +1 -1
- data/doc/guide/pre_built_components/index.md +64 -1
- data/doc/guide/pre_built_components/list.md +111 -7
- data/doc/guide/pre_built_components/show.md +57 -2
- data/doc/guide/pre_built_components/with_form.md +56 -9
- data/doc/guide/pre_built_components.md +7 -2
- data/doc/guide/standalone.md +16 -1
- data/doc/index.html +25 -4
- data/doc/integrations.md +61 -0
- data/doc/llms.txt +62 -0
- data/doc/top-level-namespace.html +1 -1
- data/lib/compony/component.rb +8 -3
- data/lib/compony/component_mixins/default/standalone/standalone_dsl.rb +32 -15
- data/lib/compony/component_mixins/default/standalone/verb_dsl.rb +11 -3
- data/lib/compony/component_mixins/resourceful.rb +30 -16
- data/lib/compony/components/destroy.rb +21 -1
- data/lib/compony/components/edit.rb +25 -1
- data/lib/compony/components/form.rb +63 -21
- data/lib/compony/components/list.rb +1 -1
- data/lib/compony/components/new.rb +25 -1
- data/lib/compony/components/with_form.rb +20 -5
- data/lib/compony/intent.rb +1 -1
- metadata +43 -1
|
@@ -130,7 +130,7 @@
|
|
|
130
130
|
|
|
131
131
|
|
|
132
132
|
<h2>
|
|
133
|
-
|
|
133
|
+
DSL
|
|
134
134
|
<small><a href="#" class="summary_toggle">collapse</a></small>
|
|
135
135
|
</h2>
|
|
136
136
|
|
|
@@ -139,7 +139,7 @@
|
|
|
139
139
|
<li class="public ">
|
|
140
140
|
<span class="summary_signature">
|
|
141
141
|
|
|
142
|
-
<a href="#form_cancancan_action-instance_method" title="#form_cancancan_action (instance method)">#<strong>form_cancancan_action</strong>(new_form_cancancan_action = :missing) ⇒
|
|
142
|
+
<a href="#form_cancancan_action-instance_method" title="#form_cancancan_action (instance method)">#<strong>form_cancancan_action</strong>(new_form_cancancan_action = :missing) ⇒ Symbol<sup>?</sup> </a>
|
|
143
143
|
|
|
144
144
|
|
|
145
145
|
|
|
@@ -154,7 +154,7 @@
|
|
|
154
154
|
|
|
155
155
|
|
|
156
156
|
<span class="summary_desc"><div class='inline'>
|
|
157
|
-
<p>DSL method Sets and gets the form’s
|
|
157
|
+
<p>DSL method Sets and gets the form’s CanCanCan action, used for per-field <code>permitted_attributes</code>.</p>
|
|
158
158
|
</div></span>
|
|
159
159
|
|
|
160
160
|
</li>
|
|
@@ -163,7 +163,7 @@
|
|
|
163
163
|
<li class="public ">
|
|
164
164
|
<span class="summary_signature">
|
|
165
165
|
|
|
166
|
-
<a href="#
|
|
166
|
+
<a href="#form_comp_class-instance_method" title="#form_comp_class (instance method)">#<strong>form_comp_class</strong>(new_form_comp_class = nil) ⇒ Class<sup>?</sup> </a>
|
|
167
167
|
|
|
168
168
|
|
|
169
169
|
|
|
@@ -178,7 +178,7 @@
|
|
|
178
178
|
|
|
179
179
|
|
|
180
180
|
<span class="summary_desc"><div class='inline'>
|
|
181
|
-
<p>
|
|
181
|
+
<p>DSL method Overrides the Form component class instantiated by <span class='object_link'><a href="#form_comp-instance_method" title="Compony::Components::WithForm#form_comp (method)">#form_comp</a></span> (defaults to the same-family <code>Form</code>).</p>
|
|
182
182
|
</div></span>
|
|
183
183
|
|
|
184
184
|
</li>
|
|
@@ -187,7 +187,7 @@
|
|
|
187
187
|
<li class="public ">
|
|
188
188
|
<span class="summary_signature">
|
|
189
189
|
|
|
190
|
-
<a href="#
|
|
190
|
+
<a href="#submit_path-instance_method" title="#submit_path (instance method)">#<strong>submit_path</strong> {|controller| ... } ⇒ void </a>
|
|
191
191
|
|
|
192
192
|
|
|
193
193
|
|
|
@@ -202,7 +202,7 @@
|
|
|
202
202
|
|
|
203
203
|
|
|
204
204
|
<span class="summary_desc"><div class='inline'>
|
|
205
|
-
<p>DSL method Overrides the
|
|
205
|
+
<p>DSL method Overrides the submit path, which otherwise defaults to this component’s own path.</p>
|
|
206
206
|
</div></span>
|
|
207
207
|
|
|
208
208
|
</li>
|
|
@@ -211,15 +211,13 @@
|
|
|
211
211
|
<li class="public ">
|
|
212
212
|
<span class="summary_signature">
|
|
213
213
|
|
|
214
|
-
<a href="#
|
|
214
|
+
<a href="#submit_verb-instance_method" title="#submit_verb (instance method)">#<strong>submit_verb</strong>(new_submit_verb = nil) ⇒ Symbol </a>
|
|
215
215
|
|
|
216
216
|
|
|
217
217
|
|
|
218
218
|
</span>
|
|
219
219
|
|
|
220
220
|
|
|
221
|
-
<span class="note title constructor">constructor</span>
|
|
222
|
-
|
|
223
221
|
|
|
224
222
|
|
|
225
223
|
|
|
@@ -228,16 +226,25 @@
|
|
|
228
226
|
|
|
229
227
|
|
|
230
228
|
<span class="summary_desc"><div class='inline'>
|
|
231
|
-
<p>
|
|
229
|
+
<p>DSL method Sets or returns the HTTP verb the twinned form submits with (<code>:post</code> for New, <code>:patch</code> for Edit).</p>
|
|
232
230
|
</div></span>
|
|
233
231
|
|
|
234
232
|
</li>
|
|
235
233
|
|
|
236
234
|
|
|
235
|
+
</ul>
|
|
236
|
+
|
|
237
|
+
<h2>
|
|
238
|
+
Instance Method Summary
|
|
239
|
+
<small><a href="#" class="summary_toggle">collapse</a></small>
|
|
240
|
+
</h2>
|
|
241
|
+
|
|
242
|
+
<ul class="summary">
|
|
243
|
+
|
|
237
244
|
<li class="public ">
|
|
238
245
|
<span class="summary_signature">
|
|
239
246
|
|
|
240
|
-
<a href="#
|
|
247
|
+
<a href="#form_comp-instance_method" title="#form_comp (instance method)">#<strong>form_comp</strong> ⇒ Object </a>
|
|
241
248
|
|
|
242
249
|
|
|
243
250
|
|
|
@@ -252,7 +259,7 @@
|
|
|
252
259
|
|
|
253
260
|
|
|
254
261
|
<span class="summary_desc"><div class='inline'>
|
|
255
|
-
<p>
|
|
262
|
+
<p>Returns an instance of the form component responsible for rendering the form.</p>
|
|
256
263
|
</div></span>
|
|
257
264
|
|
|
258
265
|
</li>
|
|
@@ -261,13 +268,15 @@
|
|
|
261
268
|
<li class="public ">
|
|
262
269
|
<span class="summary_signature">
|
|
263
270
|
|
|
264
|
-
<a href="#
|
|
271
|
+
<a href="#initialize-instance_method" title="#initialize (instance method)">#<strong>initialize</strong> ⇒ WithForm </a>
|
|
265
272
|
|
|
266
273
|
|
|
267
274
|
|
|
268
275
|
</span>
|
|
269
276
|
|
|
270
277
|
|
|
278
|
+
<span class="note title constructor">constructor</span>
|
|
279
|
+
|
|
271
280
|
|
|
272
281
|
|
|
273
282
|
|
|
@@ -276,7 +285,7 @@
|
|
|
276
285
|
|
|
277
286
|
|
|
278
287
|
<span class="summary_desc"><div class='inline'>
|
|
279
|
-
<p>
|
|
288
|
+
<p>A new instance of WithForm.</p>
|
|
280
289
|
</div></span>
|
|
281
290
|
|
|
282
291
|
</li>
|
|
@@ -354,7 +363,7 @@
|
|
|
354
363
|
<div class="method_details first">
|
|
355
364
|
<h3 class="signature first" id="form_cancancan_action-instance_method">
|
|
356
365
|
|
|
357
|
-
#<strong>form_cancancan_action</strong>(new_form_cancancan_action = :missing) ⇒ <tt>
|
|
366
|
+
#<strong>form_cancancan_action</strong>(new_form_cancancan_action = :missing) ⇒ <tt>Symbol</tt><sup>?</sup>
|
|
358
367
|
|
|
359
368
|
|
|
360
369
|
|
|
@@ -363,13 +372,53 @@
|
|
|
363
372
|
</h3><div class="docstring">
|
|
364
373
|
<div class="discussion">
|
|
365
374
|
|
|
366
|
-
<p>DSL method Sets and gets the form’s
|
|
375
|
+
<p>DSL method Sets and gets the form’s CanCanCan action, used for per-field <code>permitted_attributes</code>. Pass <code>nil</code> to disable per-field auth.</p>
|
|
367
376
|
|
|
368
377
|
|
|
369
378
|
</div>
|
|
370
379
|
</div>
|
|
371
380
|
<div class="tags">
|
|
381
|
+
<p class="tag_title">Parameters:</p>
|
|
382
|
+
<ul class="param">
|
|
383
|
+
|
|
384
|
+
<li>
|
|
385
|
+
|
|
386
|
+
<span class='name'>new_form_cancancan_action</span>
|
|
387
|
+
|
|
388
|
+
|
|
389
|
+
<span class='type'>(<tt>Symbol</tt>, <tt>nil</tt>)</span>
|
|
390
|
+
|
|
391
|
+
|
|
392
|
+
<em class="default">(defaults to: <tt>:missing</tt>)</em>
|
|
393
|
+
|
|
394
|
+
|
|
395
|
+
—
|
|
396
|
+
<div class='inline'>
|
|
397
|
+
<p>The CanCanCan action (e.g. <code>:edit</code>); omit to read the current value.</p>
|
|
398
|
+
</div>
|
|
399
|
+
|
|
400
|
+
</li>
|
|
372
401
|
|
|
402
|
+
</ul>
|
|
403
|
+
|
|
404
|
+
<p class="tag_title">Returns:</p>
|
|
405
|
+
<ul class="return">
|
|
406
|
+
|
|
407
|
+
<li>
|
|
408
|
+
|
|
409
|
+
|
|
410
|
+
<span class='type'>(<tt>Symbol</tt>, <tt>nil</tt>)</span>
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
|
|
414
|
+
—
|
|
415
|
+
<div class='inline'>
|
|
416
|
+
<p>The configured CanCanCan action.</p>
|
|
417
|
+
</div>
|
|
418
|
+
|
|
419
|
+
</li>
|
|
420
|
+
|
|
421
|
+
</ul>
|
|
373
422
|
|
|
374
423
|
</div><table class="source_code">
|
|
375
424
|
<tr>
|
|
@@ -377,15 +426,15 @@
|
|
|
377
426
|
<pre class="lines">
|
|
378
427
|
|
|
379
428
|
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
429
|
+
56
|
|
430
|
+
57
|
|
431
|
+
58
|
|
432
|
+
59
|
|
433
|
+
60
|
|
434
|
+
61</pre>
|
|
386
435
|
</td>
|
|
387
436
|
<td>
|
|
388
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line
|
|
437
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line 56</span>
|
|
389
438
|
|
|
390
439
|
<span class='kw'>def</span> <span class='id identifier rubyid_form_cancancan_action'>form_cancancan_action</span><span class='lparen'>(</span><span class='id identifier rubyid_new_form_cancancan_action'>new_form_cancancan_action</span> <span class='op'>=</span> <span class='symbol'>:missing</span><span class='rparen'>)</span>
|
|
391
440
|
<span class='kw'>if</span> <span class='id identifier rubyid_new_form_cancancan_action'>new_form_cancancan_action</span> <span class='op'>!=</span> <span class='symbol'>:missing</span>
|
|
@@ -454,7 +503,7 @@
|
|
|
454
503
|
<div class="method_details ">
|
|
455
504
|
<h3 class="signature " id="form_comp_class-instance_method">
|
|
456
505
|
|
|
457
|
-
#<strong>form_comp_class</strong>(new_form_comp_class = nil) ⇒ <tt>
|
|
506
|
+
#<strong>form_comp_class</strong>(new_form_comp_class = nil) ⇒ <tt>Class</tt><sup>?</sup>
|
|
458
507
|
|
|
459
508
|
|
|
460
509
|
|
|
@@ -463,13 +512,53 @@
|
|
|
463
512
|
</h3><div class="docstring">
|
|
464
513
|
<div class="discussion">
|
|
465
514
|
|
|
466
|
-
<p>DSL method Overrides the
|
|
515
|
+
<p>DSL method Overrides the Form component class instantiated by <span class='object_link'><a href="#form_comp-instance_method" title="Compony::Components::WithForm#form_comp (method)">#form_comp</a></span> (defaults to the same-family <code>Form</code>).</p>
|
|
467
516
|
|
|
468
517
|
|
|
469
518
|
</div>
|
|
470
519
|
</div>
|
|
471
520
|
<div class="tags">
|
|
521
|
+
<p class="tag_title">Parameters:</p>
|
|
522
|
+
<ul class="param">
|
|
523
|
+
|
|
524
|
+
<li>
|
|
525
|
+
|
|
526
|
+
<span class='name'>new_form_comp_class</span>
|
|
527
|
+
|
|
528
|
+
|
|
529
|
+
<span class='type'>(<tt>Class</tt>, <tt>nil</tt>)</span>
|
|
530
|
+
|
|
531
|
+
|
|
532
|
+
<em class="default">(defaults to: <tt>nil</tt>)</em>
|
|
533
|
+
|
|
534
|
+
|
|
535
|
+
—
|
|
536
|
+
<div class='inline'>
|
|
537
|
+
<p>The Form component class to use.</p>
|
|
538
|
+
</div>
|
|
539
|
+
|
|
540
|
+
</li>
|
|
472
541
|
|
|
542
|
+
</ul>
|
|
543
|
+
|
|
544
|
+
<p class="tag_title">Returns:</p>
|
|
545
|
+
<ul class="return">
|
|
546
|
+
|
|
547
|
+
<li>
|
|
548
|
+
|
|
549
|
+
|
|
550
|
+
<span class='type'>(<tt>Class</tt>, <tt>nil</tt>)</span>
|
|
551
|
+
|
|
552
|
+
|
|
553
|
+
|
|
554
|
+
—
|
|
555
|
+
<div class='inline'>
|
|
556
|
+
<p>The configured form component class.</p>
|
|
557
|
+
</div>
|
|
558
|
+
|
|
559
|
+
</li>
|
|
560
|
+
|
|
561
|
+
</ul>
|
|
473
562
|
|
|
474
563
|
</div><table class="source_code">
|
|
475
564
|
<tr>
|
|
@@ -477,12 +566,12 @@
|
|
|
477
566
|
<pre class="lines">
|
|
478
567
|
|
|
479
568
|
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
569
|
+
47
|
|
570
|
+
48
|
|
571
|
+
49</pre>
|
|
483
572
|
</td>
|
|
484
573
|
<td>
|
|
485
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line
|
|
574
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line 47</span>
|
|
486
575
|
|
|
487
576
|
<span class='kw'>def</span> <span class='id identifier rubyid_form_comp_class'>form_comp_class</span><span class='lparen'>(</span><span class='id identifier rubyid_new_form_comp_class'>new_form_comp_class</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='rparen'>)</span>
|
|
488
577
|
<span class='ivar'>@form_comp_class</span> <span class='op'>||=</span> <span class='id identifier rubyid_new_form_comp_class'>new_form_comp_class</span>
|
|
@@ -495,7 +584,7 @@
|
|
|
495
584
|
<div class="method_details ">
|
|
496
585
|
<h3 class="signature " id="submit_path-instance_method">
|
|
497
586
|
|
|
498
|
-
#<strong>submit_path</strong>
|
|
587
|
+
#<strong>submit_path</strong> {|controller| ... } ⇒ <tt>void</tt>
|
|
499
588
|
|
|
500
589
|
|
|
501
590
|
|
|
@@ -503,14 +592,32 @@
|
|
|
503
592
|
|
|
504
593
|
</h3><div class="docstring">
|
|
505
594
|
<div class="discussion">
|
|
506
|
-
|
|
507
|
-
<p>DSL method Overrides the submit path which
|
|
595
|
+
<p class="note returns_void">This method returns an undefined value.</p>
|
|
596
|
+
<p>DSL method Overrides the submit path, which otherwise defaults to this component’s own path.</p>
|
|
508
597
|
|
|
509
598
|
|
|
510
599
|
</div>
|
|
511
600
|
</div>
|
|
512
601
|
<div class="tags">
|
|
513
602
|
|
|
603
|
+
<p class="tag_title">Yields:</p>
|
|
604
|
+
<ul class="yield">
|
|
605
|
+
|
|
606
|
+
<li>
|
|
607
|
+
|
|
608
|
+
|
|
609
|
+
<span class='type'>(<tt>controller</tt>)</span>
|
|
610
|
+
|
|
611
|
+
|
|
612
|
+
|
|
613
|
+
—
|
|
614
|
+
<div class='inline'>
|
|
615
|
+
<p>Called with the controller; expected to return the Rails path the form submits to.</p>
|
|
616
|
+
</div>
|
|
617
|
+
|
|
618
|
+
</li>
|
|
619
|
+
|
|
620
|
+
</ul>
|
|
514
621
|
|
|
515
622
|
</div><table class="source_code">
|
|
516
623
|
<tr>
|
|
@@ -518,12 +625,12 @@
|
|
|
518
625
|
<pre class="lines">
|
|
519
626
|
|
|
520
627
|
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
628
|
+
68
|
|
629
|
+
69
|
|
630
|
+
70</pre>
|
|
524
631
|
</td>
|
|
525
632
|
<td>
|
|
526
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line
|
|
633
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line 68</span>
|
|
527
634
|
|
|
528
635
|
<span class='kw'>def</span> <span class='id identifier rubyid_submit_path'>submit_path</span><span class='lparen'>(</span><span class='op'>&</span><span class='id identifier rubyid_new_submit_path_block'>new_submit_path_block</span><span class='rparen'>)</span>
|
|
529
636
|
<span class='ivar'>@submit_path_block</span> <span class='op'>=</span> <span class='id identifier rubyid_new_submit_path_block'>new_submit_path_block</span>
|
|
@@ -536,7 +643,7 @@
|
|
|
536
643
|
<div class="method_details ">
|
|
537
644
|
<h3 class="signature " id="submit_verb-instance_method">
|
|
538
645
|
|
|
539
|
-
#<strong>submit_verb</strong>(new_submit_verb = nil) ⇒ <tt>
|
|
646
|
+
#<strong>submit_verb</strong>(new_submit_verb = nil) ⇒ <tt>Symbol</tt>
|
|
540
647
|
|
|
541
648
|
|
|
542
649
|
|
|
@@ -545,13 +652,53 @@
|
|
|
545
652
|
</h3><div class="docstring">
|
|
546
653
|
<div class="discussion">
|
|
547
654
|
|
|
548
|
-
<p>DSL method Sets or returns the
|
|
655
|
+
<p>DSL method Sets or returns the HTTP verb the twinned form submits with (<code>:post</code> for New, <code>:patch</code> for Edit).</p>
|
|
549
656
|
|
|
550
657
|
|
|
551
658
|
</div>
|
|
552
659
|
</div>
|
|
553
660
|
<div class="tags">
|
|
661
|
+
<p class="tag_title">Parameters:</p>
|
|
662
|
+
<ul class="param">
|
|
554
663
|
|
|
664
|
+
<li>
|
|
665
|
+
|
|
666
|
+
<span class='name'>new_submit_verb</span>
|
|
667
|
+
|
|
668
|
+
|
|
669
|
+
<span class='type'>(<tt>Symbol</tt>, <tt>nil</tt>)</span>
|
|
670
|
+
|
|
671
|
+
|
|
672
|
+
<em class="default">(defaults to: <tt>nil</tt>)</em>
|
|
673
|
+
|
|
674
|
+
|
|
675
|
+
—
|
|
676
|
+
<div class='inline'>
|
|
677
|
+
<p>If given, sets the submit verb; must be a known HTTP verb.</p>
|
|
678
|
+
</div>
|
|
679
|
+
|
|
680
|
+
</li>
|
|
681
|
+
|
|
682
|
+
</ul>
|
|
683
|
+
|
|
684
|
+
<p class="tag_title">Returns:</p>
|
|
685
|
+
<ul class="return">
|
|
686
|
+
|
|
687
|
+
<li>
|
|
688
|
+
|
|
689
|
+
|
|
690
|
+
<span class='type'>(<tt>Symbol</tt>)</span>
|
|
691
|
+
|
|
692
|
+
|
|
693
|
+
|
|
694
|
+
—
|
|
695
|
+
<div class='inline'>
|
|
696
|
+
<p>The (possibly just set) submit verb.</p>
|
|
697
|
+
</div>
|
|
698
|
+
|
|
699
|
+
</li>
|
|
700
|
+
|
|
701
|
+
</ul>
|
|
555
702
|
|
|
556
703
|
</div><table class="source_code">
|
|
557
704
|
<tr>
|
|
@@ -559,18 +706,18 @@
|
|
|
559
706
|
<pre class="lines">
|
|
560
707
|
|
|
561
708
|
|
|
562
|
-
27
|
|
563
|
-
28
|
|
564
|
-
29
|
|
565
|
-
30
|
|
566
|
-
31
|
|
567
709
|
32
|
|
568
710
|
33
|
|
569
711
|
34
|
|
570
|
-
35
|
|
712
|
+
35
|
|
713
|
+
36
|
|
714
|
+
37
|
|
715
|
+
38
|
|
716
|
+
39
|
|
717
|
+
40</pre>
|
|
571
718
|
</td>
|
|
572
719
|
<td>
|
|
573
|
-
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line
|
|
720
|
+
<pre class="code"><span class="info file"># File 'lib/compony/components/with_form.rb', line 32</span>
|
|
574
721
|
|
|
575
722
|
<span class='kw'>def</span> <span class='id identifier rubyid_submit_verb'>submit_verb</span><span class='lparen'>(</span><span class='id identifier rubyid_new_submit_verb'>new_submit_verb</span> <span class='op'>=</span> <span class='kw'>nil</span><span class='rparen'>)</span>
|
|
576
723
|
<span class='kw'>if</span> <span class='id identifier rubyid_new_submit_verb'>new_submit_verb</span><span class='period'>.</span><span class='id identifier rubyid_present?'>present?</span>
|
|
@@ -591,7 +738,7 @@
|
|
|
591
738
|
</div>
|
|
592
739
|
|
|
593
740
|
<div id="footer">
|
|
594
|
-
Generated on
|
|
741
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
595
742
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
596
743
|
0.9.34 (ruby-3.3.5).
|
|
597
744
|
</div>
|
data/doc/Compony/Components.html
CHANGED
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
</div>
|
|
119
119
|
|
|
120
120
|
<div id="footer">
|
|
121
|
-
Generated on
|
|
121
|
+
Generated on Mon May 18 13:55:35 2026 by
|
|
122
122
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
123
123
|
0.9.34 (ruby-3.3.5).
|
|
124
124
|
</div>
|
|
@@ -126,7 +126,7 @@
|
|
|
126
126
|
</div>
|
|
127
127
|
|
|
128
128
|
<div id="footer">
|
|
129
|
-
Generated on
|
|
129
|
+
Generated on Mon May 18 13:55:35 2026 by
|
|
130
130
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
131
131
|
0.9.34 (ruby-3.3.5).
|
|
132
132
|
</div>
|
data/doc/Compony/Engine.html
CHANGED
|
@@ -123,7 +123,7 @@
|
|
|
123
123
|
</div>
|
|
124
124
|
|
|
125
125
|
<div id="footer">
|
|
126
|
-
Generated on
|
|
126
|
+
Generated on Mon May 18 13:55:35 2026 by
|
|
127
127
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
128
128
|
0.9.34 (ruby-3.3.5).
|
|
129
129
|
</div>
|
data/doc/Compony/Intent.html
CHANGED
|
@@ -1491,7 +1491,7 @@
|
|
|
1491
1491
|
|
|
1492
1492
|
—
|
|
1493
1493
|
<div class='inline'>
|
|
1494
|
-
<p>If present, overrides the class of the generated button component, defaults to Compony#default_button_style
|
|
1494
|
+
<p>If present, overrides the class of the generated button component, defaults to <span class='object_link'><a href="../Compony.html#default_button_style-class_method" title="Compony.default_button_style (method)">Compony.default_button_style</a></span>.</p>
|
|
1495
1495
|
</div>
|
|
1496
1496
|
|
|
1497
1497
|
</li>
|
|
@@ -1561,7 +1561,7 @@
|
|
|
1561
1561
|
</div>
|
|
1562
1562
|
|
|
1563
1563
|
<div id="footer">
|
|
1564
|
-
Generated on
|
|
1564
|
+
Generated on Mon May 18 13:55:35 2026 by
|
|
1565
1565
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
1566
1566
|
0.9.34 (ruby-3.3.5).
|
|
1567
1567
|
</div>
|
|
@@ -403,7 +403,7 @@
|
|
|
403
403
|
</div>
|
|
404
404
|
|
|
405
405
|
<div id="footer">
|
|
406
|
-
Generated on
|
|
406
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
407
407
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
408
408
|
0.9.34 (ruby-3.3.5).
|
|
409
409
|
</div>
|
|
@@ -443,7 +443,7 @@ instance_of_a_hash.roo --> nil
|
|
|
443
443
|
</div>
|
|
444
444
|
|
|
445
445
|
<div id="footer">
|
|
446
|
-
Generated on
|
|
446
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
447
447
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
448
448
|
0.9.34 (ruby-3.3.5).
|
|
449
449
|
</div>
|
|
@@ -509,7 +509,7 @@
|
|
|
509
509
|
</div>
|
|
510
510
|
|
|
511
511
|
<div id="footer">
|
|
512
|
-
Generated on
|
|
512
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
513
513
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
514
514
|
0.9.34 (ruby-3.3.5).
|
|
515
515
|
</div>
|
|
@@ -603,7 +603,7 @@
|
|
|
603
603
|
</div>
|
|
604
604
|
|
|
605
605
|
<div id="footer">
|
|
606
|
-
Generated on
|
|
606
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
607
607
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
608
608
|
0.9.34 (ruby-3.3.5).
|
|
609
609
|
</div>
|
|
@@ -495,7 +495,7 @@
|
|
|
495
495
|
</div>
|
|
496
496
|
|
|
497
497
|
<div id="footer">
|
|
498
|
-
Generated on
|
|
498
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
499
499
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
500
500
|
0.9.34 (ruby-3.3.5).
|
|
501
501
|
</div>
|
|
@@ -1186,7 +1186,7 @@
|
|
|
1186
1186
|
</div>
|
|
1187
1187
|
|
|
1188
1188
|
<div id="footer">
|
|
1189
|
-
Generated on
|
|
1189
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
1190
1190
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
1191
1191
|
0.9.34 (ruby-3.3.5).
|
|
1192
1192
|
</div>
|
|
@@ -354,7 +354,7 @@
|
|
|
354
354
|
</div>
|
|
355
355
|
|
|
356
356
|
<div id="footer">
|
|
357
|
-
Generated on
|
|
357
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
358
358
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
359
359
|
0.9.34 (ruby-3.3.5).
|
|
360
360
|
</div>
|
|
@@ -289,7 +289,7 @@
|
|
|
289
289
|
</div>
|
|
290
290
|
|
|
291
291
|
<div id="footer">
|
|
292
|
-
Generated on
|
|
292
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
293
293
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
294
294
|
0.9.34 (ruby-3.3.5).
|
|
295
295
|
</div>
|
|
@@ -222,7 +222,7 @@
|
|
|
222
222
|
</div>
|
|
223
223
|
|
|
224
224
|
<div id="footer">
|
|
225
|
-
Generated on
|
|
225
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
226
226
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
227
227
|
0.9.34 (ruby-3.3.5).
|
|
228
228
|
</div>
|
|
@@ -222,7 +222,7 @@
|
|
|
222
222
|
</div>
|
|
223
223
|
|
|
224
224
|
<div id="footer">
|
|
225
|
-
Generated on
|
|
225
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
226
226
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
227
227
|
0.9.34 (ruby-3.3.5).
|
|
228
228
|
</div>
|
|
@@ -222,7 +222,7 @@
|
|
|
222
222
|
</div>
|
|
223
223
|
|
|
224
224
|
<div id="footer">
|
|
225
|
-
Generated on
|
|
225
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
226
226
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
227
227
|
0.9.34 (ruby-3.3.5).
|
|
228
228
|
</div>
|
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
</div>
|
|
145
145
|
|
|
146
146
|
<div id="footer">
|
|
147
|
-
Generated on
|
|
147
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
148
148
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
149
149
|
0.9.34 (ruby-3.3.5).
|
|
150
150
|
</div>
|
|
@@ -230,7 +230,7 @@
|
|
|
230
230
|
</div>
|
|
231
231
|
|
|
232
232
|
<div id="footer">
|
|
233
|
-
Generated on
|
|
233
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
234
234
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
235
235
|
0.9.34 (ruby-3.3.5).
|
|
236
236
|
</div>
|
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
</div>
|
|
145
145
|
|
|
146
146
|
<div id="footer">
|
|
147
|
-
Generated on
|
|
147
|
+
Generated on Mon May 18 13:55:36 2026 by
|
|
148
148
|
<a href="https://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
|
149
149
|
0.9.34 (ruby-3.3.5).
|
|
150
150
|
</div>
|