1
0
Fork 0

enabled interpolation and templating

Dieser Commit ist enthalten in:
Faizaan Gagan 2021-07-05 11:52:29 +05:30
Ursprung 21ac87cdda
Commit d47950733d

Datei anzeigen

@ -86,7 +86,7 @@ class CustomWizard::Builder
required: field_template['required'] required: field_template['required']
} }
%w(label description image key validations min_length max_length char_counter placeholder).each do |key| %w(label description image key validations min_length max_length char_counter).each do |key|
params[key.to_sym] = field_template[key] if field_template[key] params[key.to_sym] = field_template[key] if field_template[key]
end end
@ -187,6 +187,16 @@ class CustomWizard::Builder
) )
end end
if field_template['placeholder'].present?
params[:placeholder] = mapper.interpolate(
field_template['placeholder'],
user: true,
value: true,
wizard: true,
template: true
)
end
field = step.add_field(params) field = step.add_field(params)
end end