Skip to content

Add support for float intervals and min/max warnings for number inputs#26190

Merged
AlexGaillard merged 22 commits intomainfrom
CMS-1212
Nov 24, 2025
Merged

Add support for float intervals and min/max warnings for number inputs#26190
AlexGaillard merged 22 commits intomainfrom
CMS-1212

Conversation

@gaetansenn
Copy link
Copy Markdown
Contributor

@gaetansenn gaetansenn commented Nov 14, 2025

Scope

What's changed:

  • Step, min, and max options now accept decimal values for float/decimal fields
  • Input validation warnings now detect and display min/max range violations
  • Step up/down controls now properly handle float values

Tested Scenarios

  • Configured float field with decimal step interval (0.2)
  • Entered value exceeding configured maximum, warning icon displayed
  • Entered value below configured minimum, warning icon displayed
  • Step up/down controls with integer values
  • Step up/down controls with float/decimal values
  • Step controls respect min/max boundaries
  • Invalid input validation takes priority over range validation

Checklist

  • Added or updated tests
  • Documentation PR created here or not required
  • OpenAPI package PR created here or not required

Fixes #25682

@linear
Copy link
Copy Markdown

linear bot commented Nov 14, 2025

@AlexGaillard
Copy link
Copy Markdown
Member

Let's add a boilerplate test for this, at least check it mounts and then test the new logic.

Interface tests reference: https://github.com/directus/directus/blob/bd39e1c475bc0a6f6e1e64721c7b9189fbf95066/app/src/interfaces/presentation-links/presentation-links.test.ts

gaetansenn and others added 2 commits November 14, 2025 16:23
Co-authored-by: daedalus <44623501+ComfortablyCoding@users.noreply.github.com>
@formfcw formfcw self-requested a review November 17, 2025 06:41
Copy link
Copy Markdown
Contributor

@formfcw formfcw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @gaetansenn ❤️
A few minor changes.

@gaetansenn gaetansenn changed the title Add support for decimal intervals and min/max validation for float fields Addsupport for float intervals and min/max warnings for number inputs Nov 20, 2025
@gaetansenn gaetansenn changed the title Addsupport for float intervals and min/max warnings for number inputs Add support for float intervals and min/max warnings for number inputs Nov 20, 2025
Copy link
Copy Markdown
Contributor

@formfcw formfcw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @gaetansenn, just a few things to consider.

Copy link
Copy Markdown
Contributor

@formfcw formfcw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @gaetansenn ❤️
Nice improvement 🚀

LGTM 🎉

Copy link
Copy Markdown
Member

@AlexGaillard AlexGaillard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🆒🫘

@AlexGaillard AlexGaillard merged commit 523b6de into main Nov 24, 2025
69 checks passed
@AlexGaillard AlexGaillard deleted the CMS-1212 branch November 24, 2025 17:03
@github-actions github-actions bot added this to the Next Release milestone Nov 24, 2025
alexlebens pushed a commit to alexlebens/infrastructure that referenced this pull request Dec 11, 2025
This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [directus/directus](https://github.com/directus/directus) | minor | `11.13.4` -> `11.14.0` |

---

### Release Notes

<details>
<summary>directus/directus (directus/directus)</summary>

### [`v11.14.0`](https://github.com/directus/directus/releases/tag/v11.14.0)

[Compare Source](directus/directus@v11.13.4...v11.14.0)

##### ⚠️ Potential Breaking Changes

- **[@&#8203;directus/stores](https://github.com/directus/stores)**
  - Removed sidebar states from app store ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))

##### ✨ New Features & Improvements

- **[@&#8203;directus/app](https://github.com/directus/app)**
  - Added support for downloading multiple files and entire folder trees ([#&#8203;26006](directus/directus#26006) by [@&#8203;Nitwel](https://github.com/Nitwel))
  - Added AI chat sidebar ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
  - Added support for float intervals and min/max warnings for number inputs ([#&#8203;26190](directus/directus#26190) by [@&#8203;gaetansenn](https://github.com/gaetansenn))
  - Made both sidebars resizable ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
  - Added header interface ([#&#8203;26302](directus/directus#26302) by [@&#8203;AlexGaillard](https://github.com/AlexGaillard))
- **[@&#8203;directus/api](https://github.com/directus/api)**
  - Added support for downloading multiple files and entire folder trees ([#&#8203;26006](directus/directus#26006) by [@&#8203;Nitwel](https://github.com/Nitwel))
  - Added AI chat sidebar ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
- **[@&#8203;directus/types](https://github.com/directus/types)**
  - Added support for downloading multiple files and entire folder trees ([#&#8203;26006](directus/directus#26006) by [@&#8203;Nitwel](https://github.com/Nitwel))
  - Added AI chat sidebar ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
- **[@&#8203;directus/utils](https://github.com/directus/utils)**
  - Added support for downloading multiple files and entire folder trees ([#&#8203;26006](directus/directus#26006) by [@&#8203;Nitwel](https://github.com/Nitwel))
  - Moved `fetchRolesTree`,`fetchGlobalAccess`, `fetchGlobalAccessForUser` and `fetchGlobalAccessForRoles` to the public utility package ([#&#8203;26248](directus/directus#26248) by [@&#8203;ComfortablyCoding](https://github.com/ComfortablyCoding))
- **[@&#8203;directus/sdk](https://github.com/directus/sdk)**
  - Added support for downloading multiple files and entire folder trees ([#&#8203;26006](directus/directus#26006) by [@&#8203;Nitwel](https://github.com/Nitwel))
- **[@&#8203;directus/system-data](https://github.com/directus/system-data)**
  - Added AI chat sidebar ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
- **[@&#8203;directus/errors](https://github.com/directus/errors)**
  - Added AI chat sidebar ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
- **[@&#8203;directus/themes](https://github.com/directus/themes)**
  - Added AI chat sidebar ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))

##### 🐛 Bug Fixes & Optimizations

- **[@&#8203;directus/app](https://github.com/directus/app)**
  - Fixed an issue where input focus ring disappears on hover ([#&#8203;26315](directus/directus#26315) by [@&#8203;formfcw](https://github.com/formfcw))
  - Fixed display template not appearing for relations inside translations on new items ([#&#8203;26219](directus/directus#26219) by [@&#8203;gaetansenn](https://github.com/gaetansenn))
  - Ensured the created revision uses the correct label ([#&#8203;26289](directus/directus#26289) by [@&#8203;vizzv](https://github.com/vizzv))
  - Added reactive primaryKey prop to useFlows composable ([#&#8203;26287](directus/directus#26287) by [@&#8203;AlexGaillard](https://github.com/AlexGaillard))
- **[@&#8203;directus/api](https://github.com/directus/api)**
  - Added redirect validation ([#&#8203;26346](directus/directus#26346) by [@&#8203;br41nslug](https://github.com/br41nslug))
  - Moved `fetchRolesTree`,`fetchGlobalAccess`, `fetchGlobalAccessForUser` and `fetchGlobalAccessForRoles` to the public utility package ([#&#8203;26248](directus/directus#26248) by [@&#8203;ComfortablyCoding](https://github.com/ComfortablyCoding))
  - Updated synchronization of remotely stored extensions ([#&#8203;26192](directus/directus#26192) by [@&#8203;br41nslug](https://github.com/br41nslug))
  - Fixed missing accountability for `files.upload` when TUS is enabled ([#&#8203;26247](directus/directus#26247) by [@&#8203;br41nslug](https://github.com/br41nslug))
- **[@&#8203;directus/types](https://github.com/directus/types)**
  - Moved `fetchRolesTree`,`fetchGlobalAccess`, `fetchGlobalAccessForUser` and `fetchGlobalAccessForRoles` to the public utility package ([#&#8203;26248](directus/directus#26248) by [@&#8203;ComfortablyCoding](https://github.com/ComfortablyCoding))
  - Updated synchronization of remotely stored extensions ([#&#8203;26192](directus/directus#26192) by [@&#8203;br41nslug](https://github.com/br41nslug))
- **[@&#8203;directus/storage-driver-cloudinary](https://github.com/directus/storage-driver-cloudinary)**
  - Updated synchronization of remotely stored extensions ([#&#8203;26192](directus/directus#26192) by [@&#8203;br41nslug](https://github.com/br41nslug))
- **[@&#8203;directus/storage-driver-supabase](https://github.com/directus/storage-driver-supabase)**
  - Updated synchronization of remotely stored extensions ([#&#8203;26192](directus/directus#26192) by [@&#8203;br41nslug](https://github.com/br41nslug))
- **[@&#8203;directus/extensions-sdk](https://github.com/directus/extensions-sdk)**
  - Updated `esbuild` dependency from 0.25.12 to 0.26.0 ([#&#8203;26215](directus/directus#26215) by [@&#8203;dependabot](https://github.com/dependabot))
- **[@&#8203;directus/system-data](https://github.com/directus/system-data)**
  - Updated `esbuild` dependency from 0.25.12 to 0.26.0 ([#&#8203;26215](directus/directus#26215) by [@&#8203;dependabot](https://github.com/dependabot))
- **[@&#8203;directus/sdk](https://github.com/directus/sdk)**
  - Updated `esbuild` dependency from 0.25.12 to 0.26.0 ([#&#8203;26215](directus/directus#26215) by [@&#8203;dependabot](https://github.com/dependabot))
- **[@&#8203;directus/themes](https://github.com/directus/themes)**
  - Made both sidebars resizable ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))
- **[@&#8203;directus/utils](https://github.com/directus/utils)**
  - Preserved Error when passed to run-script operation ([#&#8203;26234](directus/directus#26234) by [@&#8203;gaetansenn](https://github.com/gaetansenn))
- **[@&#8203;directus/composables](https://github.com/directus/composables)**
  - Set default sidebar shadow to false ([#&#8203;26259](directus/directus#26259) by [@&#8203;rijkvanzanten](https://github.com/rijkvanzanten))

##### 📦 Published Versions

- `@directus/app@14.4.0`
- `@directus/api@32.2.0`
- `@directus/composables@11.2.8`
- `create-directus-extension@11.0.24`
- `@directus/env@5.3.3`
- `@directus/errors@2.1.0`
- `@directus/extensions@3.0.15`
- `@directus/extensions-registry@3.0.15`
- `@directus/extensions-sdk@17.0.4`
- `@directus/memory@3.0.13`
- `@directus/pressure@3.0.13`
- `@directus/schema-builder@0.0.10`
- `@directus/storage-driver-azure@12.0.13`
- `@directus/storage-driver-cloudinary@12.0.13`
- `@directus/storage-driver-gcs@12.0.13`
- `@directus/storage-driver-s3@&#8203;12.0.13`
- `@directus/storage-driver-supabase@3.0.13`
- `@directus/stores@2.0.0`
- `@directus/system-data@3.5.0`
- `@directus/themes@1.2.0`
- `@directus/types@13.5.0`
- `@directus/utils@13.1.0`
- `@directus/validation@2.0.13`
- `@directus/sdk@20.3.0`

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0Mi4zOS4xIiwidXBkYXRlZEluVmVyIjoiNDIuMzkuMSIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiaW1hZ2UiXX0=-->

Reviewed-on: https://gitea.alexlebens.dev/alexlebens/infrastructure/pulls/2365
Co-authored-by: Renovate Bot <renovate-bot@alexlebens.net>
Co-committed-by: Renovate Bot <renovate-bot@alexlebens.net>
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 24, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unable to set a step interval of 0.x (0,x) in a float field.

4 participants