Tina Docs
Introduction
Core Concepts
Querying Content
Editing
Customizing Tina
Going To Production
Drafts
Guides
Further Reference

Image Field

Table of Contents

This is an advanced-use feature, and likely not something you'll need to configure. What you probably want is the content types reference!

The image field is used for content values that point to an image used on the page. This field allows you to upload new images by via dragging or selection in Finder. Note this field does not handle any images included in the Markdown body, those would be handled by the markdown component.

image selector with an image of Portugal's beautiful night

Definition

interface ImageProps {
component: 'image'
clearable?: boolean
uploadDir?(formValues: any): string
}

KeyDescription
componentThe name of the plugin component. Always 'image'.
clearableWhen true, editors can 'clear' the image field to an empty state via a trash icon. (Optional)
uploadDirDefines the upload directory for the image. All of the form data is passed in, fileRelativePath is most useful in defining the upload directory, but you can also statically define the upload directory. (Optional)

This interfaces only shows the keys unique to the image field. Visit the Field Config docs for a complete list of options.

Last Edited: November 5, 2024