Sha256: a4844665f8cdfeec3e69247fcbf4c9164384ea0137995bcbb5410e6d17c37723

Contents?: true

Size: 1.54 KB

Versions: 86

Compression:

Stored size: 1.54 KB

Contents

<div class="relative flex flex-col w-full sm:w-auto js-actions-dropdown"
  data-controller="toggle-panel actions-picker"
  data-actions-picker-enabled-class="text-black hover:bg-primary-500 hover:text-white"
  data-actions-picker-disabled-class="cursor-wait text-gray-500"
>
  <%= a_button style: @style,
    type: :button,
    color: @color,
    class: "focus:outline-none",
    icon: 'arrow-circle-right',
    icon_class: 'transform rotate-90',
    'data-action': "click->toggle-panel#togglePanel",
    'data-actions-dropdown-button': @resource.model_key do %>
    <%= label %>
  <% end %>
  <div
    class="absolute flex inset-auto xl:right-0 top-full bg-white w-full sm:w-auto sm:min-w-[300px] mt-2 z-40 shadow-modal rounded overflow-hidden hidden"
    data-toggle-panel-target="panel"
  >
    <div class="w-full space divide-y">
      <% actions.each_with_index do |action, index| %>
        <%= link_to action_path(action.param_id),
          data: {
            'turbo-frame': 'actions_show',
            'action': 'click->actions-picker#visitAction',
            'actions-picker-target': action.standalone ? 'standaloneAction' : 'resourceAction',
            'disabled': is_disabled?(action),
          },
          title: action.action_name,
          class: "flex items-center px-4 py-3 w-full font-semibold text-sm hover:bg-primary-100 #{is_disabled?(action) ? 'text-gray-500' : 'text-black'}" do %>
          <%= svg 'play', class: 'h-5 mr-1 inline pointer-events-none' %> <%= action.action_name %>
        <% end %>
      <% end %>
    </div>
  </div>
</div>

Version data entries

86 entries across 86 versions & 1 rubygems

Version Path
avo-2.53.0 app/components/avo/actions_component.html.erb
avo-2.52.0 app/components/avo/actions_component.html.erb
avo-2.49.0 app/components/avo/actions_component.html.erb
avo-2.48.0 app/components/avo/actions_component.html.erb
avo-2.47.0 app/components/avo/actions_component.html.erb
avo-2.46.0 app/components/avo/actions_component.html.erb
avo-2.45.0 app/components/avo/actions_component.html.erb
avo-2.44.0 app/components/avo/actions_component.html.erb
avo-2.43.0 app/components/avo/actions_component.html.erb
avo-2.42.2 app/components/avo/actions_component.html.erb
avo-2.42.1 app/components/avo/actions_component.html.erb
avo-2.42.0 app/components/avo/actions_component.html.erb
avo-2.41.0 app/components/avo/actions_component.html.erb
avo-2.40.0 app/components/avo/actions_component.html.erb
avo-2.39.0 app/components/avo/actions_component.html.erb
avo-2.38.0 app/components/avo/actions_component.html.erb
avo-2.37.2 app/components/avo/actions_component.html.erb
avo-2.37.1 app/components/avo/actions_component.html.erb
avo-2.37.0 app/components/avo/actions_component.html.erb
avo-2.36.3 app/components/avo/actions_component.html.erb