diff --git a/assets/javascripts/wizard/templates/components/wizard-field.hbs b/assets/javascripts/wizard/templates/components/wizard-field.hbs index ffbf9139..8173fe78 100644 --- a/assets/javascripts/wizard/templates/components/wizard-field.hbs +++ b/assets/javascripts/wizard/templates/components/wizard-field.hbs @@ -1,6 +1,6 @@ diff --git a/assets/stylesheets/wizard/wizard_custom.scss b/assets/stylesheets/wizard/wizard_custom.scss index 8bc6209b..9e2a3b9f 100644 --- a/assets/stylesheets/wizard/wizard_custom.scss +++ b/assets/stylesheets/wizard/wizard_custom.scss @@ -125,8 +125,12 @@ flex-flow: wrap; align-items: center; - .field-label { + .label-value { width: 100%; + + p { + margin: 0; + } } .field-image { diff --git a/lib/wizard_edits.rb b/lib/wizard_edits.rb index d4bfbe12..83f2f771 100644 --- a/lib/wizard_edits.rb +++ b/lib/wizard_edits.rb @@ -28,12 +28,10 @@ end attr_accessor :dropdown_none def initialize(attrs) - attrs = attrs || {} - + @attrs = attrs || {} @id = attrs[:id] @type = attrs[:type] @required = !!attrs[:required] - @label = attrs[:label] @description = attrs[:description] @image = attrs[:image] @key = attrs[:key] @@ -42,6 +40,10 @@ end @choices = [] @dropdown_none = attrs[:dropdown_none] end + + def label + @label ||= PrettyText.cook(@attrs[:label], keep_emoji_images: true) + end end ::Wizard::Choice.class_eval do @@ -54,7 +56,7 @@ end end def label - @label ||= PrettyText.cook(@opts[:label], keep_emoji_images: true, postProcessTag: '