Converted filters to vanilla JS