From 621a9f409747a48026978670e9aaea41c6ae5c0b Mon Sep 17 00:00:00 2001 From: Guy Sartorelli <36352093+GuySartorelli@users.noreply.github.com> Date: Fri, 23 Feb 2024 15:42:03 +1300 Subject: [PATCH] DOC Fix placement of urlfield docs (#460) --- en/08_Changelogs/5.2.0.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/en/08_Changelogs/5.2.0.md b/en/08_Changelogs/5.2.0.md index 3477280d..e7d89c75 100644 --- a/en/08_Changelogs/5.2.0.md +++ b/en/08_Changelogs/5.2.0.md @@ -266,16 +266,16 @@ Both of these fields include a `setIsLazyLoaded()` method which will load a limi Note that these are both powered by react components, and are only intended to be used within the CMS. If you want to use them on the front-end of your project you will need to provide your own templates and JavaScript implementation for them. -### New `UrlField` {#urlfield} - -A new [`UrlField`](api:SilverStripe\Forms\UrlField) has been added which is a subclass of [`TextField`](api:SilverStripe\Forms\TextField) with some additional validation rules. It will validate that the value entered is a valid absolute URL with a protocol and a host. - #### Auto scaffolding of `has_one` relations A `SearchableDropdownField` will now be used when automatically scaffolding `has_one` relations on a form in the CMS. Previously a `DropdownField` was used, and when there were over 100 items a [`NumericField`](api:SilverStripe\Forms\NumericField) was used which was not user friendly. Previously the [`DBForeignKey.dropdown_field_threshold`](api:SilverStripe\ORM\FieldType\DBForeignKey->dropdown_field_threshold) config property was used as the threshold of the number of options to decide when to switch between auto-scaffolding a `DropdownField` and a `NumericField`. This configuration property is now used as the threshold of the number of options to decide when to start using lazy-loading for the `SearchableDropdownField`. +### New `UrlField` {#urlfield} + +A new [`UrlField`](api:SilverStripe\Forms\UrlField) has been added which is a subclass of [`TextField`](api:SilverStripe\Forms\TextField) with some additional validation rules. It will validate that the value entered is a valid absolute URL with a protocol and a host. + ### Create file variants with different extensions {#file-variants} A low-level API has been added which allows the creation of file variants with a different extension than the original extension. A file variant is a manipulated version of the original file - for example if you resize an image or convert a file to another format, this will generate a variant (leaving the original file intact).