mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-02-27 01:43:22 +00:00
Upgrade pagy version to latest
This commit is contained in:
3
Gemfile
3
Gemfile
@@ -63,9 +63,10 @@ gem 'devise-token_authenticatable'
|
||||
gem 'jwt', '~> 2.3'
|
||||
gem 'oauth2', '~> 1.4.7' # Used for Stripe Connect
|
||||
|
||||
gem 'activesupport'
|
||||
gem 'datafoodconsortium-connector'
|
||||
gem 'jsonapi-serializer'
|
||||
gem 'pagy', '~> 5.1'
|
||||
gem 'pagy', '~> 8'
|
||||
|
||||
gem 'rswag-api'
|
||||
gem 'rswag-ui'
|
||||
|
||||
@@ -495,8 +495,7 @@ GEM
|
||||
validate_url
|
||||
webfinger (~> 2.0)
|
||||
orm_adapter (0.5.0)
|
||||
pagy (5.10.1)
|
||||
activesupport
|
||||
pagy (8.6.3)
|
||||
paper_trail (15.1.0)
|
||||
activerecord (>= 6.1)
|
||||
request_store (~> 1.4)
|
||||
@@ -870,6 +869,7 @@ DEPENDENCIES
|
||||
activerecord-import
|
||||
activerecord-postgresql-adapter
|
||||
activerecord-session_store
|
||||
activesupport
|
||||
acts-as-taggable-on
|
||||
acts_as_list (= 1.0.4)
|
||||
angular-rails-templates (>= 0.3.0)
|
||||
@@ -940,7 +940,7 @@ DEPENDENCIES
|
||||
omniauth_openid_connect
|
||||
openid_connect
|
||||
order_management!
|
||||
pagy (~> 5.1)
|
||||
pagy (~> 8)
|
||||
paper_trail
|
||||
paranoia (~> 2.4)
|
||||
paypal-sdk-merchant (= 1.117.2)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
- link = pagy_link_proc(pagy)
|
||||
- link = pagy_anchor(pagy)
|
||||
|
||||
%nav.pagy_nav.pagination{"aria-label" => "pager", :role => "navigation"}
|
||||
- if pagy.prev
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
- link = pagy_link_proc(pagy)
|
||||
- link = pagy_anchor(pagy)
|
||||
|
||||
.pagination{ "data-controller": "search" }
|
||||
- if pagy.prev
|
||||
@@ -6,9 +6,9 @@
|
||||
- if feature?(:admin_style_v3, spree_current_user)
|
||||
%i.icon-chevron-left{ data: { action: 'click->search#changePage', page: pagy.prev } }
|
||||
- else
|
||||
!= pagy_t('pagy.nav.prev')
|
||||
!= pagy_t('pagy.prev')
|
||||
- else
|
||||
%button.page.disabled{disabled: "disabled"}!= pagy_t('pagy.nav.prev')
|
||||
%button.page.disabled{disabled: "disabled"}!= pagy_t('pagy.prev')
|
||||
|
||||
- pagy.series.each do |item| # series example: [1, :gap, 7, 8, "9", 10, 11, :gap, 36]
|
||||
- if item.is_a?(Integer) # page link
|
||||
@@ -18,13 +18,13 @@
|
||||
%button.page.current.active= item
|
||||
|
||||
- elsif item == :gap # page gap
|
||||
%span.page.gap.pagination-ellipsis!= pagy_t('pagy.nav.gap')
|
||||
%span.page.gap.pagination-ellipsis!= pagy_t('pagy.gap')
|
||||
|
||||
- if pagy.next
|
||||
%button.page.next{ data: { action: 'click->search#changePage', page: pagy.next } }
|
||||
- if feature?(:admin_style_v3, spree_current_user)
|
||||
%i.icon-chevron-right{ data: { action: 'click->search#changePage', page: pagy.next } }
|
||||
- else
|
||||
!= pagy_t('pagy.nav.next')
|
||||
!= pagy_t('pagy.next')
|
||||
- else
|
||||
%button.page.disabled.pagination-next{disabled: "disabled"}!= pagy_t('pagy.nav.next')
|
||||
%button.page.disabled.pagination-next{disabled: "disabled"}!= pagy_t('pagy.next')
|
||||
|
||||
Reference in New Issue
Block a user