Module: Coco::Concerns::ActsAsFieldWithOptions

Instance Method Summary collapse

Methods included from AppHelper

#coco_button, #coco_button_group, #coco_color_picker_button, #coco_confirm_button, #coco_dropdown_button, #coco_fields, #coco_form_button, #coco_form_for, #coco_form_with, #coco_image_picker_button, #coco_layout_picker_button, #coco_link, #coco_menu_button, #coco_notice, #coco_seamless_textarea, #coco_snackbar, #coco_system_banner, #coco_toast, #coco_toolbar

Methods included from HasName

#component_name

Instance Method Details

#combine_options!Object



8
9
10
11
12
13
# File 'app/components/coco/concerns/acts_as_field_with_options.rb', line 8

def combine_options!
  @options[:data] ||= {}
  @options[:data][:coco] = ""
  @options[:data][:component] = "app-form-#{component_name.delete_prefix("app-")}"
  super
end