`Input.Text` not displaying when used with `isRequired: true`
petru-guider opened this issue · 1 comments
Github issues should be used for bugs and feature requests. Use Stack Overflow for general "how-to" questions.
Version
Microsoft-BotFramework/3.1
botframework-connector/4.22.1
core-http/3.0.4
Node/v18.19.0
OS/(arm64-Darwin-23.4.0)
Describe the bug
Adaptive Card Input.Text
not displaying when used with isRequired: true
.
To Reproduce
Steps to reproduce the behavior:
- Make a
GET
request to/api/notify
endpoint with a route handler sends a proactive message using following card
await context.sendActivity({
attachments: [
CardFactory.adaptiveCard({
body: [
{
type: 'TextBlock',
text: 'Text area',
},
{
type: 'Input.Text',
id: 'id',
placeholder: 'Placeholder text',
maxLength: 500,
isMultiline: true,
},
],
actions: [
{
type: 'Action.Submit',
title: 'Submit',
},
],
}),
],
});
- Check bot framework
- Card is displayed properly
- Add
isRequired
afterisMultiline
- Make another
GET
request to/api/notify
- Card is not displayed properly
Expected behavior
Input.Text
works properly with isRequired: true
.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
I'm also using Input.ChoiceSet
and it works fine with isRequired: true
.
Tracking Status
Dotnet SDK TODO
- PR
- Merged
Javascript SDK TODO
- PR
- Merged
Python SDK TODO
- PR
- Merged
Java SDK TODO
- PR
- Merged
Samples TODO
- PR
- Merged
Docs TODO
- PR
- Merged
Tools TODO
- PR
- Merged
@petru-guider - Thank you for your patience. It seems that when using the isRequired
property, it is necessary to include the label
and errorMessage
properties, as well. I did a cursory search and didn't see this stated anywhere obvious in their docs. I only discovered the requirement when looking at the dev console for the browser where a couple warnings where displayed. Curiously, the Adaptive Cards Designer didn't produce any errors or warnings when I ran the card there. Anyhow, once I included the additional fields, the card rendered without issue.
Closing a resolved.