basic detection and preview added