mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
16 lines
325 B
Ruby
16 lines
325 B
Ruby
# frozen_string_literal: true
|
|
|
|
class PaginationComponent < ViewComponentReflex::Component
|
|
def initialize(pagy:, data:)
|
|
super
|
|
@count = pagy.count
|
|
@page = pagy.page
|
|
@per_page = pagy.items
|
|
@pages = pagy.pages
|
|
@next = pagy.next
|
|
@prev = pagy.prev
|
|
@data = data
|
|
@series = pagy.series
|
|
end
|
|
end
|