@microsoft/teamsfx 2.3.3-beta.2024081308.0 → 2.3.3-beta.2024090406.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14,7 +14,7 @@ var axios = require('axios');
14
14
  var https = require('https');
15
15
  var path = require('path');
16
16
  var fs = require('fs');
17
- var adaptivecardsTools = require('@microsoft/adaptivecards-tools');
17
+ var ACData = require('adaptivecards-templating');
18
18
 
19
19
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
20
20
 
@@ -3906,8 +3906,11 @@ class MessageBuilder {
3906
3906
  * ```
3907
3907
  */
3908
3908
  static attachAdaptiveCard(cardTemplate, data) {
3909
+ const context = {
3910
+ $root: data,
3911
+ };
3909
3912
  return {
3910
- attachments: [botbuilder.CardFactory.adaptiveCard(adaptivecardsTools.AdaptiveCards.declare(cardTemplate).render(data))],
3913
+ attachments: [botbuilder.CardFactory.adaptiveCard(new ACData.Template(cardTemplate).expand(context))],
3911
3914
  };
3912
3915
  }
3913
3916
  /**
@@ -3918,7 +3921,7 @@ class MessageBuilder {
3918
3921
  */
3919
3922
  static attachAdaptiveCardWithoutData(card) {
3920
3923
  return {
3921
- attachments: [botbuilder.CardFactory.adaptiveCard(adaptivecardsTools.AdaptiveCards.declareWithoutData(card).render())],
3924
+ attachments: [botbuilder.CardFactory.adaptiveCard(card)],
3922
3925
  };
3923
3926
  }
3924
3927
  /**