packagist craftcms/cms 4.5.0

latest releases: dev-feature/pt-1344-selectize-roles-are-not-appropriate-for-the-elements, 5.x-dev, dev-bugfix/16103-embedded-index-and-reordering-part2...
14 months ago

Content Management

  • Entry and category edit pages now show other authors who are currently editing the same element. (#13420)
  • Entry and category edit pages now display a notification when the element has been saved by another author. (#13420)
  • Entry and category edit pages now display a validation error summary at the top of the page, including a mention of errors from other sites. (#11569, #12125)
  • Table fields can now have a “Row heading” column. (#13231)
  • Table fields now have a “Static Rows” setting. (#13231)
  • Table fields no longer show a heading row, if all heading values are blank. (#13231)
  • Element slideouts now show their sidebar content full-screen for elements without a field layout, rather than having an empty body. (#13056, #13053)
  • Relational fields no longer track the previously-selected element(s) when something outside the field is clicked on. (#13123)
  • Element indexes now use field layouts’ overridden field labels, if all field layouts associated with an element source use the same label. (#8903)
  • Element indexes now track souces’ filters in the URL, so they can be sharable and persisted when navigating back to the index page via the browser history. (#13499)
  • Users’ default thumbnails are now the user initials over a unique color gradient. (#13511)
  • Improved the styling and max height of Selectize inputs. (#13065, #13176)
  • Selectize inputs now support click-and-drag selection. (#13273)
  • Selectize single-select inputs now automatically select the current value on focus. (#13273)
  • It’s now possible to create new entries from entry select modals when a custom source is selected, if the source is configured to only show entries from one section. (#11499)
  • The Entries index page now shows a primary “New entry” button when a custom source is selected, if the source is configured to only show entries from one section. (#13390)
  • Invalid Dropdown fields now automatically select their default option and get marked as changed (if they have a default option). (#13540)

Accessibility

  • Image assets’ thumbnails and <img> tags generated via craft\element\Asset::getImg() no longer use the assets’ titles as alt fallback values. (#12854)
  • Element index pages now have visually-hidden “Sources” headings for screen readers. (#12961)
  • Element metadata fields now have visually-hidden “Metadata” headings for screen readers. (#12961)
  • Structure elements within element indexes now convey their levels to screen readers. (#13020)
  • Non-image asset thumbnails in the control panel now have alt attributes set to the file extension. (#12724)
  • Improved copy-text buttons for screen readers. (#13073)
  • Improved the contrast of asset file type icons. (#13262)

Administration

  • Added the “Slug Translation Method” setting to entry types. (#8962, #13291)
  • Added the “Show the Status field” setting to entry types. (#12837, #13265)
  • Added the setup/cloud command, which prepares a Craft install to be deployed to Craft Cloud.
  • Added the setup/message-tables command, which can be run to set the project up for database-stored static translations via DbMessageSource. (#13542)
  • Entry types created via the entrify/global-set command now have “Show the Status field” disabled by default. (#12837)
  • Added the defaultCountryCode config setting. (#13478)
  • Custom element sources can now be configured to only appear for certain sites. (#13344)
  • The “My Account” page no longer shows a “Require a password reset on next login” checkbox.
  • The Asset Indexes utility no longer shows the “Cache remote images” option on ephemeral environments. (#13202)
  • It’s now possible to configure UK addresses to show a “County” field. (#13361)
  • The “Login Page Logo” and “Site Icon” general settings’ image previews now have checkered backgrounds. (#13210, #13229)
  • Empty field layout tabs are no longer pruned out. (#13132)
  • active, addresses, admin, email, friendlyName, locked, name, password, pending, suspended, and username are now reserved user field handles. (#13579)

Development

  • Added a new _globals global Twig variable for front-end templates, which can be used to store custom values in a global scope. (#13050, #12951)
  • The |replace Twig filter now supports passing in a hash with regular expression keys. (#12956)
  • {% exit %} tags now support passing a message after the status code. (#13166)
  • Built-in element types’ GraphQL queries now support passing null to relatedToAssets, relatedToEntries, relatedToUsers, relatedToCategories, relatedToTags, and relatedToAll arguments. (#7954)
  • Elements now include custom field values when being iterated over, and when being merged. (#13009)
  • Dropdown and Radio Buttons fields now have a “Column Type” setting, which will be set to varchar for existing fields, and defaults to “Automatic” for new fields. (#13025, #12954)
  • Successful users/login JSON responses now include information about the logged-in user. (#13374)

Extensibility

  • Filesystem types can now register custom file uploaders. (#13313)
  • When applying a draft, the canonical elements’ getDirtyAttributes() and getDirtyFields() methods now return the attribute names and field handles that were modified on the draft for save events. (#12967)
  • Admin tables can be configured to pass custom query params to the data endpoint. (#13416)
  • Admin tables can now be programatically reloaded. (#13416)
  • Admin table properties are now reactive. (#13558, #13520)
  • Native element sources can now define a defaultFilter key, which defines the default filter condition that should be applied when the source is selected. (#13499)
  • Added craft\addresses\SubdivisionRepository. (#13361)
  • Added craft\base\Element::showStatusField(). (#13265)
  • Added craft\base\Element::thumbSvg(). (#13262)
  • Added craft\base\ElementInterface::getIsSlugTranslatable().
  • Added craft\base\ElementInterface::getSlugTranslationDescription().
  • Added craft\base\ElementInterface::getSlugTranslationKey().
  • Added craft\base\ElementInterface::getThumbHtml().
  • Added craft\base\ElementInterface::modifyCustomSource().
  • Added craft\base\ElementInterface::setDirtyFields().
  • Added craft\base\ElementInterface::setFieldValueFromRequest(). (#12935)
  • Added craft\base\FieldInterface::normalizeValueFromRequest(). (#12935)
  • Added craft\base\FieldLayoutProviderInterface. (#13250)
  • Added craft\base\FsInterface::getShowHasUrlSetting(). (#13224)
  • Added craft\base\FsInterface::getShowUrlSetting(). (#13224)
  • Added craft\base\FsTrait::$showHasUrlSetting. (#13224)
  • Added craft\base\FsTrait::$showUrlSetting. (#13224)
  • Added craft\behaviors\EventBehavior. (#13502)
  • Added craft\controllers\AssetsControllerTrait.
  • Added craft\elements\db\ElementQuery::EVENT_BEFORE_POPULATE_ELEMENT.
  • Added craft\events\AssetBundleEvent.
  • Added craft\events\DefineAddressSubdivisionsEvent. (#13361)
  • Added craft\events\MoveElementEvent::$action. (#13429)
  • Added craft\events\MoveElementEvent::$targetElementId. (#13429)
  • Added craft\events\MoveElementEvent::getTargetElement(). (#13429)
  • Added craft\gql\GqlEntityRegistry::getOrCreate(). (#13354)
  • Added craft\helpers\Assets::iconSvg().
  • Added craft\helpers\StringHelper::escapeShortcodes(). (#12935)
  • Added craft\helpers\StringHelper::unescapeShortcodes(). (#12935)
  • Added craft\models\FieldLayout::$provider. (#13250)
  • Added craft\services\Addresses::$formatter, which can be used to override the default address formatter. (#13242, #12615)
  • Added craft\services\Addresses::EVENT_DEFINE_ADDRESS_SUBDIVISIONS. (#13361)
  • Added craft\services\Addresses::defineAddressSubdivisions(). (#13361)
  • Added craft\services\Elements::collectCacheInfoForElement().
  • Added craft\services\Elements::getRecentActivity(). (#13420)
  • Added craft\services\Elements::trackActivity(). (#13420)
  • Added craft\services\ProjectConfig::$cacheDuration. (#13164)
  • Added craft\services\Structures::ACTION_APPEND. (#13429)
  • Added craft\services\Structures::ACTION_PLACE_AFTER. (#13429)
  • Added craft\services\Structures::ACTION_PLACE_BEFORE. (#13429)
  • Added craft\services\Structures::ACTION_PREPEND. (#13429)
  • Added craft\services\Structures::EVENT_AFTER_INSERT_ELEMENT. (#13429)
  • Added craft\services\Structures::EVENT_BEFORE_INSERT_ELEMENT. (#13429)
  • Added craft\web\Controller::EVENT_DEFINE_BEHAVIORS. (#13477)
  • Added craft\web\Controller::defineBehaviors(). (#13477)
  • Added craft\web\CpScreenResponseBehavior::$errorSummary, errorSummary(), and errorSummaryTemplate(). (#12125)
  • Added craft\web\CpScreenResponseBehavior::$pageSidebar, pageSidebar(), and pageSidebarTemplate(). (#13019, #12795)
  • Added craft\web\CpScreenResponseBehavior::$slideoutBodyClass.
  • Added craft\web\Response::$defaultFormatters. (#13541)
  • Added craft\web\View::EVENT_AFTER_REGISTER_ASSET_BUNDLE.
  • craft\elements\actions\NewChild is no longer triggerable on elements that have a data-disallow-new-children attribute. (#13539)
  • craft\elements\actions\SetStatus is no longer triggerable on elements that have a data-disallow-status attribute.
  • craft\helpers\Cp::selectizeFieldHtml(), selectizeHtml(), and _includes/forms/selectize.twig now support a multi param. (#13176)
  • craft\helpers\Typecast::properties() now supports backed enum values. (#13371)
  • craft\services\Assets::getRootFolderByVolumeId() now ensures the root folder actually exists, and caches its results internally, improving performance. (#13297)
  • craft\services\Assets::getThumbUrl() now has an $iconFallback argument, which can be set to false to prevent a file icon URL from being returned as a fallback for assets that don’t have image thumbnails.
  • craft\services\Assets::getAllDescendantFolders() now has an $asTree argument. (#13535)
  • craft\services\Structures::EVENT_BEFORE_MOVE_ELEMENT is now cancellable. (#13429)
  • craft\validators\UniqueValidator now supports setting an additional filter via the filter property. (#12941)
  • craft\web\Response::setCacheHeaders() now has $duration and $overwrite arguments.
  • craft\web\Response::setNoCacheHeaders() now has an $overwrite argument.
  • craft\web\UrlManager no longer triggers its EVENT_REGISTER_CP_URL_RULES and EVENT_REGISTER_SITE_URL_RULES events until the request is ready to be routed, making it safe to call UrlManager::addRules() from plugin/module constructors. (#13109)
  • Deprecated craft\base\Element::EVENT_AFTER_MOVE_IN_STRUCTURE. (#13429)
  • Deprecated craft\base\Element::EVENT_BEFORE_MOVE_IN_STRUCTURE. (#13429)
  • Deprecated craft\base\Element::afterMoveInStructure(). (#13429)
  • Deprecated craft\base\Element::beforeMoveInStructure(). (#13429)
  • Deprecated craft\events\ElementStructureEvent. (#13429)
  • Deprecated craft\helpers\ArrayHelper::firstKey(). array_key_first() should be used instead.
  • Deprecated craft\helpers\Assets::iconPath(). craft\helpers\Assets::iconSvg() or craft\elements\Asset::getThumbHtml() should be used instead.
  • Deprecated craft\helpers\Assets::iconUrl().
  • Deprecated craft\helpers\UrlHelper::buildQuery(). http_build_query() should be used instead.
  • Deprecated craft\services\Volumes::ensureTopFolder(). craft\services\Assets::getRootFolderByVolumeId() should be used instead.
  • Added Craft.BaseUploader. (#13313)
  • Added Craft.createUploader(). (#13313)
  • Added Craft.registerUploaderClass(). (#13313)
  • Added Craft.Tooltip.

System

  • Added support for setting environmental values in a “secrets” PHP file, identified by a CRAFT_SECRETS_PATH environment variable. (#13283)
  • Added support for the CRAFT_LOG_ALLOW_LINE_BREAKS environment variable. (#13544)
  • All generated URL param characters are now properly encoded. (#12796)
  • migrate commands besides migrate/create no longer create the migration directory if it doesn’t exist yet. (#12732)
  • When content table columns are resized, if any existing values are too long, all column data is now backed up into a new table, and the overflowing values are set to null. (#13025)
  • When content table columns are renamed, if an existing column with the same name already exists, the original column data is now backed up into a new table and then deleted from the content table. (#13025)
  • Plain Text and Table fields no longer convert emoji to shortcodes on PostgreSQL.
  • Reduced the size of control panel Ajax request headers.
  • Improved GraphQL performance. (#13354)
  • Fixed an error that occurred when exporting assets, if a subfolder was selected. (#13570)
  • Fixed a bug where icons within secondary buttons were illegible when active.
  • Fixed a bug where the |replace filter was treating search strings as regular expressions even if they were invalid. (#12956)
  • Fixed a bug where user groups without “Edit users” permission were being granted “Assign users to [group name]” when upgrading to Craft 4.
  • Fixed a bug where keyboard shortcuts weren’t getting reactivated when control panel notifications were dismissed. (#13574)
  • Fixed a bug where Plain Text and Table fields were converting posted shortcode-looking strings to emoji. (#12935)
  • Fixed a bug where craft\elements\Asset::getUrl() was returning invalid URLs for GIF and SVG assets within filesystems without base URLs, if the transformGifs or transformSvgs config settings were disabled. (#13306)
  • Fixed a bug where the GraphQL API wasn’t enforcing schema site selections for the requested site. (#13346)
  • Fixed a bug where PM times were getting converted to AM for Greek locales. (#9942)
  • Fixed a bug where Command/Ctrl + clicks on “New entry” button menu options would open the Entries index page in a new tab, and redirect to the Edit Entry page in the current tab. (#13550)
  • Fixed DB cache support for PostgreSQL.
  • Updated Yii to 2.0.48.1. (#13445)
  • Loosened the Composer constraint to ^2.2.19. (#13396)
  • Internal Composer operations now use a bundled composer.phar file, rather than Composer’s PHP API. (#13519)
  • Updated Selectize to 0.15.2. (#13273)

Don't miss a new cms release

NewReleases is sending notifications on new releases.