Sha256: 6c495278d58e743a0adad7d703b6818bfe908c81df037dff70df44c89db6e23d

Contents?: true

Size: 1.34 KB

Versions: 53

Compression:

Stored size: 1.34 KB

Contents

<% if @actions.count > 0 %>
  <div class="relative z-30" data-controller="toggle-panel actions-picker">
    <%= a_button class: "focus:outline-none",
      color: 'light-blue',
      'data-action': "click->toggle-panel#togglePanel",
      'data-actions-dropdown-button': @resource.plural_name.downcase,
      disabled: action_name != 'show' do
    %>
      <%= svg 'arrow-left', class: 'h-4 mr-1 transform -rotate-90' %> <%= t 'avo.actions' %>
    <% end %>
    <div
      class="absolute block inset-auto right-0 top-full bg-white min-w-300px mt-2 py-4 z-20 shadow-context rounded-xl overflow-hidden hidden"
      data-toggle-panel-target="panel"
    >
      <%
        @actions.each_with_index do |action, index|
          path = action_name == 'show' ?
            "/avo/resources/#{@resource.model_class.model_name.route_key}/#{@model.id}/actions/#{action.param_id}" :
            "/avo/resources/#{@resource.model_class.model_name.route_key}/actions/#{action.param_id}"
      %>
        <%= link_to path,
          'data-turbo-frame': 'actions_show',
          'data-action': 'click->actions-picker#visitAction',
          class: 'flex items-center w-full py-2 px-4 font-bold text-gray-700 hover:text-white hover:bg-blue-500' do %>
          <%= svg 'play', class: 'h-5 mr-1 inline' %> <%= action.name %>
        <% end %>
      <% end %>
    </div>
  </div>
<% end %>

Version data entries

53 entries across 53 versions & 1 rubygems

Version Path
avo-1.5.4 app/views/avo/base/_actions.html.erb
avo-1.5.3 app/views/avo/base/_actions.html.erb
avo-1.5.2 app/views/avo/base/_actions.html.erb
avo-1.5.1 app/views/avo/base/_actions.html.erb
avo-1.5.0 app/views/avo/base/_actions.html.erb
avo-1.4.5.pre.1 app/views/avo/base/_actions.html.erb
avo-1.4.4.pre.1 app/views/avo/base/_actions.html.erb
avo-1.4.4 app/views/avo/base/_actions.html.erb
avo-1.4.3 app/views/avo/base/_actions.html.erb
avo-1.4.2 app/views/avo/base/_actions.html.erb
avo-1.4.1 app/views/avo/base/_actions.html.erb
avo-1.4.0 app/views/avo/base/_actions.html.erb
avo-1.4.0.pre.1 app/views/avo/base/_actions.html.erb
avo-1.3.5 app/views/avo/base/_actions.html.erb
avo-1.3.5.pre.1 app/views/avo/base/_actions.html.erb
avo-1.3.4 app/views/avo/base/_actions.html.erb
avo-1.3.3 app/views/avo/base/_actions.html.erb
avo-1.3.2 app/views/avo/base/_actions.html.erb
avo-1.3.1 app/views/avo/base/_actions.html.erb
avo-1.3.0 app/views/avo/base/_actions.html.erb