Skype For Business PromptDialog.Choice screwing up the formatting
Bot Info
- SDK Platform: .NET
- SDK Version: 3.15.0
- Active Channels: Skype For Business
- Deployment Environment: Azure Bot Service
Issue Description
The formatting for a list is getting messed up when I use the PromptDialog.Choice with Skype For Business. I have a list of strings that I want to have the user choose an option from and I want to display a number in front of them since Skype For Business does not support buttons. I am manually inserting the numbers in front of each choice and using that as the description. The problem is the last line is has a bullet that is smaller than the rest of them using the format of "(1) Option". Also when I use the format of "1. Option" the formatting is completely messed up and all of the numbers change to 1. This only happens on the desktop version of Skype For Business. It shows up just fine on the Android app.
Code Example
List<string> displayLanguages = new List<string>();
for (int i = 0; i < languages.Count(); i++)
displayLanguages.Add($"({i + 1}) {languages.ElementAt(i).Text}");
PromptDialog.Choice(context, AfterLanguageSelectAsync, languages, "Choose your language: ", "Invalid choice.", 3, PromptStyle.Auto, displayLanguages);
Where languages is an IEnumerable of a custom class that has the ToString overridden.
Expected Behavior
All of the text to be the same size. For the format of "1. Option" to have each choice on the same line and not overwrite the numbers.
Actual Results
This is with the format of "(1) Option"
This is the format of "1. Option"
I have created an incident with the Skype for business team. I will update you when I have more information.
Is this still an issue, or has it been fixed? We do not have a SS4B tenant to est on so unfortunately I cannot check for myself.
I've since changed the way I display the options, but the last bullet is still a little smaller.
here is a workaround:
List<string> displayLanguages = new List<string>();
for (int i = 0; i < languages.Count; i++)
{
if (i == 0)
{
displayLanguages.Add($"<ol><li> {languages[i]}</li>");
}
else if (i == languages.Count - 1)
{
displayLanguages.Add($"<li> {languages[i]}</li></ol>");
}
else
{
displayLanguages.Add($"<li> {languages[i]}</li>");
}
}
PromptDialog.Choice(context, AfterLanguageSelectAsync, languages, "Choose your language: ", "Invalid choice.", 3, PromptStyle.AutoText, displayLanguages);
Hi, I am also having the same issue. Any update on this. @JasonSowers
Thank you for opening an issue against the Bot Framework SDK v3. As part of the Bot Framework v4 release, we’ve moved all v3 work to a new repo located at https://github.com/microsoft/botbuilder-v3. We will continue to support and offer maintenance updates to v3 via this new repo.
From now on, https://github.com/microsoft/botbuilder repo will be used as hub, with pointers to all the different SDK languages, tools and samples repos.
As part of this restructuring, we are closing all tickets in this repo.
For defects or feature requests, please create a new issue in the new Bot Framework v3 repo found here: https://github.com/microsoft/botbuilder-v3/issues
For Azure Bot Service Channel specific defects or feature requests (e.g. Facebook, Twilio, Teams, Slack, etc.), please create a new issue in the new Bot Framework Channel repo found here: https://github.com/microsoft/botframework-services/issues
For product behavior, how-to, or general understanding questions, please use Stackoverflow. https://stackoverflow.com/search?q=bot+framework
Thank you.
The Bot Framework Team