Module: Card::Set::All::Board::FollowSection::HtmlFormat
- Extended by:
- Card::Set::AbstractFormat
- Defined in:
- platypus/tmp/set/gem-defaults/mod011-edit/all/board/follow_section.rb
Instance Method Summary collapse
-
#follow_advanced ⇒ Object
-
#follow_button_group ⇒ Object
-
#follow_overview_button ⇒ Object
-
#follow_section ⇒ Object
-
#followers_board_link ⇒ Object
Instance Method Details
#follow_advanced ⇒ Object
29 30 31 32 33 34 35 36 |
# File 'platypus/tmp/set/gem-defaults/mod011-edit/all/board/follow_section.rb', line 29 def follow_advanced opts = board_link_opts(class: "btn btn-sm btn-primary", path: { view: :overlay_rule }, "data-cy": "follow-advanced") opts[:path].delete :layout link_to_card card.follow_rule_card(Auth.current.name, new: {}), icon_tag("more_horiz"), opts end |
#follow_button_group ⇒ Object
17 18 19 20 21 |
# File 'platypus/tmp/set/gem-defaults/mod011-edit/all/board/follow_section.rb', line 17 def wrap_with :div, class: "btn-group btn-group-sm follow-btn-group" do [, follow_advanced] end end |
#follow_overview_button ⇒ Object
23 24 25 26 27 |
# File 'platypus/tmp/set/gem-defaults/mod011-edit/all/board/follow_section.rb', line 23 def link_to_card [Auth.current, :follow], "all followed cards", board_link_opts(class: "btn btn-sm btn-secondary", "data-cy": "follow-overview") end |
#follow_section ⇒ Object
9 10 11 12 13 14 15 |
# File 'platypus/tmp/set/gem-defaults/mod011-edit/all/board/follow_section.rb', line 9 def follow_section return unless show_follow? wrap_with :div, class: "mb-3" do [, followers_board_link, ] end end |
#followers_board_link ⇒ Object
38 39 40 41 42 43 |
# File 'platypus/tmp/set/gem-defaults/mod011-edit/all/board/follow_section.rb', line 38 def followers_board_link cnt = card.followers_count link_to_card card.name.field(:followers), "#{cnt} follower#{'s' unless cnt == 1}", board_link_opts(class: "btn btn-sm ms-2 btn-secondary slotter", remote: true, "data-cy": "followers") end |