【问题标题】:AdaptiveCards HostConfig IntegrationAdaptiveCards HostConfig 集成
【发布时间】:2019-12-17 22:09:00
【问题描述】:

有谁知道如何在 Asp.Net Core 中使用 webchat CDN 集成 HostConfig 以设置 AdaptiveCard 的样式?

例如文件名是什么? 它去了哪里等等?

我的项目设置是: 带 Angular 的 Asp.Net Core

【问题讨论】:

    标签: angular asp.net-core botframework web-chat


    【解决方案1】:

    RenderWebChat 采用一个名为adaptiveCardHostConfig 的参数,您可以在其中传递您的配置。您可以在这里查看网络聊天 API 参考 https://github.com/microsoft/BotFramework-WebChat#web-chat-api-reference

    例子

    window.WebChat.renderWebChat({
            adaptiveCardHostConfig: {
                actions: {
                    actionsOrientation: 'horizontal',
                }
            },
            styleOptions: {
                rootHeight: 500,
                rootWidth: 500,
    
            },
            directLine: dl,
            userID: '@Model.UserId',
            username: 'User',
            locale: 'en-US',
        }, document.getElementById('webchat'));
    

    【讨论】:

      猜你喜欢
      • 2019-04-10
      • 2017-10-14
      • 2015-07-16
      • 2017-10-18
      • 2021-11-14
      • 2019-06-20
      • 2019-02-26
      • 2020-08-13
      • 2023-01-20
      相关资源
      最近更新 更多