feat(conditional): show loader during autosave when other champs are dependent of it
This commit is contained in:
parent
81f00774af
commit
7c13449b4f
9 changed files with 34 additions and 3 deletions
|
@ -2,4 +2,8 @@ class EditableChamp::EditableChampBaseComponent < ApplicationComponent
|
|||
def initialize(form:, champ:, seen_at: nil)
|
||||
@form, @champ, @seen_at = form, champ, seen_at
|
||||
end
|
||||
|
||||
def data_dependent_conditions
|
||||
{ "dependent-conditions": "true" } if @champ.dependent_conditions?
|
||||
end
|
||||
end
|
||||
|
|
|
@ -2,4 +2,5 @@
|
|||
id: @champ.input_id,
|
||||
aria: { describedby: @champ.describedby_id },
|
||||
placeholder: 5,
|
||||
required: @champ.required?
|
||||
required: @champ.required?,
|
||||
data: data_dependent_conditions
|
||||
|
|
|
@ -2,4 +2,5 @@
|
|||
id: @champ.input_id,
|
||||
aria: { describedby: @champ.describedby_id },
|
||||
placeholder: @champ.libelle,
|
||||
required: @champ.required?
|
||||
required: @champ.required?,
|
||||
data: data_dependent_conditions
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
= @form.text_field :value,
|
||||
id: @champ.input_id,
|
||||
required: @champ.required?,
|
||||
aria: { describedby: @champ.describedby_id }
|
||||
aria: { describedby: @champ.describedby_id },
|
||||
data: data_dependent_conditions
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue