Sha256: feeb49c010035a3fc2b68d46d53aecf0e0a4d968f5feeec3444c7d87370705bb

Contents?: true

Size: 792 Bytes

Versions: 72

Compression:

Stored size: 792 Bytes

Contents

class NotificationsBellComponent < BaseComponent
  def initialize(tooltip:, unseen:)
    @tooltip = tooltip
    @unseen = unseen
    super
  end

  erb_template <<~ERB
    <div>
      <% if @tooltip.present? %>
        <div class="d-inline-block text-white pg--notifications-bell--tooltip">
          <%= @tooltip %>
        </div>
      <% end %>
      <button type="button" class="btn btn-primary btn-sm position-relative"
                            data-bs-toggle="collapse" data-bs-target="#notifications-collapse">
        <i class="bi-bell-fill fs-5 text-light"></i>
        <% if @unseen %>
          <span class="position-absolute p-1 xbg-danger bg-gradient rounded-circle start-50 notifications-unseen-mark">
          </span>
        <% end %>
      </button>
    </div>
  ERB
end

Version data entries

72 entries across 72 versions & 1 rubygems

Version Path
pg_rails-7.6.20 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.19 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.18 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.17 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.16 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.15 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.14 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.13 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.12 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.11 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.10 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.9 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.8 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.7 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.6 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.5 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.4 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.3 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.2 pg_engine/app/components/notifications_bell_component.rb
pg_rails-7.6.1 pg_engine/app/components/notifications_bell_component.rb