Sha256: 3a7f0fdef62de9febdbc08af6ddd62204d68205c82dddae1fcb7b781d3101ac5

Contents?: true

Size: 470 Bytes

Versions: 12

Compression:

Stored size: 470 Bytes

Contents

<%= lookbook_render :icon_button,
  name: "copy-button",
  **button_attrs,
  "x-data": prepare_alpine_data,
  "x-on:click.prevent": "copyToClipboard" do |button| %>
  <% button.with_icon name: icon, size: icon_size, "x-show": "!copied", cloak: true %>
  <% button.with_icon name: :check, size: icon_size, class: "text-green-500", "x-show": "copied", cloak: true %>
  <% if content %>
    <div x-ref="copyTarget" class="hidden"><%== content %></div>
  <% end %>
<% end %>

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
lookbook-2.3.4 app/components/lookbook/copy_button/component.html.erb
lookbook-2.3.3 app/components/lookbook/copy_button/component.html.erb
lookbook-2.3.2 app/components/lookbook/copy_button/component.html.erb
lookbook-2.3.0 app/components/lookbook/copy_button/component.html.erb
lookbook-2.2.2 app/components/lookbook/copy_button/component.html.erb
lookbook-2.2.1 app/components/lookbook/copy_button/component.html.erb
lookbook-2.2.0 app/components/lookbook/copy_button/component.html.erb
lookbook-2.1.1 app/components/lookbook/copy_button/component.html.erb
lookbook-2.1.0 app/components/lookbook/copy_button/component.html.erb
lookbook-2.0.5 app/components/lookbook/copy_button/component.html.erb
lookbook-2.0.4 app/components/lookbook/copy_button/component.html.erb
lookbook-2.0.3 app/components/lookbook/copy_button/component.html.erb