mirror of
https://github.com/docusealco/docuseal
synced 2026-11-05 06:42:32 -05:00
add infinite scroll
This commit is contained in:
1 parent
d3cc2e1ca8
commit
8cb0a7a020
21 files changed
+179
-10
No files matched your search
@@ -13,7 +13,7 @@ class ApplicationController < ActionController::Base
|
||||
before_action :maybe_redirect_to_setup, unless: :signed_in?
|
||||
before_action :authenticate_user!, unless: :devise_controller?
|
||||
|
||||
before_action :set_csp, if: -> { request.get? && !request.headers['HTTP_X_TURBO'] }
|
||||
before_action :set_csp, if: -> { request.get? && !request.headers['HTTP_X_TURBO'] && !turbo_infinite_scroll? }
|
||||
|
||||
helper_method :button_title,
|
||||
:current_account,
|
||||
@@ -65,6 +65,10 @@ class ApplicationController < ActionController::Base
|
||||
|
||||
private
|
||||
|
||||
def turbo_infinite_scroll?
|
||||
request.headers['HTTP_X_TURBO_INFINITE_SCROLL'].present?
|
||||
end
|
||||
|
||||
def turbo_native_ios?
|
||||
request.user_agent.to_s.include?('Hotwire Native iOS')
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user