Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] allow disabled dates in datepicker #8872

Open
shirleyqin-msft opened this issue Apr 12, 2024 · 0 comments
Open

[Feature Request] allow disabled dates in datepicker #8872

shirleyqin-msft opened this issue Apr 12, 2024 · 0 comments
Labels

Comments

@shirleyqin-msft
Copy link

Problem Statement

It is a pretty common use case for bots to use Input.Date for appointment booking. We would want users to pick one from all the available dates. Currently adaptive card Input.Date only supports min and max dates. It would be very nice if it also supports restricted dates like fluent UI https://react.fluentui.dev/?path=/docs/compat-components-calendar--default so we can disable unavailable dates.

Proposed solution

I see that the original Input.Date uses html datepicker which doesn't have a restricted dates options but AC can support fluent UI and fluent UI datepicker supports restricted dates. I propose to add restricted dates in the schema and add it as a parameter for Input.Date component.

Alternatives or Workarounds

I tried to write custom element like this https://learn.microsoft.com/en-us/adaptive-cards/sdk/rendering-cards/javascript/extensibility but the problem is that if I add a restrictedDates field to my inpute.Date element in the json I send from the bot, this field will be dropped because it is not in the schema

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant