Sha256: f9166c50e30a0e5ed40cb5bb5cef021bb3fe1e23e9828591814cc31c02ea416e

Contents?: true

Size: 412 Bytes

Versions: 13

Compression:

Stored size: 412 Bytes

Contents

# frozen_string_literal: true

module UiBibz::Ui::Concerns::NotificationConcern # :nodoc:
  extend ActiveSupport::Concern

  included do
    def data_attributes
      self.class.const_get('DATA_ATTRIBUTES').filter_map do |data_attribute|
        options[data_attribute].to_s.blank? ? nil : { "data-bs-#{data_attribute}" => data_attribute_value(data_attribute) }
      end.reduce(&:merge) || {}
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
ui_bibz-3.0.13 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.12 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.11 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.10 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.9 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.8 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.7 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.6 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.5 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.4 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.3 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.2 lib/ui_bibz/ui/concerns/notification_concern.rb
ui_bibz-3.0.1 lib/ui_bibz/ui/concerns/notification_concern.rb