Skip to content
Snippets Groups Projects
Commit fb7c7814 authored by Nikita Hovratov's avatar Nikita Hovratov Committed by Andreas Fernandez
Browse files

[FEATURE] Introduce TCA type "number"

The new type "number" is a replacement for type
"input" with "eval=int" or "eval=double2" set.

With this, the type "input" field is now always a
html "text" field and type "number" is always a
html "number" field.

With the new TCA option "format", a number type can
be defined. Values can be either "integer" (default)
or "decimal". The decimal format replaces the former
"double2" eval value.

In the future, a new option for precision might be
added, in order to dynamically define how many
decimal places should be possible.

The valueSlider has been moved from InputTextElement
to NumberElement, as it makes only sense with a type
number field. Additionally, the JS module is migrated
to a custom element.

Note: There is still the eval="num" option for type
"input" fields. This is solely for the purpose to
ensure only numeric characters are used. Therefore,
this option does not qualify anymore for the "range"
option. The "range" option is now removed altogether
for simple type "input" fields, as it now purely
handles text values.

Resolves: #97193
Releases: main
Change-Id: Ia0888699f2c518917412e700e2681d9fea727340
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/74067


Tested-by: default avatarNikita Hovratov <nikita.h@live.de>
Tested-by: default avatarcore-ci <typo3@b13.com>
Tested-by: default avatarAndreas Fernandez <a.fernandez@scripting-base.de>
Reviewed-by: default avatarNikita Hovratov <nikita.h@live.de>
Reviewed-by: default avatarAndreas Fernandez <a.fernandez@scripting-base.de>
parent 7edb5ee0
Branches
Tags
Showing
with 490 additions and 126 deletions
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment