Skip to content

Range input with min/max bindings is not setting its value properly #69206

@Julien-Marcou

Description

@Julien-Marcou

Which @angular/* package(s) are the source of the bug?

forms

Is this a regression?

No

Description

Considering you have the following signals you want to bind to an input[type="range"]:

protected readonly value = signal(200);
protected readonly min = signal(100);
protected readonly max = signal(300);

When using [min]="min()" & [max]="max()" to bind the min & max attributes, the value is not properly set.

<!-- not working -->
<input type="range" [value]="value()" [min]="min()" [max]="max()" step="100" />
Image

But when using min="{{ min() }} & max="{{ max() }}" everything works.

<!-- working -->
<input type="range" [value]="value()" min="{{ min() }}" max="{{ max() }}" step="100" />
Image

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw


Please provide the environment you discovered this bug in (run ng version)

Angular CLI       : 22.0.0
Angular           : 22.0.0
Node.js           : 24.16.0
Package Manager   : npm 11.16.0
Operating System  : linux x64

┌───────────────────────────┬───────────────────┬───────────────────┐
│ Package                   │ Installed Version │ Requested Version │
├───────────────────────────┼───────────────────┼───────────────────┤
│ @angular/build            │ 22.0.0            │ ^22.0.0           │
│ @angular/cli              │ 22.0.0            │ ^22.0.0           │
│ @angular/common           │ 22.0.0            │ ^22.0.0           │
│ @angular/compiler         │ 22.0.0            │ ^22.0.0           │
│ @angular/compiler-cli     │ 22.0.0            │ ^22.0.0           │
│ @angular/core             │ 22.0.0            │ ^22.0.0           │
│ @angular/forms            │ 22.0.0            │ ^22.0.0           │
│ @angular/platform-browser │ 22.0.0            │ ^22.0.0           │
│ @angular/router           │ 22.0.0            │ ^22.0.0           │
│ rxjs                      │ 7.8.2             │ ~7.8.2            │
│ typescript                │ 6.0.3             │ ~6.0.3            │
└───────────────────────────┴───────────────────┴───────────────────┘

Anything else?

The weird thing is that when using input[type="number"], it's always working, no matter if I use [min]="min()" or min="{{ min() }}"

I'm not sure if this is related to #68480 or not, because this time I'm not using [formField] at all, but it seems to be a similar problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: formsgemini-triagedLabel noting that an issue has been triaged by gemini

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions