Logic for preview is done. Bug when generating options for select panels.