module ApplicationHelper include Pagy::Frontend if defined?(Pagy) # Helper method for time period selector styling def time_period_class(period) base_classes = "px-4 py-2 text-sm font-medium border-r border-gray-300 last:border-r-0" if @time_period == period base_classes + " bg-blue-600 text-white" else base_classes + " text-gray-700 hover:bg-gray-50" end end # Custom pagination with Tailwind CSS styling def pagy_nav_tailwind(pagy, pagy_id: nil) return '' if pagy.pages <= 1 html = '' raw html end end