aimpress-chatbot/node_modules/adaptivecards/dist/adaptivecards.min.js
“SamoilenkoVadym” 55445dbc86
Some checks failed
Build and deploy Node.js app to Azure Web App - ChatBot2222 / build (push) Has been cancelled
Build and deploy Node.js app to Azure Web App - ChatBot2222 / deploy (push) Has been cancelled
Deploy bot to Azure
2025-04-27 19:55:19 +01:00

9 lines
No EOL
154 KiB
JavaScript

!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.AdaptiveCards=e():t.AdaptiveCards=e()}(window,function(){return function(t){var e={};function i(n){if(e[n])return e[n].exports;var r=e[n]={i:n,l:!1,exports:{}};return t[n].call(r.exports,r,r.exports,i),r.l=!0,r.exports}return i.m=t,i.c=e,i.d=function(t,e,n){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(i.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)i.d(n,r,function(e){return t[e]}.bind(null,r));return n},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=4)}([function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){function t(){}return t.Default="default",t.Positive="positive",t.Destructive="destructive",t}();e.ActionStyle=n,function(t){t[t.Auto=0]="Auto",t[t.Stretch=1]="Stretch",t[t.Small=2]="Small",t[t.Medium=3]="Medium",t[t.Large=4]="Large"}(e.Size||(e.Size={})),function(t){t[t.Weight=0]="Weight",t[t.Pixel=1]="Pixel"}(e.SizeUnit||(e.SizeUnit={})),function(t){t[t.Small=0]="Small",t[t.Default=1]="Default",t[t.Medium=2]="Medium",t[t.Large=3]="Large",t[t.ExtraLarge=4]="ExtraLarge"}(e.TextSize||(e.TextSize={})),function(t){t[t.Lighter=0]="Lighter",t[t.Default=1]="Default",t[t.Bolder=2]="Bolder"}(e.TextWeight||(e.TextWeight={})),function(t){t[t.Default=0]="Default",t[t.Monospace=1]="Monospace"}(e.FontType||(e.FontType={})),function(t){t[t.None=0]="None",t[t.Small=1]="Small",t[t.Default=2]="Default",t[t.Medium=3]="Medium",t[t.Large=4]="Large",t[t.ExtraLarge=5]="ExtraLarge",t[t.Padding=6]="Padding"}(e.Spacing||(e.Spacing={})),function(t){t[t.Default=0]="Default",t[t.Dark=1]="Dark",t[t.Light=2]="Light",t[t.Accent=3]="Accent",t[t.Good=4]="Good",t[t.Warning=5]="Warning",t[t.Attention=6]="Attention"}(e.TextColor||(e.TextColor={})),function(t){t[t.Left=0]="Left",t[t.Center=1]="Center",t[t.Right=2]="Right"}(e.HorizontalAlignment||(e.HorizontalAlignment={})),function(t){t[t.Top=0]="Top",t[t.Center=1]="Center",t[t.Bottom=2]="Bottom"}(e.VerticalAlignment||(e.VerticalAlignment={})),function(t){t[t.Left=0]="Left",t[t.Center=1]="Center",t[t.Right=2]="Right",t[t.Stretch=3]="Stretch"}(e.ActionAlignment||(e.ActionAlignment={})),function(t){t[t.Default=0]="Default",t[t.Person=1]="Person"}(e.ImageStyle||(e.ImageStyle={})),function(t){t[t.Inline=0]="Inline",t[t.Popup=1]="Popup"}(e.ShowCardActionMode||(e.ShowCardActionMode={})),function(t){t[t.Horizontal=0]="Horizontal",t[t.Vertical=1]="Vertical"}(e.Orientation||(e.Orientation={})),function(t){t[t.Cover=0]="Cover",t[t.RepeatHorizontally=1]="RepeatHorizontally",t[t.RepeatVertically=2]="RepeatVertically",t[t.Repeat=3]="Repeat"}(e.FillMode||(e.FillMode={})),function(t){t[t.LeftOfTitle=0]="LeftOfTitle",t[t.AboveTitle=1]="AboveTitle"}(e.ActionIconPlacement||(e.ActionIconPlacement={})),function(t){t[t.Text=0]="Text",t[t.Tel=1]="Tel",t[t.Url=2]="Url",t[t.Email=3]="Email"}(e.InputTextStyle||(e.InputTextStyle={})),function(t){t[t.Optional=0]="Optional",t[t.Required=1]="Required",t[t.RequiredWithVisualCue=2]="RequiredWithVisualCue"}(e.InputValidationNecessity||(e.InputValidationNecessity={}));var r=function(){function t(){}return t.Default="default",t.Emphasis="emphasis",t.Accent="accent",t.Good="good",t.Attention="attention",t.Warning="warning",t}();e.ContainerStyle=r,function(t){t[t.Hint=0]="Hint",t[t.ActionTypeNotAllowed=1]="ActionTypeNotAllowed",t[t.CollectionCantBeEmpty=2]="CollectionCantBeEmpty",t[t.Deprecated=3]="Deprecated",t[t.ElementTypeNotAllowed=4]="ElementTypeNotAllowed",t[t.InteractivityNotAllowed=5]="InteractivityNotAllowed",t[t.InvalidPropertyValue=6]="InvalidPropertyValue",t[t.MissingCardType=7]="MissingCardType",t[t.PropertyCantBeNull=8]="PropertyCantBeNull",t[t.TooManyActions=9]="TooManyActions",t[t.UnknownActionType=10]="UnknownActionType",t[t.UnknownElementType=11]="UnknownElementType",t[t.UnsupportedCardVersion=12]="UnsupportedCardVersion",t[t.DuplicateId=13]="DuplicateId"}(e.ValidationError||(e.ValidationError={})),function(t){t[t.FullyInContainer=0]="FullyInContainer",t[t.Overflowing=1]="Overflowing",t[t.FullyOutOfContainer=2]="FullyOutOfContainer"}(e.ContainerFitStatus||(e.ContainerFitStatus={}))},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=i(0);e.ContentTypes={applicationJson:"application/json",applicationXWwwFormUrlencoded:"application/x-www-form-urlencoded"};var r=function(){function t(){this._isProcessed=!1,this._original=null,this._processed=null}return t.prototype.getReferencedInputs=function(t,e){if(!e)throw new Error("The referencedInputs parameter cannot be null.");for(var i=0,n=t;i<n.length;i++){var r=n[i];null!=new RegExp("\\{{2}("+r.id+").value\\}{2}","gi").exec(this._original)&&(e[r.id]=r)}},t.prototype.substituteInputValues=function(t,i){this._processed=this._original;for(var n,r=/\{{2}([a-z0-9_$@]+).value\}{2}/gi;null!=(n=r.exec(this._original));){for(var o=null,s=0,a=Object.keys(t);s<a.length;s++){var l=a[s];if(l.toLowerCase()==n[1].toLowerCase()){o=t[l];break}}if(o){var u="";o.value&&(u=o.value),i===e.ContentTypes.applicationJson?u=(u=JSON.stringify(u)).slice(1,-1):i===e.ContentTypes.applicationXWwwFormUrlencoded&&(u=encodeURIComponent(u)),this._processed=this._processed.replace(n[0],u)}}this._isProcessed=!0},t.prototype.getOriginal=function(){return this._original},t.prototype.get=function(){return this._isProcessed?this._processed:this._original},t.prototype.set=function(t){this._original=t,this._isProcessed=!1},t}();e.StringWithSubstitutions=r;var o=function(t,e,i,n){void 0===t&&(t=0),void 0===e&&(e=0),void 0===i&&(i=0),void 0===n&&(n=0),this.left=0,this.top=0,this.right=0,this.bottom=0,this.top=t,this.right=e,this.bottom=i,this.left=n};e.SpacingDefinition=o;var s=function(t,e,i,r){void 0===t&&(t=n.Spacing.None),void 0===e&&(e=n.Spacing.None),void 0===i&&(i=n.Spacing.None),void 0===r&&(r=n.Spacing.None),this.top=n.Spacing.None,this.right=n.Spacing.None,this.bottom=n.Spacing.None,this.left=n.Spacing.None,this.top=t,this.right=e,this.bottom=i,this.left=r};e.PaddingDefinition=s;var a=function(){function t(t,e){this.physicalSize=t,this.unit=e}return t.parse=function(e,i){void 0===i&&(i=!1);var r=new t(0,n.SizeUnit.Weight),o=/^([0-9]+)(px|\*)?$/g.exec(e),s=i?3:2;if(o&&o.length>=s)return r.physicalSize=parseInt(o[1]),3==o.length&&"px"==o[2]&&(r.unit=n.SizeUnit.Pixel),r;throw new Error("Invalid size: "+e)},t}();e.SizeAndUnit=a;
/**
* Fast UUID generator, RFC4122 version 4 compliant.
* @author Jeff Ward (jcward.com).
* @license MIT license
* @link http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript/21963136#21963136
**/
var l=function(){function t(){}return t.generate=function(){var e=4294967295*Math.random()|0,i=4294967295*Math.random()|0,n=4294967295*Math.random()|0,r=4294967295*Math.random()|0;return t.lut[255&e]+t.lut[e>>8&255]+t.lut[e>>16&255]+t.lut[e>>24&255]+"-"+t.lut[255&i]+t.lut[i>>8&255]+"-"+t.lut[i>>16&15|64]+t.lut[i>>24&255]+"-"+t.lut[63&n|128]+t.lut[n>>8&255]+"-"+t.lut[n>>16&255]+t.lut[n>>24&255]+t.lut[255&r]+t.lut[r>>8&255]+t.lut[r>>16&255]+t.lut[r>>24&255]},t.initialize=function(){for(var e=0;e<256;e++)t.lut[e]=(e<16?"0":"")+e.toString(16)},t.lut=[],t}();e.UUID=l,l.initialize()},function(t,e,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=i(0),r=i(1);function o(t){return null==t||""===t}function s(t,e,i){if(o(e))return i;for(var n in t){if(parseInt(n,10)>=0){var r=t[n];if(r&&"string"==typeof r&&r.toLowerCase()===e.toLowerCase())return parseInt(n,10)}}return i}function a(t,e,i,n){void 0===n&&(n=void 0),null==i||i===n?delete t[e]:t[e]=i}function l(t){var e=/#([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})?/gi.exec(t);if(e&&e[4]){var i=parseInt(e[1],16)/255;return"rgba("+parseInt(e[2],16)+","+parseInt(e[3],16)+","+parseInt(e[4],16)+","+i+")"}return t}function u(t,e){for(e+=1;e<t.length&&"<"==t[e];)for(;e<t.length&&">"!=t[e++];);return e}e.generateUniqueId=function(){return"__ac-"+r.UUID.generate()},e.isNullOrEmpty=o,e.appendChild=function(t,e){null!=e&&null!=e&&t.appendChild(e)},e.getStringValue=function(t,e){return void 0===e&&(e=void 0),"string"==typeof t?t.toString():e},e.getNumberValue=function(t,e){return void 0===e&&(e=void 0),"number"==typeof t?t:e},e.getBoolValue=function(t,e){if("boolean"==typeof t)return t;if("string"==typeof t)switch(t.toLowerCase()){case"true":return!0;case"false":return!1;default:return e}return e},e.getEnumValue=s,e.setProperty=a,e.setNumberProperty=function(t,e,i,n){void 0===n&&(n=void 0),null==i||i===n||isNaN(i)?delete t[e]:t[e]=i},e.setEnumProperty=function(t,e,i,n,r){void 0===r&&(r=void 0);var o=e[i],s=null==o||void 0!==t[o];n==r?s&&delete e[i]:null==n?s&&delete e[i]:e[i]=t[n]},e.setArrayProperty=function(t,e,i){var n=[];if(i)for(var r=0,o=i;r<o.length;r++){var s=o[r];n.push(s.toJSON())}0==n.length?t.hasOwnProperty(e)&&Array.isArray(t[e])&&delete t[e]:a(t,e,n)},e.parseHostConfigEnum=function(t,e,i){return"string"==typeof e?s(t,e,i):"number"==typeof e?e:i},e.renderSeparation=function(t,e,i){if(e.spacing>0||e.lineThickness>0){var r=document.createElement("div");return r.className=t.makeCssClassName("ac-"+(i==n.Orientation.Horizontal?"horizontal":"vertical")+"-separator"),i==n.Orientation.Horizontal?e.lineThickness?(r.style.paddingTop=e.spacing/2+"px",r.style.marginBottom=e.spacing/2+"px",r.style.borderBottom=e.lineThickness+"px solid "+l(e.lineColor)):r.style.height=e.spacing+"px":e.lineThickness?(r.style.paddingLeft=e.spacing/2+"px",r.style.marginRight=e.spacing/2+"px",r.style.borderRight=e.lineThickness+"px solid "+l(e.lineColor)):r.style.width=e.spacing+"px",r.style.overflow="hidden",r}return null},e.stringToCssColor=l,e.truncate=function(t,e,i){var n=function(){return e-t.scrollHeight>=-1};if(!n()){for(var r=t.innerHTML,o=function(e){t.innerHTML=r.substring(0,e)+"..."},s=function(t){for(var e=[],i=u(t,-1);i<t.length;)" "==t[i]&&e.push(i),i=u(t,i);return e}(r),a=0,l=s.length,p=0;a<l;){var c=Math.floor((a+l)/2);o(s[c]),n()?(p=s[c],a=c+1):l=c}if(o(p),i&&e-t.scrollHeight>=i-1){for(var h=u(r,p);h<r.length&&(o(h),n());)p=h,h=u(r,h);o(p)}}},e.getFitStatus=function(t,e){var i=t.offsetTop;return i+t.clientHeight<=e?n.ContainerFitStatus.FullyInContainer:i<e?n.ContainerFitStatus.Overflowing:n.ContainerFitStatus.FullyOutOfContainer}},function(t,e,i){"use strict";var n,r=this&&this.__extends||(n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)});Object.defineProperty(e,"__esModule",{value:!0});var o=i(0),s=i(2),a=i(1),l=function(){function t(t,e){this.default="#000000",this.subtle="#666666",t&&(this.default=t),e&&(this.subtle=e)}return t.prototype.parse=function(t){t&&(this.default=t.default||this.default,this.subtle=t.subtle||this.subtle)},t}();e.ColorDefinition=l;var u=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.highlightColors=new l("#22000000","#11000000"),e}return r(e,t),e.prototype.parse=function(e){t.prototype.parse.call(this,e),e&&this.highlightColors.parse(e.highlightColors)},e}(l);e.TextColorDefinition=u;var p=function(t){this.allowCustomStyle=!1,t&&(this.allowCustomStyle=t.allowCustomStyle||this.allowCustomStyle)};e.AdaptiveCardConfig=p;var c=function(){function t(t){this.imageSize=o.Size.Medium,this.maxImageHeight=100,t&&(this.imageSize=null!=t.imageSize?t.imageSize:this.imageSize,this.maxImageHeight=s.getNumberValue(t.maxImageHeight,100))}return t.prototype.toJSON=function(){return{imageSize:o.Size[this.imageSize],maxImageHeight:this.maxImageHeight}},t}();e.ImageSetConfig=c;var h=function(){function t(t){this.allowInlinePlayback=!0,t&&(this.defaultPoster=t.defaultPoster,this.allowInlinePlayback=t.allowInlinePlayback||this.allowInlinePlayback)}return t.prototype.toJSON=function(){return{defaultPoster:this.defaultPoster,allowInlinePlayback:this.allowInlinePlayback}},t}();e.MediaConfig=h;var d=function(){function t(t){this.size=o.TextSize.Default,this.color=o.TextColor.Default,this.isSubtle=!1,this.weight=o.TextWeight.Default,this.wrap=!0,t&&(this.size=s.parseHostConfigEnum(o.TextSize,t.size,o.TextSize.Default),this.color=s.parseHostConfigEnum(o.TextColor,t.color,o.TextColor.Default),this.isSubtle=t.isSubtle||this.isSubtle,this.weight=s.parseHostConfigEnum(o.TextWeight,t.weight,this.getDefaultWeight()),this.wrap=null!=t.wrap?t.wrap:this.wrap)}return t.prototype.getDefaultWeight=function(){return o.TextWeight.Default},t.prototype.toJSON=function(){return{size:o.TextSize[this.size],color:o.TextColor[this.color],isSubtle:this.isSubtle,weight:o.TextWeight[this.weight],wrap:this.wrap}},t}();e.FactTextDefinition=d;var f=function(t){function e(e){var i=t.call(this,e)||this;return i.maxWidth=150,i.weight=o.TextWeight.Bolder,e&&(i.maxWidth=null!=e.maxWidth?e.maxWidth:i.maxWidth,i.weight=s.parseHostConfigEnum(o.TextWeight,e.weight,o.TextWeight.Bolder)),i}return r(e,t),e.prototype.getDefaultWeight=function(){return o.TextWeight.Bolder},e}(d);e.FactTitleDefinition=f;var g=function(t){this.title=new f,this.value=new d,this.spacing=10,t&&(this.title=new f(t.title),this.value=new d(t.value),this.spacing=t.spacing&&null!=t.spacing?t.spacing&&t.spacing:this.spacing)};e.FactSetConfig=g;var y=function(){function t(t){this.actionMode=o.ShowCardActionMode.Inline,this.inlineTopMargin=16,this.style=o.ContainerStyle.Emphasis,t&&(this.actionMode=s.parseHostConfigEnum(o.ShowCardActionMode,t.actionMode,o.ShowCardActionMode.Inline),this.inlineTopMargin=null!=t.inlineTopMargin?t.inlineTopMargin:this.inlineTopMargin,this.style=t.style&&"string"==typeof t.style?t.style:o.ContainerStyle.Emphasis)}return t.prototype.toJSON=function(){return{actionMode:o.ShowCardActionMode[this.actionMode],inlineTopMargin:this.inlineTopMargin,style:this.style}},t}();e.ShowCardActionConfig=y;var m=function(){function t(t){if(this.maxActions=5,this.spacing=o.Spacing.Default,this.buttonSpacing=20,this.showCard=new y,this.preExpandSingleShowCardAction=!1,this.actionsOrientation=o.Orientation.Horizontal,this.actionAlignment=o.ActionAlignment.Left,this.iconPlacement=o.ActionIconPlacement.LeftOfTitle,this.allowTitleToWrap=!1,this.iconSize=24,t){this.maxActions=null!=t.maxActions?t.maxActions:this.maxActions,this.spacing=s.parseHostConfigEnum(o.Spacing,t.spacing&&t.spacing,o.Spacing.Default),this.buttonSpacing=null!=t.buttonSpacing?t.buttonSpacing:this.buttonSpacing,this.showCard=new y(t.showCard),this.preExpandSingleShowCardAction=s.getBoolValue(t.preExpandSingleShowCardAction,!1),this.actionsOrientation=s.parseHostConfigEnum(o.Orientation,t.actionsOrientation,o.Orientation.Horizontal),this.actionAlignment=s.parseHostConfigEnum(o.ActionAlignment,t.actionAlignment,o.ActionAlignment.Left),this.iconPlacement=s.parseHostConfigEnum(o.ActionIconPlacement,t.iconPlacement,o.ActionIconPlacement.LeftOfTitle),this.allowTitleToWrap=null!=t.allowTitleToWrap?t.allowTitleToWrap:this.allowTitleToWrap;try{var e=a.SizeAndUnit.parse(t.iconSize);e.unit==o.SizeUnit.Pixel&&(this.iconSize=e.physicalSize)}catch(t){}}}return t.prototype.toJSON=function(){return{maxActions:this.maxActions,spacing:o.Spacing[this.spacing],buttonSpacing:this.buttonSpacing,showCard:this.showCard,preExpandSingleShowCardAction:this.preExpandSingleShowCardAction,actionsOrientation:o.Orientation[this.actionsOrientation],actionAlignment:o.ActionAlignment[this.actionAlignment]}},t}();e.ActionsConfig=m;var v=function(){function t(t){this.default=new u,this.dark=new u,this.light=new u,this.accent=new u,this.good=new u,this.warning=new u,this.attention=new u,this.parse(t)}return t.prototype.parseSingleColor=function(t,e){t&&this[e].parse(t[e])},t.prototype.parse=function(t){t&&(this.parseSingleColor(t,"default"),this.parseSingleColor(t,"dark"),this.parseSingleColor(t,"light"),this.parseSingleColor(t,"accent"),this.parseSingleColor(t,"good"),this.parseSingleColor(t,"warning"),this.parseSingleColor(t,"attention"))},t}();e.ColorSetDefinition=v;var b=function(){function t(t){this.foregroundColors=new v({default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},good:{default:"#54A254",subtle:"#DD54A254"},warning:{default:"#E69500",subtle:"#DDE69500"},attention:{default:"#CC3300",subtle:"#DDCC3300"}}),this.parse(t)}return t.prototype.parse=function(t){t&&(this.backgroundColor=t.backgroundColor,this.foregroundColors.parse(t.foregroundColors),this.highlightBackgroundColor=t.highlightBackgroundColor,this.highlightForegroundColor=t.highlightForegroundColor)},Object.defineProperty(t.prototype,"isBuiltIn",{get:function(){return!1},enumerable:!0,configurable:!0}),t}();e.ContainerStyleDefinition=b;var C=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),Object.defineProperty(e.prototype,"isBuiltIn",{get:function(){return!0},enumerable:!0,configurable:!0}),e}(b),S=function(){function t(t){if(this._allStyles={},this._allStyles[o.ContainerStyle.Default]=new C,this._allStyles[o.ContainerStyle.Emphasis]=new C,this._allStyles[o.ContainerStyle.Accent]=new C,this._allStyles[o.ContainerStyle.Good]=new C,this._allStyles[o.ContainerStyle.Attention]=new C,this._allStyles[o.ContainerStyle.Warning]=new C,t){this._allStyles[o.ContainerStyle.Default].parse(t[o.ContainerStyle.Default]),this._allStyles[o.ContainerStyle.Emphasis].parse(t[o.ContainerStyle.Emphasis]),this._allStyles[o.ContainerStyle.Accent].parse(t[o.ContainerStyle.Accent]),this._allStyles[o.ContainerStyle.Good].parse(t[o.ContainerStyle.Good]),this._allStyles[o.ContainerStyle.Attention].parse(t[o.ContainerStyle.Attention]),this._allStyles[o.ContainerStyle.Warning].parse(t[o.ContainerStyle.Warning]);var e=t.customStyles;if(e&&Array.isArray(e))for(var i=0,n=e;i<n.length;i++){var r=n[i];if(r){var s=r.name;s&&"string"==typeof s&&(this._allStyles.hasOwnProperty(s)?this._allStyles[s].parse(r.style):this._allStyles[s]=new b(r.style))}}}}return t.prototype.toJSON=function(){var t=this,e=[];Object.keys(this._allStyles).forEach(function(i){t._allStyles[i].isBuiltIn||e.push({name:i,style:t._allStyles[i]})});var i={default:this.default,emphasis:this.emphasis};return e.length>0&&(i.customStyles=e),i},t.prototype.getStyleByName=function(t,e){return void 0===e&&(e=null),this._allStyles.hasOwnProperty(t)?this._allStyles[t]:e},Object.defineProperty(t.prototype,"default",{get:function(){return this._allStyles[o.ContainerStyle.Default]},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"emphasis",{get:function(){return this._allStyles[o.ContainerStyle.Emphasis]},enumerable:!0,configurable:!0}),t}();e.ContainerStyleSet=S;var _=function(){function t(t,e,i){void 0===t&&(t=1),void 0===e&&(e=1),this._isValid=!0,this._major=t,this._minor=e,this._label=i}return t.parse=function(e,i){if(!e)return null;var n=new t;n._versionString=e;var r=/(\d+).(\d+)/gi.exec(e);return null!=r&&3==r.length?(n._major=parseInt(r[1]),n._minor=parseInt(r[2])):n._isValid=!1,!n._isValid&&i&&i.push({error:o.ValidationError.InvalidPropertyValue,message:"Invalid version string: "+n._versionString}),n},t.prototype.toString=function(){return this._isValid?this._major+"."+this._minor:this._versionString},t.prototype.compareTo=function(t){if(!this.isValid||!t.isValid)throw new Error("Cannot compare invalid version.");return this.major>t.major?1:this.major<t.major?-1:this.minor>t.minor?1:this.minor<t.minor?-1:0},Object.defineProperty(t.prototype,"label",{get:function(){return this._label?this._label:this.toString()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"major",{get:function(){return this._major},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"minor",{get:function(){return this._minor},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isValid",{get:function(){return this._isValid},enumerable:!0,configurable:!0}),t}();e.Version=_;var E=function(){function t(){this.capabilities=null}return t.prototype.setCapability=function(t,e){this.capabilities||(this.capabilities={}),this.capabilities[t]=e},t.prototype.parse=function(t,e){if(t)for(var i in t){var n=t[i];if("string"==typeof n)if("*"==n)this.setCapability(i,"*");else{var r=_.parse(n,e);r.isValid&&this.setCapability(i,r)}}},t.prototype.hasCapability=function(t,e){return!(!this.capabilities||!this.capabilities.hasOwnProperty(t))&&("*"==e||"*"==this.capabilities[t]||e.compareTo(this.capabilities[t])<=0)},t.prototype.areAllMet=function(t){if(this.capabilities)for(var e in this.capabilities)if(!t.hasCapability(e,this.capabilities[e]))return!1;return!0},t}();e.HostCapabilities=E;var x=function(){function t(t){this.fontFamily="Segoe UI,Segoe,Segoe WP,Helvetica Neue,Helvetica,sans-serif",this.fontSizes={small:12,default:14,medium:17,large:21,extraLarge:26},this.fontWeights={lighter:200,default:400,bolder:600},t&&(this.fontFamily=t)}return t.prototype.parse=function(t){this.fontFamily=t.fontFamily||this.fontFamily,this.fontSizes={small:t.fontSizes&&t.fontSizes.small||this.fontSizes.small,default:t.fontSizes&&t.fontSizes.default||this.fontSizes.default,medium:t.fontSizes&&t.fontSizes.medium||this.fontSizes.medium,large:t.fontSizes&&t.fontSizes.large||this.fontSizes.large,extraLarge:t.fontSizes&&t.fontSizes.extraLarge||this.fontSizes.extraLarge},this.fontWeights={lighter:t.fontWeights&&t.fontWeights.lighter||this.fontWeights.lighter,default:t.fontWeights&&t.fontWeights.default||this.fontWeights.default,bolder:t.fontWeights&&t.fontWeights.bolder||this.fontWeights.bolder}},t.monospace=new t("'Courier New', Courier, monospace"),t}();e.FontTypeDefinition=x;var A=function(){function t(t){this.default=new x,this.monospace=new x("'Courier New', Courier, monospace"),t&&(this.default.parse(t.default),this.monospace.parse(t.monospace))}return t.prototype.getStyleDefinition=function(t){switch(t){case o.FontType.Monospace:return this.monospace;case o.FontType.Default:default:return this.default}},t}();e.FontTypeSet=A;var w=function(){function t(t){this.hostCapabilities=new E,this.choiceSetInputValueSeparator=",",this.supportsInteractivity=!0,this.fontTypes=null,this.spacing={small:3,default:8,medium:20,large:30,extraLarge:40,padding:15},this.separator={lineThickness:1,lineColor:"#EEEEEE"},this.imageSizes={small:40,medium:80,large:160},this.containerStyles=new S,this.actions=new m,this.adaptiveCard=new p,this.imageSet=new c,this.media=new h,this.factSet=new g,this.cssClassNamePrefix=null,this.alwaysAllowBleed=!1,t&&(("string"==typeof t||t instanceof String)&&(t=JSON.parse(t)),this.choiceSetInputValueSeparator=t&&"string"==typeof t.choiceSetInputValueSeparator?t.choiceSetInputValueSeparator:this.choiceSetInputValueSeparator,this.supportsInteractivity=t&&"boolean"==typeof t.supportsInteractivity?t.supportsInteractivity:this.supportsInteractivity,this._legacyFontType=new x,this._legacyFontType.parse(t),t.fontTypes&&(this.fontTypes=new A(t.fontTypes)),t.lineHeights&&(this.lineHeights={small:t.lineHeights.small,default:t.lineHeights.default,medium:t.lineHeights.medium,large:t.lineHeights.large,extraLarge:t.lineHeights.extraLarge}),this.imageSizes={small:t.imageSizes&&t.imageSizes.small||this.imageSizes.small,medium:t.imageSizes&&t.imageSizes.medium||this.imageSizes.medium,large:t.imageSizes&&t.imageSizes.large||this.imageSizes.large},this.containerStyles=new S(t.containerStyles),this.spacing={small:t.spacing&&t.spacing.small||this.spacing.small,default:t.spacing&&t.spacing.default||this.spacing.default,medium:t.spacing&&t.spacing.medium||this.spacing.medium,large:t.spacing&&t.spacing.large||this.spacing.large,extraLarge:t.spacing&&t.spacing.extraLarge||this.spacing.extraLarge,padding:t.spacing&&t.spacing.padding||this.spacing.padding},this.separator={lineThickness:t.separator&&t.separator.lineThickness||this.separator.lineThickness,lineColor:t.separator&&t.separator.lineColor||this.separator.lineColor},this.actions=new m(t.actions||this.actions),this.adaptiveCard=new p(t.adaptiveCard||this.adaptiveCard),this.imageSet=new c(t.imageSet),this.factSet=new g(t.factSet))}return t.prototype.getFontTypeDefinition=function(t){return this.fontTypes?this.fontTypes.getStyleDefinition(t):t==o.FontType.Monospace?x.monospace:this._legacyFontType},t.prototype.getEffectiveSpacing=function(t){switch(t){case o.Spacing.Small:return this.spacing.small;case o.Spacing.Default:return this.spacing.default;case o.Spacing.Medium:return this.spacing.medium;case o.Spacing.Large:return this.spacing.large;case o.Spacing.ExtraLarge:return this.spacing.extraLarge;case o.Spacing.Padding:return this.spacing.padding;default:return 0}},t.prototype.paddingDefinitionToSpacingDefinition=function(t){return new a.SpacingDefinition(this.getEffectiveSpacing(t.top),this.getEffectiveSpacing(t.right),this.getEffectiveSpacing(t.bottom),this.getEffectiveSpacing(t.left))},t.prototype.makeCssClassNames=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var i=[],n=0,r=t;n<r.length;n++){var o=r[n];i.push((this.cssClassNamePrefix?this.cssClassNamePrefix+"-":"")+o)}return i},t.prototype.makeCssClassName=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var i=this.makeCssClassNames.apply(this,t).join(" ");return i||""},Object.defineProperty(t.prototype,"fontFamily",{get:function(){return this._legacyFontType.fontFamily},set:function(t){this._legacyFontType.fontFamily=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"fontSizes",{get:function(){return this._legacyFontType.fontSizes},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"fontWeights",{get:function(){return this._legacyFontType.fontWeights},enumerable:!0,configurable:!0}),t}();e.HostConfig=w},function(t,e,i){"use strict";function n(t){for(var i in t)e.hasOwnProperty(i)||(e[i]=t[i])}Object.defineProperty(e,"__esModule",{value:!0}),n(i(5)),n(i(0)),n(i(3)),n(i(1)),n(i(2))},function(t,e,i){"use strict";var n,r=this&&this.__extends||(n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)});Object.defineProperty(e,"__esModule",{value:!0});var o,s=i(0),a=i(1),l=i(2),u=i(3),p=i(6);function c(t,e){t&&t.setCollection(e)}function h(t,e){if(e)for(var i=0;i<e.length;i++)if(t.getJsonTypeName()===e[i])return!1;return!0}function d(t,e,i,n,r,s,a){var u=null;if(e&&"object"==typeof e){var p=!1,c=l.getStringValue(e.type);if(i&&i.indexOf(c)>=0)lt(s(c,o.ForbiddenType),a);else if((u=r(c))?(u.setParent(t),u.parse(e,a),p=u.shouldFallback()&&n):(p=n,lt(s(c,o.UnknownType),a)),p){var h=e.fallback;h||t.setShouldFallback(!0),"string"==typeof h&&"drop"===h.toLowerCase()?u=null:"object"==typeof h&&(u=d(t,h,i,!0,r,s,a))}}return u}function f(t,e,i,n,r){return d(t,e,i,n,function(t){return dt.actionTypeRegistry.createInstance(t)},function(t,e){return e==o.UnknownType?{error:s.ValidationError.UnknownActionType,message:"Unknown action type: "+t+". Fallback will be used if present."}:{error:s.ValidationError.ActionTypeNotAllowed,message:"Action type "+t+" is not allowed in this context."}},r)}function g(t,e,i,n){return d(t,e,[],i,function(t){return dt.elementTypeRegistry.createInstance(t)},function(t,e){return e==o.UnknownType?{error:s.ValidationError.UnknownElementType,message:"Unknown element type: "+t+". Fallback will be used if present."}:{error:s.ValidationError.ElementTypeNotAllowed,message:"Element type "+t+" is not allowed in this context."}},n)}!function(t){t[t.UnknownType=0]="UnknownType",t[t.ForbiddenType=1]="ForbiddenType"}(o||(o={})),e.createActionInstance=f,e.createElementInstance=g;var y=function(){function t(){this._rawProperties={}}return t.prototype.parse=function(t,e){this._rawProperties=dt.enableFullJsonRoundTrip?t:{}},t.prototype.toJSON=function(){return dt.enableFullJsonRoundTrip&&this._rawProperties&&"object"==typeof this._rawProperties?this._rawProperties:{}},t.prototype.setCustomProperty=function(t,e){"string"==typeof e&&l.isNullOrEmpty(e)||null==e?delete this._rawProperties[t]:this._rawProperties[t]=e},t.prototype.getCustomProperty=function(t){return this._rawProperties[t]},t}();e.SerializableObject=y;var m=function(t){this.cardObject=t,this.errors=[]};e.ValidationFailure=m;var v=function(){function t(){this.allIds={},this.failures=[]}return t.prototype.getFailureIndex=function(t){for(var e=0;e<this.failures.length;e++)if(this.failures[e].cardObject===t)return e;return-1},t.prototype.addFailure=function(t,e){var i,n=this.getFailureIndex(t);n<0?(i=new m(t),this.failures.push(i)):i=this.failures[n],i.errors.push(e)},t}();e.ValidationResults=v;var b=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.internalValidateProperties=function(t){l.isNullOrEmpty(this.id)||(t.allIds.hasOwnProperty(this.id)?(1==t.allIds[this.id]&&t.addFailure(this,{error:s.ValidationError.DuplicateId,message:"Duplicate Id: "+this.id}),t.allIds[this.id]+=1):t.allIds[this.id]=1)},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.id=l.getStringValue(e.id)},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"type",this.getJsonTypeName()),l.setProperty(e,"id",this.id),e},e.prototype.validateProperties=function(){var t=new v;return this.internalValidateProperties(t),t},e}(y);e.CardObject=b;var C=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._shouldFallback=!1,e._lang=void 0,e._hostConfig=null,e._parent=null,e._renderedElement=null,e._separatorElement=null,e._isVisible=!0,e._truncatedDueToOverflow=!1,e._defaultRenderedElementDisplayMode=null,e._padding=null,e.requires=new u.HostCapabilities,e.horizontalAlignment=null,e.spacing=s.Spacing.Default,e.separator=!1,e.customCssSelector=null,e.height="auto",e.minPixelHeight=null,e}return r(e,t),e.prototype.internalRenderSeparator=function(){var t=l.renderSeparation(this.hostConfig,{spacing:this.hostConfig.getEffectiveSpacing(this.spacing),lineThickness:this.separator?this.hostConfig.separator.lineThickness:null,lineColor:this.separator?this.hostConfig.separator.lineColor:null},this.separatorOrientation);if(dt.alwaysBleedSeparators&&t&&this.separatorOrientation==s.Orientation.Horizontal){var e=this.getParentContainer();if(e&&e.getEffectivePadding()){var i=this.hostConfig.paddingDefinitionToSpacingDefinition(e.getEffectivePadding());t.style.marginLeft="-"+i.left+"px",t.style.marginRight="-"+i.right+"px"}}return t},e.prototype.updateRenderedElementVisibility=function(){var t=this.isDesignMode()||this.isVisible?this._defaultRenderedElementDisplayMode:"none";this._renderedElement&&(this._renderedElement.style.display=t),this._separatorElement&&(this.parent&&this.parent.isFirstElement(this)?this._separatorElement.style.display="none":this._separatorElement.style.display=t)},e.prototype.hideElementDueToOverflow=function(){this._renderedElement&&this.isVisible&&(this._renderedElement.style.visibility="hidden",this.isVisible=!1,at(this,!1))},e.prototype.showElementHiddenDueToOverflow=function(){this._renderedElement&&!this.isVisible&&(this._renderedElement.style.visibility=null,this.isVisible=!0,at(this,!1))},e.prototype.handleOverflow=function(t){if(this.isVisible||this.isHiddenDueToOverflow()){var e=this.truncateOverflow(t);this._truncatedDueToOverflow=e||this._truncatedDueToOverflow,e?e&&!this.isVisible&&this.showElementHiddenDueToOverflow():this.hideElementDueToOverflow()}},e.prototype.resetOverflow=function(){var t=!1;return this._truncatedDueToOverflow&&(this.undoOverflowTruncation(),this._truncatedDueToOverflow=!1,t=!0),this.isHiddenDueToOverflow&&this.showElementHiddenDueToOverflow(),t},e.prototype.createPlaceholderElement=function(){var t=document.createElement("div");return t.style.border="1px dashed #DDDDDD",t.style.padding="4px",t.style.minHeight="32px",t.style.fontSize="10px",t.innerText="Empty "+this.getJsonTypeName(),t},e.prototype.adjustRenderedElementSize=function(t){"auto"===this.height?t.style.flex="0 0 auto":t.style.flex="1 1 auto",this.minPixelHeight&&(t.style.minHeight=this.minPixelHeight+"px")},e.prototype.overrideInternalRender=function(){return this.internalRender()},e.prototype.applyPadding=function(){if(this.separatorElement)if(dt.alwaysBleedSeparators&&this.separatorOrientation==s.Orientation.Horizontal&&!this.isBleeding()){var t=new a.PaddingDefinition;this.getImmediateSurroundingPadding(t);var e=this.hostConfig.paddingDefinitionToSpacingDefinition(t);this.separatorElement.style.marginLeft="-"+e.left+"px",this.separatorElement.style.marginRight="-"+e.right+"px"}else this.separatorElement.style.marginRight="0",this.separatorElement.style.marginLeft="0"},e.prototype.truncateOverflow=function(t){return!1},e.prototype.undoOverflowTruncation=function(){},e.prototype.getDefaultPadding=function(){return new a.PaddingDefinition},e.prototype.getHasBackground=function(){return!1},e.prototype.getPadding=function(){return this._padding},e.prototype.setPadding=function(t){this._padding=t},Object.defineProperty(e.prototype,"supportsMinHeight",{get:function(){return!1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"useDefaultSizing",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"allowCustomPadding",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"separatorOrientation",{get:function(){return s.Orientation.Horizontal},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"defaultStyle",{get:function(){return s.ContainerStyle.Default},enumerable:!0,configurable:!0}),e.prototype.asString=function(){return""},e.prototype.isBleeding=function(){return!1},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"isVisible",this.isVisible,!0),null!==this.horizontalAlignment&&l.setEnumProperty(s.HorizontalAlignment,e,"horizontalAlignment",this.horizontalAlignment),l.setEnumProperty(s.Spacing,e,"spacing",this.spacing,s.Spacing.Default),l.setProperty(e,"separator",this.separator,!1),l.setProperty(e,"height",this.height,"auto"),this.supportsMinHeight&&l.setProperty(e,"minHeight","number"!=typeof this.minPixelHeight||isNaN(this.minPixelHeight)?void 0:this.minPixelHeight+"px"),e},e.prototype.setParent=function(t){this._parent=t},e.prototype.getEffectiveStyle=function(){return this.parent?this.parent.getEffectiveStyle():this.defaultStyle},e.prototype.getForbiddenElementTypes=function(){return null},e.prototype.getForbiddenActionTypes=function(){return null},e.prototype.getImmediateSurroundingPadding=function(t,e,i,n,r){if(void 0===e&&(e=!0),void 0===i&&(i=!0),void 0===n&&(n=!0),void 0===r&&(r=!0),this.parent){var o=e&&this.parent.isTopElement(this),a=i&&this.parent.isRightMostElement(this),l=n&&this.parent.isBottomElement(this),u=r&&this.parent.isLeftMostElement(this),p=this.parent.getEffectivePadding();p&&(o&&p.top!=s.Spacing.None&&(t.top=p.top,o=!1),a&&p.right!=s.Spacing.None&&(t.right=p.right,a=!1),l&&p.bottom!=s.Spacing.None&&(t.bottom=p.bottom,l=!1),u&&p.left!=s.Spacing.None&&(t.left=p.left,u=!1)),(o||a||l||u)&&this.parent.getImmediateSurroundingPadding(t,o,a,l,u)}},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),function(t,e,i){var n=t.getRootElement(),r=n&&n.onParseElement?n.onParseElement:dt.onParseElement;null!=r&&r(t,e,i)}(this,e,i),this.requires.parse(e.requires,i),this.isVisible=l.getBoolValue(e.isVisible,this.isVisible),this.horizontalAlignment=l.getEnumValue(s.HorizontalAlignment,e.horizontalAlignment,this.horizontalAlignment),this.spacing=l.getEnumValue(s.Spacing,e.spacing,s.Spacing.Default),this.separator=l.getBoolValue(e.separator,this.separator);var n=e.separation;void 0!==n&&("none"===n?(this.spacing=s.Spacing.None,this.separator=!1):"strong"===n?(this.spacing=s.Spacing.Large,this.separator=!0):"default"===n&&(this.spacing=s.Spacing.Default,this.separator=!1),lt({error:s.ValidationError.Deprecated,message:'The "separation" property is deprecated and will be removed. Use the "spacing" and "separator" properties instead.'},i));var r=e.height;if("auto"!==r&&"stretch"!==r||(this.height=r),this.supportsMinHeight){var o=e.minHeight;if(o&&"string"==typeof o){var u=!1;try{var p=a.SizeAndUnit.parse(o,!0);p.unit==s.SizeUnit.Pixel&&(this.minPixelHeight=p.physicalSize,u=!0)}catch(t){}u||lt({error:s.ValidationError.InvalidPropertyValue,message:'Invalid "minHeight" value: '+o},i)}}else this.minPixelHeight=null},e.prototype.getActionCount=function(){return 0},e.prototype.getActionAt=function(t){throw new Error("Index out of range.")},e.prototype.remove=function(){return!!(this.parent&&this.parent instanceof P)&&this.parent.removeItem(this)},e.prototype.render=function(){return this._renderedElement=this.overrideInternalRender(),this._separatorElement=this.internalRenderSeparator(),this._renderedElement?(this.customCssSelector&&this._renderedElement.classList.add(this.customCssSelector),this._renderedElement.style.boxSizing="border-box",this._defaultRenderedElementDisplayMode=this._renderedElement.style.display,this.adjustRenderedElementSize(this._renderedElement),this.updateLayout(!1)):this.isDesignMode()&&(this._renderedElement=this.createPlaceholderElement()),this._renderedElement},e.prototype.updateLayout=function(t){void 0===t&&(t=!0),this.updateRenderedElementVisibility(),this.applyPadding()},e.prototype.indexOf=function(t){return-1},e.prototype.isDesignMode=function(){var t=this.getRootElement();return t instanceof dt&&t.designMode},e.prototype.isRendered=function(){return this._renderedElement&&this._renderedElement.offsetHeight>0},e.prototype.isFirstElement=function(t){return!0},e.prototype.isLastElement=function(t){return!0},e.prototype.isAtTheVeryLeft=function(){return!this.parent||this.parent.isLeftMostElement(this)&&this.parent.isAtTheVeryLeft()},e.prototype.isAtTheVeryRight=function(){return!this.parent||this.parent.isRightMostElement(this)&&this.parent.isAtTheVeryRight()},e.prototype.isAtTheVeryTop=function(){return!this.parent||this.parent.isFirstElement(this)&&this.parent.isAtTheVeryTop()},e.prototype.isAtTheVeryBottom=function(){return!this.parent||this.parent.isLastElement(this)&&this.parent.isAtTheVeryBottom()},e.prototype.isBleedingAtTop=function(){return!1},e.prototype.isBleedingAtBottom=function(){return!1},e.prototype.isLeftMostElement=function(t){return!0},e.prototype.isRightMostElement=function(t){return!0},e.prototype.isTopElement=function(t){return this.isFirstElement(t)},e.prototype.isBottomElement=function(t){return this.isLastElement(t)},e.prototype.isHiddenDueToOverflow=function(){return this._renderedElement&&"hidden"==this._renderedElement.style.visibility},e.prototype.getRootElement=function(){for(var t=this;t.parent;)t=t.parent;return t},e.prototype.getParentContainer=function(){for(var t=this.parent;t;){if(t instanceof et)return t;t=t.parent}return null},e.prototype.getAllInputs=function(){return[]},e.prototype.getResourceInformation=function(){return[]},e.prototype.getElementById=function(t){return this.id===t?this:null},e.prototype.getActionById=function(t){return null},e.prototype.shouldFallback=function(){return this._shouldFallback||!this.requires.areAllMet(this.hostConfig.hostCapabilities)},e.prototype.setShouldFallback=function(t){this._shouldFallback=t},e.prototype.getEffectivePadding=function(){var t=this.getPadding();return t&&this.allowCustomPadding?t:this.getDefaultPadding()},Object.defineProperty(e.prototype,"lang",{get:function(){return this._lang?this._lang:this.parent?this.parent.lang:void 0},set:function(t){if(t&&""!=t){if(!/^[a-z]{2,3}$/gi.exec(t))throw new Error("Invalid language identifier: "+t)}this._lang=t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hostConfig",{get:function(){return this._hostConfig?this._hostConfig:this.parent?this.parent.hostConfig:gt},set:function(t){this._hostConfig=t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"index",{get:function(){return this.parent?this.parent.indexOf(this):0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isInteractive",{get:function(){return!1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isStandalone",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isInline",{get:function(){return!1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"parent",{get:function(){return this._parent},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isVisible",{get:function(){return this._isVisible},set:function(t){dt.useAdvancedCardBottomTruncation&&!t&&this.undoOverflowTruncation(),this._isVisible!=t&&(this._isVisible=t,this.updateRenderedElementVisibility(),this._renderedElement&&at(this))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hasVisibleSeparator",{get:function(){return!(!this.parent||!this.separatorElement)&&(!this.parent.isFirstElement(this)&&(this.isVisible||this.isDesignMode()))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"renderedElement",{get:function(){return this._renderedElement},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"separatorElement",{get:function(){return this._separatorElement},enumerable:!0,configurable:!0}),e}(b);e.CardElement=C;var S=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._selectAction=null,e.size=s.TextSize.Default,e.weight=s.TextWeight.Default,e.color=s.TextColor.Default,e.isSubtle=!1,e.fontType=null,e}return r(e,t),e.prototype.getEffectiveStyleDefinition=function(){return this.hostConfig.containerStyles.getStyleByName(this.getEffectiveStyle())},e.prototype.getFontSize=function(t){switch(this.size){case s.TextSize.Small:return t.fontSizes.small;case s.TextSize.Medium:return t.fontSizes.medium;case s.TextSize.Large:return t.fontSizes.large;case s.TextSize.ExtraLarge:return t.fontSizes.extraLarge;default:return t.fontSizes.default}},e.prototype.getColorDefinition=function(t,e){switch(e){case s.TextColor.Accent:return t.accent;case s.TextColor.Dark:return t.dark;case s.TextColor.Light:return t.light;case s.TextColor.Good:return t.good;case s.TextColor.Warning:return t.warning;case s.TextColor.Attention:return t.attention;default:return t.default}},e.prototype.setText=function(t){this._text=t},e.prototype.asString=function(){return this.text},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setEnumProperty(s.TextSize,e,"size",this.size,s.TextSize.Default),l.setEnumProperty(s.TextWeight,e,"weight",this.weight,s.TextWeight.Default),l.setEnumProperty(s.TextColor,e,"color",this.color,s.TextColor.Default),l.setProperty(e,"text",this.text),l.setProperty(e,"isSubtle",this.isSubtle,!1),l.setEnumProperty(s.FontType,e,"fontType",this.fontType,s.FontType.Default),e},e.prototype.applyStylesTo=function(t){var e,i=this.hostConfig.getFontTypeDefinition(this.fontType);switch(i.fontFamily&&(t.style.fontFamily=i.fontFamily),this.size){case s.TextSize.Small:e=i.fontSizes.small;break;case s.TextSize.Medium:e=i.fontSizes.medium;break;case s.TextSize.Large:e=i.fontSizes.large;break;case s.TextSize.ExtraLarge:e=i.fontSizes.extraLarge;break;default:e=i.fontSizes.default}t.style.fontSize=e+"px";var n,r=this.getColorDefinition(this.getEffectiveStyleDefinition().foregroundColors,this.effectiveColor);switch(t.style.color=l.stringToCssColor(this.isSubtle?r.subtle:r.default),this.weight){case s.TextWeight.Lighter:n=i.fontWeights.lighter;break;case s.TextWeight.Bolder:n=i.fontWeights.bolder;break;default:n=i.fontWeights.default}t.style.fontWeight=n.toString()},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.text=l.getStringValue(e.text);var n=l.getStringValue(e.size);n&&"normal"===n.toLowerCase()?(this.size=s.TextSize.Default,lt({error:s.ValidationError.Deprecated,message:'The TextBlock.size value "normal" is deprecated and will be removed. Use "default" instead.'},i)):this.size=l.getEnumValue(s.TextSize,n,this.size);var r=l.getStringValue(e.weight);r&&"normal"===r.toLowerCase()?(this.weight=s.TextWeight.Default,lt({error:s.ValidationError.Deprecated,message:'The TextBlock.weight value "normal" is deprecated and will be removed. Use "default" instead.'},i)):this.weight=l.getEnumValue(s.TextWeight,r,this.weight),this.color=l.getEnumValue(s.TextColor,e.color,this.color),this.isSubtle=l.getBoolValue(e.isSubtle,this.isSubtle),this.fontType=l.getEnumValue(s.FontType,e.fontType,this.fontType)},Object.defineProperty(e.prototype,"effectiveColor",{get:function(){return this.color?this.color:s.TextColor.Default},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this._text},set:function(t){this.setText(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"selectAction",{get:function(){return this._selectAction},set:function(t){this._selectAction=t,this._selectAction&&this._selectAction.setParent(this)},enumerable:!0,configurable:!0}),e}(C);e.BaseTextBlock=S;var _=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._processedText=null,e._treatAsPlainText=!0,e.wrap=!1,e.useMarkdown=!0,e}return r(e,t),e.prototype.restoreOriginalContent=function(){var t=this.maxLines?this._computedLineHeight*this.maxLines+"px":null;this.renderedElement.style.maxHeight=t,this.renderedElement.innerHTML=this._originalInnerHtml},e.prototype.truncateIfSupported=function(t){var e=this.renderedElement.children,i=!e.length;if(i||1==e.length&&"p"==e[0].tagName.toLowerCase()){var n=i?this.renderedElement:e[0];return l.truncate(n,t,this._computedLineHeight),!0}return!1},e.prototype.setText=function(e){t.prototype.setText.call(this,e),this._processedText=null},e.prototype.getRenderedDomElementType=function(){return"div"},e.prototype.internalRender=function(){var t=this;if(this._processedText=null,l.isNullOrEmpty(this.text))return null;var e=this.hostConfig,i=document.createElement(this.getRenderedDomElementType());if(i.classList.add(e.makeCssClassName("ac-textBlock")),i.style.overflow="hidden",this.applyStylesTo(i),this.selectAction&&(i.onclick=function(e){e.preventDefault(),e.cancelBubble=!0,t.selectAction.execute()},e.supportsInteractivity&&(i.tabIndex=0,i.setAttribute("role","button"),i.setAttribute("aria-label",this.selectAction.title),i.classList.add(e.makeCssClassName("ac-selectable")))),!this._processedText){this._treatAsPlainText=!0;var n=p.formatText(this.lang,this.text);if(this.useMarkdown){dt.allowMarkForTextHighlighting&&(n=n.replace(/<mark>/g,"===").replace(/<\/mark>/g,"/=="));var r=dt.applyMarkdown(n);if(r.didProcess&&r.outputHtml){if(this._processedText=r.outputHtml,this._treatAsPlainText=!1,dt.allowMarkForTextHighlighting){var o="",s=this.getEffectiveStyleDefinition();s.highlightBackgroundColor&&(o+="background-color: "+s.highlightBackgroundColor+";"),s.highlightForegroundColor&&(o+="color: "+s.highlightForegroundColor+";"),l.isNullOrEmpty(o)||(o='style="'+o+'"'),this._processedText=this._processedText.replace(/===/g,"<mark "+o+">").replace(/\/==/g,"</mark>")}}else this._processedText=n,this._treatAsPlainText=!0}else this._processedText=n,this._treatAsPlainText=!0}if(this._treatAsPlainText?i.innerText=this._processedText:i.innerHTML=this._processedText,i.firstElementChild instanceof HTMLElement){var a=i.firstElementChild;a.style.marginTop="0px",a.style.width="100%",this.wrap||(a.style.overflow="hidden",a.style.textOverflow="ellipsis")}i.lastElementChild instanceof HTMLElement&&(i.lastElementChild.style.marginBottom="0px");for(var u=i.getElementsByTagName("a"),c=0;c<u.length;c++){var h=u[c];h.classList.add(e.makeCssClassName("ac-anchor")),h.target="_blank",h.onclick=function(e){ot(t,e.target)&&(e.preventDefault(),e.cancelBubble=!0)}}return this.wrap?(i.style.wordWrap="break-word",this.maxLines>0&&(i.style.maxHeight=this._computedLineHeight*this.maxLines+"px",i.style.overflow="hidden")):(i.style.whiteSpace="nowrap",i.style.textOverflow="ellipsis"),(dt.useAdvancedTextBlockTruncation||dt.useAdvancedCardBottomTruncation)&&(this._originalInnerHtml=i.innerHTML),i},e.prototype.truncateOverflow=function(t){return t>=this._computedLineHeight&&this.truncateIfSupported(t)},e.prototype.undoOverflowTruncation=function(){if(this.restoreOriginalContent(),dt.useAdvancedTextBlockTruncation&&this.maxLines){var t=this._computedLineHeight*this.maxLines;this.truncateIfSupported(t)}},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"wrap",this.wrap,!1),l.setNumberProperty(e,"maxLines",this.maxLines),e},e.prototype.applyStylesTo=function(e){t.prototype.applyStylesTo.call(this,e);var i=this.getParentContainer(),n=!!i&&i.isRtl();switch(this.horizontalAlignment){case s.HorizontalAlignment.Center:e.style.textAlign="center";break;case s.HorizontalAlignment.Right:e.style.textAlign=n?"left":"right";break;default:e.style.textAlign=n?"right":"left"}var r=this.hostConfig.lineHeights;if(r)switch(this.size){case s.TextSize.Small:this._computedLineHeight=r.small;break;case s.TextSize.Medium:this._computedLineHeight=r.medium;break;case s.TextSize.Large:this._computedLineHeight=r.large;break;case s.TextSize.ExtraLarge:this._computedLineHeight=r.extraLarge;break;default:this._computedLineHeight=r.default}else this._computedLineHeight=1.33*this.getFontSize(this.hostConfig.getFontTypeDefinition(this.fontType));e.style.lineHeight=this._computedLineHeight+"px"},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.wrap=l.getBoolValue(e.wrap,this.wrap),this.maxLines=l.getNumberValue(e.maxLines)},e.prototype.getJsonTypeName=function(){return"TextBlock"},e.prototype.updateLayout=function(e){void 0===e&&(e=!1),t.prototype.updateLayout.call(this,e),dt.useAdvancedTextBlockTruncation&&this.maxLines&&this.isRendered()&&(this.restoreOriginalContent(),this.truncateIfSupported(this._computedLineHeight*this.maxLines))},e}(S);e.TextBlock=_;var E=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.getRenderedDomElementType=function(){return"label"},e.prototype.internalRender=function(){var e=t.prototype.internalRender.call(this);return l.isNullOrEmpty(this.forElementId)||(e.htmlFor=this.forElementId),e},e}(_),x=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.italic=!1,e.strikethrough=!1,e.highlight=!1,e}return r(e,t),e.prototype.internalRender=function(){var t=this;if(l.isNullOrEmpty(this.text))return null;var e=this.hostConfig,i=p.formatText(this.lang,this.text),n=document.createElement("span");if(n.classList.add(e.makeCssClassName("ac-textRun")),this.applyStylesTo(n),this.selectAction&&e.supportsInteractivity){var r=document.createElement("a");r.classList.add(e.makeCssClassName("ac-anchor")),r.href=this.selectAction.getHref(),r.target="_blank",r.onclick=function(e){e.preventDefault(),e.cancelBubble=!0,t.selectAction.execute()},r.innerText=i,n.appendChild(r)}else n.innerText=i;return n},e.prototype.applyStylesTo=function(e){if(t.prototype.applyStylesTo.call(this,e),this.italic&&(e.style.fontStyle="italic"),this.strikethrough&&(e.style.textDecoration="line-through"),this.highlight){var i=this.getColorDefinition(this.getEffectiveStyleDefinition().foregroundColors,this.effectiveColor);e.style.backgroundColor=l.stringToCssColor(this.isSubtle?i.highlightColors.subtle:i.highlightColors.default)}},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"italic",this.italic,!1),l.setProperty(e,"strikethrough",this.strikethrough,!1),l.setProperty(e,"highlight",this.highlight,!1),this.selectAction&&l.setProperty(e,"selectAction",this.selectAction.toJSON()),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.italic=l.getBoolValue(e.italic,this.italic),this.strikethrough=l.getBoolValue(e.strikethrough,this.strikethrough),this.highlight=l.getBoolValue(e.highlight,this.highlight),this.selectAction=f(this,e.selectAction,[Y.JsonTypeName],!this.isDesignMode(),i)},e.prototype.getJsonTypeName=function(){return"TextRun"},Object.defineProperty(e.prototype,"isStandalone",{get:function(){return!1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isInline",{get:function(){return!0},enumerable:!0,configurable:!0}),e}(S);e.TextRun=x;var A=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._inlines=[],e}return r(e,t),e.prototype.internalAddInline=function(t,e){if(void 0===e&&(e=!1),!t.isInline)throw new Error("RichTextBlock.addInline: the specified card element cannot be used as a RichTextBlock inline.");if(!(null==t.parent||e)&&t.parent!=this)throw new Error("RichTextBlock.addInline: the specified inline already belongs to another RichTextBlock.");t.setParent(this),this._inlines.push(t)},e.prototype.internalRender=function(){if(this._inlines.length>0){var t=document.createElement("div");t.className=this.hostConfig.makeCssClassName("ac-richTextBlock");var e=this.getParentContainer(),i=!!e&&e.isRtl();switch(this.horizontalAlignment){case s.HorizontalAlignment.Center:t.style.textAlign="center";break;case s.HorizontalAlignment.Right:t.style.textAlign=i?"left":"right";break;default:t.style.textAlign=i?"right":"left"}for(var n=0,r=this._inlines;n<r.length;n++){var o=r[n];t.appendChild(o.render())}return t}return null},e.prototype.asString=function(){for(var t="",e=0,i=this._inlines;e<i.length;e++){t+=i[e].asString()}return t},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),this._inlines=[],Array.isArray(e.inlines))for(var n=0,r=e.inlines;n<r.length;n++){var o=r[n],s=void 0;if("string"==typeof o){var a=new x;a.text=o,s=a}else s=g(this,o,!1,i);s&&this.internalAddInline(s,!0)}},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);if(this._inlines.length>0){for(var i=[],n=0,r=this._inlines;n<r.length;n++){var o=r[n];i.push(o.toJSON())}l.setProperty(e,"inlines",i)}return e},e.prototype.getJsonTypeName=function(){return"RichTextBlock"},e.prototype.getInlineCount=function(){return this._inlines.length},e.prototype.getInlineAt=function(t){if(t>=0&&t<this._inlines.length)return this._inlines[t];throw new Error("RichTextBlock.getInlineAt: Index out of range ("+t+")")},e.prototype.addInline=function(t){this.internalAddInline(t)},e.prototype.removeInline=function(t){var e=this._inlines.indexOf(t);return e>=0&&(this._inlines[e].setParent(null),this._inlines.splice(e,1),!0)},e}(C);e.RichTextBlock=A;var w=function(t){function e(e,i){void 0===e&&(e=void 0),void 0===i&&(i=void 0);var n=t.call(this)||this;return n.name=e,n.value=i,n}return r(e,t),e.prototype.parse=function(e){t.prototype.parse.call(this,e),this.name=l.getStringValue(e.title),this.value=l.getStringValue(e.value)},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"title",this.name),l.setProperty(e,"value",this.value),e},e}(y);e.Fact=w;var I=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.facts=[],e}return r(e,t),Object.defineProperty(e.prototype,"useDefaultSizing",{get:function(){return!1},enumerable:!0,configurable:!0}),e.prototype.internalRender=function(){var t=null,e=this.hostConfig;if(this.facts.length>0){(t=document.createElement("table")).style.borderWidth="0px",t.style.borderSpacing="0px",t.style.borderStyle="none",t.style.borderCollapse="collapse",t.style.display="block",t.style.overflow="hidden",t.classList.add(e.makeCssClassName("ac-factset"));for(var i=0;i<this.facts.length;i++){var n=document.createElement("tr");i>0&&(n.style.marginTop=e.factSet.spacing+"px");var r=document.createElement("td");r.style.padding="0",r.classList.add(e.makeCssClassName("ac-fact-title")),e.factSet.title.maxWidth&&(r.style.maxWidth=e.factSet.title.maxWidth+"px"),r.style.verticalAlign="top";var o=new _;o.setParent(this),o.text=l.isNullOrEmpty(this.facts[i].name)?"Title":this.facts[i].name,o.size=e.factSet.title.size,o.color=e.factSet.title.color,o.isSubtle=e.factSet.title.isSubtle,o.weight=e.factSet.title.weight,o.wrap=e.factSet.title.wrap,o.spacing=s.Spacing.None,l.appendChild(r,o.render()),l.appendChild(n,r),(r=document.createElement("td")).style.width="10px",l.appendChild(n,r),(r=document.createElement("td")).style.padding="0",r.style.verticalAlign="top",r.classList.add(e.makeCssClassName("ac-fact-value")),(o=new _).setParent(this),o.text=this.facts[i].value,o.size=e.factSet.value.size,o.color=e.factSet.value.color,o.isSubtle=e.factSet.value.isSubtle,o.weight=e.factSet.value.weight,o.wrap=e.factSet.value.wrap,o.spacing=s.Spacing.None,l.appendChild(r,o.render()),l.appendChild(n,r),l.appendChild(t,n)}}return t},e.prototype.getJsonTypeName=function(){return"FactSet"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setArrayProperty(e,"facts",this.facts),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.facts=[];var n=e.facts;if(Array.isArray(n))for(var r=0,o=n;r<o.length;r++){var s=o[r],a=new w;a.parse(s),this.facts.push(a)}},e}(C);e.FactSet=I;var T=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.style=s.ImageStyle.Default,e.size=s.Size.Auto,e.pixelWidth=null,e.pixelHeight=null,e.altText="",e}return r(e,t),e.prototype.parseDimension=function(t,e,i){if(e){if("string"==typeof e)try{var n=a.SizeAndUnit.parse(e);if(n.unit==s.SizeUnit.Pixel)return n.physicalSize}catch(t){}lt({error:s.ValidationError.InvalidPropertyValue,message:"Invalid image "+t+": "+e},i)}return 0},e.prototype.applySize=function(t){if(this.pixelWidth||this.pixelHeight)this.pixelWidth&&(t.style.width=this.pixelWidth+"px"),this.pixelHeight&&(t.style.height=this.pixelHeight+"px");else switch(this.size){case s.Size.Stretch:t.style.width="100%";break;case s.Size.Auto:t.style.maxWidth="100%";break;case s.Size.Small:t.style.width=this.hostConfig.imageSizes.small+"px";break;case s.Size.Large:t.style.width=this.hostConfig.imageSizes.large+"px";break;case s.Size.Medium:t.style.width=this.hostConfig.imageSizes.medium+"px"}},Object.defineProperty(e.prototype,"useDefaultSizing",{get:function(){return!1},enumerable:!0,configurable:!0}),e.prototype.internalRender=function(){var t=this,e=null;if(!l.isNullOrEmpty(this.url)){switch((e=document.createElement("div")).style.display="flex",e.style.alignItems="flex-start",e.onkeypress=function(e){!t.selectAction||13!=e.keyCode&&32!=e.keyCode||(e.preventDefault(),e.cancelBubble=!0,t.selectAction.execute())},e.onclick=function(e){t.selectAction&&(e.preventDefault(),e.cancelBubble=!0,t.selectAction.execute())},this.horizontalAlignment){case s.HorizontalAlignment.Center:e.style.justifyContent="center";break;case s.HorizontalAlignment.Right:e.style.justifyContent="flex-end";break;default:e.style.justifyContent="flex-start"}var i=this.hostConfig,n=document.createElement("img");n.onload=function(e){rt(t)},n.onerror=function(e){var i=t.getRootElement();if(t.renderedElement.innerHTML="",i&&i.designMode){var n=document.createElement("div");n.style.display="flex",n.style.alignItems="center",n.style.justifyContent="center",n.style.backgroundColor="#EEEEEE",n.style.color="black",n.innerText=":-(",n.style.padding="10px",t.applySize(n),t.renderedElement.appendChild(n)}rt(t)},n.style.maxHeight="100%",n.style.minWidth="0",n.classList.add(i.makeCssClassName("ac-image")),null!=this.selectAction&&i.supportsInteractivity&&(n.tabIndex=0,n.setAttribute("role","button"),n.setAttribute("aria-label",this.selectAction.title),n.classList.add(i.makeCssClassName("ac-selectable"))),this.applySize(n),this.style===s.ImageStyle.Person&&(n.style.borderRadius="50%",n.style.backgroundPosition="50% 50%",n.style.backgroundRepeat="no-repeat"),l.isNullOrEmpty(this.backgroundColor)||(n.style.backgroundColor=l.stringToCssColor(this.backgroundColor)),n.src=this.url,n.alt=this.altText,e.appendChild(n)}return e},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return this._selectAction&&l.setProperty(e,"selectAction",this._selectAction.toJSON()),l.setEnumProperty(s.ImageStyle,e,"style",this.style,s.ImageStyle.Default),l.setProperty(e,"backgroundColor",this.backgroundColor),l.setProperty(e,"url",this.url),l.setEnumProperty(s.Size,e,"size",this.size,s.Size.Auto),this.pixelWidth&&l.setProperty(e,"width",this.pixelWidth+"px"),this.pixelHeight&&l.setProperty(e,"height",this.pixelHeight+"px"),l.setProperty(e,"altText",this.altText),e},e.prototype.getJsonTypeName=function(){return"Image"},e.prototype.getActionById=function(e){var i=t.prototype.getActionById.call(this,e);return!i&&this.selectAction&&(i=this.selectAction.getActionById(e)),i},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.url=l.getStringValue(e.url),this.backgroundColor=l.getStringValue(e.backgroundColor);var n=l.getStringValue(e.style);n&&"normal"===n.toLowerCase()?(this.style=s.ImageStyle.Default,lt({error:s.ValidationError.Deprecated,message:'The Image.style value "normal" is deprecated and will be removed. Use "default" instead.'},i)):this.style=l.getEnumValue(s.ImageStyle,n,this.style),this.size=l.getEnumValue(s.Size,e.size,this.size),this.altText=l.getStringValue(e.altText),e.pixelWidth&&"number"==typeof e.pixelWidth&&(this.pixelWidth=e.pixelWidth,lt({error:s.ValidationError.Deprecated,message:"The pixelWidth property is deprecated and will be removed. Use the width property instead."},i)),e.pixelHeight&&"number"==typeof e.pixelHeight&&(this.pixelHeight=e.pixelHeight,lt({error:s.ValidationError.Deprecated,message:"The pixelHeight property is deprecated and will be removed. Use the height property instead."},i));var r=this.parseDimension("width",e.width,i);r>0&&(this.pixelWidth=r),(r=this.parseDimension("height",e.height,i))>0&&(this.pixelHeight=r),this.selectAction=f(this,e.selectAction,[Y.JsonTypeName],!this.isDesignMode(),i)},e.prototype.getResourceInformation=function(){return l.isNullOrEmpty(this.url)?[]:[{url:this.url,mimeType:"image"}]},Object.defineProperty(e.prototype,"selectAction",{get:function(){return this._selectAction},set:function(t){this._selectAction=t,this._selectAction&&this._selectAction.setParent(this)},enumerable:!0,configurable:!0}),e}(C);e.Image=T;var P=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._selectAction=null,e.allowVerticalOverflow=!1,e}return r(e,t),e.prototype.isElementAllowed=function(t,e){if(!this.hostConfig.supportsInteractivity&&t.isInteractive)return!1;if(e)for(var i=0,n=e;i<n.length;i++){var r=n[i];if(t.getJsonTypeName()===r)return!1}return!0},e.prototype.applyPadding=function(){if(t.prototype.applyPadding.call(this),this.renderedElement){var e=new a.SpacingDefinition;this.getEffectivePadding()&&(e=this.hostConfig.paddingDefinitionToSpacingDefinition(this.getEffectivePadding())),this.renderedElement.style.paddingTop=e.top+"px",this.renderedElement.style.paddingRight=e.right+"px",this.renderedElement.style.paddingBottom=e.bottom+"px",this.renderedElement.style.paddingLeft=e.left+"px",this.renderedElement.style.marginRight="0",this.renderedElement.style.marginLeft="0"}},e.prototype.getSelectAction=function(){return this._selectAction},e.prototype.setSelectAction=function(t){this._selectAction=t,this._selectAction&&this._selectAction.setParent(this)},Object.defineProperty(e.prototype,"isSelectable",{get:function(){return!1},enumerable:!0,configurable:!0}),e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.isSelectable&&(this._selectAction=f(this,e.selectAction,[Y.JsonTypeName],!this.isDesignMode(),i))},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return this._selectAction&&this.isSelectable&&l.setProperty(e,"selectAction",this._selectAction.toJSON()),e},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e);for(var i=0;i<this.getItemCount();i++){var n=this.getItemAt(i);!this.hostConfig.supportsInteractivity&&n.isInteractive&&e.addFailure(this,{error:s.ValidationError.InteractivityNotAllowed,message:"Interactivity is not allowed."}),this.isElementAllowed(n,this.getForbiddenElementTypes())||e.addFailure(this,{error:s.ValidationError.InteractivityNotAllowed,message:"Elements of type "+n.getJsonTypeName()+" are not allowed in this container."}),n.internalValidateProperties(e)}this._selectAction&&this._selectAction.internalValidateProperties(e)},e.prototype.render=function(){var e=this,i=t.prototype.render.call(this),n=this.hostConfig;return this.allowVerticalOverflow&&(i.style.overflowX="hidden",i.style.overflowY="auto"),i&&this.isSelectable&&this._selectAction&&n.supportsInteractivity&&(i.classList.add(n.makeCssClassName("ac-selectable")),i.tabIndex=0,i.setAttribute("role","button"),i.setAttribute("aria-label",this._selectAction.title),i.onclick=function(t){null!=e._selectAction&&(t.preventDefault(),t.cancelBubble=!0,e._selectAction.execute())},i.onkeypress=function(t){null==e._selectAction||13!=t.keyCode&&32!=t.keyCode||(t.preventDefault(),t.cancelBubble=!0,e._selectAction.execute())}),i},e.prototype.updateLayout=function(e){if(void 0===e&&(e=!0),t.prototype.updateLayout.call(this,e),e)for(var i=0;i<this.getItemCount();i++)this.getItemAt(i).updateLayout()},e.prototype.getAllInputs=function(){for(var t=[],e=0;e<this.getItemCount();e++)t=t.concat(this.getItemAt(e).getAllInputs());return t},e.prototype.getResourceInformation=function(){for(var t=[],e=0;e<this.getItemCount();e++)t=t.concat(this.getItemAt(e).getResourceInformation());return t},e.prototype.getElementById=function(e){var i=t.prototype.getElementById.call(this,e);if(!i)for(var n=0;n<this.getItemCount()&&!(i=this.getItemAt(n).getElementById(e));n++);return i},e}(C);e.CardElementContainer=P;var O=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._images=[],e.imageSize=s.Size.Medium,e}return r(e,t),e.prototype.internalRender=function(){var t=null;if(this._images.length>0){(t=document.createElement("div")).style.display="flex",t.style.flexWrap="wrap";for(var e=0;e<this._images.length;e++){this._images[e].size=this.imageSize;var i=this._images[e].render();i.style.display="inline-flex",i.style.margin="0px",i.style.marginRight="10px",i.style.maxHeight=this.hostConfig.imageSet.maxImageHeight+"px",l.appendChild(t,i)}}return t},e.prototype.getItemCount=function(){return this._images.length},e.prototype.getItemAt=function(t){return this._images[t]},e.prototype.getFirstVisibleRenderedItem=function(){return this._images&&this._images.length>0?this._images[0]:null},e.prototype.getLastVisibleRenderedItem=function(){return this._images&&this._images.length>0?this._images[this._images.length-1]:null},e.prototype.removeItem=function(t){if(t instanceof T){var e=this._images.indexOf(t);if(e>=0)return this._images.splice(e,1),t.setParent(null),this.updateLayout(),!0}return!1},e.prototype.getJsonTypeName=function(){return"ImageSet"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);if(l.setEnumProperty(s.Size,e,"imageSize",this.imageSize,s.Size.Medium),this._images.length>0){for(var i=[],n=0,r=this._images;n<r.length;n++){var o=r[n];i.push(o.toJSON())}l.setProperty(e,"images",i)}return e},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),this.imageSize=l.getEnumValue(s.Size,e.imageSize,s.Size.Medium),null!=e.images){var n=e.images;this._images=[];for(var r=0;r<n.length;r++){var o=new T;o.parse(n[r],i),this.addImage(o)}}},e.prototype.addImage=function(t){if(t.parent)throw new Error("This image already belongs to another ImageSet");this._images.push(t),t.setParent(this)},e.prototype.indexOf=function(t){return t instanceof T?this._images.indexOf(t):-1},e}(P);e.ImageSet=O;var k=function(t){function e(e,i){void 0===e&&(e=void 0),void 0===i&&(i=void 0);var n=t.call(this)||this;return n.url=e,n.mimeType=i,n}return r(e,t),e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.mimeType=l.getStringValue(e.mimeType),this.url=l.getStringValue(e.url)},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"mimeType",this.mimeType),l.setProperty(e,"url",this.url),e},e}(y);e.MediaSource=k;var V=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.sources=[],e}return r(e,t),e.prototype.getPosterUrl=function(){return this.poster?this.poster:this.hostConfig.media.defaultPoster},e.prototype.processSources=function(){this._selectedSources=[],this._selectedMediaType=void 0;for(var t=0,i=this.sources;t<i.length;t++){var n=i[t],r=n.mimeType?n.mimeType.split("/"):[];if(2==r.length){if(!this._selectedMediaType){var o=e.supportedMediaTypes.indexOf(r[0]);o>=0&&(this._selectedMediaType=e.supportedMediaTypes[o])}r[0]==this._selectedMediaType&&this._selectedSources.push(n)}}},e.prototype.renderPoster=function(){var t=this,i=document.createElement("div");i.className=this.hostConfig.makeCssClassName("ac-media-poster"),i.setAttribute("role","contentinfo"),i.setAttribute("aria-label",this.altText?this.altText:"Media content"),i.style.position="relative",i.style.display="flex";var n=this.getPosterUrl();if(n){var r=document.createElement("img");r.style.width="100%",r.style.height="100%",r.onerror=function(t){r.parentNode.removeChild(r),i.classList.add("empty"),i.style.minHeight="150px"},r.src=n,i.appendChild(r)}else i.classList.add("empty"),i.style.minHeight="150px";if(this.hostConfig.supportsInteractivity&&this._selectedSources.length>0){var o=document.createElement("div");o.setAttribute("role","button"),o.setAttribute("aria-label","Play media"),o.className=this.hostConfig.makeCssClassName("ac-media-playButton"),o.style.display="flex",o.style.alignItems="center",o.style.justifyContent="center",o.onclick=function(i){if(t.hostConfig.media.allowInlinePlayback){i.preventDefault(),i.cancelBubble=!0;var n=t.renderMediaPlayer();t.renderedElement.innerHTML="",t.renderedElement.appendChild(n),n.play()}else e.onPlay&&(i.preventDefault(),i.cancelBubble=!0,e.onPlay(t))};var s=document.createElement("div");s.className=this.hostConfig.makeCssClassName("ac-media-playButton-arrow"),s.style.width="12px",s.style.height="15px",s.style.borderTopWidth="7.5px",s.style.borderBottomWidth="7.5px",s.style.borderLeftWidth="12px",s.style.borderRightWidth="0",s.style.borderStyle="solid",s.style.borderTopColor="transparent",s.style.borderRightColor="transparent",s.style.borderBottomColor="transparent",s.style.transform="translate(1.2px,0px)",o.appendChild(s);var a=document.createElement("div");a.style.position="absolute",a.style.left="0",a.style.top="0",a.style.width="100%",a.style.height="100%",a.style.display="flex",a.style.justifyContent="center",a.style.alignItems="center",a.appendChild(o),i.appendChild(a)}return i},e.prototype.renderMediaPlayer=function(){var t;if("video"==this._selectedMediaType){var e=document.createElement("video"),i=this.getPosterUrl();i&&(e.poster=i),t=e}else t=document.createElement("audio");t.controls=!0,t.preload="none",t.style.width="100%";for(var n=0,r=this.sources;n<r.length;n++){var o=r[n],s=document.createElement("source");s.src=o.url,s.type=o.mimeType,t.appendChild(s)}return t},e.prototype.internalRender=function(){var t=document.createElement("div");return t.className=this.hostConfig.makeCssClassName("ac-media"),this.processSources(),t.appendChild(this.renderPoster()),t},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),this.poster=l.getStringValue(e.poster),this.altText=l.getStringValue(e.altText),this.sources=[],Array.isArray(e.sources))for(var n=0,r=e.sources;n<r.length;n++){var o=r[n],s=new k;s.parse(o,i),this.sources.push(s)}},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"poster",this.poster),l.setProperty(e,"altText",this.altText),l.setArrayProperty(e,"sources",this.sources),e},e.prototype.getJsonTypeName=function(){return"Media"},e.prototype.getResourceInformation=function(){var t=[],e=this.getPosterUrl();l.isNullOrEmpty(e)||t.push({url:e,mimeType:"image"});for(var i=0,n=this.sources;i<n.length;i++){var r=n[i];l.isNullOrEmpty(r.url)||t.push({url:r.url,mimeType:r.mimeType})}return t},Object.defineProperty(e.prototype,"selectedMediaType",{get:function(){return this._selectedMediaType},enumerable:!0,configurable:!0}),e.supportedMediaTypes=["audio","video"],e}(C);e.Media=V;var N=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.necessity=s.InputValidationNecessity.Optional,e.errorMessage=void 0,e}return r(e,t),e.prototype.parse=function(e){t.prototype.parse.call(this,e),this.necessity=l.getEnumValue(s.InputValidationNecessity,e.necessity,this.necessity),this.errorMessage=l.getStringValue(e.errorMessage)},e.prototype.toJSON=function(){if(this.necessity==s.InputValidationNecessity.Optional&&l.isNullOrEmpty(this.errorMessage))return null;var e=t.prototype.toJSON.call(this);return l.setEnumProperty(s.InputValidationNecessity,e,"necessity",this.necessity,s.InputValidationNecessity.Optional),l.setProperty(e,"errorMessage",this.errorMessage),e},e}(y);e.InputValidationOptions=N;var z=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.validation=new N,e}return r(e,t),Object.defineProperty(e.prototype,"isNullable",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"renderedInputControlElement",{get:function(){return this._renderedInputControlElement},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"inputControlContainerElement",{get:function(){return this._inputControlContainerElement},enumerable:!0,configurable:!0}),e.prototype.overrideInternalRender=function(){var t=this.hostConfig;return this._outerContainerElement=document.createElement("div"),this._outerContainerElement.style.display="flex",this._outerContainerElement.style.flexDirection="column",this._inputControlContainerElement=document.createElement("div"),this._inputControlContainerElement.className=t.makeCssClassName("ac-input-container"),this._inputControlContainerElement.style.display="flex",this._renderedInputControlElement=this.internalRender(),this._renderedInputControlElement.style.minWidth="0px",dt.useBuiltInInputValidation&&this.isNullable&&this.validation.necessity==s.InputValidationNecessity.RequiredWithVisualCue&&this._renderedInputControlElement.classList.add(t.makeCssClassName("ac-input-required")),this._inputControlContainerElement.appendChild(this._renderedInputControlElement),this._outerContainerElement.appendChild(this._inputControlContainerElement),this._outerContainerElement},e.prototype.valueChanged=function(){var t,e,i;this.resetValidationFailureCue(),this.onValueChanged&&this.onValueChanged(this),e=(t=this).getRootElement(),(i=e&&e.onInputValueChanged?e.onInputValueChanged:dt.onInputValueChanged)&&i(t)},e.prototype.resetValidationFailureCue=function(){dt.useBuiltInInputValidation&&this.renderedElement&&(this._renderedInputControlElement.classList.remove(this.hostConfig.makeCssClassName("ac-input-validation-failed")),this._errorMessageElement&&(this._outerContainerElement.removeChild(this._errorMessageElement),this._errorMessageElement=null))},e.prototype.showValidationErrorMessage=function(){this.renderedElement&&dt.useBuiltInInputValidation&&dt.displayInputValidationErrors&&!l.isNullOrEmpty(this.validation.errorMessage)&&(this._errorMessageElement=document.createElement("span"),this._errorMessageElement.className=this.hostConfig.makeCssClassName("ac-input-validation-error-message"),this._errorMessageElement.textContent=this.validation.errorMessage,this._outerContainerElement.appendChild(this._errorMessageElement))},e.prototype.parseInputValue=function(t){return t},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"title",this.title),l.setProperty(e,"value",this.renderedElement&&!l.isNullOrEmpty(this.value)?this.value:this.defaultValue),dt.useBuiltInInputValidation&&l.setProperty(e,"validation",this.validation.toJSON()),e},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e),l.isNullOrEmpty(this.id)&&e.addFailure(this,{error:s.ValidationError.PropertyCantBeNull,message:"All inputs must have a unique Id"})},e.prototype.validateValue=function(){if(dt.useBuiltInInputValidation){this.resetValidationFailureCue();var t=this.validation.necessity==s.InputValidationNecessity.Optional||!l.isNullOrEmpty(this.value);return!t&&this.renderedElement&&(this._renderedInputControlElement.classList.add(this.hostConfig.makeCssClassName("ac-input-validation-failed")),this.showValidationErrorMessage()),t}return!0},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),this.id=l.getStringValue(e.id),this.defaultValue=l.getStringValue(e.value),dt.useBuiltInInputValidation){var n=e.validation;n&&this.validation.parse(n)}},e.prototype.getAllInputs=function(){return[this]},Object.defineProperty(e.prototype,"defaultValue",{get:function(){return this._defaultValue},set:function(t){this._defaultValue=this.parseInputValue(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isInteractive",{get:function(){return!0},enumerable:!0,configurable:!0}),e}(C);e.Input=z;var D=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.isMultiline=!1,e.style=s.InputTextStyle.Text,e}return r(e,t),e.prototype.internalRender=function(){var t=this;if(this.isMultiline){var e=document.createElement("textarea");return e.className=this.hostConfig.makeCssClassName("ac-input","ac-textInput","ac-multiline"),e.style.flex="1 1 auto",e.tabIndex=0,l.isNullOrEmpty(this.placeholder)||(e.placeholder=this.placeholder,e.setAttribute("aria-label",this.placeholder)),l.isNullOrEmpty(this.defaultValue)||(e.value=this.defaultValue),this.maxLength&&this.maxLength>0&&(e.maxLength=this.maxLength),e.oninput=function(){t.valueChanged()},e.onkeypress=function(e){10==e.keyCode&&t.inlineAction&&t.inlineAction.execute()},e}var i=document.createElement("input");return i.type=s.InputTextStyle[this.style].toLowerCase(),i.className=this.hostConfig.makeCssClassName("ac-input","ac-textInput"),i.style.flex="1 1 auto",i.tabIndex=0,l.isNullOrEmpty(this.placeholder)||(i.placeholder=this.placeholder,i.setAttribute("aria-label",this.placeholder)),l.isNullOrEmpty(this.defaultValue)||(i.value=this.defaultValue),this.maxLength&&this.maxLength>0&&(i.maxLength=this.maxLength),i.oninput=function(){t.valueChanged()},i.onkeypress=function(e){13==e.keyCode&&t.inlineAction&&t.inlineAction.execute()},i},e.prototype.overrideInternalRender=function(){var e=this,i=t.prototype.overrideInternalRender.call(this);if(this.inlineAction){var n=document.createElement("button");if(n.className=this.hostConfig.makeCssClassName("ac-inlineActionButton"),n.onclick=function(t){t.preventDefault(),t.cancelBubble=!0,e.inlineAction.execute()},l.isNullOrEmpty(this.inlineAction.iconUrl))n.classList.add("textOnly"),n.textContent=l.isNullOrEmpty(this.inlineAction.title)?"Title":this.inlineAction.title;else{n.classList.add("iconOnly");var r=document.createElement("img");r.style.height="100%",r.style.display="none",r.onload=function(){r.style.removeProperty("display")},r.onerror=function(){n.removeChild(r),n.classList.remove("iconOnly"),n.classList.add("textOnly"),n.textContent=l.isNullOrEmpty(e.inlineAction.title)?"Title":e.inlineAction.title},r.src=this.inlineAction.iconUrl,n.appendChild(r),l.isNullOrEmpty(this.inlineAction.title)||(n.title=this.inlineAction.title)}n.style.marginLeft="8px",this.inputControlContainerElement.appendChild(n)}return i},e.prototype.getJsonTypeName=function(){return"Input.Text"},e.prototype.getActionById=function(e){var i=t.prototype.getActionById.call(this,e);return!i&&this.inlineAction&&(i=this.inlineAction.getActionById(e)),i},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"placeholder",this.placeholder),l.setNumberProperty(e,"maxLength",this.maxLength),l.setProperty(e,"isMultiline",this.isMultiline,!1),l.setEnumProperty(s.InputTextStyle,e,"style",this.style,s.InputTextStyle.Text),this._inlineAction&&l.setProperty(e,"inlineAction",this._inlineAction.toJSON()),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.maxLength=l.getNumberValue(e.maxLength),this.isMultiline=l.getBoolValue(e.isMultiline,this.isMultiline),this.placeholder=l.getStringValue(e.placeholder),this.style=l.getEnumValue(s.InputTextStyle,e.style,this.style),this.inlineAction=f(this,e.inlineAction,[Y.JsonTypeName],!this.isDesignMode(),i)},Object.defineProperty(e.prototype,"inlineAction",{get:function(){return this._inlineAction},set:function(t){this._inlineAction=t,this._inlineAction&&this._inlineAction.setParent(this)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"value",{get:function(){return this.renderedInputControlElement?(this.isMultiline,this.renderedInputControlElement.value):null},enumerable:!0,configurable:!0}),e}(z);e.TextInput=D;var F=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.valueOn="true",e.valueOff="false",e.wrap=!1,e}return r(e,t),e.prototype.internalRender=function(){var t=this,e=document.createElement("div");if(e.className=this.hostConfig.makeCssClassName("ac-input","ac-toggleInput"),e.style.width="100%",e.style.display="flex",e.style.alignItems="center",this._checkboxInputElement=document.createElement("input"),this._checkboxInputElement.id=l.generateUniqueId(),this._checkboxInputElement.type="checkbox",this._checkboxInputElement.style.display="inline-block",this._checkboxInputElement.style.verticalAlign="middle",this._checkboxInputElement.style.margin="0",this._checkboxInputElement.style.flex="0 0 auto",this._checkboxInputElement.setAttribute("aria-label",this.title),this._checkboxInputElement.tabIndex=0,this.defaultValue==this.valueOn&&(this._checkboxInputElement.checked=!0),this._checkboxInputElement.onchange=function(){t.valueChanged()},l.appendChild(e,this._checkboxInputElement),!l.isNullOrEmpty(this.title)||this.isDesignMode()){var i=new E;i.setParent(this),i.forElementId=this._checkboxInputElement.id,i.hostConfig=this.hostConfig,i.text=l.isNullOrEmpty(this.title)?this.getJsonTypeName():this.title,i.useMarkdown=dt.useMarkdownInRadioButtonAndCheckbox,i.wrap=this.wrap;var n=i.render();n.style.display="inline-block",n.style.flex="1 1 auto",n.style.marginLeft="6px",n.style.verticalAlign="middle";var r=document.createElement("div");r.style.width="6px",l.appendChild(e,r),l.appendChild(e,n)}return e},Object.defineProperty(e.prototype,"isNullable",{get:function(){return!1},enumerable:!0,configurable:!0}),e.prototype.getJsonTypeName=function(){return"Input.Toggle"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"valueOn",this.valueOn,"true"),l.setProperty(e,"valueOff",this.valueOff,"false"),l.setProperty(e,"wrap",this.wrap),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.title=l.getStringValue(e.title),this.valueOn=l.getStringValue(e.valueOn,this.valueOn),this.valueOff=l.getStringValue(e.valueOff,this.valueOff),this.wrap=l.getBoolValue(e.wrap,this.wrap)},Object.defineProperty(e.prototype,"value",{get:function(){return this._checkboxInputElement?this._checkboxInputElement.checked?this.valueOn:this.valueOff:null},enumerable:!0,configurable:!0}),e}(z);e.ToggleInput=F;var M=function(t){function e(e,i){void 0===e&&(e=void 0),void 0===i&&(i=void 0);var n=t.call(this)||this;return n.title=e,n.value=i,n}return r(e,t),e.prototype.parse=function(e){t.prototype.parse.call(this,e),this.title=l.getStringValue(e.title,""),this.value=l.getStringValue(e.value,"")},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"title",this.title),l.setProperty(e,"value",this.value),e},e}(y);e.Choice=M;var B=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.choices=[],e.isCompact=!1,e.isMultiSelect=!1,e.wrap=!1,e}return r(e,t),e.getUniqueCategoryName=function(){var t="__ac-category"+e.uniqueCategoryCounter;return e.uniqueCategoryCounter++,t},e.prototype.internalRender=function(){var t=this;if(this.isMultiSelect){var i=this.defaultValue?this.defaultValue.split(this.hostConfig.choiceSetInputValueSeparator):null;(u=document.createElement("div")).className=this.hostConfig.makeCssClassName("ac-input","ac-choiceSetInput-multiSelect"),u.style.width="100%",this._toggleInputs=[];for(var n=0;n<this.choices.length;n++){var r=document.createElement("input");r.id=l.generateUniqueId(),r.type="checkbox",r.style.margin="0",r.style.display="inline-block",r.style.verticalAlign="middle",r.value=this.choices[n].value,r.style.flex="0 0 auto",r.setAttribute("aria-label",this.choices[n].title),i&&i.indexOf(this.choices[n].value)>=0&&(r.checked=!0),r.onchange=function(){t.valueChanged()},this._toggleInputs.push(r),(h=new E).setParent(this),h.forElementId=r.id,h.hostConfig=this.hostConfig,h.text=l.isNullOrEmpty(this.choices[n].title)?"Choice "+n:this.choices[n].title,h.useMarkdown=dt.useMarkdownInRadioButtonAndCheckbox,h.wrap=this.wrap,(d=h.render()).style.display="inline-block",d.style.flex="1 1 auto",d.style.marginLeft="6px",d.style.verticalAlign="middle",(f=document.createElement("div")).style.width="6px",(g=document.createElement("div")).style.display="flex",g.style.alignItems="center",l.appendChild(g,r),l.appendChild(g,f),l.appendChild(g,d),l.appendChild(u,g)}return u}if(this.isCompact){this._selectElement=document.createElement("select"),this._selectElement.className=this.hostConfig.makeCssClassName("ac-input","ac-multichoiceInput","ac-choiceSetInput-compact"),this._selectElement.style.width="100%";var o=document.createElement("option");o.selected=!0,o.disabled=!0,o.hidden=!0,o.value="",this.placeholder&&(o.text=this.placeholder),l.appendChild(this._selectElement,o);for(var s=0;s<this.choices.length;s++){var a=document.createElement("option");a.value=this.choices[s].value,a.text=this.choices[s].title,a.setAttribute("aria-label",this.choices[s].title),this.choices[s].value==this.defaultValue&&(a.selected=!0),l.appendChild(this._selectElement,a)}return this._selectElement.onchange=function(){t.valueChanged()},this._selectElement}var u,p=e.getUniqueCategoryName();(u=document.createElement("div")).className=this.hostConfig.makeCssClassName("ac-input","ac-choiceSetInput-expanded"),u.style.width="100%",this._toggleInputs=[];for(var c=0;c<this.choices.length;c++){var h,d,f,g,y=document.createElement("input");y.id=l.generateUniqueId(),y.type="radio",y.style.margin="0",y.style.display="inline-block",y.style.verticalAlign="middle",y.name=l.isNullOrEmpty(this.id)?p:this.id,y.value=this.choices[c].value,y.style.flex="0 0 auto",y.setAttribute("aria-label",this.choices[c].title),this.choices[c].value==this.defaultValue&&(y.checked=!0),y.onchange=function(){t.valueChanged()},this._toggleInputs.push(y),(h=new E).setParent(this),h.forElementId=y.id,h.hostConfig=this.hostConfig,h.text=l.isNullOrEmpty(this.choices[c].title)?"Choice "+c:this.choices[c].title,h.useMarkdown=dt.useMarkdownInRadioButtonAndCheckbox,h.wrap=this.wrap,(d=h.render()).style.display="inline-block",d.style.flex="1 1 auto",d.style.marginLeft="6px",d.style.verticalAlign="middle",(f=document.createElement("div")).style.width="6px",(g=document.createElement("div")).style.display="flex",g.style.alignItems="center",l.appendChild(g,y),l.appendChild(g,f),l.appendChild(g,d),l.appendChild(u,g)}return u},e.prototype.getJsonTypeName=function(){return"Input.ChoiceSet"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"placeholder",this.placeholder),l.setArrayProperty(e,"choices",this.choices),l.setProperty(e,"style",this.isCompact?null:"expanded"),l.setProperty(e,"isMultiSelect",this.isMultiSelect,!1),l.setProperty(e,"wrap",this.wrap,!1),e},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e),0==this.choices.length&&e.addFailure(this,{error:s.ValidationError.CollectionCantBeEmpty,message:"An Input.ChoiceSet must have at least one choice defined."});for(var i=0,n=this.choices;i<n.length;i++){var r=n[i];r.title&&r.value||e.addFailure(this,{error:s.ValidationError.PropertyCantBeNull,message:"All choices in an Input.ChoiceSet must have their title and value properties set."})}},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),this.isCompact=!("expanded"===e.style),this.isMultiSelect=l.getBoolValue(e.isMultiSelect,this.isMultiSelect),this.placeholder=l.getStringValue(e.placeholder),this.choices=[],Array.isArray(e.choices))for(var n=0,r=e.choices;n<r.length;n++){var o=r[n],s=new M;s.parse(o),this.choices.push(s)}this.wrap=l.getBoolValue(e.wrap,this.wrap)},Object.defineProperty(e.prototype,"value",{get:function(){if(this.isMultiSelect){if(!this._toggleInputs||0==this._toggleInputs.length)return null;var t="";for(e=0;e<this._toggleInputs.length;e++)this._toggleInputs[e].checked&&(""!=t&&(t+=this.hostConfig.choiceSetInputValueSeparator),t+=this._toggleInputs[e].value);return""==t?null:t}if(this.isCompact)return this._selectElement&&this._selectElement.selectedIndex>0?this._selectElement.value:null;if(!this._toggleInputs||0==this._toggleInputs.length)return null;for(var e=0;e<this._toggleInputs.length;e++)if(this._toggleInputs[e].checked)return this._toggleInputs[e].value;return null},enumerable:!0,configurable:!0}),e.uniqueCategoryCounter=0,e}(z);e.ChoiceSetInput=B;var L=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.internalRender=function(){var t=this;return this._numberInputElement=document.createElement("input"),this._numberInputElement.setAttribute("type","number"),this.min&&this._numberInputElement.setAttribute("min",this.min.toString()),this.max&&this._numberInputElement.setAttribute("max",this.max.toString()),this._numberInputElement.className=this.hostConfig.makeCssClassName("ac-input","ac-numberInput"),this._numberInputElement.style.width="100%",this._numberInputElement.tabIndex=0,l.isNullOrEmpty(this.defaultValue)||(this._numberInputElement.value=this.defaultValue),l.isNullOrEmpty(this.placeholder)||(this._numberInputElement.placeholder=this.placeholder,this._numberInputElement.setAttribute("aria-label",this.placeholder)),this._numberInputElement.oninput=function(){t.valueChanged()},this._numberInputElement},e.prototype.getJsonTypeName=function(){return"Input.Number"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"placeholder",this.placeholder),l.setNumberProperty(e,"min",this.min),l.setNumberProperty(e,"max",this.max),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.placeholder=l.getStringValue(e.placeholder),this.min=l.getNumberValue(e.min),this.max=l.getNumberValue(e.max)},Object.defineProperty(e.prototype,"min",{get:function(){return this._min},set:function(t){this._min=t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"max",{get:function(){return this._max},set:function(t){this._max=t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"value",{get:function(){return this._numberInputElement?this._numberInputElement.value:void 0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"valueAsNumber",{get:function(){return this._numberInputElement?this._numberInputElement.valueAsNumber:void 0},enumerable:!0,configurable:!0}),e}(z);e.NumberInput=L;var R=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.internalRender=function(){var t=this;return this._dateInputElement=document.createElement("input"),this._dateInputElement.setAttribute("type","date"),this._dateInputElement.setAttribute("min",this.min),this._dateInputElement.setAttribute("max",this.max),this._dateInputElement.className=this.hostConfig.makeCssClassName("ac-input","ac-dateInput"),this._dateInputElement.style.width="100%",this._dateInputElement.oninput=function(){t.valueChanged()},l.isNullOrEmpty(this.defaultValue)||(this._dateInputElement.value=this.defaultValue),this._dateInputElement},e.prototype.getJsonTypeName=function(){return"Input.Date"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"min",this.min),l.setProperty(e,"max",this.max),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.min=l.getStringValue(e.min),this.max=l.getStringValue(e.max)},Object.defineProperty(e.prototype,"min",{get:function(){return this._min},set:function(t){this._min=this.parseInputValue(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"max",{get:function(){return this._max},set:function(t){this._max=this.parseInputValue(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"value",{get:function(){return this._dateInputElement?this._dateInputElement.value:null},enumerable:!0,configurable:!0}),e}(z);e.DateInput=R;var H,j=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.internalRender=function(){var t=this;return this._timeInputElement=document.createElement("input"),this._timeInputElement.setAttribute("type","time"),this._timeInputElement.setAttribute("min",this.min),this._timeInputElement.setAttribute("max",this.max),this._timeInputElement.className=this.hostConfig.makeCssClassName("ac-input","ac-timeInput"),this._timeInputElement.style.width="100%",this._timeInputElement.oninput=function(){t.valueChanged()},l.isNullOrEmpty(this.defaultValue)||(this._timeInputElement.value=this.defaultValue),this._timeInputElement},e.prototype.parseInputValue=function(t){return/^[0-9]{2}:[0-9]{2}$/.test(t)?t:null},e.prototype.getJsonTypeName=function(){return"Input.Time"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"min",this.min),l.setProperty(e,"max",this.max),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.min=l.getStringValue(e.min),this.max=l.getStringValue(e.max)},Object.defineProperty(e.prototype,"min",{get:function(){return this._min},set:function(t){this._min=this.parseInputValue(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"max",{get:function(){return this._max},set:function(t){this._max=this.parseInputValue(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"value",{get:function(){return this._timeInputElement?this._timeInputElement.value:null},enumerable:!0,configurable:!0}),e}(z);e.TimeInput=j,function(t){t[t.Normal=0]="Normal",t[t.Expanded=1]="Expanded",t[t.Subdued=2]="Subdued"}(H||(H={}));var J=function(){function t(t,e){this._state=H.Normal,this.onClick=null,this.action=t,this._parentContainerStyle=e}return t.prototype.updateCssStyle=function(){var t,e,i=this.action.parent.hostConfig;switch(this.action.renderedElement.className=i.makeCssClassName("ac-pushButton"),l.isNullOrEmpty(this._parentContainerStyle)||this.action.renderedElement.classList.add("style-"+this._parentContainerStyle),this.action instanceof Y&&this.action.renderedElement.classList.add(i.makeCssClassName("expandable")),this.action.renderedElement.classList.remove(i.makeCssClassName("expanded")),this.action.renderedElement.classList.remove(i.makeCssClassName("subdued")),this._state){case H.Expanded:this.action.renderedElement.classList.add(i.makeCssClassName("expanded"));break;case H.Subdued:this.action.renderedElement.classList.add(i.makeCssClassName("subdued"))}l.isNullOrEmpty(this.action.style)||(this.action.style===s.ActionStyle.Positive?(t=this.action.renderedElement.classList).add.apply(t,i.makeCssClassNames("primary","style-positive")):(e=this.action.renderedElement.classList).add.apply(e,i.makeCssClassNames("style-"+this.action.style.toLowerCase())))},t.prototype.render=function(){var t=this;this.action.render(),this.action.renderedElement.onclick=function(e){e.preventDefault(),e.cancelBubble=!0,t.click()},this.updateCssStyle()},t.prototype.click=function(){null!=this.onClick&&this.onClick(this)},Object.defineProperty(t.prototype,"state",{get:function(){return this._state},set:function(t){this._state=t,this.updateCssStyle()},enumerable:!0,configurable:!0}),t}(),W=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._shouldFallback=!1,e._parent=null,e._actionCollection=null,e._renderedElement=null,e.requires=new u.HostCapabilities,e.style=s.ActionStyle.Default,e}return r(e,t),e.prototype.setCollection=function(t){this._actionCollection=t},e.prototype.addCssClasses=function(t){},e.prototype.internalGetReferencedInputs=function(t){return{}},e.prototype.internalPrepareForExecution=function(t){},e.prototype.internalValidateInputs=function(t){var e=[];if(dt.useBuiltInInputValidation&&!this.ignoreInputValidation)for(var i=0,n=Object.keys(t);i<n.length;i++){var r=t[n[i]];r.validateValue()||e.push(r)}return e},e.prototype.getHref=function(){return""},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"type",this.getJsonTypeName()),l.setProperty(e,"title",this.title),l.setProperty(e,"iconUrl",this.iconUrl),l.setProperty(e,"style",this.style,s.ActionStyle.Default),e},e.prototype.render=function(t){void 0===t&&(t="ac-pushButton");var e=this.parent.hostConfig,i=document.createElement("button");this.addCssClasses(i),i.setAttribute("aria-label",this.title),i.type="button",i.style.display="flex",i.style.alignItems="center",i.style.justifyContent="center";var n=!l.isNullOrEmpty(this.title),r=document.createElement("div");if(r.style.overflow="hidden",r.style.textOverflow="ellipsis",e.actions.iconPlacement==s.ActionIconPlacement.AboveTitle||e.actions.allowTitleToWrap||(r.style.whiteSpace="nowrap"),n&&(r.innerText=this.title),l.isNullOrEmpty(this.iconUrl))i.classList.add("noIcon"),i.appendChild(r);else{var o=document.createElement("img");o.src=this.iconUrl,o.style.width=e.actions.iconSize+"px",o.style.height=e.actions.iconSize+"px",o.style.flex="0 0 auto",e.actions.iconPlacement==s.ActionIconPlacement.AboveTitle?(i.classList.add("iconAbove"),i.style.flexDirection="column",n&&(o.style.marginBottom="4px")):(i.classList.add("iconLeft"),n&&(o.style.marginRight="4px")),i.appendChild(o),i.appendChild(r)}this._renderedElement=i},e.prototype.setParent=function(t){this._parent=t},e.prototype.execute=function(){var t,e,i;this.onExecute&&this.onExecute(this),e=(t=this).parent.getRootElement(),(i=e&&e.onExecuteAction?e.onExecuteAction:dt.onExecuteAction)&&t.prepareForExecution()&&i(t)},e.prototype.prepareForExecution=function(){var t=this.getReferencedInputs();return!(this.internalValidateInputs(t).length>0)&&(this.internalPrepareForExecution(t),!0)},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),function(t,e,i){var n=t.parent?t.parent.getRootElement():null,r=n&&n.onParseAction?n.onParseAction:dt.onParseAction;null!=r&&r(t,e,i)}(this,e,i),this.requires.parse(e.requires,i),e.title||""===e.title||lt({error:s.ValidationError.PropertyCantBeNull,message:"Actions should always have a title."},i),this.title=l.getStringValue(e.title),this.iconUrl=l.getStringValue(e.iconUrl),this.style=l.getStringValue(e.style,this.style)},e.prototype.remove=function(){return!!this._actionCollection&&this._actionCollection.removeAction(this)},e.prototype.getAllInputs=function(){return[]},e.prototype.getResourceInformation=function(){return l.isNullOrEmpty(this.iconUrl)?[]:[{url:this.iconUrl,mimeType:"image"}]},e.prototype.getActionById=function(t){if(this.id==t)return this},e.prototype.getReferencedInputs=function(){return this.internalGetReferencedInputs(this.parent.getRootElement().getAllInputs())},e.prototype.validateInputs=function(){return this.internalValidateInputs(this.getReferencedInputs())},e.prototype.shouldFallback=function(){return this._shouldFallback||!this.requires.areAllMet(this.parent.hostConfig.hostCapabilities)},Object.defineProperty(e.prototype,"isPrimary",{get:function(){return this.style==s.ActionStyle.Positive},set:function(t){t?this.style=s.ActionStyle.Positive:this.style==s.ActionStyle.Positive&&(this.style=s.ActionStyle.Default)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"ignoreInputValidation",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"parent",{get:function(){return this._parent},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"renderedElement",{get:function(){return this._renderedElement},enumerable:!0,configurable:!0}),e}(b);e.Action=W;var U=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._isPrepared=!1,e._ignoreInputValidation=!1,e}return r(e,t),e.prototype.internalGetReferencedInputs=function(t){for(var e={},i=0,n=t;i<n.length;i++){var r=n[i];e[r.id]=r}return e},e.prototype.internalPrepareForExecution=function(t){this._originalData?this._processedData=JSON.parse(JSON.stringify(this._originalData)):this._processedData={};for(var e=0,i=Object.keys(t);e<i.length;e++){var n=t[i[e]];null!=n.value&&(this._processedData[n.id]=n.value)}this._isPrepared=!0},e.prototype.getJsonTypeName=function(){return e.JsonTypeName},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"ignoreInputValidation",this.ignoreInputValidation,!1),l.setProperty(e,"data",this._originalData),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this._ignoreInputValidation=l.getBoolValue(e.ignoreInputValidation,this._ignoreInputValidation),this.data=e.data},Object.defineProperty(e.prototype,"ignoreInputValidation",{get:function(){return this._ignoreInputValidation},set:function(t){this._ignoreInputValidation=t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"data",{get:function(){return this._isPrepared?this._processedData:this._originalData},set:function(t){this._originalData=t,this._isPrepared=!1},enumerable:!0,configurable:!0}),e.JsonTypeName="Action.Submit",e}(W);e.SubmitAction=U;var q=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.getJsonTypeName=function(){return e.JsonTypeName},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"url",this.url),e},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e),l.isNullOrEmpty(this.url)&&e.addFailure(this,{error:s.ValidationError.PropertyCantBeNull,message:"An Action.OpenUrl must have its url property set."})},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.url=l.getStringValue(e.url)},e.prototype.getHref=function(){return this.url},e.JsonTypeName="Action.OpenUrl",e}(W);e.OpenUrlAction=q;var G=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.targetElements={},e}return r(e,t),e.prototype.getJsonTypeName=function(){return e.JsonTypeName},e.prototype.execute=function(){for(var t=0,e=Object.keys(this.targetElements);t<e.length;t++){var i=e[t],n=this.parent.getRootElement().getElementById(i);n&&("boolean"==typeof this.targetElements[i]?n.isVisible=this.targetElements[i]:n.isVisible=!n.isVisible)}},e.prototype.parse=function(e){t.prototype.parse.call(this,e),this.targetElements={};var i=e.targetElements;if(i&&Array.isArray(i))for(var n=0,r=i;n<r.length;n++){var o=r[n];if("string"==typeof o)this.targetElements[o]=void 0;else if("object"==typeof o){var s=o.elementId;s&&"string"==typeof s&&(this.targetElements[s]=l.getBoolValue(o.isVisible,void 0))}}},e.prototype.toJSON=function(){for(var e=t.prototype.toJSON.call(this),i=[],n=0,r=Object.keys(this.targetElements);n<r.length;n++){var o=r[n];"boolean"==typeof this.targetElements[o]?i.push({elementId:o,isVisible:this.targetElements[o]}):i.push(o)}return e.targetElements=i,e},e.prototype.addTargetElement=function(t,e){void 0===e&&(e=void 0),this.targetElements[t]=e},e.prototype.removeTargetElement=function(t){delete this.targetElements[t]},e.JsonTypeName="Action.ToggleVisibility",e}(W);e.ToggleVisibilityAction=G;var X=function(t){function e(e,i){void 0===e&&(e=""),void 0===i&&(i="");var n=t.call(this)||this;return n._value=new a.StringWithSubstitutions,n.name=e,n.value=i,n}return r(e,t),e.prototype.parse=function(e){t.prototype.parse.call(this,e),this.name=l.getStringValue(e.name),this.value=l.getStringValue(e.value)},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"name",this.name),l.setProperty(e,"value",this._value.getOriginal()),e},e.prototype.getReferencedInputs=function(t,e){this._value.getReferencedInputs(t,e)},e.prototype.prepareForExecution=function(t){this._value.substituteInputValues(t,a.ContentTypes.applicationXWwwFormUrlencoded)},Object.defineProperty(e.prototype,"value",{get:function(){return this._value.get()},set:function(t){this._value.set(t)},enumerable:!0,configurable:!0}),e}(y);e.HttpHeader=X;var $=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._url=new a.StringWithSubstitutions,e._body=new a.StringWithSubstitutions,e._headers=[],e._ignoreInputValidation=!1,e}return r(e,t),e.prototype.internalGetReferencedInputs=function(t){var e={};this._url.getReferencedInputs(t,e);for(var i=0,n=this._headers;i<n.length;i++){n[i].getReferencedInputs(t,e)}return this._body.getReferencedInputs(t,e),e},e.prototype.internalPrepareForExecution=function(t){this._url.substituteInputValues(t,a.ContentTypes.applicationXWwwFormUrlencoded);for(var e=a.ContentTypes.applicationJson,i=0,n=this._headers;i<n.length;i++){var r=n[i];r.prepareForExecution(t),r.name&&"content-type"==r.name.toLowerCase()&&(e=r.value)}this._body.substituteInputValues(t,e)},e.prototype.getJsonTypeName=function(){return e.JsonTypeName},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"method",this.method),l.setProperty(e,"url",this._url.getOriginal()),l.setProperty(e,"body",this._body.getOriginal()),l.setProperty(e,"ignoreInputValidation",this.ignoreInputValidation,!1),l.setArrayProperty(e,"headers",this.headers),e},e.prototype.internalValidateProperties=function(e){if(t.prototype.internalValidateProperties.call(this,e),l.isNullOrEmpty(this.url)&&e.addFailure(this,{error:s.ValidationError.PropertyCantBeNull,message:"An Action.Http must have its url property set."}),this.headers.length>0)for(var i=0,n=this.headers;i<n.length;i++){n[i].name||e.addFailure(this,{error:s.ValidationError.PropertyCantBeNull,message:"All headers of an Action.Http must have their name and value properties set."})}},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),this.url=l.getStringValue(e.url),this.method=l.getStringValue(e.method),this.body=l.getStringValue(e.body),this._ignoreInputValidation=l.getBoolValue(e.ignoreInputValidation,this._ignoreInputValidation),this._headers=[],Array.isArray(e.headers))for(var n=0,r=e.headers;n<r.length;n++){var o=r[n],s=new X;s.parse(o),this.headers.push(s)}},Object.defineProperty(e.prototype,"ignoreInputValidation",{get:function(){return this._ignoreInputValidation},set:function(t){this._ignoreInputValidation=t},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._url.get()},set:function(t){this._url.set(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"body",{get:function(){return this._body.get()},set:function(t){this._body.set(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"headers",{get:function(){return this._headers?this._headers:[]},set:function(t){this._headers=t},enumerable:!0,configurable:!0}),e.JsonTypeName="Action.Http",e}(W);e.HttpAction=$;var Y=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.card=new ft,e}return r(e,t),e.prototype.addCssClasses=function(e){t.prototype.addCssClasses.call(this,e),e.classList.add(this.parent.hostConfig.makeCssClassName("expandable"))},e.prototype.getJsonTypeName=function(){return e.JsonTypeName},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return this.card&&l.setProperty(e,"card",this.card.toJSON()),e},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e),this.card.internalValidateProperties(e)},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i);var n=e.card;n?this.card.parse(n,i):lt({error:s.ValidationError.PropertyCantBeNull,message:'An Action.ShowCard must have its "card" property set to a valid AdaptiveCard object.'},i)},e.prototype.setParent=function(e){t.prototype.setParent.call(this,e),this.card.setParent(e)},e.prototype.getAllInputs=function(){return this.card.getAllInputs()},e.prototype.getResourceInformation=function(){return t.prototype.getResourceInformation.call(this).concat(this.card.getResourceInformation())},e.prototype.getActionById=function(e){var i=t.prototype.getActionById.call(this,e);return i||(i=this.card.getActionById(e)),i},e.JsonTypeName="Action.ShowCard",e}(W);e.ShowCardAction=Y;var Z=function(){function t(t){this._expandedAction=null,this._renderedActionCount=0,this._actionCard=null,this.items=[],this.buttons=[],this._owner=t}return t.prototype.refreshContainer=function(){if(this._actionCardContainer.innerHTML="",null!==this._actionCard){this._actionCardContainer.style.marginTop=this._renderedActionCount>0?this._owner.hostConfig.actions.showCard.inlineTopMargin+"px":"0px";var t=this._owner.getEffectivePadding();this._owner.getImmediateSurroundingPadding(t);var e=this._owner.hostConfig.paddingDefinitionToSpacingDefinition(t);null!==this._actionCard&&(this._actionCard.style.paddingLeft=e.left+"px",this._actionCard.style.paddingRight=e.right+"px",this._actionCard.style.marginLeft="-"+e.left+"px",this._actionCard.style.marginRight="-"+e.right+"px",0==e.bottom||this._owner.isDesignMode()||(this._actionCard.style.paddingBottom=e.bottom+"px",this._actionCard.style.marginBottom="-"+e.bottom+"px"),l.appendChild(this._actionCardContainer,this._actionCard))}else this._actionCardContainer.style.marginTop="0px"},t.prototype.layoutChanged=function(){this._owner.getRootElement().updateLayout()},t.prototype.hideActionCard=function(){var t=this._expandedAction;this._expandedAction=null,this._actionCard=null,this.refreshContainer(),t&&(this.layoutChanged(),st(t,!1))},t.prototype.showActionCard=function(t,e,i){if(void 0===e&&(e=!1),void 0===i&&(i=!0),null!=t.card){t.card.suppressStyle=e;var n=t.card.render();this._actionCard=n,this._expandedAction=t,this.refreshContainer(),i&&(this.layoutChanged(),st(t,!0))}},t.prototype.collapseExpandedAction=function(){for(var t=0;t<this.buttons.length;t++)this.buttons[t].state=H.Normal;this.hideActionCard()},t.prototype.expandShowCardAction=function(t,e){for(var i=0;i<this.buttons.length;i++)this.buttons[i].action!==t?this.buttons[i].state=H.Subdued:this.buttons[i].state=H.Expanded;this.showActionCard(t,!(this._owner.isAtTheVeryLeft()&&this._owner.isAtTheVeryRight()),e)},t.prototype.actionClicked=function(t){if(t.action instanceof Y)this._owner.hostConfig.actions.showCard.actionMode===s.ShowCardActionMode.Popup?t.action.execute():t.action===this._expandedAction?this.collapseExpandedAction():this.expandShowCardAction(t.action,!0);else{for(var e=0;e<this.buttons.length;e++)this.buttons[e].state=H.Normal;this.hideActionCard(),t.action.execute()}},t.prototype.getParentContainer=function(){return this._owner instanceof et?this._owner:this._owner.getParentContainer()},t.prototype.findActionButton=function(t){for(var e=0,i=this.buttons;e<i.length;e++){var n=i[e];if(n.action==t)return n}return null},t.prototype.parse=function(t,e){if(this.clear(),t&&t instanceof Array)for(var i=0,n=t;i<n.length;i++){var r=n[i],o=f(this._owner,r,[],!this._owner.isDesignMode(),e);o&&this.addAction(o)}},t.prototype.toJSON=function(){if(this.items.length>0){for(var t=[],e=0,i=this.items;e<i.length;e++){var n=i[e];t.push(n.toJSON())}return t}return null},t.prototype.getActionById=function(t){for(var e=null,i=0;i<this.items.length&&!(e=this.items[i].getActionById(t));i++);return e},t.prototype.validateProperties=function(t){this._owner.hostConfig.actions.maxActions&&this.items.length>this._owner.hostConfig.actions.maxActions&&t.addFailure(this._owner,{error:s.ValidationError.TooManyActions,message:"A maximum of "+this._owner.hostConfig.actions.maxActions+" actions are allowed."}),this.items.length>0&&!this._owner.hostConfig.supportsInteractivity&&t.addFailure(this._owner,{error:s.ValidationError.InteractivityNotAllowed,message:"Interactivity is not allowed."});for(var e=0,i=this.items;e<i.length;e++){var n=i[e];h(n,this._owner.getForbiddenActionTypes())||t.addFailure(this._owner,{error:s.ValidationError.ActionTypeNotAllowed,message:"Actions of type "+n.getJsonTypeName()+" are not allowe."}),n.internalValidateProperties(t)}},t.prototype.render=function(t,e){var i=this,n=this._owner.hostConfig;if(!n.supportsInteractivity)return null;var r=document.createElement("div"),o=n.actions.maxActions?Math.min(n.actions.maxActions,this.items.length):this.items.length,a=this._owner.getForbiddenActionTypes();if(this._actionCardContainer=document.createElement("div"),this._renderedActionCount=0,n.actions.preExpandSingleShowCardAction&&1==o&&this.items[0]instanceof Y&&h(this.items[0],a))this.showActionCard(this.items[0],!0),this._renderedActionCount=1;else{var u=document.createElement("div");if(u.className=n.makeCssClassName("ac-actionSet"),u.style.display="flex",t==s.Orientation.Horizontal)if(u.style.flexDirection="row",this._owner.horizontalAlignment&&n.actions.actionAlignment!=s.ActionAlignment.Stretch)switch(this._owner.horizontalAlignment){case s.HorizontalAlignment.Center:u.style.justifyContent="center";break;case s.HorizontalAlignment.Right:u.style.justifyContent="flex-end";break;default:u.style.justifyContent="flex-start"}else switch(n.actions.actionAlignment){case s.ActionAlignment.Center:u.style.justifyContent="center";break;case s.ActionAlignment.Right:u.style.justifyContent="flex-end";break;default:u.style.justifyContent="flex-start"}else if(u.style.flexDirection="column",this._owner.horizontalAlignment&&n.actions.actionAlignment!=s.ActionAlignment.Stretch)switch(this._owner.horizontalAlignment){case s.HorizontalAlignment.Center:u.style.alignItems="center";break;case s.HorizontalAlignment.Right:u.style.alignItems="flex-end";break;default:u.style.alignItems="flex-start"}else switch(n.actions.actionAlignment){case s.ActionAlignment.Center:u.style.alignItems="center";break;case s.ActionAlignment.Right:u.style.alignItems="flex-end";break;case s.ActionAlignment.Stretch:u.style.alignItems="stretch";break;default:u.style.alignItems="flex-start"}for(var p=this.getParentContainer().getEffectiveStyle(),c=0;c<this.items.length;c++)if(h(this.items[c],a)){var d=this.findActionButton(this.items[c]);if(d||((d=new J(this.items[c],p)).onClick=function(t){i.actionClicked(t)},this.buttons.push(d)),d.render(),n.actions.actionsOrientation==s.Orientation.Horizontal&&n.actions.actionAlignment==s.ActionAlignment.Stretch?d.action.renderedElement.style.flex="0 1 100%":d.action.renderedElement.style.flex="0 1 auto",u.appendChild(d.action.renderedElement),this._renderedActionCount++,this._renderedActionCount>=n.actions.maxActions||c==this.items.length-1)break;if(n.actions.buttonSpacing>0){var f=document.createElement("div");t===s.Orientation.Horizontal?(f.style.flex="0 0 auto",f.style.width=n.actions.buttonSpacing+"px"):f.style.height=n.actions.buttonSpacing+"px",l.appendChild(u,f)}}var g=document.createElement("div");g.style.overflow="hidden",g.appendChild(u),l.appendChild(r,g)}l.appendChild(r,this._actionCardContainer);for(c=0;c<this.buttons.length;c++)if(this.buttons[c].state==H.Expanded){this.expandShowCardAction(this.buttons[c].action,!1);break}return this._renderedActionCount>0?r:null},t.prototype.addAction=function(t){if(!t)throw new Error("The action parameter cannot be null.");if(t.parent&&t.parent!==this._owner||!(this.items.indexOf(t)<0))throw new Error("The action already belongs to another element.");this.items.push(t),t.parent||t.setParent(this._owner),c(t,this)},t.prototype.removeAction=function(t){this.expandedAction&&this._expandedAction==t&&this.collapseExpandedAction();var e=this.items.indexOf(t);if(e>=0){this.items.splice(e,1),t.setParent(null),c(t,null);for(var i=0;i<this.buttons.length;i++)if(this.buttons[i].action==t){this.buttons.splice(i,1);break}return!0}return!1},t.prototype.clear=function(){this.items=[],this.buttons=[],this._expandedAction=null,this._renderedActionCount=0},t.prototype.getAllInputs=function(){for(var t=[],e=0;e<this.items.length;e++){var i=this.items[e];t=t.concat(i.getAllInputs())}return t},t.prototype.getResourceInformation=function(){for(var t=[],e=0;e<this.items.length;e++)t=t.concat(this.items[e].getResourceInformation());return t},Object.defineProperty(t.prototype,"renderedActionCount",{get:function(){return this._renderedActionCount},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"expandedAction",{get:function(){return this._expandedAction},enumerable:!0,configurable:!0}),t}(),K=function(t){function e(){var e=t.call(this)||this;return e.orientation=null,e._actionCollection=new Z(e),e}return r(e,t),e.prototype.internalRender=function(){return this._actionCollection.render(this.orientation?this.orientation:this.hostConfig.actions.actionsOrientation,this.isDesignMode())},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setEnumProperty(s.Orientation,e,"orientation",this.orientation),l.setProperty(e,"actions",this._actionCollection.toJSON()),e},e.prototype.isBleedingAtBottom=function(){return 0==this._actionCollection.renderedActionCount?t.prototype.isBleedingAtBottom.call(this):1==this._actionCollection.items.length?null!=this._actionCollection.expandedAction&&!this.hostConfig.actions.preExpandSingleShowCardAction:null!=this._actionCollection.expandedAction},e.prototype.getJsonTypeName=function(){return"ActionSet"},e.prototype.getActionCount=function(){return this._actionCollection.items.length},e.prototype.getActionAt=function(e){if(e>=0&&e<this.getActionCount())return this._actionCollection.items[e];t.prototype.getActionAt.call(this,e)},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e),this._actionCollection.validateProperties(e)},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i);var n=e.orientation;n&&(this.orientation=l.getEnumValue(s.Orientation,n,s.Orientation.Horizontal)),this._actionCollection.parse(e.actions,i)},e.prototype.addAction=function(t){this._actionCollection.addAction(t)},e.prototype.getAllInputs=function(){return this._actionCollection.getAllInputs()},e.prototype.getResourceInformation=function(){return this._actionCollection.getResourceInformation()},Object.defineProperty(e.prototype,"isInteractive",{get:function(){return!0},enumerable:!0,configurable:!0}),e}(C);e.ActionSet=K;var Q=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._style=null,e._bleed=!1,e}return r(e,t),e.prototype.applyBackground=function(){var t=this.hostConfig.containerStyles.getStyleByName(this.style,this.hostConfig.containerStyles.getStyleByName(this.defaultStyle));l.isNullOrEmpty(t.backgroundColor)||(this.renderedElement.style.backgroundColor=l.stringToCssColor(t.backgroundColor))},e.prototype.applyPadding=function(){if(t.prototype.applyPadding.call(this),this.renderedElement){var e=new a.SpacingDefinition;if(this.getEffectivePadding()&&(e=this.hostConfig.paddingDefinitionToSpacingDefinition(this.getEffectivePadding())),this.renderedElement.style.paddingTop=e.top+"px",this.renderedElement.style.paddingRight=e.right+"px",this.renderedElement.style.paddingBottom=e.bottom+"px",this.renderedElement.style.paddingLeft=e.left+"px",this.isBleeding()){var i=new a.PaddingDefinition;this.getImmediateSurroundingPadding(i);var n=this.hostConfig.paddingDefinitionToSpacingDefinition(i);this.renderedElement.style.marginRight="-"+n.right+"px",this.renderedElement.style.marginLeft="-"+n.left+"px",this.isDesignMode()||(this.renderedElement.style.marginTop="-"+n.top+"px",this.renderedElement.style.marginBottom="-"+n.bottom+"px"),this.separatorElement&&this.separatorOrientation==s.Orientation.Horizontal&&(this.separatorElement.style.marginLeft="-"+n.left+"px",this.separatorElement.style.marginRight="-"+n.right+"px")}else this.renderedElement.style.marginRight="0",this.renderedElement.style.marginLeft="0",this.renderedElement.style.marginTop="0",this.renderedElement.style.marginBottom="0",this.separatorElement&&(this.separatorElement.style.marginRight="0",this.separatorElement.style.marginLeft="0")}},e.prototype.getHasBackground=function(){for(var t=this.parent;t;){var i=t instanceof et&&t.backgroundImage.isValid();if(t instanceof e&&this.hasExplicitStyle&&(t.getEffectiveStyle()!=this.getEffectiveStyle()||i))return!0;t=t.parent}return!1},e.prototype.getDefaultPadding=function(){return this.getHasBackground()?new a.PaddingDefinition(s.Spacing.Padding,s.Spacing.Padding,s.Spacing.Padding,s.Spacing.Padding):t.prototype.getDefaultPadding.call(this)},e.prototype.getHasExpandedAction=function(){return!1},e.prototype.getBleed=function(){return this._bleed},e.prototype.setBleed=function(t){this._bleed=t},Object.defineProperty(e.prototype,"renderedActionCount",{get:function(){return 0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hasExplicitStyle",{get:function(){return null!=this._style},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"allowCustomStyle",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"supportsMinHeight",{get:function(){return!0},enumerable:!0,configurable:!0}),e.prototype.isBleeding=function(){return(this.getHasBackground()||this.hostConfig.alwaysAllowBleed)&&this.getBleed()},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"style",this.style),e},e.prototype.internalValidateProperties=function(e){(t.prototype.internalValidateProperties.call(this,e),this._style)&&(this.hostConfig.containerStyles.getStyleByName(this._style)||e.addFailure(this,{error:s.ValidationError.InvalidPropertyValue,message:"Unknown container style: "+this._style}))},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this._style=l.getStringValue(e.style)},e.prototype.render=function(){var e=t.prototype.render.call(this);return e&&this.getHasBackground()&&this.applyBackground(),e},e.prototype.getEffectiveStyle=function(){var e=this.style;return e||t.prototype.getEffectiveStyle.call(this)},Object.defineProperty(e.prototype,"style",{get:function(){return this.allowCustomStyle&&this._style&&this.hostConfig.containerStyles.getStyleByName(this._style)?this._style:null},set:function(t){this._style=t},enumerable:!0,configurable:!0}),e}(P);e.StylableCardElementContainer=Q;var tt=function(t){function e(){var i=null!==t&&t.apply(this,arguments)||this;return i.fillMode=e.defaultFillMode,i.horizontalAlignment=e.defaultHorizontalAlignment,i.verticalAlignment=e.defaultVerticalAlignment,i}return r(e,t),e.prototype.reset=function(){this.url=void 0,this.fillMode=e.defaultFillMode,this.horizontalAlignment=e.defaultHorizontalAlignment,this.verticalAlignment=e.defaultVerticalAlignment},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.url=l.getStringValue(e.url),this.fillMode=l.getEnumValue(s.FillMode,e.fillMode,this.fillMode),this.horizontalAlignment=l.getEnumValue(s.HorizontalAlignment,e.horizontalAlignment,this.horizontalAlignment),this.verticalAlignment=l.getEnumValue(s.VerticalAlignment,e.verticalAlignment,this.verticalAlignment)},e.prototype.toJSON=function(){if(!this.isValid())return null;if(this.fillMode==e.defaultFillMode&&this.horizontalAlignment==e.defaultHorizontalAlignment&&this.verticalAlignment==e.defaultVerticalAlignment)return this.url;var i=t.prototype.toJSON.call(this);return l.setProperty(i,"url",this.url),l.setEnumProperty(s.FillMode,i,"fillMode",this.fillMode,e.defaultFillMode),l.setEnumProperty(s.HorizontalAlignment,i,"horizontalAlignment",this.horizontalAlignment,e.defaultHorizontalAlignment),l.setEnumProperty(s.VerticalAlignment,i,"verticalAlignment",this.verticalAlignment,e.defaultVerticalAlignment),i},e.prototype.apply=function(t){if(this.url){switch(t.style.backgroundImage="url('"+this.url+"')",this.fillMode){case s.FillMode.Repeat:t.style.backgroundRepeat="repeat";break;case s.FillMode.RepeatHorizontally:t.style.backgroundRepeat="repeat-x";break;case s.FillMode.RepeatVertically:t.style.backgroundRepeat="repeat-y";break;case s.FillMode.Cover:default:t.style.backgroundRepeat="no-repeat",t.style.backgroundSize="cover"}switch(this.horizontalAlignment){case s.HorizontalAlignment.Center:t.style.backgroundPositionX="center";break;case s.HorizontalAlignment.Right:t.style.backgroundPositionX="right"}switch(this.verticalAlignment){case s.VerticalAlignment.Center:t.style.backgroundPositionY="center";break;case s.VerticalAlignment.Bottom:t.style.backgroundPositionY="bottom"}}},e.prototype.isValid=function(){return!l.isNullOrEmpty(this.url)},e.defaultFillMode=s.FillMode.Cover,e.defaultHorizontalAlignment=s.HorizontalAlignment.Left,e.defaultVerticalAlignment=s.VerticalAlignment.Top,e}(y);e.BackgroundImage=tt;var et=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._items=[],e._renderedItems=[],e.backgroundImage=new tt,e.verticalContentAlignment=s.VerticalAlignment.Top,e.rtl=null,e}return r(e,t),e.prototype.insertItemAt=function(t,e,i){if(t.parent&&!i)throw new Error("The element already belongs to another container.");if(!t.isStandalone)throw new Error("Elements of type "+t.getJsonTypeName()+" cannot be used as standalone elements.");e<0||e>=this._items.length?this._items.push(t):this._items.splice(e,0,t),t.setParent(this)},e.prototype.supportsExcplitiHeight=function(){return!0},e.prototype.getItemsCollectionPropertyName=function(){return"items"},e.prototype.applyBackground=function(){this.backgroundImage.isValid()&&this.backgroundImage.apply(this.renderedElement),t.prototype.applyBackground.call(this)},e.prototype.internalRender=function(){this._renderedItems=[];var t=this.hostConfig,e=document.createElement("div");switch(null!=this.rtl&&this.rtl&&(e.dir="rtl"),e.classList.add(t.makeCssClassName("ac-container")),e.style.display="flex",e.style.flexDirection="column",dt.useAdvancedCardBottomTruncation&&(e.style.minHeight="-webkit-min-content"),this.verticalContentAlignment){case s.VerticalAlignment.Center:e.style.justifyContent="center";break;case s.VerticalAlignment.Bottom:e.style.justifyContent="flex-end";break;default:e.style.justifyContent="flex-start"}if(this._items.length>0)for(var i=0;i<this._items.length;i++){var n=this.isElementAllowed(this._items[i],this.getForbiddenElementTypes())?this._items[i].render():null;n&&(this._renderedItems.length>0&&this._items[i].separatorElement&&(this._items[i].separatorElement.style.flex="0 0 auto",l.appendChild(e,this._items[i].separatorElement)),l.appendChild(e,n),this._renderedItems.push(this._items[i]))}else if(this.isDesignMode()){var r=this.createPlaceholderElement();r.style.width="100%",r.style.height="100%",e.appendChild(r)}return e},e.prototype.truncateOverflow=function(t){for(var e=this.renderedElement.offsetTop+t+1,i=function(t){var n=t.renderedElement;if(n)switch(l.getFitStatus(n,e)){case s.ContainerFitStatus.FullyInContainer:t.resetOverflow()&&i(t);break;case s.ContainerFitStatus.Overflowing:var r=e-n.offsetTop;t.handleOverflow(r);break;case s.ContainerFitStatus.FullyOutOfContainer:t.handleOverflow(0)}},n=0,r=this._items;n<r.length;n++){var o=r[n];i(o)}return!0},e.prototype.undoOverflowTruncation=function(){for(var t=0,e=this._items;t<e.length;t++){e[t].resetOverflow()}},e.prototype.getHasBackground=function(){return this.backgroundImage.isValid()||t.prototype.getHasBackground.call(this)},Object.defineProperty(e.prototype,"isSelectable",{get:function(){return!0},enumerable:!0,configurable:!0}),e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);if(l.setProperty(e,"backgroundImage",this.backgroundImage.toJSON()),l.setEnumProperty(s.VerticalAlignment,e,"verticalContentAlignment",this.verticalContentAlignment,s.VerticalAlignment.Top),this._items.length>0){for(var i=[],n=0,r=this._items;n<r.length;n++){var o=r[n];i.push(o.toJSON())}l.setProperty(e,this.getItemsCollectionPropertyName(),i)}return l.setProperty(e,"bleed",this.bleed,!1),e},e.prototype.getItemCount=function(){return this._items.length},e.prototype.getItemAt=function(t){return this._items[t]},e.prototype.getFirstVisibleRenderedItem=function(){if(this.renderedElement&&this._renderedItems&&this._renderedItems.length>0)for(var t=0,e=this._renderedItems;t<e.length;t++){var i=e[t];if(i.isVisible)return i}return null},e.prototype.getLastVisibleRenderedItem=function(){if(this.renderedElement&&this._renderedItems&&this._renderedItems.length>0)for(var t=this._renderedItems.length-1;t>=0;t--)if(this._renderedItems[t].isVisible)return this._renderedItems[t];return null},e.prototype.getJsonTypeName=function(){return"Container"},e.prototype.isFirstElement=function(t){for(var e=this.isDesignMode(),i=0;i<this._items.length;i++)if(this._items[i].isVisible||e)return this._items[i]==t;return!1},e.prototype.isLastElement=function(t){for(var e=this.isDesignMode(),i=this._items.length-1;i>=0;i--)if(this._items[i].isVisible||e)return this._items[i]==t;return!1},e.prototype.isRtl=function(){if(null!=this.rtl)return this.rtl;var t=this.getParentContainer();return!!t&&t.isRtl()},e.prototype.isBleedingAtTop=function(){var t=this.getFirstVisibleRenderedItem();return this.isBleeding()||!!t&&t.isBleedingAtTop()},e.prototype.isBleedingAtBottom=function(){var t=this.getLastVisibleRenderedItem();return this.isBleeding()||!!t&&(t.isBleedingAtBottom()&&t.getEffectiveStyle()==this.getEffectiveStyle())},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this.setShouldFallback(!1),this._items=[],this._renderedItems=[],this.backgroundImage.reset();var n=e.backgroundImage;if(n&&("string"==typeof n?(this.backgroundImage.url=n,this.backgroundImage.fillMode=s.FillMode.Cover):"object"==typeof n&&this.backgroundImage.parse(n,i)),this.verticalContentAlignment=l.getEnumValue(s.VerticalAlignment,e.verticalContentAlignment,this.verticalContentAlignment),null!=e[this.getItemsCollectionPropertyName()]){var r=e[this.getItemsCollectionPropertyName()];this.clear();for(var o=0;o<r.length;o++){var a=g(this,r[o],!this.isDesignMode(),i);a&&this.insertItemAt(a,-1,!0)}}this.bleed=l.getBoolValue(e.bleed,this.bleed)},e.prototype.indexOf=function(t){return this._items.indexOf(t)},e.prototype.addItem=function(t){this.insertItemAt(t,-1,!1)},e.prototype.insertItemBefore=function(t,e){this.insertItemAt(t,this._items.indexOf(e),!1)},e.prototype.insertItemAfter=function(t,e){this.insertItemAt(t,this._items.indexOf(e)+1,!1)},e.prototype.removeItem=function(t){var e=this._items.indexOf(t);return e>=0&&(this._items.splice(e,1),t.setParent(null),this.updateLayout(),!0)},e.prototype.clear=function(){this._items=[]},e.prototype.getResourceInformation=function(){var e=t.prototype.getResourceInformation.call(this);return this.backgroundImage.isValid()&&e.push({url:this.backgroundImage.url,mimeType:"image"}),e},e.prototype.getActionById=function(e){var i=t.prototype.getActionById.call(this,e);if(!i&&(this.selectAction&&(i=this.selectAction.getActionById(e)),!i))for(var n=0;n<this._items.length&&!(i=this._items[n].getActionById(e));n++);return i},Object.defineProperty(e.prototype,"padding",{get:function(){return this.getPadding()},set:function(t){this.setPadding(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"selectAction",{get:function(){return this.getSelectAction()},set:function(t){this.setSelectAction(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"bleed",{get:function(){return this.getBleed()},set:function(t){this.setBleed(t)},enumerable:!0,configurable:!0}),e}(Q);e.Container=et;var it=function(t){function e(e){void 0===e&&(e="auto");var i=t.call(this)||this;return i._computedWeight=0,i.width="auto",i.width=e,i}return r(e,t),e.prototype.adjustRenderedElementSize=function(t){if(this.isDesignMode()?(t.style.minWidth="20px",t.style.minHeight=(this.minPixelHeight?Math.max(this.minPixelHeight,20):20)+"px"):(t.style.minWidth="0",this.minPixelHeight&&(t.style.minHeight=this.minPixelHeight+"px")),"auto"===this.width)t.style.flex="0 1 auto";else if("stretch"===this.width)t.style.flex="1 1 50px";else{var e=this.width;e.unit==s.SizeUnit.Pixel?(t.style.flex="0 0 auto",t.style.width=e.physicalSize+"px"):t.style.flex="1 1 "+(this._computedWeight>0?this._computedWeight:e.physicalSize)+"%"}},Object.defineProperty(e.prototype,"separatorOrientation",{get:function(){return s.Orientation.Vertical},enumerable:!0,configurable:!0}),e.prototype.getJsonTypeName=function(){return"Column"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return this.width instanceof a.SizeAndUnit?this.width.unit==s.SizeUnit.Pixel?l.setProperty(e,"width",this.width.physicalSize+"px"):l.setProperty(e,"width",this.width.physicalSize):l.setProperty(e,"width",this.width),e},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i);var n=e.width;if(void 0===n&&void 0!==(n=e.size)&&lt({error:s.ValidationError.Deprecated,message:'The "Column.size" property is deprecated and will be removed. Use the "Column.width" property instead.'},i),n){var r=!1;try{this.width=a.SizeAndUnit.parse(n)}catch(t){"string"!=typeof n||"auto"!==n&&"stretch"!==n?r=!0:this.width=n}r&&lt({error:s.ValidationError.InvalidPropertyValue,message:"Invalid column width:"+n+' - defaulting to "auto"'},i)}},Object.defineProperty(e.prototype,"hasVisibleSeparator",{get:function(){return!!(this.parent&&this.parent instanceof nt)&&(this.separatorElement&&!this.parent.isLeftMostElement(this))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isStandalone",{get:function(){return!1},enumerable:!0,configurable:!0}),e}(et);e.Column=it;var nt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._columns=[],e}return r(e,t),e.prototype.createColumnInstance=function(t,e){return d(this,t,[],!this.isDesignMode(),function(t){return t&&"Column"!==t?null:new it},function(t,e){return e==o.UnknownType?{error:s.ValidationError.UnknownElementType,message:"Unknown element type: "+t+". Fallback will be used if present."}:{error:s.ValidationError.ElementTypeNotAllowed,message:"Element type "+t+" isn't allowed in a ColumnSet."}},e)},e.prototype.internalRender=function(){if(this._renderedColumns=[],this._columns.length>0){var t=this.hostConfig,e=document.createElement("div");switch(e.className=t.makeCssClassName("ac-columnSet"),e.style.display="flex",dt.useAdvancedCardBottomTruncation&&(e.style.minHeight="-webkit-min-content"),this.horizontalAlignment){case s.HorizontalAlignment.Center:e.style.justifyContent="center";break;case s.HorizontalAlignment.Right:e.style.justifyContent="flex-end";break;default:e.style.justifyContent="flex-start"}for(var i=0,n=0,r=this._columns;n<r.length;n++){(p=r[n]).width instanceof a.SizeAndUnit&&p.width.unit==s.SizeUnit.Weight&&(i+=p.width.physicalSize)}for(var o=0,u=this._columns;o<u.length;o++){var p;if((p=u[o]).width instanceof a.SizeAndUnit&&p.width.unit==s.SizeUnit.Weight&&i>0){var c=100/i*p.width.physicalSize;p._computedWeight=c}var h=p.render();h&&(this._renderedColumns.length>0&&p.separatorElement&&(p.separatorElement.style.flex="0 0 auto",l.appendChild(e,p.separatorElement)),l.appendChild(e,h),this._renderedColumns.push(p))}return this._renderedColumns.length>0?e:null}return null},e.prototype.truncateOverflow=function(t){for(var e=0,i=this._columns;e<i.length;e++){i[e].handleOverflow(t)}return!0},e.prototype.undoOverflowTruncation=function(){for(var t=0,e=this._columns;t<e.length;t++){e[t].resetOverflow()}},Object.defineProperty(e.prototype,"isSelectable",{get:function(){return!0},enumerable:!0,configurable:!0}),e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);if(this._columns.length>0){for(var i=[],n=0,r=this._columns;n<r.length;n++){var o=r[n];i.push(o.toJSON())}l.setProperty(e,"columns",i)}return l.setProperty(e,"bleed",this.bleed,!1),e},e.prototype.isFirstElement=function(t){for(var e=0;e<this._columns.length;e++)if(this._columns[e].isVisible)return this._columns[e]==t;return!1},e.prototype.isBleedingAtTop=function(){if(this.isBleeding())return!0;if(this._renderedColumns&&this._renderedColumns.length>0)for(var t=0,e=this._columns;t<e.length;t++){if(e[t].isBleedingAtTop())return!0}return!1},e.prototype.isBleedingAtBottom=function(){if(this.isBleeding())return!0;if(this._renderedColumns&&this._renderedColumns.length>0)for(var t=0,e=this._columns;t<e.length;t++){if(e[t].isBleedingAtBottom())return!0}return!1},e.prototype.getCount=function(){return this._columns.length},e.prototype.getItemCount=function(){return this.getCount()},e.prototype.getFirstVisibleRenderedItem=function(){return this.renderedElement&&this._renderedColumns&&this._renderedColumns.length>0?this._renderedColumns[0]:null},e.prototype.getLastVisibleRenderedItem=function(){return this.renderedElement&&this._renderedColumns&&this._renderedColumns.length>0?this._renderedColumns[this._renderedColumns.length-1]:null},e.prototype.getColumnAt=function(t){return this._columns[t]},e.prototype.getItemAt=function(t){return this.getColumnAt(t)},e.prototype.getJsonTypeName=function(){return"ColumnSet"},e.prototype.parse=function(e,i){if(t.prototype.parse.call(this,e,i),null!=e.columns){var n=e.columns;this._columns=[];for(var r=0;r<n.length;r++){var o=this.createColumnInstance(n[r],i);this._columns.push(o)}}this.bleed=l.getBoolValue(e.bleed,this.bleed)},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e);for(var i=0,n=0,r=0,o=this._columns;r<o.length;r++){var a=o[r];"number"==typeof a.width?i++:"stretch"===a.width&&n++}i>0&&n>0&&e.addFailure(this,{error:s.ValidationError.Hint,message:"It is not recommended to use weighted and stretched columns in the same ColumnSet, because in such a situation stretched columns will always get the minimum amount of space."})},e.prototype.addColumn=function(t){if(t.parent)throw new Error("This column already belongs to another ColumnSet.");this._columns.push(t),t.setParent(this)},e.prototype.removeItem=function(t){if(t instanceof it){var e=this._columns.indexOf(t);if(e>=0)return this._columns.splice(e,1),t.setParent(null),this.updateLayout(),!0}return!1},e.prototype.indexOf=function(t){return t instanceof it?this._columns.indexOf(t):-1},e.prototype.isLeftMostElement=function(t){return 0==this._columns.indexOf(t)},e.prototype.isRightMostElement=function(t){return this._columns.indexOf(t)==this._columns.length-1},e.prototype.isTopElement=function(t){return this._columns.indexOf(t)>=0},e.prototype.isBottomElement=function(t){return this._columns.indexOf(t)>=0},e.prototype.getActionById=function(t){for(var e=null,i=0;i<this._columns.length&&!(e=this._columns[i].getActionById(t));i++);return e},Object.defineProperty(e.prototype,"bleed",{get:function(){return this.getBleed()},set:function(t){this.setBleed(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"padding",{get:function(){return this.getPadding()},set:function(t){this.setPadding(t)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"selectAction",{get:function(){return this.getSelectAction()},set:function(t){this.setSelectAction(t)},enumerable:!0,configurable:!0}),e}(Q);function rt(t){var e=t.getRootElement(),i=e&&e.onImageLoaded?e.onImageLoaded:dt.onImageLoaded;i&&i(t)}function ot(t,e){var i=t.getRootElement(),n=i&&i.onAnchorClicked?i.onAnchorClicked:dt.onAnchorClicked;return null!=n&&n(t,e)}function st(t,e){var i=t.parent.getRootElement(),n=i&&i.onInlineCardExpanded?i.onInlineCardExpanded:dt.onInlineCardExpanded;n&&n(t,e)}function at(t,e){void 0===e&&(e=!0);var i=t.getRootElement();e&&i.updateLayout();var n=i,r=n&&n.onElementVisibilityChanged?n.onElementVisibilityChanged:dt.onElementVisibilityChanged;null!=r&&r(t)}function lt(t,e){e&&e.push(t),null!=dt.onParseError&&dt.onParseError(t)}e.ColumnSet=nt;var ut=function(t){function e(){var e=t.call(this)||this;return e._actionCollection=new Z(e),e}return r(e,t),e.prototype.internalRender=function(){var e=t.prototype.internalRender.call(this),i=this._actionCollection.render(this.hostConfig.actions.actionsOrientation,!1);return i&&(l.appendChild(e,l.renderSeparation(this.hostConfig,{spacing:this.hostConfig.getEffectiveSpacing(this.hostConfig.actions.spacing),lineThickness:null,lineColor:null},s.Orientation.Horizontal)),l.appendChild(e,i)),this.renderIfEmpty?e:e.children.length>0?e:null},e.prototype.getHasExpandedAction=function(){return 0!=this.renderedActionCount&&(1==this.renderedActionCount?null!=this._actionCollection.expandedAction&&!this.hostConfig.actions.preExpandSingleShowCardAction:null!=this._actionCollection.expandedAction)},Object.defineProperty(e.prototype,"renderedActionCount",{get:function(){return this._actionCollection.renderedActionCount},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"renderIfEmpty",{get:function(){return!1},enumerable:!0,configurable:!0}),e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"actions",this._actionCollection.toJSON()),e},e.prototype.getActionCount=function(){return this._actionCollection.items.length},e.prototype.getActionAt=function(e){if(e>=0&&e<this.getActionCount())return this._actionCollection.items[e];t.prototype.getActionAt.call(this,e)},e.prototype.getActionById=function(e){var i=this._actionCollection.getActionById(e);return i||t.prototype.getActionById.call(this,e)},e.prototype.parse=function(e,i){t.prototype.parse.call(this,e,i),this._actionCollection.parse(e.actions,i)},e.prototype.internalValidateProperties=function(e){t.prototype.internalValidateProperties.call(this,e),this._actionCollection&&this._actionCollection.validateProperties(e)},e.prototype.isLastElement=function(e){return t.prototype.isLastElement.call(this,e)&&0==this._actionCollection.items.length},e.prototype.addAction=function(t){this._actionCollection.addAction(t)},e.prototype.clear=function(){t.prototype.clear.call(this),this._actionCollection.clear()},e.prototype.getAllInputs=function(){return t.prototype.getAllInputs.call(this).concat(this._actionCollection.getAllInputs())},e.prototype.getResourceInformation=function(){return t.prototype.getResourceInformation.call(this).concat(this._actionCollection.getResourceInformation())},e.prototype.isBleedingAtBottom=function(){return 0==this._actionCollection.renderedActionCount?t.prototype.isBleedingAtBottom.call(this):1==this._actionCollection.items.length?null!=this._actionCollection.expandedAction&&!this.hostConfig.actions.preExpandSingleShowCardAction:null!=this._actionCollection.expandedAction},Object.defineProperty(e.prototype,"isStandalone",{get:function(){return!1},enumerable:!0,configurable:!0}),e}(et);e.ContainerWithActions=ut;var pt=function(){function t(){this._items=[],this.reset()}return t.prototype.findTypeRegistration=function(t){for(var e=0;e<this._items.length;e++)if(this._items[e].typeName===t)return this._items[e];return null},t.prototype.clear=function(){this._items=[]},t.prototype.registerType=function(t,e){var i=this.findTypeRegistration(t);null!=i?i.createInstance=e:(i={typeName:t,createInstance:e},this._items.push(i))},t.prototype.unregisterType=function(t){for(var e=0;e<this._items.length;e++)if(this._items[e].typeName===t)return void this._items.splice(e,1)},t.prototype.createInstance=function(t){var e=this.findTypeRegistration(t);return e?e.createInstance():null},t.prototype.getItemCount=function(){return this._items.length},t.prototype.getItemAt=function(t){return this._items[t]},t}();e.TypeRegistry=pt;var ct=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.reset=function(){this.clear(),this.registerType("Container",function(){return new et}),this.registerType("TextBlock",function(){return new _}),this.registerType("RichTextBlock",function(){return new A}),this.registerType("TextRun",function(){return new x}),this.registerType("Image",function(){return new T}),this.registerType("ImageSet",function(){return new O}),this.registerType("Media",function(){return new V}),this.registerType("FactSet",function(){return new I}),this.registerType("ColumnSet",function(){return new nt}),this.registerType("ActionSet",function(){return new K}),this.registerType("Input.Text",function(){return new D}),this.registerType("Input.Date",function(){return new R}),this.registerType("Input.Time",function(){return new j}),this.registerType("Input.Number",function(){return new L}),this.registerType("Input.ChoiceSet",function(){return new B}),this.registerType("Input.Toggle",function(){return new F})},e}(pt);e.ElementTypeRegistry=ct;var ht=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.reset=function(){this.clear(),this.registerType(q.JsonTypeName,function(){return new q}),this.registerType(U.JsonTypeName,function(){return new U}),this.registerType(Y.JsonTypeName,function(){return new Y}),this.registerType(G.JsonTypeName,function(){return new G})},e}(pt);e.ActionTypeRegistry=ht;var dt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._cardTypeName="AdaptiveCard",e._fallbackCard=null,e.onAnchorClicked=null,e.onExecuteAction=null,e.onElementVisibilityChanged=null,e.onImageLoaded=null,e.onInlineCardExpanded=null,e.onInputValueChanged=null,e.onParseElement=null,e.onParseAction=null,e.version=new u.Version(1,0),e.designMode=!1,e}return r(e,t),Object.defineProperty(e,"processMarkdown",{get:function(){throw new Error("The processMarkdown event has been removed. Please update your code and set onProcessMarkdown instead.")},set:function(t){throw new Error("The processMarkdown event has been removed. Please update your code and set onProcessMarkdown instead.")},enumerable:!0,configurable:!0}),e.applyMarkdown=function(t){var i={didProcess:!1};return e.onProcessMarkdown?e.onProcessMarkdown(t,i):window.markdownit?(i.outputHtml=window.markdownit().render(t),i.didProcess=!0):console.warn("Markdown processing isn't enabled. Please see https://www.npmjs.com/package/adaptivecards#supporting-markdown"),i},e.prototype.isVersionSupported=function(){return!!this.bypassVersionCheck||!(!this.version||!this.version.isValid||e.currentVersion.major<this.version.major||e.currentVersion.major==this.version.major&&e.currentVersion.minor<this.version.minor)},e.prototype.getItemsCollectionPropertyName=function(){return"body"},e.prototype.internalRender=function(){var i=t.prototype.internalRender.call(this);return e.useAdvancedCardBottomTruncation&&(i.style.minHeight=null),i},e.prototype.getHasBackground=function(){return!0},e.prototype.getDefaultPadding=function(){return new a.PaddingDefinition(s.Spacing.Padding,s.Spacing.Padding,s.Spacing.Padding,s.Spacing.Padding)},Object.defineProperty(e.prototype,"renderIfEmpty",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"bypassVersionCheck",{get:function(){return!1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"allowCustomStyle",{get:function(){return this.hostConfig.adaptiveCard&&this.hostConfig.adaptiveCard.allowCustomStyle},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"hasBackground",{get:function(){return!0},enumerable:!0,configurable:!0}),e.prototype.getJsonTypeName=function(){return"AdaptiveCard"},e.prototype.toJSON=function(){var e=t.prototype.toJSON.call(this);return l.setProperty(e,"$schema","http://adaptivecards.io/schemas/adaptive-card.json"),!this.bypassVersionCheck&&this.version&&l.setProperty(e,"version",this.version.toString()),l.setProperty(e,"fallbackText",this.fallbackText),l.setProperty(e,"lang",this.lang),l.setProperty(e,"speak",this.speak),e},e.prototype.internalValidateProperties=function(i){t.prototype.internalValidateProperties.call(this,i),"AdaptiveCard"!=this._cardTypeName&&i.addFailure(this,{error:s.ValidationError.MissingCardType,message:'Invalid or missing card type. Make sure the card\'s type property is set to "AdaptiveCard".'}),this.bypassVersionCheck||this.version?this.isVersionSupported()||i.addFailure(this,{error:s.ValidationError.UnsupportedCardVersion,message:"The specified card version ("+this.version+") is not supported. The maximum supported card version is "+e.currentVersion}):i.addFailure(this,{error:s.ValidationError.PropertyCantBeNull,message:"The version property must be specified."})},e.prototype.parse=function(i,n){this._fallbackCard=null,this._cardTypeName=l.getStringValue(i.type),this.speak=l.getStringValue(i.speak);var r=l.getStringValue(i.lang);if(r&&"string"==typeof r)try{this.lang=r}catch(t){lt({error:s.ValidationError.InvalidPropertyValue,message:t.message},n)}this.version=u.Version.parse(i.version,n),this.fallbackText=l.getStringValue(i.fallbackText);var o=g(null,i.fallback,!this.isDesignMode(),n);o&&(this._fallbackCard=new e,this._fallbackCard.addItem(o)),t.prototype.parse.call(this,i,n)},e.prototype.render=function(e){var i;return this.shouldFallback()&&this._fallbackCard?(this._fallbackCard.hostConfig=this.hostConfig,i=this._fallbackCard.render()):(i=t.prototype.render.call(this))&&(i.classList.add(this.hostConfig.makeCssClassName("ac-adaptiveCard")),i.tabIndex=0,l.isNullOrEmpty(this.speak)||i.setAttribute("aria-label",this.speak)),e&&(e.appendChild(i),this.updateLayout()),i},e.prototype.updateLayout=function(i){if(void 0===i&&(i=!0),t.prototype.updateLayout.call(this,i),e.useAdvancedCardBottomTruncation&&this.isRendered()){var n=this.renderedElement,r=this.hostConfig.getEffectiveSpacing(s.Spacing.Default);this.handleOverflow(n.offsetHeight-r)}},e.prototype.shouldFallback=function(){return t.prototype.shouldFallback.call(this)||!this.isVersionSupported()},Object.defineProperty(e.prototype,"hasVisibleSeparator",{get:function(){return!1},enumerable:!0,configurable:!0}),e.currentVersion=new u.Version(1,2),e.useAdvancedTextBlockTruncation=!0,e.useAdvancedCardBottomTruncation=!1,e.useMarkdownInRadioButtonAndCheckbox=!0,e.allowMarkForTextHighlighting=!1,e.alwaysBleedSeparators=!1,e.enableFullJsonRoundTrip=!1,e.useBuiltInInputValidation=!0,e.displayInputValidationErrors=!0,e.elementTypeRegistry=new ct,e.actionTypeRegistry=new ht,e.onAnchorClicked=null,e.onExecuteAction=null,e.onElementVisibilityChanged=null,e.onImageLoaded=null,e.onInlineCardExpanded=null,e.onInputValueChanged=null,e.onParseElement=null,e.onParseAction=null,e.onParseError=null,e.onProcessMarkdown=null,e}(ut);e.AdaptiveCard=dt;var ft=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.suppressStyle=!1,e}return r(e,t),e.prototype.getDefaultPadding=function(){return new a.PaddingDefinition(this.suppressStyle?s.Spacing.None:s.Spacing.Padding,s.Spacing.Padding,this.suppressStyle?s.Spacing.None:s.Spacing.Padding,s.Spacing.Padding)},Object.defineProperty(e.prototype,"bypassVersionCheck",{get:function(){return!0},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"defaultStyle",{get:function(){return this.suppressStyle?s.ContainerStyle.Default:this.hostConfig.actions.showCard.style?this.hostConfig.actions.showCard.style:s.ContainerStyle.Emphasis},enumerable:!0,configurable:!0}),e.prototype.render=function(e){var i=t.prototype.render.call(this,e);return i.setAttribute("aria-live","polite"),i.removeAttribute("tabindex"),i},e.prototype.getForbiddenActionTypes=function(){return[Y]},e}(dt),gt=new u.HostConfig({supportsInteractivity:!0,spacing:{small:10,default:20,medium:30,large:40,extraLarge:50,padding:20},separator:{lineThickness:1,lineColor:"#EEEEEE"},fontTypes:{default:{fontFamily:"'Segoe UI', Tahoma, Geneva, Verdana, sans-serif",fontSizes:{small:12,default:14,medium:17,large:21,extraLarge:26},fontWeights:{lighter:200,default:400,bolder:600}},monospace:{fontFamily:"'Courier New', Courier, monospace",fontSizes:{small:12,default:14,medium:17,large:21,extraLarge:26},fontWeights:{lighter:200,default:400,bolder:600}}},imageSizes:{small:40,medium:80,large:160},containerStyles:{default:{backgroundColor:"#FFFFFF",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#54a254",subtle:"#DD54a254"},warning:{default:"#e69500",subtle:"#DDe69500"}}},emphasis:{backgroundColor:"#08000000",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#54a254",subtle:"#DD54a254"},warning:{default:"#e69500",subtle:"#DDe69500"}}},accent:{backgroundColor:"#C7DEF9",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#54a254",subtle:"#DD54a254"},warning:{default:"#e69500",subtle:"#DDe69500"}}},good:{backgroundColor:"#CCFFCC",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#54a254",subtle:"#DD54a254"},warning:{default:"#e69500",subtle:"#DDe69500"}}},attention:{backgroundColor:"#FFC5B2",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#54a254",subtle:"#DD54a254"},warning:{default:"#e69500",subtle:"#DDe69500"}}},warning:{backgroundColor:"#FFE2B2",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#54a254",subtle:"#DD54a254"},warning:{default:"#e69500",subtle:"#DDe69500"}}}},actions:{maxActions:5,spacing:s.Spacing.Default,buttonSpacing:10,showCard:{actionMode:s.ShowCardActionMode.Inline,inlineTopMargin:16},actionsOrientation:s.Orientation.Horizontal,actionAlignment:s.ActionAlignment.Left},adaptiveCard:{allowCustomStyle:!1},imageSet:{imageSize:s.Size.Medium,maxImageHeight:100},factSet:{title:{color:s.TextColor.Default,size:s.TextSize.Default,isSubtle:!1,weight:s.TextWeight.Bolder,wrap:!0,maxWidth:150},value:{color:s.TextColor.Default,size:s.TextSize.Default,isSubtle:!1,weight:s.TextWeight.Default,wrap:!0},spacing:10}})},function(t,e,i){"use strict";var n,r=this&&this.__extends||(n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i])})(t,e)},function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)});Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(t){this._regularExpression=t}return t.prototype.format=function(t,e){for(var i,n=e;null!=(i=this._regularExpression.exec(e));)n=n.replace(i[0],this.internalFormat(t,i));return n},t}(),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.internalFormat=function(t,e){var i=new Date(Date.parse(e[1])),n=null!=e[2]?e[2].toLowerCase():"compact";return"compact"!=n?i.toLocaleDateString(t,{day:"numeric",weekday:n,month:n,year:"numeric"}):i.toLocaleDateString()},e}(o),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.prototype.internalFormat=function(t,e){return new Date(Date.parse(e[1])).toLocaleTimeString(t,{hour:"numeric",minute:"2-digit"})},e}(o);e.formatText=function(t,e){for(var i=[new s(/\{{2}DATE\((\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:Z|(?:(?:-|\+)\d{2}:\d{2})))(?:, ?(COMPACT|LONG|SHORT))?\)\}{2}/g),new a(/\{{2}TIME\((\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:Z|(?:(?:-|\+)\d{2}:\d{2})))\)\}{2}/g)],n=e,r=0;r<i.length;r++)n=i[r].format(t,n);return n}}])});
//# sourceMappingURL=adaptivecards.min.js.map