Sha256: 39b16e3db10f1cc1b32d43d1b0031316954f6e128fe9509df420d775ca1d4801

Contents?: true

Size: 836 Bytes

Versions: 28

Compression:

Stored size: 836 Bytes

Contents

<%= render_component_tag tag_name,
  id: id,
  href: href,
  class: [
    "block px-2 py-1.5 text-xs rounded-md bg-lookbook-button-bg text-lookbook-button-text w-full transition focus:outline-none focus-visible:outline-none",
    {
      "hover:bg-lookbook-button-bg-hover": !disabled,
      "cursor-[not-allowed] opacity-50": disabled
    }
  ],
  disabled: disabled,
  aria: { label: tooltip } do %>

  <span class="flex items-center space-x-2 justify-center">
    <span x-ref="icon">
      <%= icons.present? ? safe_join(icons) : (lookbook_render(:icon, name: icon, size: icon_size, ":class": "{'animate-spin': _spinning}") if icon) %>
    </span>
    <% if content %>
      <span><%= content %></span>
    <% end %>
  </span>

  <% if tooltip %>
    <label class="hidden" x-ref="tooltip"><%= tooltip %></label>
  <% end %>
<% end %>

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
lookbook-2.3.4 app/components/lookbook/text_button/component.html.erb
lookbook-2.3.3 app/components/lookbook/text_button/component.html.erb
lookbook-2.3.2 app/components/lookbook/text_button/component.html.erb
lookbook-2.3.0 app/components/lookbook/text_button/component.html.erb
lookbook-2.2.2 app/components/lookbook/text_button/component.html.erb
lookbook-2.2.1 app/components/lookbook/text_button/component.html.erb
lookbook-2.2.0 app/components/lookbook/text_button/component.html.erb
lookbook-2.1.1 app/components/lookbook/text_button/component.html.erb
lookbook-2.1.0 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.5 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.4 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.3 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.2 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.1 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.0 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.0.rc.3 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.0.rc.2 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.0.rc.1 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.0.beta.9 app/components/lookbook/text_button/component.html.erb
lookbook-2.0.0.beta.8 app/components/lookbook/text_button/component.html.erb