fixed preview generation