Skip to content

Feature request: Accept multiple range separators #1096

@jono-hayward

Description

@jono-hayward

Is your feature request related to a problem? Please describe.
In testing this component, many of my users expressed confusion at being unable to type their date range as something like "13/5/2025 to 19/5/2025". I have the datepicker configured to use the default hyphen as the rangeSeparator as I believe that's the most common usage, but I can understand wanting to use "to" as well. Unfortunately, the datepicker currently only accepts a single rangeSeparator so I have to choose one or the other.

Describe the solution you'd like
Update rangeSeparator so that it can optionally accept an array of values, much like how text-input.format can.

Describe alternatives you've considered
Have attempted using a regex object /(-|to)/ instead of a string to no avail.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions