Sha256: 88aec8e8a0d0f601bb1f4ed413dab75a2c89c4d998a682a42cbd49674d5d4d45

Contents?: true

Size: 1.38 KB

Versions: 34

Compression:

Stored size: 1.38 KB

Contents

-# frozen_string_literal: true
- available_width = question.presentation == :horizontal ? 100 : 66

- if opt.inner_title
  %td.option{ :style => "width:#{available_width/(table.columns)}%"}= opt.description
- else
  - checked = @answer.send(question.key) == opt.key.to_s
  - return if (opt.hidden and not checked)
  - optionclasses =  [os_cycle]
  - optionclasses << question.question_group if question.question_group

  %td.option{:class => optionclasses, :style => "width:#{available_width/(table.columns)}%", :data => {:for => question.key}, :rowspan => question.row_span}
    - radio_classes = [question.type]
    - radio_classes << "deselectable" if question.deselectable
    - show_values = question.show_values_in_mode? :all
    .radiocheckwrapper
      - if show_values
        .value= opt.value
      = radio_button(:answer, question.key, opt.key, {:class => radio_classes, :data => {'field-key' => question.key}})
    -if question.table.show_option_desc
      .labelwrapper
        %label{for: opt.view_id}
          %span
            - if table.columns >= 10
              %br
            = Quby::MarkdownParser.new(opt.description).html_safe
    - subq = opt.questions.first
    - if subq and (subq.presentation != :next_to_title and subq.type == :string)
      %br
      = render :partial => "quby/v1/shared/inline_text_field", :locals => {:answer => @answer, :question => subq}
    = validations

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
quby-5.6.6 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.6.5 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.6.3 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.6.2 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.6.1 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.6.0 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.5.0 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.4.0 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.3.1 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.3.0 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.2.0 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.1.3 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.1.2 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.1.1 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.1.0 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.0.5 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.0.4 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.0.3 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.0.2 app/views/quby/v1/table/_item_option_radio.html.haml
quby-5.0.1 app/views/quby/v1/table/_item_option_radio.html.haml