{{/* One image field of a form (the design page, a post's featured image). The select lists the recent images so it works without the script; a chosen image older than those gets its own option (named through .names, or "Current image" once the file is gone), so the select always carries the choice and a save keeps it. With the script the select is hidden and "Choose from library…" opens the form's imagelib panel, which fetches the library page by page and marks the pickers with .js. */}} {{define "imagepick"}}{{$cur := .current}}{{$listed := false}}{{range .images}}{{if eq .ID.String $cur}}{{$listed = true}}{{end}}{{end}}
{{.hint}}
{{end}}