Content Management
- Custom fields within element edit pages can now have action menus with “Copy value from site…”, “Edit field” and “Copy field handle” items. (#16415, #14056)
- Added the “Field” entry condition rule, which replaces “Matrix field”, includes a “has a value” operator. (#16270)
- “Related To”, “Not Related To”, “Author”, and relational field condition rules now allow multiple elements to be specified. (#16121)
- Section condition rules now have a “has a value” operator. (#16270)
- Added the “Widget Title” setting to Quick Post widgets. (#16429)
- Improved the styling of inline code fragments. (#16141)
- Improved the styling of attribute previews in card view. (#16324)
- Added the “Affiliated Site” user condition rule. (#16174)
- Added the “Credentialed” user card/table attribute.
- The global sidebar no longer shows “Failed” for queue jobs, for users that don’t have access to the Queue Manager. (#16184)
- Addresses and Matrix fields now show provisional drafts when previewing an owner element. (#16295)
- Color fields with a predefined color palette now primarily show a color select dropdown, rather than a manual color input. (#16249)
- Improved how fields are sized in responsive field layouts. (#16303)
- Entry indexes now only show table column options and sort options for custom fields associated with the selected sections/entry types within custom entry sources’ conditions.
- Structure views are now available to element indexes on mobile browsers. (#16190)
- Datepickers now include a dropdown menu for selecting the year. (#16376)
- Element exports now include date attribute values set to the system time zone. (#16447)
- Heads-up displays now reposition themselves on window scroll.
Accessibility
- Improved the accessibility of Checkboxes and Radio Buttons fields that allow custom options. (#16080)
- Improved the accessibility of control panel icons. (#16128)
- Improved the accessibility of Selectize inputs. (#16110)
- Improved the accessibility of the image rotation control within the Image Editor. (#16218)
- Improved the accessibility of action menus on the Plugins index page.
- Improved the accessibility of “More” and “Advanced” toggle triggers. (#16293)
- Improved the accessibility of the Craft Support widget. (#16293)
- Improved the accessibility of field translatable indicators and tooltips.
- Progress bars now announce their progress to screen readers. (#16398)
- Loading spinners within element indexes and inline-editable Matrix fields are now announced to screen readers. (#16417)
- Improved the accessibility of timepicker inputs. (#16152)
Administration
- Added support for setting site-specific email setting overrides. (#16187)
- Added the “Affiliated Site” native user field. (#16174)
- Added the “View users” user permission. (#16206)
- Added the ability to override entry type names and handles for sections and Matrix fields. (#16453)
- Added the “Advanced Fields” setting to Link fields, with “Target”, “URL Suffix”, “Title Text”, “ARIA Label”, “Class Name”, “ID”, and “Relation (rel)” options. (#16268)
- Added the “Palette” setting to Color fields, which replaces “Presets”. (#16249)
- Added the “Allow custom colors” setting to Color fields. (#16249)
- Added the “GraphQL Mode” Link field setting. (#16237)
- Added a card view designer for addresses. (#16446)
- It’s now possible to view (but not edit) system and plugin settings on environments where
allowAdminChanges
is disabled. (#16265) - Added “Copy plugin handle” and “Copy package name” options to plugins’ action menus on the Plugins index page. (#16281)
- The Updates utility now shows an action menu for each plugin, with “Copy plugin handle” and “Copy package name” options. (#16281)
- The Queue Manager utility now shows jobs’ class names. (#16228)
- Field layout designers no longer show the element library in a persisting sidebar. Instead, tabs always show “Add” buttons, which open the element library within a heads-up display. (#16374)
- It’s now possible to add new field layout elements to tabs by clicking/tapping or pressing Return/Spacebar on them. (#16374)
- After creating a new field from a field layout designer, the field is now immediately added to the field layout tab. (#16374)
- Templates rendered for “Template” field layout UI elements can now call control panel template functions like
elementChip()
andelementCard()
. (#16267) - “Template” field layout UI elements now show suggestions for the Template input.
- Removed the “Edit field” action from field instance action menus within field layout designers. (#16451)
- Added the
elements/delete-all-of-type
command. (#16423) - Added the
utils/delete-empty-volume-folders
command. (#16388) - Improved the error output for nested elements when they can’t be resaved via
resave
commands. resave
commands’--drafts
,--provisional-drafts
, and--revisions
options can now be set tonull
, causing elements to be resaved regardless of whether they’re drafts/provisional drafts/revisions.- Added the
systemTemplateCss
config setting. (#16344) - The
loginPath
,logoutPath
,setPasswordPath
, andverifyEmailPath
config settings are now respected in headless mode. (#16344)
Development
- Added support for fallback element partial templates, e.g.
_partials/entry.twig
as opposed to_partials/entry/typeHandle.twig
. (#16125) - Added the
primarySite
global Twig variable. (#16370) - Added the
PHP_INT_MAX
global Twig variable. - The
duration
Twig filter now has alanguage
argument. (#16332) - The
indexOf
Twig filter now has adefault
argument, which can be any integer ornull
. (-1
by default for backwards compatibility.) {% cache %}
tags now cache any JavaScript import map entries registered viacraft\web\View::registerJsImport()
within them.- The
{% requireAdmin %}
tag now supports passing a boolean value, which determines whether administrative changes must be allowed (defaults totrue
). - Added the
withProvisionalDrafts
element query param, which causes the resulting elements to be replaced with any provisional drafts for the current user. - It’s now possible to pass nested custom field value keys into element queries’
orderBy
andselect
params (e.g.myDateField.tz
). (#16157) - It’s now possible to reference custom field handles in element queries’
where
params. (#16318) - Number fields’ scalar values now return an integer if Decimals is set to
0
, and a number formatted with the correct decimal points when using MySQL. (16369) - Added the
affiliatedSite
andaffiliatedSiteId
user query and GraphQL params. (#16174) - Added the
affiliatedSiteHandle
andaffiliatedSiteId
user GraphQL field. (#16174) - Added support for specifying the current site via an
X-Craft-Site
header set to a site ID or handle. (#16367) - It’s now possible to set Link field values to arrays with
value
keys set to element instances or IDs. (#16255) - Added the
disable2fa
config setting. (#16426) - Added support for defining redirects from
config/redirects.php
. (#16355) - Deprecated the
ucfirst
Twig filter.capitalize
should be used instead.
Extensibility
- Added
craft\attributes\EnvName
. - Added
craft\base\ConfigurableComponentInterface::getReadOnlySettingsHtml()
. (#16265) - Added
craft\base\CrossSiteCopyableFieldInterface
. (#14056) - Added
craft\base\Element::EVENT_DEFINE_ALT_ACTIONS
. (#16294) - Added
craft\base\ElementInterface::getAltActions()
. (#16294) - Added
craft\base\ElementInterface::getIsCrossSiteCopyable()
. (#14056) - Added
craft\base\ElementTrait::$viewMode
. (#16324) - Added
craft\base\Field::copyCrossSiteValue()
. (#14056) - Added
craft\base\Field::dbTypeForValueSql()
. - Added
craft\base\Indicative
. - Added
craft\base\NestedElementTrait::ownerType()
. - Added
craft\base\PluginTrait::$hasReadOnlyCpSettings
. (#16265) - Added
craft\base\Plugininterface::getReadOnlySettingsResponse()
. (#16265) - Added
craft\base\conditions\BaseElementSelectConditionRule::allowMultiple()
. - Added
craft\base\conditions\BaseElementSelectConditionRule::getElementIds()
. - Added
craft\base\conditions\BaseElementSelectConditionRule::setElementIds()
. - Added
craft\elements\User::$affiliatedSiteId
. - Added
craft\elements\User::getAffiliatedSite()
. - Added
craft\elements\User::getHasPassword()
. - Added
craft\elements\conditions\entries\FieldConditionRule
. - Added
craft\elements\db\ElementQueryInterface::getFieldLayouts()
. - Added
craft\elements\db\NestedElementQueryTrait::fieldLayouts()
. - Added
craft\events\DefineAltActionsEvent
. - Added
craft\events\RedirectEvent
. (#16355) - Added
craft\fieldlayoutelements\BaseField::actionMenuItems()
. - Added
craft\fieldlayoutelements\BaseField::isCrossSiteCopyable()
. - Added
craft\fields\BaseRelationField::gqlFieldArguments()
. - Added
craft\fields\Color::$allowCustomColors
. (#16249) - Added
craft\fields\Color::$palette
. (#16249) - Added
craft\fields\Color::getDefaultColor()
. (#16249) - Added
craft\fields\Color::setDefaultValue()
. (#16249) - Added
craft\fields\data\LinkData::$ariaLabel
. - Added
craft\fields\data\LinkData::$class
. - Added
craft\fields\data\LinkData::$id
. - Added
craft\fields\data\LinkData::$rel
. - Added
craft\fields\data\LinkData::$title
. - Added
craft\fields\data\LinkData::$urlSuffix
. - Added
craft\fields\data\LinkData::getElementQuery()
. (#16458) - Added
craft\fields\data\LinkData::getUrl()
. - Added
craft\fields\linktypes\BaseElementLinkType::elementQuery()
. - Added
craft\gql\types\LinkData
. - Added
craft\gql\types\generators\LinkDataType
. - Added
craft\helpers\Cp::colorHtml()
. - Added
craft\helpers\Cp::readOnlyNoticeHtml()
. (#16265) - Added
craft\helpers\Image::EXIF_IFD0_ROTATE_0_MIRRORED
. - Added
craft\helpers\Image::EXIF_IFD0_ROTATE_0
. - Added
craft\helpers\Image::EXIF_IFD0_ROTATE_180_MIRRORED
. - Added
craft\helpers\Image::EXIF_IFD0_ROTATE_270_MIRRORED
. - Added
craft\helpers\Image::EXIF_IFD0_ROTATE_90_MIRRORED
. - Added
craft\helpes\Html::disableInputs()
. (#16265) - Added
craft\mail\Mailer::$siteId
. - Added
craft\mail\Mailer::$siteOverrides
. - Added
craft\models\AssetIndexingSession::$forceStop
. (#16435) - Added
craft\models\EntryType::$original
. (#16453) - Added
craft\models\EntryType::$validateHandleUniqueness
. (#16453) - Added
craft\models\EntryType::getUsageConfig()
. (#16453) - Added
craft\models\MailSettings::$siteOverrides
. - Added
craft\services\Elements::canSaveCanonical()
. - Added
craft\services\Entries::getEntryType()
. (#16453) - Added
craft\services\Gql::getFieldLayoutArguments()
. - Added
craft\web\ErrorHandler::EVENT_BEFORE_REDIRECT
. (#16355) - Added
craft\web\RedirectRule
. (#16355) - Added
craft\web\UrlRule::regexTokens()
. - Added
craft\web\User::getImpersonator()
. - Added
craft\web\User::getImpersonatorId()
. - Added
craft\web\User::setImpersonatorId()
. - Added
craft\web\View::clearJsImportBuffer()
. (#16414) - Added
craft\web\View::registerJsImport()
. (#16414) - Added
craft\web\View::registerScriptWithVars()
. (#16414) - Added
craft\web\View::setTwig()
. - Added
craft\web\View::startJsImportBuffer()
. (#16414) - Added
craft\web\twig\variables\Cp::EVENT_REGISTER_READ_ONLY_CP_SETTINGS
. (#16265) GuzzleHttp\Client
is now instantiated viaCraft::createObject()
. (#16366)craft\elements\Entry::getAvailableEntryTypes()
now has a$triggerEvent
argument.craft\elements\NestedElementManager::getIndexHtml()
now supports passingdefaultSort
in the$config
array. (#16236)craft\elements\conditions\entries\MatrixFieldConditionRule
is now an alias ofFieldConditionRule
.craft\helpers\App::envConfig()
now checks for acraft\attributes\EnvName
attribute on public properties, which can be used to override the environment variable name (sans prefix) that is associated with the property.craft\helpers\Cp::elementIndexHtml()
now supports passingdefaultSort
in the$config
array, whensources
isnull
. (#16236)craft\helpers\Cp::fieldHtml()
now supports passing anactionMenuItems
array in the config. (#16415)craft\helpers\DateTimeHelper::humanDuration()
now has a$language
argument. (#16332)craft\models\ImageTransform
objects are now instantiated viaCraft::createObject()
. (#15646)craft\models\Site
now implementscraft\base\Chippable
.craft\services\Revisions::createRevision()
no longer creates the revision if anEVENT_BEFORE_CREATE_REVISION
event handler sets$event->handled
totrue
and at least one revision already exists for the element. (#16260)- Elements’
defineCardAttributes()
methods can now return aplaceholder
value set to a callable. - Deprecated
craft\controllers\RedirectController
. (#16355) - Deprecated
craft\elements\User::EVENT_REGISTER_USER_ACTIONS
. - Deprecated
craft\elements\User::IMPERSONATE_KEY
.craft\web\User::getImpersonatorId()
should be used instead. - Deprecated
craft\fields\Color::$presets
. (#16249) - Deprecated
craft\fields\Link::$showTargetField
. _includes/forms/autosuggest.twig
now supports asuggestTemplates
variable._includes/forms/colorSelect.twig
now supportsoptions
andwithBlankOption
variables._includes/forms/componentSelect.twig
now supports ashowIndicators
variable._includes/forms/entryTypeSelect.twig
now supports anallowOverrides
variable._includes/forms/selectize.twig
now supports acolor
property in option data, which can be set to a hex value or a color name.- Added
Craft.EntryTypeSelectInput
. - Added
Craft.IntervalManager
. (#16398) - Sortable checkbox selects now always display the selected options first on initial render.
System
- Craft now keeps track of which site users registered from. When sending an email from the control panel, the current site is now set to the user’s affiliated site, if known. (#16174)
- The system Login template is now rendered from
/login
(per theloginPath
config setting) if a site template doesn’t exist in the same location. (#16344) - When a user with an active two-step verification method logs in from the front end, they’ll be redirected to
/login
(per theloginPath
config setting) to complete the verification process. (#16344) - System templates (Login, Set Password, and error message screens) now have more generic styling when rendered on the front end, and can now have custom CSS styling via the
systemTemplateCss
config setting. (#16344) - Verification emails now link to the front-end Set Password form, if the email was sent from the front end. (#16340)
- Added a
preview/<elementId>
control panel route, which renders Live Preview in a standalone mode for the element. (#16441) - Database rows with foreign keys referencing nonexistent rows are now deleted via garbage collection.
- Pages which contain image transform generation URLs now set no-cache headers. (#16195)
- Action requests (such as
actions/app/health-check
) now send no-cache headers by default. (#16364) - Reduced the size of GraphQL introspection schemas. (#16326)
- Entry types names are no longer renamed for uniqueness when upgrading to Craft 5. (#16453)
- Entry type handles are now overridden to match their prior values for sections and Matrix fields, when upgrading to Craft 5. (#16453)
- The “Password & Verification” and “Passkeys” pages are no longer shown for users who don’t currently have a password.
- Image cleansing now preserves the original image quality, if known.
- Updated Twig to 3.15. (#16207)
- Added the Symfony CssSelector component.
- Added the Symfony DomCrawler component.
- Fixed a bug where
craft\config\GeneralConfig::safeMode()
set Safe Mode tofalse
by default. - Fixed a bug where Craft wasn’t auto-rotating or flipping images uploaded with a mirrored EXIF orientation.
- Fixed a bug where asset indexing could get stuck in an infinite loop if the index data was deleted. (#16435)
- Fixed a bug where embedded element index filter HUDs were including condition rules for fields that weren’t applicable to the nested elements. (#16289)
- Fixed a bug where element queries were ignoring params for custom fields that weren’t involved with the query, rather than returning zero results.
- Fixed a bug where opening heads-up displays could cause the page to scroll to the focused element.
- Fixed a bug where field labels weren’t being read by screen readers. (#16424)
- Fixed a bug where not all status labels were getting styled correctly. (#16448)
- Fixed an error that could occur when setting
relatedTo*
GraphQL arguments tonull
. (#16433) - Fixed a bug where old structure data wasn’t getting soft-deleted when a section was assigned a new structure UUID when applying project config changes. (#16450)
- Fixed a bug where
craft\events\DefineAssetUrlEvent::$transform
wasn’t always defined for assets’EVENT_BEFORE_DEFINE_URL
andEVENT_DEFINE_URL
events. (#16464) - Fixed an error that occurred if a new user couldn’t be created due to validation errors. (#16437)
- Fixed an error that could occur when adding or removing card attributes.
- Fixed a bug where element query params that included
*
weren’t respectingcaseInsensitive: true
. (#16409)