add next prev classes for dynamic container on init