|
6 | 6 |
|
7 | 7 | <% if board.published? %> |
8 | 8 | <div class="border-radius pad fill-selected"> |
9 | | - <div class="flex-inline center justify-between gap"> |
10 | | - <span class="txt-large"><%= icon_tag "lock" %></span> |
11 | | - <label class="switch flex align-center justify-between"> |
12 | | - <%= form_with url: board_publication_path(board), method: :delete, data: { controller: "form" } do |form| %> |
| 9 | + <%= form_with url: board_publication_path(board), method: :delete, class: "flex-inline center justify-between gap", data: { controller: "form" } do |form| %> |
| 10 | + <label class="flex gap cursor-pointer"> |
| 11 | + <span class="txt-large"><%= icon_tag "lock" %></span> |
| 12 | + <span class="switch flex align-center justify-between"> |
13 | 13 | <%= form.check_box :published, class: "switch__input", checked: true, data: { action: "change->form#submit" }, disabled: !Current.user.can_administer_board?(@board) %> |
14 | 14 | <span class="switch__btn round"></span> |
15 | | - <span class="for-screen-reader">Turn off the public link</span> |
16 | | - <% end %> |
| 15 | + </span> |
| 16 | + <span class="for-screen-reader">Turn off the public link</span> |
17 | 17 | </label> |
18 | | - <span class="txt-large"><%= icon_tag "world" %></span> |
19 | | - </div> |
| 18 | + <span class="txt-large" aria-hidden="true"><%= icon_tag "world" %></span> |
| 19 | + <% end %> |
20 | 20 |
|
21 | 21 | <div class="flex align-center gap-half margin-block"> |
22 | 22 | <%= text_field_tag :publication_url, published_board_url(board), readonly: true, class: "full-width input fill-white" %> |
|
40 | 40 | </div> |
41 | 41 | <% else %> |
42 | 42 | <div class="border-radius pad fill-shade"> |
43 | | - <div class="flex-inline center justify-between gap"> |
44 | | - <span class="txt-large"><%= icon_tag "lock" %></span> |
45 | | - <label class="switch flex align-center justify-between"> |
46 | | - <%= form_with url: board_publication_path(board), method: :post, data: { controller: "form" } do |form| %> |
| 43 | + <%= form_with url: board_publication_path(board), method: :post, class: "flex-inline center justify-between gap", data: { controller: "form" } do |form| %> |
| 44 | + <span class="txt-large" aria-hidden="true"><%= icon_tag "lock" %></span> |
| 45 | + <label class="flex gap cursor-pointer"> |
| 46 | + <span class="switch flex align-center justify-between"> |
47 | 47 | <%= form.check_box :published, class: "switch__input", checked: false, data: { action: "change->form#submit" }, disabled: !Current.user.can_administer_board?(@board) %> |
48 | 48 | <span class="switch__btn round"></span> |
49 | | - <span class="for-screen-reader">Turn on the public link</span> |
50 | | - <% end %> |
| 49 | + </span> |
| 50 | + <span class="txt-large"><%= icon_tag "world" %></span> |
| 51 | + <span class="for-screen-reader">Turn on the public link</span> |
51 | 52 | </label> |
52 | | - <span class="txt-large"><%= icon_tag "world" %></span> |
53 | | - </div> |
| 53 | + <% end %> |
54 | 54 | </div> |
55 | 55 | <% end %> |
56 | 56 | <% end %> |
0 commit comments