Sha256: 15e51dce27c1193e5db60583a744b843ca12222563964a998d1bee1c8b180ee9

Contents?: true

Size: 803 Bytes

Versions: 253

Compression:

Stored size: 803 Bytes

Contents

# frozen_string_literal: true

module Playbook
  module PbSelectableList
    class SelectableListItem < Playbook::KitBase
      prop :tabindex
      prop :checked, type: Playbook::Props::Boolean,
                     default: false
      prop :name, type: Playbook::Props::String
      prop :text, type: Playbook::Props::String
      prop :value, type: Playbook::Props::String
      prop :variant, type: Playbook::Props::Enum,
                     values: %w[radio checkbox],
                     default: "radio"
      prop :input_options, type: Playbook::Props::Hash,
                           default: {}

      def classname
        generate_classname("pb_item_kit") + checked_class
      end

    private

      def checked_class
        checked ? " checked_item" : ""
      end
    end
  end
end

Version data entries

253 entries across 253 versions & 1 rubygems

Version Path
playbook_ui-12.31.0.pre.alpha.customiconsfa928 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.31.0 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1.pre.alpha.play846responsivespacingglobalpropsneedsdefault924 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1.pre.alpha.PLAY906multilevelselectedidsprop917 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1.pre.alpha.PLAY906multilevelselectedidsprop916 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1.pre.alpha.hovertesting914 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1.pre.alpha.PLAY906multilevelselectedidsprop912 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1.pre.alpha.PLAY802responsivetitlekit909 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.0.pre.alpha.PLAY906multilevelselectedidsprop902 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.1 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.30.0 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.29.0.pre.alpha.play716popoverkitcloseonclickissue893 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.29.0 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0.pre.alpha.PLAY863multilevelv2877 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0.pre.alpha.PLAY863multilevelv2876 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0.pre.alpha.PLAY814removemomentjs871 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0.pre.alpha.PLAY603datepickerquickpickinputpresetdropdown869 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0.pre.alpha.PLAY837MapCustomButton868 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0.pre.alpha.20230613implementbakesupport865 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb
playbook_ui-12.28.0 app/pb_kits/playbook/pb_selectable_list/selectable_list_item.rb