{# /** * @file * Theme override for an image field widget. * * Available variables: * - attributes: HTML attributes for the containing element. * - data: Render elements of the image widget. * - multiple: Whether this widget is the part of a multi-value file widget or * not. * - upload: Whether the file upload input is displayed or not. * - has_value: true if the widget already contains an image. * - has_meta: true when one of the title or alt inputs are enabled and visible. * * @see template_preprocess_image_widget() * @see stable_preprocess_image_widget() * @see claro_preprocess_image_widget() */ #} {% set classes = [ 'form-managed-file--image', multiple ? 'is-multiple' : 'is-single', upload ? 'has-upload' : 'no-upload', has_value ? 'has-value' : 'no-value', has_meta ? 'has-meta' : 'no-meta', data.preview ? 'has-preview' : 'no-preview', ] %}